TURN Relay Demo
TL;DR: TURN is a relay that forwards encrypted packets when direct peer-to-peer (P2P) connection fails. With end-to-end encryption, the relay can move bytes, but it cannot read the contents.
Imagine you are sending a locked box to a friend. The box can travel two different routes, but it stays locked the whole time.
- Direct route: the box goes straight to your friend.
- Relay route: the box goes through a helper place that forwards packages.
Pick the route
The route changes where the encrypted data travels. The locked box (encrypted payload) stays the same size.
What you should notice
Watch two things: (1) the route and (2) the payload size. When you switch routes, the payload size stays the same. Only the path changes.
Technical demo (simple)
Here is a tiny preview of the encrypted data (it looks like nonsense on purpose):
Generating...
Switching between Direct and TURN does not change the payload size. The preview changes only when you click "Make a new locked box".
What TURN is (in plain English)
TURN is like a package forwarding station. If two devices cannot reach each other directly (Wi-Fi rules, school networks, hotels, firewalls), TURN helps by passing the encrypted data through.
- TURN can: move/relay encrypted bytes (like forwarding a package).
- TURN cannot: read what is inside the encrypted bytes (cannot open the locked box).
Real-life examples
- Hotel Wi-Fi: blocks direct connections, so a relay helps.
- School network: strict firewall rules, so a relay helps.
- Home Wi-Fi with NAT: devices cannot easily find each other, so a relay helps.