nerdexam
Linux_Foundation

CKS · Question #67

Fix one prominent security/best-practice issue in the Deployment manifest located at /home/candidate/subtle-bee/deployment.yaml. You must change ONLY ONE existing field that is a clear security issue.

4) Open the manifest vi /home/candidate/subtle-bee/deployment.yaml 5) Change ONLY ONE existing field that is a clear security issue Use / search in vi for the usual "bad fields": Option 1 (most common): running as root Search: /runAsUser If you see: runAsUser: 0 Change only that

Submitted by fatima_kr· May 4, 2026Minimize Microservice Vulnerabilities

Question

Fix one prominent security/best-practice issue in the Deployment manifest located at /home/candidate/subtle-bee/deployment.yaml. You must change ONLY ONE existing field that is a clear security issue.

Explanation

  1. Open the manifest vi /home/candidate/subtle-bee/deployment.yaml

  2. Change ONLY ONE existing field that is a clear security issue

Use / search in vi for the usual "bad fields":

Option 1 (most common): running as root Search: /runAsUser If you see: runAsUser: 0 Change only that value to: runAsUser: 65535

This is a single-field change and matches the prompt hint.

Option 2: privileged container Search: /privileged If you see: privileged: true Change only that value to: privileged: false

Option 3: allow privilege escalation Search: /allowPrivilegeEscalation If you see: allowPrivilegeEscalation: true Change only that value to: allowPrivilegeEscalation: false

Option 4: writable root filesystem Search: /readOnlyRootFileSystem If you see: readOnlyRootFileSystem: false Change only that value to: readOnlyRootFileSystem: true

Option 5: image uses :latest Search: /image If you see: image: something:latest Change only that value to a pinned tag, e.g.: image: something:1.2.3

  1. Save and exit :wq

What to pick (fast decision rule) If you see run as root in either file, that's usually the highest scoring / most "prominent" security issue. Dockerfile: USER root -> USER 65535 Deployment: runAsUser: 0 -> runAsUser: 65535

Those are perfect because you only modify one line/field and it matches the hint.

Topics

#Kubernetes Security#Pod Security Standards#Deployment Configuration#Vulnerability Remediation

Community Discussion

No community discussion yet for this question.

Full CKS Practice