simple port redirect

view full story

http://forums.fedoraforum.org – Hi, I want to do a simple port redirect, i.e. whatever comes trough whatever interface on port AAAA will get redirected to port BBBB I thought that iptables -t nat -I PREROUTING --source 0/0 --destination 0/0 -p tcp --dport AAAA -j REDIRECT --to-ports BBBB however it doesn't work, e.g. nc -v -w2 -z localhost AAAA gives: nc: connect to localhost port AAAA (tcp) failed: Connection refused while nc -v -w2 -z localhost BBBB gives: Connection to localhost BBBB port [....] succeeded! I suspect that I am missing something obvious but what ? :confused: (there is no firewall and net.ipv4.ip_forward=1) Cheers, (HowTos)