On Sunday 01 June 2008 02:49:22 alexus wrote:
> Hello,
> I'm trying to establish a VPN tunnel over internet, I read a
> http://www.freebsd.org/doc/en/books/handbook/ipsec.html on how to set
> it up, I'm some what strangeling if my setup will work at all.
> i have box #1 that have 1 primary IP, which is private IP but in front
> of my box, I have a device that translate a public IP address into
> private IP, so "technicaly" its a public IP not a private, yet system
> sees it as private, yet my box #2 has interface with real public ip
> and another interface with private ip, i created GIF0 interface, yet i
> can't ping private range on other box.
> box#1
> fxp0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu
> 1500 options=8<VLAN_MTU>
>         ether 00:0f:fe:aa:f4:61
>         inet netmask 0xffffff00 broadcast
>         inet netmask 0xffffffff broadcast
>         media: Ethernet autoselect (100baseTX <full-duplex>)
>         status: active
> mtu 1500 lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu
> 16384 inet6 fe80::1%lo0 prefixlen 64 scopeid 0x3
>         inet6 ::1 prefixlen 128
>         inet netmask 0xff000000
> gif0: flags=8051<UP,POINTOPOINT,RUNNING,MULTICAST> metric 0 mtu 1280
>         tunnel inet -->
>         inet --> netmask 0xffffffff

You said that the router in front of box#1 is willing to NAT
your rfc1918 address to a "public" one. Yet, you seem to have
configured gif0 with your exterior peer address,
which is not your address, but seems like the "public" one.

Example configuration:
box#1 ifconfig fxp0
box#2 ifconfig fxp0

## let's set up the endpoints of tunnel
box#1 ifconfig gif0 tunnel
box#2 ifconfig gif0 tunnel

## let's set up the interior addresses
box#1 ifconfig gif0 netmask
box#2 ifconfig gif0 netmask

You should be able to ping remote peer addresses at this time.
box#1 ping
Set up some routes and it will be fine.

Nevertheless, in case it doesn't be sure that the NAT device:
1) is willing to NAT IPIP
and 2) will do 1:1 NAT

HTH, Nikos
freebsd-questions@freebsd.org mailing list
To unsubscribe, send any mail to "[EMAIL PROTECTED]"

Reply via email to