Back to all terms
Securityintermediate

Encryption in Transit (TLS)

Encrypting data as it moves between systems using TLS to prevent eavesdropping, tampering, and man-in-the-middle attacks.

Also known as: transport layer security, TLS encryption, SSL/TLS, data-in-transit encryption

Description

Encryption in transit ensures that data is protected as it travels between clients and servers, between microservices, and between any networked systems. Transport Layer Security (TLS) is the standard protocol for this, providing confidentiality through encryption, integrity through message authentication codes, and authentication through digital certificates. Without encryption in transit, any network intermediary can read, modify, or inject data.

TLS operates by establishing a secure channel through a handshake process: the client and server negotiate a protocol version and cipher suite, the server presents its certificate for authentication, and both parties derive shared session keys through an asymmetric key exchange. Modern TLS 1.3 streamlined this process to a single round trip, removing deprecated cipher suites and providing forward secrecy by default through ephemeral Diffie-Hellman key exchange.

Implementing encryption in transit goes beyond just enabling HTTPS on your load balancer. It includes enforcing TLS for all internal service-to-service communication (mutual TLS/mTLS in service meshes like Istio or Linkerd), encrypting database connections (sslmode=require for PostgreSQL, useSSL=true for MySQL), securing Redis and message queue connections, and ensuring all API integrations use HTTPS endpoints. Certificate management through automated solutions like Let's Encrypt with auto-renewal prevents outages from expired certificates.

Prompt Snippet

Enforce TLS 1.2 as the minimum protocol version with TLS 1.3 preferred. Configure your reverse proxy (nginx, Caddy, or ALB) with strong cipher suites: TLS_AES_256_GCM_SHA384, TLS_CHACHA20_POLY1305_SHA256 for TLS 1.3, and ECDHE+AESGCM for TLS 1.2. Require encrypted connections for all database clients (sslmode=verify-full for PostgreSQL, ssl.rejectUnauthorized=true for Node.js drivers). Implement mTLS for service-to-service communication in your service mesh. Automate certificate provisioning and renewal with cert-manager and Let's Encrypt, and configure alerts for certificates expiring within 14 days.

Tags

tlsencryptiontransport-securitycertificateshttps