OpenSwan on Ubuntu 11.10

Openswan lets you set up IPSec VPNs. This guide was created on the Ubuntu 11.10 virtual machine image within Amazon EC2.

Install utilities required for compilation:

apt-get update
apt-get install build-essential libgmp3-dev bison flex

Fetch Openswan:

tar -zxf openswan-2.6.37.tar.gz
cd openswan-2.6.37/

Compile and Install Openswan:

make programs
sudo make install

Install L2TP

sudo apt-get install xl2tpd