Vyatta is a great free firewall/routing solution. As of version 5 (I’m specifically using 5.0.2), OpenVPN support was added. OpenVPN is a much better alternative than any of the L2TP/IPSec VPN solutions out there, and with just a little problem solving, I was able to get a Client-Server (aka road-warrior) vpn set up.
In Part1, I explained how to get the certificates and keys generated. Part2 explained how to set up OpenVPN within Vyatta. Part3 explains how to set up the client on Windows.
I went the easy route of downloading the latest OpenVPN 2.1 release candidate which included the latest OpenVPN GUI. Make sure to download 2.1 as apparently Vyatta’s implementation doesn’t support 2.0.
Some documents I read online said to download the latest version from the OpenVPN GUI site, but I found the TUN install to fail on Vista. Apparently the latest Vista SP recognizes the tun0801.sys driver as incompatible and will not start the virtual device. The 2.1 release candidate from the OpenVPN site includes the newer tun0901.sys driver, which installs in Vista x86 & x64.
Proceed with a standard install. Read each installable’s description to determine the need for install. I personally did not install the service component as I would always be initiating the connection.
At this point, the client is ready to connect, but we need to tell it where and how. In Part1 I explained how to create keys for the client. At this point, we need those keys locally. The way I retrieved them from the Vyatta server was enabling SSH on Vyatta and using WinSCP. The required files are ca.crt, clientname.crt, and clientname.key. (where clientname is the name given during Part1)
As the VPN documentation from Vyatta says, create an .ovpn file and make the contents the following.
dev tun
client
remote 12.34.56.78
ca ca.crt
cert clientname.crt
key clientname.key
Place this file in the OpenVPN’s config folder (typically c:\program files\openvpn\config). If the crt and key files are not in the config folder as well, make sure to put full paths to the files and use double backslashes since a backslash is a control character.
At this point, OpenVPN GUI should see the config and allow you to connect.
Additional Note for Vista: OpenVPN GUI must be launched as Administrator (which can be set as a property of the .exe if desired) in order to have permissions to set routes.
Hope this helps.
If you wish to review either of the previous blogs about setting up Vyatta’s OpenVPN or the easy-rsa keys/certs, read Part1 and Part2.