← Back to section · Post-Quantum Migration

Size Compatibility Testing: When Handshake Messages Grow by an Order of Magnitude

Post-quantum public keys, ciphertexts and signatures are dozens of times larger than classical ones. Test size before you switch: certificate chains, handshake messages, MTU and fragmentation, and the middleboxes on the path — anywhere the bytes do not fit, connections fail silently.

Published 22 November 2026 · 5 min read · PQ Frontier

Size Compatibility Testing: When Handshake Messages Grow by an Order of Magnitude
AI-generated site artwork
Video explainer · Compatibility Testing: Size, Performance, Interoperability

Size is the first compatibility gate of the migration

In most post-quantum migration discussions, algorithm security and performance absorb all the attention, but in production the first thing that bites is usually size. A classical ECDHE key share is 32 bytes (X25519) and an ECDSA signature is about 70 bytes. Under the FIPS 203/204 parameter sets, an ML-KEM-768 public key is 1,184 bytes with a 1,088-byte ciphertext, and an ML-DSA-65 public key is 1,952 bytes with a 3,309-byte signature. Mapped onto one full TLS handshake: key exchange grows by roughly 2.2 KB, and if the server chain is re-issued with ML-DSA, the combined public-key and signature growth across three or four certificates can reach well over ten kilobytes. These bytes are not abstractions — they must physically traverse every MTU, every buffer queue and every middlebox on your network path.

The goal of size compatibility testing is to find every place where the bytes “do not fit” before cut-over. Its difficulty lies in the failure modes: size problems rarely produce errors. They show up as connection timeouts, stalled handshakes and intermittent drops — indistinguishable from ordinary network jitter on a monitoring dashboard.

Count the bytes first: quantify the growth hop by hop

The first step of testing is not packet capture; it is arithmetic. List every protocol hop the migration touches and write down the old and new values:

  • Key exchange: the key_share in the ClientHello grows from a few dozen bytes to over a thousand, so a single message can exceed one Ethernet frame (MTU 1500);
  • Certificate chains: each certificate grows by roughly the public-key delta plus the signature delta, and the effect compounds with chain length; cross-signing and dual certificates (hybrid deployment) stack further;
  • Application-layer signatures: if the business signs messages (API signatures, tokens), even the smallest SLH-DSA signature is 7,856 bytes, which will breach many gateways’ header and body size limits first;
  • Storage and logging: certificates, key fingerprints and audit-log fields designed as fixed-length structures around classical sizes may overflow after the switch.

With this ledger done, you have a “size-sensitive points list” — every subsequent test revolves around the list instead of load-testing at random.

Fragmentation and the congestion window: two traps on the TCP path

There are two classic traps at the TCP layer. The first is IP fragmentation: when handshake messages travel over UDP (DTLS, or bespoke protocols outside QUIC) or the path MTU is smaller than the sender assumes, large datagrams get fragmented — and many firewalls and carrier networks drop fragments outright. The result: small packets work perfectly, handshakes time out. The second is the congestion window: the initial TCP congestion window is typically about 10 segments (roughly 14.6 KB). If the server’s certificate chain exceeds that, the handshake needs an extra round trip waiting for acknowledgements; on high-latency links this reads as “connections got slower”, which operations teams easily misattribute to the new algorithm being slow to compute.

Test method: in the test environment, set the path MTU to several values in turn (1500, 1400, 1280, 576) and measure handshake success rates at each step; confirm fragmentation and retransmissions from packet captures; record the number of round trips the handshake needs against the classical baseline. For QUIC, also watch the RFC 9000 amplification limit: before validating the client address, a server may send at most three times the bytes it received — a large certificate chain runs straight into that ceiling.

Middleboxes: the invisible layer on the path

Real network paths are full of middleboxes: corporate firewalls, intrusion detection, load balancers, carrier NAT, cloud security groups and gateways. A substantial share of them parse protocols under classical size assumptions: they inspect only the first fragment of a ClientHello, truncate buffers at fixed sizes, or drop unfamiliar extensions and over-long chains outright. These faults cannot be found on an office network, because the path from the office to the test server is too “clean”.

Size testing must therefore cover a matrix of real paths: different carrier egresses, cross-cloud links, inside VPN tunnels (tunnel encapsulation eats further into the MTU), and mobile networks. For each combination, record handshake success rates and failure shapes, and keep packet captures. When a middlebox problem is found, the fix is usually not on the algorithm side: adjust tunnel MTU/MSS clamping, slim the chain (drop redundant intermediates), or get the gateway vendor to fix its parser — but all of that presupposes you can point to the exact hop at fault with capture evidence.

Most size discussion assumes one-way traffic: the server sends the chain, the client only receives. But in mutual TLS (mTLS), the client equally sends its own certificate chain and signatures, and the growth happens in both directions at once. Service meshes, zero-trust access and device authentication inside enterprises use mTLS heavily, which means gateway inbound buffers and client-side send windows must pass size testing too. The subtler case is the device-side client: when industrial terminals and IoT devices initiate mTLS, their protocol-stack buffers are often hard-coded to classical certificate sizes; after the server switches to a post-quantum chain, these devices do not fail at the verification step — they never receive the full chain at all. Fault location and root cause sit a layer apart, and diagnosis easily misattributes the problem to the device firmware’s verification logic. So keep two byte ledgers, one per direction, and give mTLS combinations their own rows in the test matrix.

Turn size testing into a regression item

Size compatibility is not a one-off acceptance test. A renewed certificate with a longer chain, a hybrid deployment stacking another certificate, a gateway upgrade changing buffer policy — any of these invalidates yesterday’s conclusions. The pragmatic approach: turn the byte ledger and handshake success rates on key paths into automated regression, re-run on every certificate or configuration change; and give “handshake failure rate” its own alerting dimension in production monitoring — the signature of a size fault is precisely that this number rises without a sound. Count the bytes, test the paths, then freeze it into regression: only after these three steps is the size gate truly passed.

Tags: Size CompatibilityCertificate ChainsFragmentationMiddleboxes