landmark VPN release , which marks the delivery of WireGuard components in the main kernel and stabilization of development. The code included in the Linux kernel an additional security audit conducted by an independent firm specializing in such reviews. The audit revealed no issues.
As WireGuard is now being developed within the main Linux kernel, a repository has been prepared . The repository includes backported WireGuard code and a compat.h layer to ensure compatibility with older kernels. It is noted that as long as developers have the capability and users have the need, a separate variant of the patches will be maintained in working condition. Currently, the separate WireGuard variant can be used with kernels from and , and is also available as patches for Linux kernels and . Distributions using the latest kernels, such as Arch, Gentoo, and
Fedora 32, will be able to use WireGuard alongside kernel update 5.6.
The main development process is now carried out in the repository , which includes the complete Linux kernel tree with changes from the WireGuard project. Patches from this repository will be reviewed for inclusion in the main kernel and regularly moved to the net/net-next branches. The development of user-space utilities and scripts, such as wg and wg-quick, is conducted in the repository , which can be used to create packages in distributions.
Let us remind you that the WireGuard VPN is built on modern encryption methods, providing very high performance, simplicity of use, and a lack of complexity, and has proven itself in several large deployments handling significant traffic volumes. The project has been evolving since 2015, has passed an audit and of the employed encryption methods. Support for WireGuard has already been integrated into NetworkManager and systemd, and kernel patches are included in the base of the distributions , Mageia, Alpine, Arch, Gentoo, OpenWrt, NixOS, and .
WireGuard uses the concept of key-based routing, which implies binding a private key to each network interface and using it to link public keys. The exchange of public keys for establishing a connection is done similarly to SSH. Key agreement and connection establishment without launching a separate daemon in user space is achieved using the Noise_IK mechanism from , similar to maintaining authorized_keys in SSH. Data is transmitted via encapsulation in UDP packets. Support is provided for changing the VPN server's IP address (roaming) without breaking the connection, with automatic client reconfiguration.
For encryption the stream cipher and the message authentication algorithm (MAC) , developed by Daniel Bernstein (), Tanja Lange
(Tanja Lange) and Peter Schwabe (Peter Schwabe). ChaCha20 and Poly1305 are presented as faster and safer alternatives to AES-256-CTR and HMAC, with software implementation allowing fixed execution time without requiring specialized hardware support. For generating a shared secret key, the elliptic curve Diffie-Hellman protocol is used, implemented in , also proposed by Daniel Bernstein. The hashing algorithm used is .
With older WireGuard has demonstrated 3.9 times higher throughput and 3.8 times greater responsiveness compared to OpenVPN (256-bit AES with HMAC-SHA2-256). When compared to IPsec (256-bit ChaCha20+Poly1305 and AES-256-GCM-128), WireGuard shows a slight performance edge (13-18%) and reduced latency (21-23%). The testing results published on the project's site cover an older isolated implementation of WireGuard and are noted to be of insufficient quality. Since the testing was conducted, the code for both WireGuard and IPsec has been further optimized and now operates faster. More comprehensive testing, which includes the kernel-integrated implementation, has yet to be conducted. Nevertheless, it is noted that WireGuard still outpaces IPsec in certain situations due to its multithreading capabilities, while OpenVPN remains very slow.
Source: opennet.ru
