KCSA Kubernetes Security Fundamentals Practice Question
A developer accidentally committed plain-text database passwords into a public Git repository. The password was stored in a Kubernetes Secret manifest. What immediate remediation step should be taken regarding the Secret?
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
✓
Rotate the credential in the underlying database, then update the Kubernetes Secret with the new value.
Rotate the compromised password in the database immediately, then update the Kubernetes Secret with the new password.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Apply a DenyAll NetworkPolicy to the namespace.
Why it's wrong here
NetworkPolicies do not address credentials exposed in source control repositories.
- ✗
Delete the Secret object and restart all cluster nodes.
Why it's wrong here
Restarting nodes does not revoke compromised credentials stored in Git or active database users.
- ✓
Rotate the credential in the underlying database, then update the Kubernetes Secret with the new value.
Why this is correct
Since the secret was exposed, the credential itself is compromised and must be rotated at the source.
- ✗
Change the Secret manifest encoding from base64 to hex format.
Why it's wrong here
Encoding is not encryption; hex provides no security against exposure.
About these practice questions
One of 320 original KCSA 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 →
JA
Written and reviewed by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
Last reviewed August 2026 · checked against the official CNCF / Linux Foundation exam blueprint
This KCSA practice question is part of Courseiva's free CNCF / Linux Foundation 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 KCSA exam.