Custom OpenVPN Installer 10+ (NSIS)

In this tutorial I will show you how to roll your own custom OpenVPN client installer using NSIS. The installer will include the Better OpenVPN GUI Client and is based on OpenVPN 2.4.8 which features the ability to run OpenVPN GUI without administrative privileges. The new OpenVPN GUI features are documented here. Click here for the Vista-8.1 version or here for the older 2.3 XP version.

Note: Customized OpenVPN Installer Source has been updated to version 2.4.8 including the OpenVPN GUI v11.14 client on Mar 17, 2020. This installer will not work on XP. With this release, we have removed the x86 version from the package. Also note that the OpenSSL heartbleed vulnerability does not affect this package as it is a client only install package.

Required software

  • NSIS 3.05 – Nullsoft Scriptable Install System available here.
  • Customized OpenVPN Installer Source and NSIS build scripts available (10+) here.
  • Archived OpenVPN Installer Source and NSIS build scripts available (x86-64) here.

Preparations

  • Download and install NSIS 3.05 (requires full install).
  • Download and extract the OpenVPN-Installer-Source.zip file referred to above.
  • Note: all source files must be in the same directory in order to compile.

Packaging

  • Building the installer package: simply right-click the NSIS script (openvpn.nsi) and chose Compile NSI.
  • openvpn.nsi may be modified using Notepad++ or your favorite text editor to customize your installer.

Modify The Script

How do I include my own openvpn configuration file?

  • Create your own config file and name it as you want the connection named when using the GUI. For example Office.ovpn.
  • Create a config folder inside the openvpn folder.
  • Put Office.ovpn in the openvpn\config folder.
  • Under the OpenVPN GUI section in the NSIS script uncomment the following line: File "${HOME}\config\Office.ovpn"
Did you find this article useful? Why not share it with your friends?

3 thoughts on “Custom OpenVPN Installer 10+ (NSIS)

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.