The mknod creates a FIFO that can use to pass data between the tees and NetCats.
Dears,
I am trying to implement Port redirection using netcat. I have 3 PCs:
"A" from which I run
"B" from which I runCode:nc -vv 192.168.1.2 -p 80
"C" from which I runCode:nc -lvvp 80 | nc -vv 192.168.1.3 -p 5555
The idea is to connect from A to C on the port 5555 (assuming A is behind firewall and only port 80 is opened)Code:nc -lvvp 5555
the flow works correctly, Text from A goes to C, however, text from C doesn't came back to A, but stuck in B.
I have searched and found that this can be solved by adding a second pipe to B as follows:
nc -lvvp 80 | nc -vv 192.168.1.3 -p 5555 | nc -lvv -b -p 80
however, my netcat doesnt contain -b option (on both BT2 & windows binary).
I have searched the forum and found a solutions using backpipe, but really I didn't understood it.
thanks in advance,Code:mknod backpipe p nc -l -p 80 0<backpipe | tee -a inflow | nc localhost 81 | tee -a outflow 1>backpipe
The mknod creates a FIFO that can use to pass data between the tees and NetCats.
Thanks level for the clarification.The mknod creates a FIFO that can use to pass data between the tees and NetCats.
However, I think mknod is a *nix command, which means that it cannot be run on a windows box (I know some will say, this is not a windows forum).
May problem is why the netcat version on BT2.0 doesn't contain the -b option (for broadcasting).
Thanks alot in advance,
mknod is available under the GNUWin32 CoreUtils package:
http://gnuwin32.sourceforge.net/packages/coreutils.htm
I'm a compulsive post editor, you might wanna wait until my post has been online for 5-10 mins before quoting it as it will likely change.
I know I seem harsh in some of my replies. SORRY! But if you're doing something illegal or posting something that seems to be obvious BS I'm going to call you on it.