LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 11-28-2013, 05:40 PM   #1
AnalBeard
Member
 
Registered: Aug 2010
Distribution: Ubuntu 13.04 Server
Posts: 31

Rep: Reputation: 0
How to force some traffic to use a VPN


Ok, so I've recently started using a VPN provider with an OpenVPN setup for my home server. This introduces complications, in that I run a mailserver etc on it, and once the VPN is active, ddclient advertises the VPN endpoint as my IP, and as port forwarding doesn't exist down the tunnel, no traffic actually gets into the server. This also applies for SSH traffic etc - currently I'm jumping through my Pi to get there externally.

I have an idea as to how I could solve this, but I need to run it past someone who has more knowledge on the situation before I attempt a solution. I know I can force the applications I want to tunnel to use a specific interface, and I know that you can bind OpenVPN to a specific interface, so would it be theoretically possible to bring up a pseudo interface, bind the VPN to that and then make the applications use the pseudo interface? Is this a practical solution? If so, what would I need to do to achieve this? Obviously I'd want any traffic coming in the VPN to then leave via it again, or it will defeat the object.

Thanks in advance!
 
Old 11-29-2013, 01:02 PM   #2
AnalBeard
Member
 
Registered: Aug 2010
Distribution: Ubuntu 13.04 Server
Posts: 31

Original Poster
Rep: Reputation: 0
I should add a little more information to this - both interfaces would be on the same subnet, although in theory it wouldn't be too difficult to change this as my router supports tagging each switch port with individual VLANs, but I'd rather not have to go down this route if I can avoid it.
 
Old 01-17-2014, 05:54 PM   #3
AnalBeard
Member
 
Registered: Aug 2010
Distribution: Ubuntu 13.04 Server
Posts: 31

Original Poster
Rep: Reputation: 0
Can anyone chime in on this?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Force all internet traffic through tun0 (Vpn Interface) dschuett Linux - Security 3 08-10-2011 09:36 AM
Force all internet traffic through tun0 (Vpn Interface) dschuett Linux - Security 2 08-10-2011 01:24 AM
How to use VPN tunnel for all traffic except SMTP (port 25) traffic? maven12 Linux - Networking 2 11-09-2010 07:00 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 04:40 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration