I followed this tutorial to setup a VPN server.
However, then I try to connect with it, it gaves a handshake failure. I tried to see with ngrep if the server was receiving any requests, and it is. So, the problem is somewhere in the client.
I guess that I messed up somewhere in following the tutorial but I don’t know where. I tried to change to TCP and to port 443 and no results.
My client config:
client dev tun proto tcp (tried UDP and TCP and same result) remote <ip> 443 resolv-retry infinite nobind persist-key persist-tun <ca> … </ca> <cert> … </cert> <key> … </key>
My server config:
port 443
proto tcp
dev tun
ca ca.crt
cert server.crt
key server.key # This file should be kept secret
dh 2048.pem
server 10.8.0.0 255.255.255.0
ifconfig-pool-persist ipp.txt
push “redirect-gateway def1 bypass-dhcp”
push “dhcp-option DNS 8.8.8.8”
push “dhcp-option DNS 8.8.4.4”
keepalive 10 120
comp-lzo
user nobody
group nogroup
persist-key
persist-tun
status openvpn-status.log
verb 3
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
There is no tls-auth ta.key 0 # This file is secret line in the config file, both server and client need it, no need for “KEY DIRECTION” line
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.