Workspace

TLS, HTTP & QUIC

3 day streakD
Systems syllabus
PHASE 02 · MODULE 05

TLS, HTTP/1.1, HTTP/2, HTTP/3 and QUIC.

No HTTP version is simply the best. Each one moved the bottleneck somewhere else.

HTTP/2 put many streams on one TCP connection. TCP knows nothing about those streams, so one lost packet stalls all of them until it is resent. QUIC moves streams into the transport, so a lost packet stalls only its own stream. HTTP/3 wins on lossy, high-latency mobile paths; inside a data centre, HTTP/2 is usually the better default.

6 lessons115 minutes of reading6 illustrations
Start lesson 1
Basics
  • HTTP semantics
  • Status codes
  • Caching headers
  • Keep-alive
  • Certificates and the chain of trust
  • SNI
  • ALPN
Depth
  • TLS 1.3 key schedule
  • Forward secrecy
  • Resumption
  • HTTP/2 framing and flow control
  • HPACK by hand
  • QUIC packet spaces
  • Stream and connection flow control
  • The HTTP/2 Rapid Reset attack
Current
  • Hybrid post-quantum key exchange
  • Encrypted Client Hello
  • MASQUE
  • Multipath QUIC
  • 103 Early Hints replacing server push

Lessons

  1. 01HTTP semantics: methods, status, headers and cachingBefore versions and transports, HTTP is a contract: what a method promises, what a status means, and which headers let caches and retries work safely.Basics18 min
  2. 02TLS: certificates, trust and the 1-RTT handshakeHow two strangers agree on a secret over a hostile network, and how the client knows it is talking to the right server. Then what TLS 1.3 removed and why it is faster.Basics22 min
  3. 03The cold-connection tax and connection reuseAdd up every round trip before the first byte of a response, and you will see why connection reuse matters more than most code optimisation.Depth15 min
  4. 04HTTP/2: frames, streams and head-of-line blockingHTTP/2 sends many requests over one connection as interleaved binary frames. Learn the framing, HPACK compression and flow control, and the TCP-level blocking HTTP/2 could not fix.Depth22 min
  5. 05QUIC and HTTP/3QUIC rebuilds TCP's job in user space on top of UDP, with TLS built in and streams in the transport. Learn what that changes, what it costs, and when not to use it.Depth22 min
  6. 06Post-quantum TLS, Encrypted Client Hello and Early HintsWhat changed in the last two years: hybrid post-quantum key exchange in most TLS traffic, encrypted server names, and preload hints that replaced server push.Current16 min

Module lab

  1. Build an HTTP/1.1 server on raw sockets: parse the request line and headers, support keep-alive and chunked responses.
  2. Decode TLS in Wireshark using SSLKEYLOGFILE.
  3. Load the same page over HTTP/2 and HTTP/3 with 0%, 1% and 5% loss, and plot the results.
  4. View a QUIC connection with qlog and qvis.

Interview questions

When would you not use HTTP/3 between internal services?

Low loss removes its main benefit, while CPU cost, weaker offload and tooling get worse.

Head-of-line blocking exists at which layers?

HTTP/1.1 application, TCP transport, and QPACK dynamic-table references.

Why is 0-RTT dangerous?

Replay. A POST that charges money must not use it.

What does X25519MLKEM768 protect, and what not?

Key exchange yes, certificate authentication no.

Read

  • RFC 9000, 9001, 9114 and 9204 for QUIC and HTTP/3
  • RFC 9113 for HTTP/2
  • RFC 9846 for updated TLS 1.3
  • The Illustrated TLS 1.3 Connection and The Illustrated QUIC Connection, Michael Driscoll

A good place to start

Explore a pattern

A little guidance

Start with a pattern, read through a problem, and mark it solved when the idea clicks. Save anything you want to revisit.

New tutorials are added one at a time. Your bookmarks and solved checkmarks stay in this browser.

Explore the roadmap