This is question is somehow related to https://superuser.com/questions/270698/how-is-it-called-when-listeningconnecting-two-sockets-and-exchanging-data-betw
In the test setup I have three terminal windows open I run in
Term1: "nc -l 55545" Term2: "nc -l 55546" Term3: "socat tcp:localhost:55545 tcp:localhost:55546"
Input to Term1 now appears in Term2 and input to Term2 appears in Term1.
This is the desired behavior. How can I achieve this behavior by only using nc?
When I run in
Term3: "nc localhost 55545 | nc localhost 55546"
then Input to Term1 appears in Term2 but input to Term2 appears in Term3. How can I make the pipe bidirectional? If possible without temporary files.