Courseiva
easyMultiple Choice

CAS-004 Practice Question: Implementing a microservices architecture and…

A company is implementing a microservices architecture and needs to ensure secure service-to-service communication. Which of the following BEST describes the recommended approach?

⚠ Common exam trap

CompTIA often tests the misconception that IP whitelisting or shared API keys are sufficient for service-to-service security, but the trap here is that candidates overlook the need for both encryption and mutual authentication in a zero-trust microservices environment, where network perimeters are obsolete and dynamic identity verification is critical.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

✓

Mutual TLS (mTLS) with certificate authentication

Mutual TLS (mTLS) with certificate authentication is the recommended approach for secure service-to-service communication in a microservices architecture because it provides both encryption and bidirectional authentication. Each service presents a unique X.509 certificate to verify its identity, preventing unauthorized access and man-in-the-middle attacks. This aligns with the principle of zero-trust networking, where no implicit trust is granted based on network location.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • ✗

    Basic HTTP authentication

    Why it's wrong here

    Basic HTTP authentication sends reusable base64 credentials with every request, giving no per-service identity or scoped authorisation. It is tempting because it is trivial to add to internal endpoints, and would be correct for a throwaway prototype behind a trusted network boundary, not production microservices.

  • ✓

    Mutual TLS (mTLS) with certificate authentication

    Why this is correct

    Mutual TLS authenticates both client and server via X.509 certificates, giving each microservice a cryptographic identity independent of network location. This satisfies the zero-trust requirement for service-to-service communication, where workloads are ephemeral and IP-based trust fails. Certificates can be rotated and scoped per service, enabling least-privilege access without shared secrets.

  • ✗

    IP whitelisting

    Why it's wrong here

    IP whitelisting trusts network location, so any workload on a permitted address is accepted and identity is never verified. It is tempting because it is simple and blocks external scanners, and would be correct as a defence-in-depth layer alongside authenticated service identity, not as the primary mechanism.

  • ✗

    Shared API keys

    Why it's wrong here

    Shared API keys are long-lived secrets common to every caller, so they cannot express per-service identity, scoped permissions or rotation without coordinated downtime. They are tempting for quick internal integrations, and would be correct for a single trusted client calling one API, not a mesh of services.

About these practice questions

One of 973 original CAS-005 practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This CAS-005 practice question is part of Courseiva's free CompTIA certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the CAS-005 exam.