1. QUIC Packets & Header Compression (QPACK)

The QUIC protocol defines its own packet format sitting on top of UDP datagrams. To work efficiently within the UDP space, QUIC implements its own handshake, reliability guarantees, and flow control.

Meanwhile, HTTP/3 uses QPACK (Quick Protocol Header Compression) to efficiently compress HTTP headers. This is more optimized than HTTP/2's HPACK and prevents head-of-line blocking.

  • QUIC packet headers contain the Connection ID and Packet Number
  • QPACK optimizes the use of dynamic and static tables
  • Packet numbers are used for loss detection and retransmission
📦
// QUIC Packet Structure:
UDP Datagram {
  QUIC Header {
    Connection ID (CID),
    Packet Number (PN)
  }
  QUIC Frames {
    STREAM Frame (Data),
    ACK Frame (Acknowledge)
  }
}

2. Connection ID (CID) & Network Migration

QUIC introduces the concept of a Connection ID (CID). This randomly generated identifier is used to track sessions between clients and servers, rather than relying on traditional IP addresses and ports.

The use of CID is the key to achieving connection migration. Even if a user's IP address changes (e.g., switching networks), the session remains active via the CID, enabling seamless continuity.

  • Session identification is independent of the network 5-tuple
  • Enables seamless session persistence and reconnection
  • The ideal choice for mobile devices and IoT
🆔
// Network Change:
(IP1:Port1) → (IP2:Port2)
QUIC: CID remains 4A-3C-B9-F2
TCP: Connection State Lost

3. Native TLS 1.3 Integration: Encryption as a Service

QUIC integrates the TLS 1.3 handshake directly into its connection establishment process. Encryption is no longer an optional overlay but an inherent component of the protocol.

This integration eliminates the complexity of separate TCP + TLS handshakes and is the technical prerequisite for 0-RTT. All QUIC frames are authenticated and mostly encrypted, providing robust security.

  • TLS and connection handshakes are combined into one
  • Mandates the use of TLS 1.3 or higher
  • Provides Perfect Forward Secrecy
🔒
// Handshake Steps:
1. ClientHello (Includes QUIC parameters)
2. Server sends Encrypted Extensions
3. Client & Server exchange traffic keys
4. Data flows (1-RTT or 0-RTT)
System Ready