mTLS: Why Both Sides of a Connection Show ID
When you open an HTTPS website, your browser checks the site's digital certificate. That helps the browser confirm which server it has reached. The website may then ask you to sign in, because recognizing the server and recognizing its visitor are two different jobs.
Mutual TLS, usually written mTLS, brings identity checks to both ends of the connection. The caller checks the service it has reached, and the service checks the caller. This is useful when programs need to recognize one another before exchanging data.
TLS stands for Transport Layer Security, the protocol that protects an HTTPS connection against eavesdropping and undetected changes. TLS already supports checking the client, the device or program making the connection. Using that ability in both directions makes the TLS connection mutual.
What Your Browser Does Before Sending a Secret
A certificate needs a matching secret
A digital certificate is a record linking identity information to a public key. This key is data that others can use to check a cryptographic signature. The matching private key must stay secret. It allows its holder to create the signature.
A certificate can be copied. Showing someone a copy doesn't prove that you are the system named in it.
In certificate-based mTLS, each side therefore needs to do two jobs. It checks the other side's certificate against its trust rules, and it checks proof that the other side controls the matching private key.
TLS 1.3 calls the message carrying this proof CertificateVerify. It contains a digital signature tied to the connection being established. The other side can check that signature without receiving the secret key. The TLS 1.3 standard describes these certificate and signature checks.
- Sign in to CAC and PIV sites from your own desk instead of driving back to the office.
- Start working the minute you plug it in, with no drivers to install on Windows 10/11 or a recent Mac.
- Slim enough to live in your laptop bag, so your card goes wherever you work.
Once the required checks succeed, the programs have an encrypted connection and evidence of who is at each end. They haven't had to send each other their private keys to get there.
Two programs working on one order
Suppose an online store has separate programs for shipping and payments. The shipping service needs to ask the payment service whether an order has been paid for.
With mTLS, the shipping service can check that it reached the payment service. The payment service can also check that the caller is the shipping service. Being on the company's network is no longer the whole basis for recognizing the caller.
The payment service then has a further decision to make. Should shipping be allowed to read an order's payment status? Should it be allowed to change the amount charged?
Who Vouches for a Website's Certificate?
Checking the caller's identity is authentication. Deciding which requests to allow is authorization. The store could allow the status check while refusing changes to payment records.
The Istio project's security documentation shows how this can work in a real software system. Istio can put proxies beside services. These programs handle connections on a service's behalf: they establish mTLS, check whether a request is allowed and then forward it.
That also makes the scope of the identity check clear. Identifying the shipping service doesn't identify the shopper whose order it is processing. The application may need separate evidence about that person.
- Understand what AES, RSA and hashing actually do before you rely on them.
- Learn to spot the mistakes that break real-world encryption.
- Get a practical introduction to modern encryption in one book.
Keeping those checks working
Certificates have to be issued to the right systems. Each side needs rules for which certificates it trusts. Private keys need protection, and certificates need replacing before they expire. Istio documents automatic key and certificate rotation to handle part of that ongoing work.
Enforcement matters, too. TLS allows a server to request a client certificate, but the server's policy determines whether a caller without an acceptable certificate gets rejected. A system can support mTLS without requiring it on every connection. Istio's permissive mode, intended to help with migration, accepts unencrypted traffic as well as mTLS traffic.
Finally, the protection follows the connection. If a proxy ends one TLS connection and opens another, the next connection needs its own protection. Encrypting the trip doesn't encrypt a file after it has been stored.
A valid certificate also can't tell whether an attacker has taken over the program using it. A request from the shipping service might really come from that service and still ask for something it shouldn't do. The permission check is what keeps it from rewriting payment records.
Digital Certificates: What Your Browser Can Actually Verify

Certificate Authentication: Why the Private Key Matters

TLS Protects the Connection. The Destination Still Gets the Data.

QUOTE:
"Amateurs hack systems, professionals hack people."

