NordVPN and buggy Network Manager ovpn import
I’m not a fan of Network Manager but it seems to be rather pervasive, I’m using Ubuntu. It’s not very good at importing openvpn .ovpn configuration files if the certificates are embedded. It asks for a CA .pem file but there are none as it’s embedded in the .ovpn file so you need to do a little work to get around Network Managers inadequacies.
To get it to work with NordVPN ovpn files where the import wants a CA .pem file requires a few steps.
- Download the OpenVPN config files from NordVPN.
- Download ovpnsplit from https://github.com/dolanor/ovpnsplit and stick it somewhere on your PATH.
- Unpack the NordVPN config zip file. The latest zip contains a couple of directories ovpn_tcp and ovpn_udp.
- Open a terminal and cd to the unpacked directory of choice, for this example ovpn_tcp. There should be a load of .ovpn files there.
- Run opvnsplit theovpnfile.ovpn to split a single file or run: find . -name “*.ovpn” -exec ovpnsplit {} \; to split them all.
- Open Network Manager and follow: Edit Connections->Add->Import a saved VPN Configuration->Create
- Locate the directory with your recently split ovpn files. ovpnsplit has created <original file>.new.ovpn along with <original file>.ca.pem and <original file>.tls-auth.ovpn. Select one of the .new.ovpn files.
- Enter your credentials you would normally use for NordVPN.
- Network Manager should have pre-filled the CA Certificate, but it may not have gone far enough so click on the Advanced button, then the TLS Authentication tab and make sure Key Direction is set to 1.
- Click OK, then Save to save the configuration. That’s it!
Choose your new configuration and it should connect.