I again used the, openvpn has its own . There are, however, several dependencies:
- libssl.so.0.9.8 and libcrypto.so.0.9.8 from
- liblzo2.so.2.0.0 (and symlinks) from
I already had libcrypto installed, so I only needed 713kB of free space.
Setup was fairly straightforward. Just make sure to do all heavy calculations on your desktop computer (i.e. generating keys). I installed the CA and host certificate into /jffs/etc/ssl, and added my openvpn-specific config files into /jffs/etc/openvpn. I did rewrite the verify-cn script from perl to bash, since dd-wrt doesn’t come with perl.
Next, I wrote a very simple wanup script to get openvpn (re)started at the appropriate time:
# openvpn.wanup if [ -e /tmp/openvpn.pid ] ; then kill -HUP `cat /tmp/openvpn.pid` else /jffs/sbin/openvpn --cd /jffs/etc/openvpn --config server.conf --daemon --log /tmp/openvpn.log --writepid /tmp/openvpn.pid fi
Obviously: don’t forget to add the corresponding configuration to the firewall.