[ale] One to one NAT mapping
tewkewl at mindspring.com
tewkewl at mindspring.com
Wed Mar 7 17:00:58 EST 2001
Does iptables work with kernels less than 2.4?
James Kinney <jkinney at localnetsolutions.com> wrote:
> iptables -t nat -A PREROUTING -d $REALADDRESS -j DNAT --to $INTERNALIP
iptables -t nat -A POSTROUTING -s $INTERNALIP -j SNAT --to $REALADDRESS
The first line will repoint the incoming packets to the actual address
used by the interface. The second will make the leaving packets appear to
have come from the real IP address.
This may be easier to do with ip aliasing. Just have the the real IP
address listed on the NIC and it will also pickup those packets as well as
the ones sent to the private net address.
James P. Kinney III \Changing the mobile computing world/
President and COO \ one Linux user /
Local Net Solutions,LLC \ at a time. /
770-493-8244 \.___________________________./
On Wed, 7 Mar 2001, Bao Ha wrote:
>
> How do I map an external valid ip address to an internal private
> IP address through ipchains? I don't want to use port-forwarding.
>
> I think it should be easier, but can't seem to know how to do it.
>
> Thanks.
> Bao
>
> --
> To unsubscribe: mail majordomo at ale.org with "unsubscribe ale" in message body.
>
--
To unsubscribe: mail majordomo at ale.org with "unsubscribe ale" in message body.
--
To unsubscribe: mail majordomo at ale.org with "unsubscribe ale" in message body.
More information about the Ale
mailing list