What is Wireguard?
WireGuard is a free and open-source software application and communication protocol that implements virtual private network techniques to create secure point-to-point connections in routed or bridged configurations
WireGuard is a new, modern and open-source VPN protocol. You might have heard about it as it has been merge a exactly a year ago in the Linux core.
Is my VPN Provider compatible?
Some of the most famous providers already offer WireGuard through their mobile or desktop applications and some of them also provide configuration files for custom install!
How to use it on my Synology NAS?
I have recently discovered a GitHub project which let you build your own custom Synology package, fully compatible with your Synology NAS to let you use the "wg" and "wg-quick" commands of WireGuard.
The first step is to identity the CPU architecture your Synology NAS is running and to ensure your Kernel is above 3.10.
You can easily check all of that by searching for your Synology NAS model in the official documentation: What kind of CPU does my Synology NAS have?.
As soon as you have identity it, you can either download a pre-built version in the GitHub releases section or you can built it yourself.
It's pretty straight forward, you just have to download the .spk file matching your Synology NAS' CPU architecture.
To build manually your package, you will have to run the following commands:
- Connect to your Synology NAS via SSH and use a folder dedicated for that purpose
- Download the source code from GitHub
git clone https://github.com/runfalk/synology-wireguard.git
- Browse the source code's folder freshly cloned
- Start the building process
docker build -t synobuild .
- Generate the package matching your Synology NAS' CPU architecture. On my side, it's "braswell" with DSM 6.2
docker run --rm --privileged --network=host --env PACKAGE_ARCH=braswell --env DSM_VER=6.2 -v $(pwd):/result_spk synobuild
- You can find the .spk file in the WireGuard. Version number will change so use the tab key.
cd WireGuard-0.0.20210124 && ls *.spk
You can now easily install the package with this command line or through the DSM interface:
synopkg install WireGuard-braswell-1.0.20210124.spk
To activate the package, just run
synoservice --start pkgctl-WireGuard.
synoservice --status pkgctl-WireGuard to check if the package is running correctly.
You can now use "wg" and "wg-quick" commands of WireGuard directly on your Synology NAS.
Feel free to share your projets with WireGuard in the comments. 🚀