Re: iptables using MASQUERADE and static IPs
From: Martin Cooper (usenet_at_martinc.me.uk)
Date: 05/30/03
- Previous message: Lars M. Hansen: "Re: ms had me on hold for 4 hours and then just disconected and had to start over."
- In reply to: G. Artim: "iptables using MASQUERADE and static IPs"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Thu, 29 May 2003 23:10:59 +0100
G. Artim wrote:
<snip>
> # setup Masquerqading
> /sbin/iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
Hi,
change the above line to :-
/sbin/iptables -A POSTROUTING -t nat -s 192.168.1.0/24 -o
eth0 -j SNAT --to-source $SRCIP
where $SRCIP is the real fixed IP address to be used for all traffic
to / from your boxes with private IP's. This change will make iptables
only mangle outgoing traffic from your private IP's, so traffic from
any real IP's on your network will pass through unaffected. Of
course, you will also need to block any unwanted traffic to these
machines in the FORWARD chain.
Martin
- Previous message: Lars M. Hansen: "Re: ms had me on hold for 4 hours and then just disconected and had to start over."
- In reply to: G. Artim: "iptables using MASQUERADE and static IPs"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|
|