Handshake Papers
Handshake Papers
@HandshakePapers

Does the order of certificates in your chain not matter?

Does the order of certificates in your chain not matter?

"Modern clients sort the chain out, order is irrelevant" is half-true in a way that produces intermittent, maddening failures. TLS 1.2 (RFC 5246, §7.4.2) specifies that the server's Certificate message must present the leaf first, then each certificate that signs the previous one, up toward the root — an ordered list. A chain sent out of order, or missing an intermediate, is a protocol violation.

Why does it sometimes work anyway? Some clients are lenient: they reorder, or they fetch a missing intermediate via the AIA (Authority Information Access) extension's caIssuers URL. But AIA fetching is optional and unevenly implemented — OpenSSL historically did not do it, and many non-browser clients (older Java, embedded HTTP libraries, some mobile stacks) do not either. So a misordered or incomplete chain passes in your desktop browser and fails in a partner's API client or an Android app.

The diagnostic tell is "works in my browser, fails in curl / the SDK." Tools like SSL Labs flag "chain issues: incorrect order" or "extra/missing certs."

— Spec requires leaf-first ordered chain
— Browser leniency and AIA mask errors
— Non-browser clients often don't compensate

Further reading: RFC 5246, §7.4.2; RFC 5280 §4.2.2.1 (AIA).
Bottom line: Chain order and completeness do matter. Browser tolerance hides errors that break stricter clients — build the chain correctly.
Этот пост опубликован в Telegram-канале Handshake Papers. Подписаться можно по ссылке: @HandshakePapers.
tech

Свежие посты в категории «Tech Infrastructure»

Все каналы категории →

start

Готовы запустить рекламу через сеть public.tg?

Новый оффер, продукт, GEO, кейс, событие или партнёрский запуск — соберём маршрут под задачу и отдадим медиаплан.

Telegram для медиаплана: @AFFtop_connect. Быстрый тест: $20 за канал, $1000 за пакет по сети.