-   Linux - Networking (
-   -   Using IPTABLES to redirect web traffic to another network. (

slugman92 04-20-2011 05:19 AM

Using IPTABLES to redirect web traffic to another network.
I've got a redhat box (5.2) with two NIC;s installed.

I have it connected to a network. (its a private network [I know is public but its been bought] ) this is on interface eth0

on eth1 i have the network which has a nice internet connection. Deafault gateway =

so eth0 =
and eth1 =

I want to be able to point a computer to use 128.172..101.33 (eth0) as a proxy on port 8080 or somthing.

This server will have to NAT anything coming in on port 8080 on eth0 and redirect it out of eth1 interface so it can destin itself for the internet.

I am a fairly seasoned linux user.

Never been able to grasp IP tables though.

Could someone please just post the commands so i can get this done.

I would like some feedback too on documentation and stuff but i have some but its not sufficent.

thanks in advance


estabroo 04-20-2011 05:41 PM

imho the easiest thing would be to set up a squid proxy on that redhat box that listens on the desired port. It'll take care of all the pain of sending it the right direction without having to do any iptables stuff (unless you want to do a transparent proxy).

All times are GMT -5. The time now is 12:39 PM.