Page 1 of 1

IPsec VPN route traffic through vpn issue

Posted: Mon Sep 09, 2013 2:16 am
by thanp
Hi,

I have installed amahi 7 with fedora19.
I installed the application IPsec and everything works fine.
this is the racoon.conf:

mode_cfg {
auth_source system;
save_passwd on;
network4 10.8.1.1;
netmask4 255.255.255.0;
pool_size 10;
dns4 192.168.1.10;
wins4 192.168.1.10;
default_domain "home.com";
auth_throttle 60;
split_network include 192.168.1.0/24, 10.8.1.0/24;
split_dns "home.com";
banner "/etc/racoon/welcome.txt";
}


If i follow the wiki:https://wiki.amahi.org/index.php/IPsec_VPN in order to route all traffic through the ipsec vpn i must have this:

mode_cfg {
auth_source system;
save_passwd on;
network4 10.8.1.1;
netmask4 255.255.255.0;
pool_size 10;
dns4 192.168.1.10;
wins4 192.168.1.10;
default_domain "home.com";
auth_throttle 60;
split_network local_lan 10.8.1.0/24;
split_dns "home.com";
banner "/etc/racoon/welcome.txt";
}

Ok?
But with this configuration i can't connet with vpn.
Can anyone help me with this?

Re: IPsec VPN route traffic through vpn issue

Posted: Wed Sep 18, 2013 11:52 pm
by thanp
Solution for IPSec VPN Server in Fedora 19 with Amahi 7

1. At /etc/racoon/racoon.conf
Delete the 2 lines with split in mode_cfg :
split_network include 192.168.1.0/24, 10.8.1.0/24;
split_dns "home.com";

2. At /etc/racoon/amahi-up-down
I change the lines 19 and 26 from eth0 to em1 because this is the network interface of my hda. I found it running ifconfig in my hda. The changes are
from:
iptables -t nat -A POSTROUTING -s ${INTERNAL_ADDR4}/32 -o eth0 -j MASQUERADE
to
iptables -t nat -A POSTROUTING -s ${INTERNAL_ADDR4}/32 -o em1 -j MASQUERADE

and from:
iptables -t nat -D POSTROUTING -s ${INTERNAL_ADDR4}/32 -o eth0 -j MASQUERADE
to
iptables -t nat -D POSTROUTING -s ${INTERNAL_ADDR4}/32 -o em1 -j MASQUERADE

Finally I go to http://hda->Setup->Settings->Servers and restart the IPsec VPN Server.

Re: IPsec VPN route traffic through vpn issue

Posted: Thu Sep 19, 2013 5:09 am
by bigfoot65
Thanks for adding this to the wiki. For others, it is located below:
https://wiki.amahi.org/index.php/IPsec_VPN