Labs / Lab 09 / Real crypto
Wire Overhead
Watch a TLS 1.3 handshake twice: today's key exchange and the hybrid one. Step through it, open any packet, and find the bytes the new algorithm adds.
Formal term: hybrid TLS 1.3 key exchange
All labs (10)
Explainer
Watch the idea first.
Why the handshake needs a second lock, what that lock costs in bytes, and when the hello stops fitting in one packet. 1 min 30 s, with captions.
Read the transcript
- Every secure website visit starts with a handshake. Your browser sends a key share. The server sends one back. From those two halves, both sides build the same secret, and anyone watching the wire cannot.
- But someone can record that handshake today, and keep it. If a large enough quantum computer arrives, it could work out the secret later, and unlock everything in the recording.
- So the handshake gets a second lock. The hybrid key share pairs today's X25519 with ML-KEM-768, a post-quantum method. To read the traffic, an attacker would have to break both.
- That protection costs bytes. The browser's key share grows from 32 bytes to 1,216. Its whole hello grows from 179 bytes to 1,365. More than seven times bigger.
- Networks carry data in packets, and each packet has a size limit. The old hello fits with room to spare. The new one still fits under 1,500 bytes, but at 1,200, it spills into a second packet.
- Now see it for yourself. Step through both handshakes in the lab below, open the hybrid hello, and find the bytes the new algorithm adds.
Steps
The client says hello and offers a key share: its half of a secret the two sides will build together.
Stage
Classical X25519
Hybrid X25519MLKEM768
ClientHello, both versions on one scale
- Headers
- Classical key share
- Post-quantum addition
- Past the packet limit
FitsBoth hellos fit in one packet. Lower the limit until the hybrid one splits.
| # | From | Message | Classical | Hybrid | Added |
|---|---|---|---|---|---|
| 1 | Client | ClientHello | 179 B | 1,365 B | +1,186 B |
Goal
Find the field that grew.
Open the hybrid ClientHello in the inspector and select the part that the classical version does not have.
ClientHello
Locked. Everything after the two hellos is encrypted, so its fields are hidden from anyone watching the wire.
Educational, not for production use. One synthetic hello to example.com, built in code: real ones differ by browser and extensions. Key material shown is random filler of the right length, not real ML-KEM output. Message layout per RFC 8446 (TLS 1.3, since obsoleted by RFC 9846); key share sizes per RFC 10024 and FIPS 203, both Published. As of 1 Dec 2026.
Where this picture breaks
This is one synthetic hello. Real ones differ by browser and extensions, and the slider models one packet size, not a real network path. A key exchange alone does not prove who is on the other end: that takes signatures and certificates.
The handshake as text
- ClientHello (Client). The client says hello and offers a key share: its half of a secret the two sides will build together. Classical 179 B, hybrid 1,365 B.
- ServerHello (Server). The server answers with its own half. Both sides can now work out the same secret. Someone watching the wire cannot. Classical 127 B, hybrid 1,215 B.
- Encrypted server flight (Server). From here on, everything is locked with that secret. The server sends its certificate and proves who it is.
- Client Finished (Client). The client confirms it worked out the same secret.
- Application data (Client). Real data flows, protected by the secret built in steps 1 and 2.
Practise this
Five questions: put the handshake in order, predict the added bytes, spot what a recorder could open later. No timer. It never blocks your progress.
Planned