map xl0 192.168.0.0/24 -> 210.82.47.237/32 portmap tcp/udp auto map xl0 192.168.0.0/24 -> 210.82.47.237/32

map means, when a packet comes OUT of interface 'xl0', change its source IP from 192.168.0.xxx to 210.82.47.237.

From: Octavian Hornoiu <[EMAIL PROTECTED]>
Reply-To: [EMAIL PROTECTED]
To: Shepherd <[EMAIL PROTECTED]>
CC: [EMAIL PROTECTED]
Subject: Re: "no route to host"
Date: Tue, 02 Sep 2003 01:53:41 -0700

If I am not mistaken... you will need to change the second set of
addresses to be just 0/32 and NOT 210.82.47.237/32.  You are doing NAT
to the internet which is signified by 0/32 and not to another network.

octavian

On Tue, 2003-09-02 at 00:54, Shepherd wrote:
> I am on FreeBSD 4.8 with 2 network adaptors:
> ifconfig_fxp0="inet 192.168.0.5 netmask 255.255.255.0"
> ifconfig_xl0="inet 210.82.47.237 netmask 255.255.255.252"
> defaultrouter="210.82.47.238"
>
> fxp0 to switch of my company, and xl0 to ISP.
> When I ping www.google.com, it reports "no route to host" or sometimes "communication prohibited by filter". And at this time I couldn't ssh to this machine.
>
> ipf.rules:
> pass in all
> pass out all
>
> ipnat.rules:
> map fxp0 192.168.0.0/24 -> 210.82.47.237/32 portmap tcp/udp auto
> map fxp0 192.168.0.0/24 -> 210.82.47.237/32
>
> Where am I wrong?
>
> Thanks.
>
> Shepherd
>



_________________________________________________________________
STOP MORE SPAM with the new MSN 8 and get 2 months FREE* http://join.msn.com/?page=features/junkmail




Reply via email to