liveBook · Manning

Certificate pinning

As explained in Real-World Cryptography

Certificate pinning is a client-side validation technique that accepts a server only when its certificate matches a specifically expected certificate or certificate digest.

Certificate pinning is a client-side check that permits a TLS connection only when the server presents a specifically expected certificate or public key. It reduces reliance on the web public key infrastructure. section 9.3 section 9.6

The threat is a misbehaving certificate authority: an attacker who controls a domain-matching certificate and reaches a man-in-the-middle position could impersonate the service. Pinning gives a client-controlled connection an additional identity check. section 9.3

A deployment can choose between two trust boundaries:

A certificate authority goes rogue

Suppose a CA signs a certificate for your domain using a public key it controls. If an attacker can intercept traffic, ordinary web-PKI validation may accept the impersonator; pinning can reject the unexpected certificate or key. section 9.3

How Real-World Cryptography covers it

How deep it goes
Defines the trust decision and its CA-impersonation rationale, but does not provide implementation steps or operational rotation guidance.
Examples
Uses a rogue certificate authority and intercepted domain traffic to illustrate possible service impersonation.
What it assumes
Assumes familiarity with TLS, certificates, public keys, certificate authorities, and web-PKI trust.
What you can do after
Apply certificate or public-key pinning as a defense-in-depth restriction for client-controlled TLS connections.
How it connects
Connects TLS with web PKI, certificate authorities, man-in-the-middle attacks, certificate revocation, and organizational PKI.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Real-World Cryptography. The section links point to the parts of the book it draws on.