Chapter 1
Symmetric encryption: one shared key
Symmetric encryption scrambles data with one secret key, and only someone who holds that same key can turn the scrambled data back into readable text.
26 chapters in 8 parts, from your first secret key to post-quantum cryptography. Every chapter starts in plain words, then goes as deep as you want. No account needed.
26 of 26 chapters published in this early edition. Each chapter matches one level of the game.
Keeping a message private: shared keys, key pairs and agreeing a secret in public.
Chapter 1
Symmetric encryption scrambles data with one secret key, and only someone who holds that same key can turn the scrambled data back into readable text.
Chapter 2
A shared secret key must reach each partner without anyone else seeing it, and every pair needs its own key, so sharing secret keys does not scale.
Chapter 3
A key pair is two keys: a public key anyone may have and a private key only you hold, so strangers can encrypt to you without sharing a secret first.
Chapter 4
Two parties can agree a shared secret over an open network without ever sending it, then derive fast symmetric keys from it to protect the actual data.
Proving a message is unchanged and really from its sender: hashes and signatures.
Chapter 5
A cryptographic hash turns any data into a short, fixed-size fingerprint; any change gives a completely different fingerprint, and you cannot run it backwards to get the data.
Chapter 6
A digital signature is a value only the private-key holder can compute for a message, and anyone with the public key can check that it matches that exact, unchanged message.
Chapter 7
Encryption and signatures only help if you use the right person's public key, so something you already trust must vouch that a key belongs to a name.
Binding a name to a public key: X.509, names, requests and validation.
Chapter 8
An X.509 certificate is a public, signed record that ties one public key to names for a fixed period, and you can read every field with openssl.
Chapter 9
A certificate is valid only for the names in its Subject Alternative Name list, and only for the jobs that its key usage, extended key usage and CA flag allow.
Chapter 10
You generate a key pair, keep the private key, and send the CA a certificate signing request (CSR) carrying only your public key and the names you want.
Chapter 11
Before issuing, a CA checks that you control each name, using a file, a DNS record or a TLS response, and reads CAA records; OV and EV check the organisation.
Trust stores, chains, cross-signing and the TLS 1.3 handshake.
Chapter 12
Every client trusts only the root certificates in its own trust store, so a certificate is accepted only if its chain ends at one of them; being self-signed earns nothing.
Chapter 13
Servers must send their leaf and intermediate certificates; clients link them by name and key identifier up to a trusted root and check every signature, date and constraint.
Chapter 14
Cross-signing gives one CA key two certificates from different issuers, so a chain can reach either an old or a new root; clients must pick a path that is valid.
Chapter 15
In one round trip, client and server agree fresh keys with ECDHE, the server proves it holds the certificate's key by signing the handshake, and both confirm nothing was altered.
Revocation, Certificate Transparency and what famous failures taught us.
Chapter 16
Revocation lets a CA cancel a certificate before it expires, but many clients check late, softly or not at all, so short lifetimes now do much of the work.
Chapter 17
Certificate Transparency records every publicly trusted TLS certificate in public, append-only logs, so anyone can spot a certificate for their name that they never asked for.
Chapter 18
Real PKI failures, from a hacked CA to expired certificates, follow one pattern: a weak point breaks trust, someone notices, and the rules or practices change.
Inventory, renewal, ACME, guarding keys and running a CA of your own.
Chapter 19
Every certificate expires and lifetimes keep shrinking, so you need an inventory, an owner for each certificate, monitoring of what servers really send, and automated renewal.
Chapter 20
ACME lets software prove control of a name, then fetch, renew and install certificates automatically: the only practical way to live with very short certificate lifetimes.
Chapter 21
A CA is only as trustworthy as its private keys, so they live in certified hardware, are created in witnessed ceremonies and are used only under multi-person control.
Chapter 22
A private CA lets you issue certificates for internal systems under your own rules, built safely as an offline root plus an online issuing CA with clear policies and templates.
Mutual TLS, code and document signing, and device identity.
Chapter 23
In mutual TLS the client also proves who it is, with a certificate and a signature from its private key, so both ends are authenticated before any data flows.
Chapter 24
A code or document signature proves who signed a file and that nobody changed it since; a trusted timestamp keeps that proof valid after the signing certificate expires.
Chapter 25
A device certificate, installed at the factory with its private key locked in secure hardware, lets a machine prove what it is and who made it, for its whole life.
Post-quantum cryptography and what changes next.
Chapter 26
A large quantum computer would break RSA and elliptic-curve cryptography, so key exchange is already moving to ML-KEM, and signatures and certificates come next.
Reference pages to keep open while you work.
Every PKI and TLS term used on this site, from ACME to X.509, each with a one-line answer, a fuller explanation and the chapter that teaches it.
Tested OpenSSL, curl, keytool, Windows and Kubernetes commands for everyday certificate work, grouped by the task you are trying to do.
The formats are wrappings of the same data: DER is binary, PEM is DER in Base64, PKCS #12 bundles a key with its certificates, and PKCS #7 carries certificates only.
From the first public-key papers in the 1970s to ever-shorter certificate lifetimes and post-quantum key exchange: the milestones and incidents that shaped how certificates work today.
The RFCs, CA/Browser Forum documents, root program policies, NIST standards and EU rules that this handbook relies on, each with what it covers and where to read it.