I'm using netcat -e $prog
, which is fine, but whenever $prog
exits, netcat
hangs up on the original connection. Any thoughts on how to make it disconnect with a clean FIN-ACK? Or why it's not in the first place?
$ nc localhost 2000
*random data that should just cause it to exit cleanly*
read(net): Connection reset by peer
$