Quiz: Chapter 06 (Security Context & Pod Hardening)
Questions
Why is
runAsNonRoot: truea production guardrail?What risk does
allowPrivilegeEscalation: falsereduce?Why use
capabilities.drop: [ALL]by default?What does
readOnlyRootFilesystem: trueforce teams to do?Which statement is correct?
- A) If a pod fails on permissions, run it as root.
- B) Use explicit writable volume mounts and keep non-root execution.
- C) Disable seccomp for easier debugging.
Name one signal that a pod is not properly hardened.
Why is
seccompProfile: RuntimeDefaultimportant?Best rollback for a broken hardening change is:
- A) patch live pod with root and continue
- B) revert manifest in Git and let Flux reconcile
- C) disable all admission/security controls
Which control pair best limits container escape surface?
Complete the course rule:
- A) AI can bypass pod hardening in urgent incidents
- B) guardrails stay on; fixes must preserve security baseline
- C) non-prod should ignore hardening
Answer Key (Short)
- Prevents root execution and reduces privilege abuse surface.
- Blocks gaining additional privileges via setuid/setcap paths.
- Minimizes Linux kernel attack surface and unnecessary privileges.
- Declare required writable paths explicitly (for example
/tmp, cache/run dirs). - B
- Example:
runAsUser: 0, privileged mode, no seccomp, writable root FS without justification. - It applies a safer syscall profile and reduces kernel exploit surface.
- B
- Non-root execution + dropped capabilities (plus no privilege escalation).
- B