-e, --exec=PROGRAM program to exec after connect
実際のところ
受け側
$ nc -l -p 5000 -e "echo 123"
送り側
$ echo yeah! | nc localhost 5000
実行結果
受け側
$ nc -l -p 5000 -e "echo 123" $
送り側
$ echo yeah! | nc localhost 5000 123 read(net): Connection reset by peer