-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support listening on multiple addresses and connecting at the same time
This change has numerous additional features but comes with breaking changes to arguments. The new usage offers strictly greater capabilities than before. One major new capability is that you can now specify `-l` or `-L` and *also* specify targets to connect to. netcrab will start listening sockets and also start outbound connections. The resulting pool of connections can be brokered or channeled like before. The other major new capability is that you can specify `-l` or `-L` multiple times to listen on more than one local address and port at a time. Another secondary capability is that `-s`, `-l`, and `-L` support any hostname format that can be handled by a DNS lookup, including both numeric addresses and non-numeric hostnames. The `-p` argument to specify the local port number has been removed entirely. Now the local port is specified in two ways: - for outbound connections, it is given by `-s ADDR:PORT` - for listening connections, it is given by `-l ADDR:PORT` or `-L ADDR:PORT` The `ADDR:PORT` syntax also supports `*:PORT` and `*` as options to bind to the wildcard address. The code no longer really treats "listening" and "outbound" as different scenarios. An outbound connection scenario is the same as listening, except no local addresses were chosen to listen on. Likewise, a listening scenario is just one where no outbound connection targets were specified. There are just `do_tcp` and `do_udp` now. Outbound TCP connections now print out the local port they're attempting the connection from.
- Loading branch information
Showing
4 changed files
with
323 additions
and
254 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.