Open-source, modular and portable IPsec-based VPN solution
open sourceGPL-2.0-or-laterself-hostablefree
strongSwan is an IPsec VPN implementation built around its IKE daemon, charon, which negotiates IKEv2 (and IKEv1) security associations and installs them in the operating system's IPsec stack. It handles site-to-site tunnels, host-to-host connections and remote-access (road warrior) clients with virtual IPs, authenticating with X.509 certificates, pre-shared keys or EAP methods, with MOBIKE, NAT traversal, dead peer detection, high availability and post-quantum key exchange including ML-KEM. It's configured with swanctl over the VICI interface (the older ipsec/stroke interface is deprecated), ships a pki tool for keys and certificates, and has an official Android client. Runs on Linux, with ports to Android, FreeBSD, macOS, iOS and Windows; GPLv2, with commercial licences from secunet.
Ways to install
Package managers
Problems it solves
- connect two office networks with an IPsec tunnel between Linux gateways
- set up an IKEv2 VPN server that the built-in clients on Windows, macOS and iPhone can connect to
- give remote employees a VPN with certificate authentication and a virtual IP from a pool
- build an IPsec tunnel from a Linux server to a Fortinet or Cisco firewall
- authenticate VPN users against RADIUS with EAP instead of shared keys
- keep the VPN session alive when a laptop moves between Wi-Fi and mobile data
- an open source IPsec stack we can embed in our own appliance under a commercial licence
- issue the certificates for our VPN from the command line without a separate CA product
- an Android VPN app that talks IKEv2 to our own gateway
- post-quantum key exchange for our site-to-site IPsec tunnels
- route-based IPsec VPN on a Linux gateway
- run a highly available pair of IPsec VPN gateways that fail over
Features
- IKEv2 (RFC 7296) and IKEv1
- policy-based and route-based IPsec, IPv4 and IPv6 in tunnel and transport mode
- X.509 certificate, pre-shared key and EAP authentication (EAP-TLS, EAP-AKA, EAP-MSCHAPv2 and others), RADIUS
- post-quantum key exchange including ML-KEM
- MOBIKE, NAT traversal, dead peer detection
- virtual IPs for remote-access clients
- swanctl and the VICI configuration interface; legacy ipsec/stroke interface deprecated
- pki tool for RSA, ECDSA and EdDSA keys, X.509 certificates and CRLs
- high availability, IPComp, IP-TFS and per-CPU SAs
- NetworkManager plugin
View 3 more
- official Android VPN client on Google Play and F-Droid
- Trusted Network Connect and TPM 2.0 support
- modular plugin system
Limitations
- Android app supports only IKEv2: no IKEv1 and no pre-shared key authentication3
- Windows port can't install virtual IP addresses: kernel-iph doesn't support them, so it doesn't work as a road-warrior client4
Capabilities
| Has a command line tool | plan not known |
|---|---|
| Takes plugins | plan not known |
Alternatives
The same job
These do what strongSwan does.
- Libreswan Free software implementation of the IPsec VPN protocol and the Internet Key Exchange (IKE)
- WireGuard Fast, modern, secure VPN tunnel
- OpenVPN Access Server Fast and Easy Zero-Trust VPN Fully in Your Control
- OpenVPN Open source VPN daemon
- CloudConnexa Cloud-delivered VPN and zero trust network access from OpenVPN
- Firezone Zero Trust Access That Scales
