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

NAT problems


I've got a problem with my network setup that I can't solve.

It looks like IP tables in kernel 2.4 solves it but I dont have the time
(and courage) to do that right now.

My firewall have these NICs:

eth0 is connected to my IP-provider using private ip
eth1 a.x.y.z1/27 is connected to my server segment using "real" ip
eth2 a.x.y.z2/27 is connected to my workstation segment using "real" ip

and now I must add a fourth net:
eth3 ond I want to NAT those adresses when they access
internet (through eth0)

The problem is that when I add the rule for masqurading it translates
all to eth0's before routed to my ip
provider, and that adress is a private one and will not work!

How do I solve this in kernel 2.2?

In kernel 2.4 it looks like it's possible to do something like:

iptables -t nat -A POSTROUTING -i eth3 -j SNAT - -to a.x.y.z1

but 2.4 is not an option right now.


Reply to: