# VPN (Virtual Private Network) Confidence: high Last verified: 2026-05-22 Generation: human_only ## TL;DR A VPN creates an encrypted tunnel between a device and a network, protecting data in transit and masking the user's IP address. Protocols: IPsec (network layer, site-to-site), OpenVPN/WireGuard (application layer, client-to-server). WireGuard (2020, Linux kernel since 5.6) is faster and simpler than IPsec/OpenVPN. ## Core Explanation WireGuard uses state-of-the-art cryptography: Curve25519 (key exchange), ChaCha20 (encryption), Poly1305 (authentication), BLAKE2s (hashing). Only ~4000 lines of code vs. ~600K for OpenVPN — dramatically smaller attack surface. VPNs do NOT provide anonymity — they shift trust from ISP to VPN provider. Tor (onion routing) provides stronger anonymity via three-hop circuit. ## Further Reading - [undefined](undefined)