Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I'm going to connecting two LAN's in some way, I imagine some form of VPN tunnel between the gateway/router on each side. Both routers have Ubuntu-server 10.04 installed, but the only vpn-like experience I have is setting on-demand TCP-port forwarding with ssh, but I want this to work for windows clients as well.

The two networks are only connected through an Internet connection, and I don't want my private traffic exposed (traffic like samba).

So how can I do this?

share|improve this question
    
This question does not seem to make sense. You say both ends are routers, so assuming you set the routes correctly, and the routers are gateways, what is the question? –  txwikinger Aug 17 '10 at 17:13
    
I understand that he wants to setup a VPN between two LANs connected only by internet to keep his traffic encrypted. Then his first choice should be to check if the routers can do it themselves. It will be way more transparent (and convenient) than using a computer. –  Javier Rivera Aug 17 '10 at 17:29
    
@txwikinger Hope that clarified it a little. –  Source Lab Aug 17 '10 at 17:37
    
@Javier Rivera, "Both routers have Ubuntu-server 10.04 installed." –  Source Lab Aug 17 '10 at 17:38
    
@Javire Rivera: I think he tries to say the Ubuntu servers are the routers. –  txwikinger Aug 17 '10 at 17:50
show 2 more comments

2 Answers 2

up vote 1 down vote accepted

While we have VPNs at work we usually use cisco tech to build them (although we use linux machines to do some advanced routing before it hits the real routers). So I have no experience using OpenVPN, but a quick google search gives some quite straight forward tutorials. I liked this one.

share|improve this answer
add comment

A VPN is a virtual private network. By definition that makes you traffic protected. It works by encrypting the packets when they are sent over the public network between the gateways.

Therefore, you don't need to be concerned about your traffic. It is protected when going through the tunnel.

If you want to prevent certain traffic to even cross over the tunnel, you can do this by setting up a firewall (or setting the iptables in the appropriate way) such that this particular traffic will not be routed through the vpn interface.

You can set this up by using openvpn as provided in the Ubuntu repositories.

I am still not sure if this is what you are looking for, but this is the best I can answer this question as it is at this time.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.