John G. Norman wrote:
Hi.
I'm trying to redirect from one port to another with iptables (destination NAT -- transparent proxying . . . e.g., "destination NAT" in this article: http://www.linux-mag.com/content/view/849/2236/).
I've done this many times before, including on SuSE and various flavors of BSD (with ipfw).
For some reason I can't get it to work on Fedora 3.
I do have ip forwarding on (/proc/sys/net/ipv4/ip_forward shows 1)
The command I am trying to use is:
/sbin/iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j REDIRECT --to-port 8080
I think this should probably by /sbin/iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j DNAT --to-port 8080
I believe that's what works for me...