AWS, Azure & GCP · Cloud across providers

How do you encrypt data in transit?

EasytlsencryptioncertificatesUpdated Oct 2026
Quiz this track

Short answer

Use TLS for all network paths, verify certificates, prefer modern protocol versions and cipher suites, and avoid plaintext inside the network. Private endpoints reduce exposure but do not replace TLS.

TLS protects data between a client and a server by negotiating a session key and authenticating the server with a certificate. Modern deployments use TLS 1.2 or 1.3, disable weak ciphers, and automate certificate renewal.

Practical controls

  • Enforce TLS on load balancers, APIs, databases and internal service calls
  • Verify certificates and hostnames; never disable verification to make a test pass
  • Use HSTS for browser-facing endpoints and redirect HTTP to HTTPS
  • Use mutual TLS when services must authenticate each other
  • Automate certificate issuance and renewal, and alert before expiry
bash
curl --tlsv1.2 --fail --silent   https://api.example.com/health
openssl s_client -connect api.example.com:443   -servername api.example.com
Check that the endpoint negotiates TLS and presents the expected certificate.

Internal traffic is not automatically safe. Flat networks, shared clusters and compromised workloads can sniff or intercept plaintext. A service mesh can provide mTLS and identity, but it adds operational complexity and still needs correct certificate management.

TLS protects data in transit, not data at rest or a compromised endpoint. Use it alongside encryption at rest and strong identity.

Follow-ups you should expect

Interviewers use these to check whether the first answer was understanding or memorisation.

  1. 1What is the difference between TLS termination and passthrough?
  2. 2When would you use mutual TLS?
  3. 3Why is disabling certificate verification dangerous?
  4. 4How do you prevent certificate expiry outages?

Say it in the interview

I enforce TLS on every network path, verify certificates and hostnames, and prefer TLS 1.2 or 1.3 with strong ciphers. For service-to-service traffic I may use mutual TLS, and I automate renewal so expiry does not become an outage. Private networking reduces exposure, but I do not treat it as a replacement for encryption in transit.

Use this as a model, not a script. Saying it in your own words is what makes it survive follow-up pressure.

Related questions

Reading is step one

Now say it out loud.

Understanding an answer and delivering it under pressure are different skills. Rehearse this topic in a live AWS, Azure & GCP mock interview and get scored feedback on depth, clarity and confidence.