What is OpenVPN?
OpenVPN is a VPN protocol built on TLS. It authenticates with X.509 certificates, negotiates its ciphers rather than fixing them, and runs over either UDP or TCP. Running over TCP port 443 makes it very hard to distinguish from ordinary HTTPS, which is why it survives restrictive networks.
4 min read
OpenVPN first appeared in 2001 and is still the most widely deployed VPN protocol outside corporate IPsec. Its design is the opposite of WireGuard's: where WireGuard fixes every choice in advance, OpenVPN negotiates almost everything, and that flexibility is both its strength and the reason it is larger and slower.
Two channels
An OpenVPN connection has a control channel and a data channel.
The control channel is TLS. It authenticates both ends, negotiates parameters, and exchanges the keys the data channel will use. It is the same TLS that secures HTTPS, which is why an OpenVPN connection on port 443 looks so much like a web connection.
The data channel carries your traffic, encrypted with the negotiated cipher and authenticated with the negotiated HMAC or an AEAD construction.
That separation is why an OpenVPN configuration has certificate blocks and cipher settings: they belong to different channels.
Certificates rather than keys
OpenVPN authenticates with X.509 certificates. Each client has a certificate signed by a certificate authority the server trusts, and the server has one the client trusts.
Compared with WireGuard's bare 32-byte public keys, certificates are heavy. They also bring things bare keys do not have:
- Expiry. A certificate stops working on a date, without anyone doing anything.
- Revocation. A certificate revocation list invalidates one client immediately.
- A chain of trust. An organisation can issue thousands of client certificates from one authority.
That is why almost every corporate deployment is OpenVPN or IPsec rather than WireGuard: managing ten thousand employees' access is a certificate problem.
Cipher negotiation
Modern OpenVPN negotiates from a list, configured as data-ciphers. The usual
choices are AES-256-GCM and ChaCha20-Poly1305, with AES preferred on hardware
that accelerates it.
Older configurations used a single cipher directive, commonly
AES-256-CBC with a separate HMAC. If a client and server disagree about which
model they are using, the connection fails during negotiation — a common
symptom when a very old client meets a current server.
tls-auth and tls-crypt
Two optional extra layers on the control channel, and worth knowing because they appear in nearly every provider's configuration file.
tls-auth adds an HMAC to every control packet using a shared key. Packets
without a valid HMAC are discarded before any TLS processing, which stops port
scanning and absorbs denial-of-service attempts cheaply. It requires opposite
key-direction values on the two ends, which is a classic misconfiguration.
tls-crypt does the same and also encrypts the control channel, so the TLS
handshake itself is hidden. It has no direction to get wrong, and it makes
fingerprinting harder. It is the better of the two and what current
configurations use.
UDP or TCP
OpenVPN runs over either.
UDP is the normal choice. Lower overhead, and no interaction between the tunnel's reliability and the tunnelled protocol's.
TCP exists for networks that block or filter UDP. On port 443 it is very hard to distinguish from HTTPS without deep packet inspection. The cost is TCP-over-TCP: two congestion control loops and two retransmission timers stacked, which degrades badly on a lossy link. It is a compatibility mode, not a performance one.
Speed, and what changed recently
OpenVPN traditionally ran entirely in userspace, so every packet crossed the kernel boundary twice. That, plus larger headers, is most of why it is slower than WireGuard.
OpenVPN 2.6 introduced data channel offload, which moves the data path into a kernel module and closes a substantial part of the gap. The control channel stays in userspace, so the flexibility is preserved.
Where it still wins
- Restrictive networks. TCP 443 with
tls-cryptgets through places nothing else does. - Certificate-based identity with revocation and expiry.
- Router firmware. Nearly every router with any VPN client support has OpenVPN, including old firmware that will never see WireGuard. The router guide covers both.
- Ancient clients. Two decades of deployment means an OpenVPN client exists for almost anything.
Where it does not
On a phone, a tablet, a TV or a modern desktop, WireGuard is faster, reconnects instantly and costs less battery. For consumer use the sensible arrangement is WireGuard by default and OpenVPN as the fallback for networks that block UDP — which is exactly how most providers configure their apps, including on Windows.