Quick revision
The short answer
For 100 services on Kubernetes I would make a service mesh's mTLS the default, because it encrypts all traffic without code changes, gives every workload its own identity and rotates certificates centrally, and I would use application-level TLS where the mesh does not reach or where end-to-end protection through intermediaries is required. The choice also weighs operational cost, latency and team skills. Either way the standard requires TLS 1.2 or later with 1.3 preferred, strong cipher suites enforced by policy, and authorization based on workload identity, not just encryption.
What to remember
In this answer, we defined an encryption-in-transit standard for 100 services. A service mesh gives mTLS for all traffic without code changes, with per-workload identity and central rotation, at the cost of running the mesh; application-level TLS works anywhere and reaches into the JVM, but every team must configure it correctly. We weigh operational cost, performance and team skills, often ending with a hybrid, require TLS 1.2 or later with 1.3 preferred and strong cipher suites enforced by policy, and add authorization by workload identity because encryption alone does not decide who may call what.
Your turn
Answer it aloud as you would in the interview, or type your answer below. Then show one part at a time and compare.
For 100 services on Kubernetes I would make a service mesh's mTLS the default, because it encrypts all traffic without code changes, gives every workload its own identity and rotates certificates centrally, and I would use application-level TLS where the mesh does not reach or where end-to-end protection through intermediaries is required. The choice also weighs operational cost, latency and team skills. Either way the standard requires TLS 1.2 or later with 1.3 preferred, strong cipher suites enforced by policy, and authorization based on workload identity, not just encryption.
Why this question is asked
Inside a Kubernetes cluster, traffic between pods often travels in plain HTTP because the network feels private. Regulators, auditors and attackers who land on one node do not agree. Defining a standard for 100 services is a platform decision with long consequences: it decides who configures certificates, what breaks when they expire, and how services prove who they are. Interviewers ask this design question to see whether we can compare the mesh and the application approach honestly and write a standard teams can actually follow. In this answer, we will recap mTLS, compare mesh and application-level TLS, weigh cost and skills, set protocol requirements, and add identity-based authorization.
1A Quick Recap of mTLS Between Services
TLS encrypts a connection and lets the client verify the server's certificate. Mutual TLS adds the reverse: the client presents a certificate too, so both sides know who they are talking to. In a cluster, the certificate does not name a host as much as a workload, for example a SPIFFE identity such as spiffe://cluster.local/ns/shop/sa/orders, derived from the namespace and service account.
Certificates need issuing, distributing to every pod and rotating before they expire, often every 24 hours in a mesh. Who does that work is the heart of the decision.
2Option 1: Service Mesh mTLS
A service mesh such as Istio or Linkerd adds a proxy next to each pod (a sidecar), or in newer designs a per-node proxy as in Istio's ambient mode. The application talks plain HTTP to localhost; the proxy upgrades the connection to mTLS, presents the workload's certificate, verifies the peer and forwards. The mesh's control plane issues and rotates certificates automatically.
So every service gets encryption and identity without changing a line of Java, policies are set in one place (for example Istio's PeerAuthentication in STRICT mode rejects plain traffic), and rotation is invisible. The costs are real: another critical system to run and upgrade, extra memory and a little latency per hop, a learning curve for debugging, and the fact that encryption ends at the proxy, so traffic on the pod's loopback is plain.
- orders containerplain HTTP to localhost
- orders proxymTLS with identity sa/orders
- networkencrypted, both sides verified
- payments proxyverifies sa/orders, applies policy
- payments containerplain HTTP from localhost
5 layers, from the top down. Step through them one at a time.
3Option 2: Application-Level TLS
Without a mesh, each Spring Boot service terminates TLS itself, with SSL bundles for the server and for its clients, and certificates issued by something like cert-manager and mounted as files. This works on any platform, keeps encryption all the way into the JVM, and has no extra proxy to run.
But there is a catch: 100 services means 100 teams configuring keystores, truststores, client authentication and reloading correctly, plus Kafka clients, database drivers and any non-Java components. One team that sets the client to trust all certificates, or forgets to reload renewed ones, creates either a hole or an outage. A shared platform starter reduces this a lot, but it cannot cover every language and library in the estate.
4Weighing Cost, Performance and Skills
The decision depends on the organisation. If the platform team already runs a mesh for traffic management or can staff it properly, the mesh wins on consistency: one policy, one rotation mechanism, identity for free. If the platform team is small, services are spread across environments a mesh cannot reach, or latency budgets are very tight, application-level TLS with strong shared libraries may be safer, because a badly run mesh is worse than none.
Performance is usually not the decider. TLS 1.3 handshakes are fast, connections are reused, and a sidecar typically adds well under a millisecond per hop, though memory per pod adds up across thousands of pods. In practice, many organisations choose a hybrid: mesh mTLS as the baseline for all in-cluster traffic, plus application-level TLS for calls that leave the cluster or must stay encrypted end to end through gateways.
| Concern | Service mesh | Application TLS |
|---|---|---|
| Code changes | None | Every service, via shared starter |
| Workload identity | Built in per service account | Must be designed and issued |
| Certificate rotation | Automatic, central | cert-manager plus reload in each app |
| Operational cost | Run and upgrade the mesh | Spread across 100 teams |
| End-to-end into the JVM | No, ends at the proxy | Yes |
| Works outside Kubernetes | Limited | Yes |
5The Protocol Requirements in the Standard
Whichever mechanism we choose, the standard states the same minimums: TLS 1.2 or later everywhere, TLS 1.3 preferred, with TLS 1.0, 1.1 and all SSL versions disabled. For TLS 1.2, only forward-secret AEAD cipher suites (ECDHE with AES-GCM or ChaCha20-Poly1305); no CBC, RC4 or 3DES. Certificates use RSA 2048 or larger or ECDSA P-256, with short lifetimes and automatic renewal.
A standard nobody checks is a wish, so we enforce it: mesh policy in strict mode, Kubernetes admission policies that reject workloads opting out, Spring Boot starters configured with server.ssl.enabled-protocols set to TLSv1.3 and TLSv1.2, and a regular scan that connects to every service endpoint and reports any that accept old protocols or plain text.
6Encryption Is Not Authorization
mTLS tells payments that the caller is the orders service. It does not say whether orders may call the refund endpoint. The standard therefore requires authorization based on workload identity: the mesh's authorization policies, or the application checking the peer identity, allow only named callers to reach each service, and deny everything else by default. That limits what an attacker can do from a compromised pod, which encryption alone never does.
7Follow-up questions
Does mesh mTLS satisfy a requirement for end-to-end encryption?
Often not literally, because traffic between the proxy and the application inside the pod is plain, and TLS may terminate at gateways. For most compliance needs, encrypted pod-to-pod traffic is accepted, but for specific data flows that demand end-to-end protection we add application-level TLS or message-level encryption.
How would you roll out STRICT mode without breaking things?
Start in PERMISSIVE mode, which accepts both plain and mTLS, watch the mesh telemetry to find clients still sending plain traffic, fix them, then switch namespaces to STRICT one at a time, with the most sensitive ones first.
8Conclusion
In this answer, we defined an encryption-in-transit standard for 100 services. A service mesh gives mTLS for all traffic without code changes, with per-workload identity and central rotation, at the cost of running the mesh; application-level TLS works anywhere and reaches into the JVM, but every team must configure it correctly. We weigh operational cost, performance and team skills, often ending with a hybrid, require TLS 1.2 or later with 1.3 preferred and strong cipher suites enforced by policy, and add authorization by workload identity because encryption alone does not decide who may call what.
Open with
For a hundred services on Kubernetes, my default would be mesh mTLS, if we can staff the mesh properly. It encrypts every hop without code changes, gives each workload an identity from its service account, and rotates short-lived certificates centrally, which removes the most common failure: a team mishandling keystores or forgetting to reload a renewed certificate.
Then, if they want more
I would roll it out in permissive mode, use telemetry to find plain-text clients, then switch namespaces to strict. Application-level TLS is the alternative, with Spring Boot SSL bundles and cert-manager.
It works on any platform and protects traffic all the way into the JVM, but it puts the configuration burden on every team and every library, from Kafka clients to database drivers, which is where mistakes happen at this scale.
So I would weigh operational cost, latency and skills: if the platform team is small or traffic leaves the cluster a lot, application TLS with a strong shared starter may be the better choice, and in practice many of us end up hybrid, with the mesh as the baseline and application TLS for external or end-to-end flows.
The standard itself would say TLS 1.2 minimum, 1.3 preferred, only forward-secret AEAD cipher suites, short-lived certificates, enforced by mesh policy, admission control and a regular endpoint scan. And I would insist on authorization by workload identity, deny by default, because mTLS tells payments who is calling but not whether that caller is allowed.
About this answer
- Last updated
- 12 November 2026
- Checked
- Its structure and format are checked automatically. Use it as a carefully prepared study note: where a detail matters, confirm it against the documentation below. What the checks cover
- Where the question comes from
- Written by Scrivio for practice. It is not taken from an interview.
- Official documentation
- Spring Security reference
Report an issue with this answer
Copy the line below and send it to the author with what you found. It carries the address of this page.
Issue with "Define the encryption-in-transit standard for 100 services in a Kubernetes environment....": https://scrivio-interview-library.netlify.app/spring-boot/secrets-and-crypto/eda7d9fd69/