Page 1 of 1

VPN either on selective ports or ouput only

Posted: Thu Jul 31, 2014 8:59 am
by irishbiker
Hi All

I've setup openvpn + PIA on my B and its working great. My question is, I've installed a web cloud server (BarracudaDrive) but of course as soon as I start openvpn all the traffic is routed via tun0 and I then cannot connect to my box remotely.

Is it possible to redirect certain ports to not use tun0 (eg SSH or Port 80) or have the B listen to incoming traffic on eth0?


Thanks In Advance

Paul

Re: VPN either on selective ports or ouput only

Posted: Thu Jul 31, 2014 12:50 pm
by cpc464
Can you give some more detail about what you are trying to achieve?

Re: VPN either on selective ports or ouput only

Posted: Thu Jul 31, 2014 1:53 pm
by irishbiker
Sorry I thought it was clear, my fault. I want to use SSH,cloud server etc etc while my VPN is switched on. Currency all traffic is directed via the VPN (tun0) My question(s) are:

1. Can certain ports be directed to use eth0 instead of tun0 for example Port 80, 22 etc.etc.

2. Is it also possible to have my Pi only use the VPN Tun0 on traffic that is out bound?

Maybe Split tunneling?

Re: VPN either on selective ports or ouput only

Posted: Fri Aug 01, 2014 11:03 am
by cpc464
VPNs are pretty bullet proof. I think you have to be in the VPN or out of it, no splitting. But I don't really know TBH.

Re: VPN either on selective ports or ouput only

Posted: Fri Aug 01, 2014 11:49 am
by ghans
Most servers can be instructed to bind only to a specific
interface while defaulting to all (at least lighttpd and Apache
offer it) - i don't know if BarracudaDrive works similiar.

As for clients , i have no idea. In the worst case you will have
to meddle with iptables.

ghans

Re: VPN either on selective ports or ouput only

Posted: Fri Aug 01, 2014 2:07 pm
by irishbiker
I did come across this - which is basically what I want to do. Its for Centos (RH Distro).

Anyone review and convert the instructions to work Raspbian?

http://www.gigahype.com/setup-split-tun ... g-openvpn/

Re: VPN either on selective ports or ouput only

Posted: Wed Aug 06, 2014 12:00 pm
by irishbiker
Can anyone give me any pointers to get this to work on my Pi?