Concepts / Identity and access

Identity and access

Mutual TLS

Also called mTLS, client certificate, client certificate authentication, two-way TLS, ssl_verify_client, certificate revocation, CRL, revocation list

TLS in which the server also asks for the client's certificate and checks it, so both ends prove who they are.

In ordinary HTTPS only the server shows a certificate. In mutual TLS the server also sends a certificate request in the handshake, naming the CAs it trusts; the client answers with its own certificate and signs the handshake with the matching private key. The server checks the signature chain to a trusted CA, that the certificate is meant for clients (extended key usage clientAuth), and that it is not on the CA's revocation list (CRL), then reads the name in it to decide what the caller may do. The certificate is public; the identity is the private key, which is why keys are kept in hardware and certificates kept short-lived. In nginx: ssl_verify_client on, ssl_client_certificate (the trusted CA), ssl_crl, and $ssl_client_s_dn for the verified name.

See it on real machines

Learn it on real machines.

Every lab is a small network of real Linux machines in your browser. Start with a free account: Google or email, no card.

Open this lab