port 1194 proto tcp dev tun ca ca.crt cert server.crt key server.key # This file should be kept secret dh dh2048.pem server 10.8.0.0 255.255.255.0 ifconfig-pool-persist ipp.txt push "redirect-gateway def1 bypass-dhcp" keepalive 10 120 tls-auth ta.key 0 # This file is secret cipher AES-256-CBC auth SHA256 user nobody group nogroup persist-key persist-tun status openvpn-status.log log openvpn.log log-append openvpn.log verb 3 explicit-exit-notify 0
client dev tun proto tcp remote example.com 1194 resolv-retry infinite nobind persist-key persist-tun mute-replay-warnings remote-cert-tls server cipher AES-256-CBC auth SHA256 verb 3 ;mute 20 ca [inline] cert [inline] key [inline] tls-auth [inline] 1 <ca> -----BEGIN CERTIFICATE----- -----END CERTIFICATE----- </ca> <cert> -----BEGIN CERTIFICATE----- -----END CERTIFICATE----- </cert> <key> -----BEGIN PRIVATE KEY----- -----END PRIVATE KEY----- </key> <tls-auth> -----BEGIN OpenVPN Static key V1----- -----END OpenVPN Static key V1----- </tls-auth>

Referencias

https://www.digitalocean.com/community/tutorials/how-to-set-up-an-openvpn-server-on-ubuntu-16-04

https://serverfault.com/questions/483941/generate-an-openvpn-profile-for-client-user-to-import