Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 19 Jan 2005 10:16:57 +0100
From:      "Mattias Nordlund" <mattias.nordlund@bahnhofbredband.net>
To:        <freebsd-newbies@freebsd.org>
Subject:   Freebsd 5.3-stable natd multiple external  ipadress
Message-ID:  <A8F5DD049DA1984189CE0E5818EF48EA151DF3@EXCH-03.bredband.bahnhof.se>

next in thread | raw e-mail | index | archive | help


Hi,
I have a problem .
Freebsd 5.3 Stable
Natd
Ipfw

external interface =3D fxp1
internal interface =3D fxp2

I have three external ipadress on fxp1
81.10.5.2 /29
81.10.5.3=20
81.10.5.4=20

On the fxp2 (internal interface) I have :
192.168.1.0/24
192.168.2.0/24
192.168.3.0/24

I need to route the packets from my internal net to the correct external
ipadress.
Something like:
iptables -t nat -A POSTROUTING -s 192.168.1.0/24 -j SNAT --to 81.10.5.2
iptables -t nat -A POSTROUTING -s 192.168.2.0/24 -j SNAT --to 81.10.5.3
iptables -t nat -A POSTROUTING -s 192.168.3.0/24 -j SNAT --to 81.10.5.4

How can I do that with ipfw and nat ?
Heeelp=20


Regards,
Mattias=20



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?A8F5DD049DA1984189CE0E5818EF48EA151DF3>