Courseiva

CCSP Cloud Application Security Practice Question

A cloud security engineer needs to ensure that a containerized application running in a Kubernetes cluster securely stores and rotates database credentials. Which is the most appropriate solution?

⚠ Common exam trap

ISC2 often tests the misconception that Kubernetes Secrets are inherently secure because they are base64-encoded, but the trap is that base64 is not encryption, and without encryption at rest or an external secrets manager, they are vulnerable to etcd compromise.

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

✓

Use a secrets management system integrated with Kubernetes, such as HashiCorp Vault with CSI driver

HashiCorp Vault integrated with the Kubernetes CSI (Container Storage Interface) driver allows dynamic, short-lived database credentials to be injected into pods as volumes, enabling automatic rotation without application changes. This approach ensures secrets are never stored in the cluster's etcd or exposed in environment variables, aligning with the principle of least privilege and compliance requirements for credential rotation.

Answer analysis

Option-by-option breakdown

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

  • ✗

    Store credentials as environment variables in the pod manifest

    Why it's wrong here

    Environment variables in a pod manifest are static, visible to anyone with pod-spec read access, and cannot rotate without redeploying the workload, so they fail the rotation requirement. They suit non-sensitive configuration such as feature flags or log levels, where values rarely change and exposure carries no credential risk.

  • ✗

    Embed credentials in the container image during build

    Why it's wrong here

    Embedding credentials in the image bakes static secrets into every layer, so rotation requires rebuilding and redeploying, and anyone pulling the image can extract them. It is tempting because image builds routinely inject configuration, and this works for non-sensitive, immutable defaults. Secrets management, not image baking, satisfies the rotation requirement.

  • ✓

    Use a secrets management system integrated with Kubernetes, such as HashiCorp Vault with CSI driver

    Why this is correct

    Vault's CSI driver mounts secrets directly into pods as ephemeral volumes, so credentials never persist in etcd or manifest files, and Vault's lease mechanism rotates them automatically. This satisfies the requirement for secure storage and rotation of database credentials within Kubernetes.

  • ✗

    Use Kubernetes Secrets without encryption at rest

    Why it's wrong here

    Unencrypted Kubernetes Secrets are stored as base64 in etcd, readable by anyone with API or etcd access, and lack automated rotation. Kubernetes Secrets suit non-sensitive configuration; encrypted secrets with an external rotation controller are needed here.

About these practice questions

This CCSP question is part of Courseiva's 934-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. 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 CCSP practice question is part of Courseiva's free ISC2 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 CCSP exam.