This may come for handy for a admins who prefers openvpn with virtual users, rather having users auth from ldap / pop.
compile auth-pam from openvpn source
cp openvpn-auth-pam.so /etc/openvpn/
download & install pam-pam_pwd
pam for virtual user.
auth required pam_pwdfile.so pwdfile /etc/openvpn/users
account required pam_permit.so
Append following in server.conf
plugin /etc/openvpn/openvpn-auth-pam.so “/etc/pam.d/vuser”
Create virtual users using htpasswd.
htpasswd -c -b /etc/openvpn/users linux tux
This is all needs to be done at server end. at client end append following line in client.conf
if you find any missing point in here, please let us know in comment section or tweet us at @linuxreaders. To get more articles like this, subscribe to our RSS feeds / Mails.