APPLICATION-SECURITY Contents

mTLS Basics (Service-to-Service Identity)

mTLS basics for operators: when to use it, how to deploy safely, certificate rotation, and common failure modes in service meshes and gateways.

On this page

What mTLS Gives You

  • Encryption in transit
  • Service identity (client cert proves who is calling)
  • Optional policy enforcement at the boundary

When to Use mTLS

  • Service-to-service traffic in zero-trust networks
  • Admin/control plane endpoints
  • Internal APIs where API keys are too weak

Operational Checklist

  • Define certificate issuer/CA ownership and rotation cadence.
  • Set certificate lifetime short enough to limit blast radius.
  • Roll out gradually with dual-stack acceptance (mTLS optional → required).
  • Monitor handshake failures explicitly.

Common Failure Modes

  • Clock skew: cert not yet valid / expired.
  • CA mismatch: wrong trust bundle deployed.
  • Rotation outage: old certs removed too early.

Quick TLS Sanity Check

# Server cert dates
echo | openssl s_client -connect api.internal:443 -servername api.internal 2>/dev/null 
| openssl x509 -noout -dates -subject