I have set up an application that listens constantly to a port for network packets, and I would like to create another one that receives the same network packets ( for use as a test bed). Getting the packets sent to 2 different ports on the machine is not an option, so I was wondering if there is a way to set up a "port-mirror". Basically, is there an easy way to make all traffic received on port XXXXX also copy to port XXXXX + 1?
I know there is a similar question here, but I don't quite understand the suggested solution.
Barring that, is there another easy way to simulate network data to test some code with that I am overlooking? Any tips would be appreciated. Thanks!
iptablescommands. What is your kernel version? – Gilles Mar 7 '12 at 0:00uname -rs, I'm on 2.6.32. – SuperTron Mar 7 '12 at 20:23