Licensing Portal

Knowledge Base

Add Sophos SSL VPN client to startup with automatic login

In this article, we’ll show you how to configure the Sophos SSL VPN Client to start immediately after the Windows login and connect automatically to your VPN.

Info: For this guide, we assume that you have already installed the Sophos SSL VPN client on your Windows system. Otherwise the following two instructions can help you:

1. Remove the SSL VPN Client for Windows from startup

When you install the SSL VPN Client, a shortcut is automatically added to the startup. In the process of this manual, however, we now create our own shortcut and can first of all deactivate the existing one.

Removing the Sophos SSL VPN Client from startup
  1. Open the task manager and switch to the tab ‘Startup’.
  2. Find the SSL VPN Client for Windows shortcut and disable it with the right mouse button.

Note: In Windows 10, you can find the startup settings in the task manager. For older Windows versions there is an startup folder.

2. Composing Paths with Parameters

For our own startup shortcut, which we will create later in the registry, we first build a command line with a few parameters. The command line is structured as following:

"[Path-to-openvpn-gui.exe" --config_dir "[Path-to-Open-VPN-config-file]" --connect [Name-of-the-Open-VPN-config-file].ovpn

To create this command line, you need two paths and the name of your Open VPN Config file:

  1. Path to openvpn-gui-exe
    • Für 32 bit Windows - “C:\Program Files\Sophos\Sophos SSL VPN Client\bin\openvpn-gui.exe”
    • Für 64 bit Windows - “C:\Program Files (x86)\Sophos\Sophos SSL VPN Client\bin\openvpn-gui.exe”
  2. Path to Open VPN config file
    • Für 32 bit Windows - “C:\Program Files\Sophos\Sophos SSL VPN Client\config"
    • Für 64 bit Windows - “C:\Program Files (x86)\Sophos\Sophos SSL VPN Client\config"
  3. Name of the Open VPN config file
Path to the Sophos SSL VPN Client file

In our example, our whole command line looks like this:

"C:\Program Files (x86)\Sophos\Sophos SSL VPN Client\bin\openvpn-gui.exe" --config_dir "C:\Program Files (x86)\Sophos\Sophos SSL VPN Client\config\" --connect

3. Create own startup shortcut

If you have created your own command line, you can now define a new startup entry in the registry.

Creating a Sophos SSL VPN Client registry entry for startup
  1. Open the Registry Editor and go to the following path: HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run.
  2. Right-click in the right column and select New > String.
  3. Give the new entry a name (e. g. sophos-ssl-vpn).
  4. Open the file with a double-click and paste your compound command line into the field “Value”.
  5. Click on OK and close the Registry Editor.

5. Login without entering a password

To avoid having to enter the VPN password every time you reboot your computer, follow these steps:

  1. Start the text editor as administrator and open the file “OpenVPNconfigFile”.
  2. Now find the line “auth-user-pass” in the file and change it to “auth-user-pass password. txt”.
  3. Save your changes and create a new text file named “password. txt” in the same folder where the OpenVPNconfigFile is located.
  4. Open the file “password. txt” and just insert your username and password. Note that you must write each entry on a separate line. That will look like this, for example:

  5. Save “password. txt” and restart your computer.

Important: Make sure that the “password. txt” file is really in the same folder as your Open VPN config file. In addition, this method saves your password in plain text. If you are uncomfortable with this, you will have to avoid the comfort of automatic registration.

Was this article helpful?

Yes No

Many Thanks! Is there anything else you want to tell us? Have you seen an error in this article? Your feedback is invaluable to us and helps us improve the quality of our articles.

This is a pity that our article could not help you! Your feedback is invaluable to us. We would be very pleased if you could tell us what we could improve on this article, so that it could be useful to you.

* Any comment left here will be read by us, but we do not respond to specific technical questions.