Establishing and disconnecting a VPN connection in Linux
Requirements
- Set up multi-factor authentication and authentication app ons Smartphone or YubiKey
- Configured VPN software
- Fedora users: Note the section Error message when connecting: Manually install Root certificate
1. Selecting connection option, entering access data
Two options are available for establishing a connection:
- Route all traffic through the VPN tunnel by specifying port 8443 when connecting:
f5fpc -s -t vpn.univie.ac.at:8443 -d /etc/ssl/certs/ -u u:account-UserID@ - Only route data traffic to computers in the university’s data network through the VPN tunnel (split tunnel):
f5fpc -s -t vpn.univie.ac.at -d /etc/ssl/certs/ -u u:account-UserID@
In the parameter -u type in your u:account UserID followed by an @ symbol and the one-time password:
- With an authentication app on your smartphone: Open the app and enter the currently valid code immediately after the @ symbol, which is displayed in the app in the ZID Universität Wien account. Then, before the code expires, press Enter.
- With YubiKey: Plug the YubiKey into a USB port on your device and then press the button on the YubiKey. The one-time password is entered automatically at the current position of the cursor (immediately after the @ symbol) and Enter is pressed automatically.
Typing in the directory the certificates are in is not always necessary and can be ignored (Option: -d /etc/ssl/certs/).
Type in your u:account password and click Enter.
The connection should be up and running.
Error message when connecting: Manually installing Root certificate
If you receive the failure notice Server certificate verfication failed, do the following steps:
- Check which folder your distribution uses to store TLS certificates. These are usually located in /etc/ssl/certs (Ubuntu/Debian-like) or /etc/pki/tls/certs (Red Hat-like).
- Adjust the parameter -d accordingly and try again.
If it still does not work, install the root certificate as follows:
Debian-like:
wget https://repo.harica.gr/certs/HARICA-TLS-Root-2021-RSA.pem
sudo mv -f HARICA-TLS-Root-2021-RSA.pem /etc/ssl/certs/
sudo ln -s /etc/ssl/certs/HARICA-TLS-Root-2021-RSA.pem /etc/ssl/certs/9f727ac7.0
Red Hat-like:
wget https://repo.harica.gr/certs/HARICA-TLS-Root-2021-RSA.pem
sudo mv -f HARICA-TLS-Root-2021-RSA.pem /etc/pki/tls/certs/
sudo ln -s /etc/pki/tls/certs/HARICA-TLS-Root-2021-RSA.pem /etc/pki/tls/certs/9f727ac7.0
Repeat the connection establishment.