Re: iptables -- trying to redirect, but doesn't work

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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...


-- *Trevor "TeC" Christian* Cell #: (767) 225 4472 IM MSN: trevorc98@xxxxxxxxxxx / trevor@xxxxxxxxxxxxxxxxx YM : trevorc01 AIM: DoubleOTeC ------------------------------------------------------------------------ Curriculum Vitae (PDF) <http://bouyon.dalive.com/cv/curriculum_vitae.pdf> Curriculum Vitae (HTML) <http://bouyon.dalive.com/cv/curriculum_vitae.html>


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux