Courseiva
Develop Azure compute solutionsmediumMultiple ChoiceObjective-mapped

AZ-204 Develop Azure compute solutions Practice Question

A company deploys a microservices application on Azure Kubernetes Service (AKS). They need to securely store configuration settings such as database connection strings and API keys. The solution must minimize administrative overhead and automatically rotate keys. What should they use?

⚠ Common exam trap

Candidates often confuse Azure App Configuration (which is for non-sensitive config and feature flags) with Azure Key Vault (which is the correct service for secrets), or they assume base64 encoding in Kubernetes Secrets provides security, when it is merely obfuscation.

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 Azure Key Vault with the Secrets Store CSI driver.

Azure Key Vault with the Secrets Store CSI driver allows you to mount secrets as volumes or environment variables in AKS pods without exposing them in plaintext or requiring manual rotation. The CSI driver synchronizes secrets from Key Vault to a Kubernetes volume, and Key Vault supports automatic key rotation policies, minimizing administrative overhead while ensuring security.

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 secrets as Kubernetes Secrets objects with base64 encoding.

    Why it's wrong here

    While Kubernetes Secrets can store sensitive data, base64 encoding is merely an obfuscation, not encryption, meaning the secret content is easily decodable by anyone with access. By default, these secrets are stored unencrypted in etcd, making them vulnerable if the etcd database is compromised. Furthermore, managing secret rotation for Kubernetes Secrets is a manual process, increasing operational overhead and the risk of using stale or compromised credentials.

  • Use Azure Key Vault with the Secrets Store CSI driver.

    Why this is correct

    This is the most secure and recommended approach for microservices on AKS. Azure Key Vault provides a highly secure, centralized store for secrets, certificates, and keys, with robust access controls, auditing, and encryption at rest. The Secrets Store CSI driver allows Kubernetes pods to mount secrets from Key Vault as an ephemeral volume, making them available to containers as files, and supports automatic secret rotation without requiring pod restarts, significantly enhancing security and reducing operational overhead.

  • Use Azure App Configuration with feature flags.

    Why it's wrong here

    Azure App Configuration is primarily designed for managing application settings and feature flags, not for storing high-value secrets like database connection strings or API keys. While it can store key-value pairs, it lacks the advanced security features of a dedicated secret management service. Specifically, it does not offer automatic secret rotation, versioning, or granular access policies tailored for sensitive data, making it unsuitable for robust secret management.

  • Store secrets as environment variables in the container's deployment YAML.

    Why it's wrong here

    Storing secrets directly as environment variables within a container's deployment YAML is highly insecure. These secrets are exposed in plain text within the YAML file itself, are easily visible via `kubectl describe pod` commands, and can be inadvertently logged or accessed through process inspection within the container. This method offers no encryption at rest or in transit, lacks any rotation mechanism, and violates fundamental security best practices for sensitive data handling.

About these practice questions

One of 881 original AZ-204 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 AZ-204 practice question is part of Courseiva's free Microsoft 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 AZ-204 exam.