Courseiva

Kubernetes and Cloud Native Security Associate (KCSA, CNCF) (KCSA) (KCSA) — Questions 301320

320 questions total · 5pages · All types, answers revealed

Page 4

Page 5 of 5

301
MCQmedium

Your security team has discovered that an application container image contains outdated packages with known remote code execution vulnerabilities. Which phase of the software development lifecycle is the most effective place to initially scan and remediate these vulnerabilities?

A.Node OS package manager updates
B.Kubelet container startup phase
C.CI/CD pipeline build stage
D.Kubernetes API server audit logging
AnswerC

Scanning during the CI/CD build phase catches vulnerabilities early and prevents vulnerable images from entering registries.

Why this answer

Scanning images during the CI/CD pipeline build phase allows developers to patch or replace vulnerable packages before the image is ever pushed to a registry or deployed to production.

302
MCQhard

An auditor reviews container runtime configurations for compliance with NIST SP 800-190 recommendations on privilege escalation. Which Kubernetes feature controls whether a process can gain more privileges than its parent process?

A.allowPrivilegeEscalation: false
B.automountServiceAccountToken: false
C.runAsUser: 1000
D.privileged: false
AnswerA

Setting allowPrivilegeEscalation to false prevents child processes from gaining additional privileges.

Why this answer

allowPrivilegeEscalation controls whether a process can gain more privileges through mechanisms like setuid binaries, fulfilling privilege restriction controls.

303
Multi-Selectmedium

Which THREE of the following steps are part of proper Kubernetes control plane certificate management? (Choose THREE)

Select 3 answers
A.Using a trusted Certificate Authority (CA) rather than self-signed certificates where possible.
B.Implementing regular certificate rotation before expiration.
C.Disabling TLS verification for all internal cluster components.
D.Securing private keys with strict file permissions (e.g., 600) on control plane nodes.
E.Storing all private keys in unencrypted public ConfigMaps.
AnswersA, B, D

Trusted CAs integrate with enterprise PKI.

Why this answer

Proper certificate management includes regular rotation, using a trusted internal or enterprise CA, and setting appropriate validity durations.

304
MCQmedium

An administrator suspects that someone is attempting brute-force attacks against the Kubernetes API server. Where should the administrator look to inspect authentication failures generated by the API server?

A.The etcd WAL (Write-Ahead Log) files.
B.The kubelet container logs on worker nodes.
C.The kube-proxy packet capture logs.
D.API server audit logs configured via --audit-log-path.
AnswerD

Audit logs record authentication metadata, including user identities and request outcomes.

Why this answer

API server audit logs capture authentication attempts, including failures, when configured with an appropriate audit policy.

305
Multi-Selecthard

Which THREE security controls can be enforced by admission webhook policy engines (like Kyverno or OPA Gatekeeper) regarding container images? (Choose three)

Select 3 answers
A.Verifying cryptographic image signatures using tools like Cosign
B.Requiring container images to be pulled exclusively from approved enterprise registries
C.Automatically updating kernel modules on the underlying worker node
D.Manually restarting unhealthy pods across worker nodes
E.Blocking deployments of images that contain unmitigated high-severity vulnerabilities
AnswersA, B, E

Policy engines can check signature annotations and public keys before allowing deployment.

Why this answer

Policy engines can enforce image security by requiring specific trusted registries, mandating cryptographic signatures, and blocking images with high/critical vulnerabilities.

306
MCQmedium

An administrator wants to ensure that the Kubernetes API server rejects any incoming requests that do not match known API resource paths or have invalid syntax. Which admission controller helps validate request structures and schema compliance?

A.The etcd transaction validator.
B.The core scheduler admission plugin.
C.The built-in OpenAPI schema validation and ValidatingAdmissionWebhook.
D.The kube-proxy filter admission module.
AnswerC

The API server enforces schema validation using OpenAPI schemas before passing requests to etcd.

Why this answer

Schema validation and structural compliance are handled by the built-in validation mechanisms and admission controllers in the API server.

307
MCQmedium

You are reviewing a security alert indicating that a container running in your Kubernetes cluster attempted to modify host kernel parameters via /proc/sys. Which security configuration was likely missing or misconfigured for this container?

A.The CoreDNS deployment had too few replicas
B.The Ingress controller did not enable TLS termination
C.The PersistentVolumeClaim lacked a storage class
D.The container was run in privileged mode or lacked necessary capability and filesystem hardening
AnswerD

Privileged containers or those with SYS_ADMIN capabilities can modify kernel parameters in /proc and /sys.

Why this answer

Containers must have their capabilities dropped (such as CAP_SYS_ADMIN) and should not run in privileged mode or with writable sysfs/procfs to prevent kernel parameter tampering.

308
MCQmedium

A cluster administrator wants to mitigate supply chain risks stemming from vulnerable base images used by developers. Where in the software lifecycle should vulnerability scanning ideally be integrated first to shift-left security?

A.Manual inspection of etcd database backups
B.Configuring kube-dns forwarding rules to external resolvers
C.Setting up PersistentVolume backup retention policies
D.CI/CD pipeline build and image registry push stages
AnswerD

Scanning container images inside the CI/CD pipeline prevents vulnerable artifacts from ever being published to registries or deployed to production clusters.

Why this answer

Integrating vulnerability scanning into the CI/CD pipeline registry push phase or source code repository ensures vulnerable base images are flagged before they reach cluster deployment stages.

309
MCQmedium

An organization uses AWS IAM to restrict access to their EKS cluster control plane endpoints. According to the shared responsibility model, configuring and maintaining these access entries and cluster RBAC roles is the responsibility of whom?

A.The Linux kernel maintainers
B.The cloud provider only
C.The CNCF security committee
D.The customer
AnswerD

Customers are responsible for configuring IAM policies and Kubernetes RBAC.

Why this answer

Access control configuration (IAM and Kubernetes RBAC) is the responsibility of the customer.

310
MCQmedium

An auditor notices that a secret is mounted as a volume in a pod. Where is this secret stored on the worker node filesystem by default?

A.In an encrypted SQLite database on the node's root partition.
B.In plaintext files inside /etc/kubernetes/secrets on the node's hard drive.
C.Inside the container image layer cache.
D.In tmpfs (memory), ensuring it is not written to non-volatile disk storage.
AnswerD

Secret volumes are backed by tmpfs so they reside in RAM.

Why this answer

Kubernetes secrets mounted as volumes are stored in tmpfs (RAM-backed memory) on the worker node, preventing them from being written to persistent disk storage.

311
MCQmedium

A Kubernetes cluster experiences an attack where an untrusted pod attempts to access the Kubernetes API server and discover cluster secrets. The cluster uses RBAC. What is the mechanism that prevents this pod from reading secrets in other namespaces?

A.Enabling the AlwaysAdmit authorization webhook mode
B.Default ClusterRole bindings assigned automatically to all service accounts
C.NetworkPolicies blocking traffic directed at the Kubernetes API server port
D.Namespaced RoleBindings limiting permissions strictly to the pod's own namespace
AnswerD

Namespaced RoleBindings enforce isolation boundaries so that identities authorized in one namespace cannot access resources in another.

Why this answer

Kubernetes RBAC RoleBindings are namespaced, meaning a Role or RoleBinding grants permissions only within the specific namespace where it is created, preventing cross-namespace access unless a ClusterRoleBinding is used.

312
MCQmedium

You have deployed a NetworkPolicy in a namespace that selects backend pods, defining an 'ingress' rule with a 'from' block. No other NetworkPolicies exist in the namespace. What is the default behavior for traffic from pods not matched by the 'from' selector?

A.All ingress traffic remains allowed by default.
B.The policy fails to apply because an egress rule must also be defined.
C.Only traffic from other namespaces is denied; same-namespace traffic is still allowed.
D.All ingress traffic from unmatched pods is denied.
AnswerD

NetworkPolicies are additive and restrictive; defining an ingress rule makes the targeted pods default-deny for unspecified sources.

Why this answer

When a NetworkPolicy selects a pod and defines an ingress section, all ingress traffic not explicitly allowed by the policy is denied by default.

313
Multi-Selecthard

An enterprise security auditor is reviewing Kubernetes API server admission control configurations for compliance. Which THREE admission plugins or mechanisms are critical for enforcing security policies at admission time? (Choose THREE)

Select 3 answers
A.ValidatingAdmissionWebhook
B.PodSecurity
C.InsecureServing
D.NodeRestriction
E.AlwaysAllow
AnswersA, B, D

Webhooks allow external engines (like OPA Gatekeeper) to validate incoming requests.

Why this answer

NodeRestriction, ValidatingAdmissionWebhook, and PodSecurity are key admission mechanisms for enforcing security policies.

314
Multi-Selecthard

Which THREE of the following supply chain vulnerabilities or risks can impact Kubernetes application deployments during the build or deployment phase?

Select 3 answers
A.Enforcing Pod Security Standards in baseline mode in production namespaces
B.Using outdated container base images containing known remote code execution CVEs
C.Typosquatting malicious packages in public package registries (npm, PyPI)
D.Deploying third-party Helm charts that contain backdoored deployment templates
E.Enabling Kubernetes audit logging with webhook sinks
AnswersB, C, D

Outdated base images inherit known vulnerabilities that attackers can exploit at runtime.

Why this answer

Compromised base images, typosquatting dependencies, and untrusted Helm charts are all common supply chain vectors.

315
Multi-Selecthard

Which THREE of the following auditing or logging mechanisms should be configured on a secure Kubernetes control plane? (Choose THREE)

Select 3 answers
A.Kubernetes API server audit logging configured with an audit policy file.
B.Routing all cluster traffic through an unencrypted proxy log.
C.Kubelet system and container execution logs on worker nodes.
D.Disabling all log outputs to prevent disk space exhaustion.
E.Etcd audit and operational logging for database transactions and peer health.
AnswersA, C, E

API server audit logs capture request history and user metadata.

Why this answer

API server audit logging, etcd transaction logging, and node system logs are crucial auditing layers.

316
MCQmedium

A security team needs to ensure that Kubernetes nodes have secure file permissions for the kubelet configuration files, in alignment with CIS benchmarks. What should the file permissions on "/etc/kubernetes/kubelet.conf" typically be set to?

A.777
B.755
C.600
D.644
AnswerC

600 restricts read and write access exclusively to the root owner.

Why this answer

CIS benchmarks state that configuration files containing sensitive credentials, such as kubelet.conf, must have permissions set to 600 or stricter and be owned by root:root.

317
MCQhard

You are auditing a Kubernetes cluster and notice that a specific ServiceAccount has been granted the 'impersonate' verb on users. What security risk does this permission introduce?

A.It automatically generates valid X.509 client certificates for cluster nodes.
B.It allows the pod to intercept network traffic of other pods on the same node.
C.It permits the ServiceAccount to bypass the Kubernetes API server and write directly to etcd.
D.It allows the ServiceAccount to act as any user or service account, leading to privilege escalation.
AnswerD

Impersonation grants the ability to assume other identities, bypassing standard RBAC restrictions if high-privilege identities can be assumed.

Why this answer

The 'impersonate' verb allows the holder to act as other users or service accounts, effectively escalating their privileges to match any identity they can impersonate.

318
Multi-Selecteasy

Which TWO configuration practices improve container runtime security on Kubernetes nodes? (Choose two)

Select 2 answers
A.Enforcing non-root execution via container securityContext
B.Mounting the Docker socket inside application containers
C.Using read-only root filesystems to prevent tampering with binaries
D.Disabling all seccomp and AppArmor profiles
E.Granting CAP_SYS_ADMIN to all containers by default
AnswersA, C

Running containers as non-root reduces the blast radius of container escapes.

Why this answer

Runtime security is improved by using non-root users and ensuring root filesystems are read-only where possible.

319
MCQmedium

A DevOps team uses mutable image tags like `:latest` in their deployment manifests. Under supply chain threat modeling, what vulnerability does this practice introduce?

A.Automatic revocation of TLS certificates issued by cert-manager
B.Exposition of etcd database credentials on public DNS servers
C.Escalation of RBAC permissions from Role to ClusterRole
D.Image Tag Hijacking / Malicious substitution without manifest updates
AnswerD

Because `:latest` can point to different digests over time, a compromised registry allows attackers to replace legitimate images with malicious ones silently.

Why this answer

Mutable image tags allow an attacker who compromises the image registry to overwrite the tag with a malicious binary, causing pods restarting or pulling new instances to execute compromised code without changing the deployment manifest.

320
MCQhard

A cluster administrator wants to implement admission control auditing to record all mutating and validating requests made to the API server. Which component configuration handles this requirement?

A.Configure the kubelet audit webhook via /etc/kubernetes/audit.json.
B.Enable kube-proxy audit mode using --audit-proxy=true.
C.Set etcd logging level to DEBUG in the etcd configuration yaml.
D.Configure an audit policy file and pass its path to the API server via --audit-policy-file.
AnswerD

The API server uses an audit policy file referenced by flag to determine which requests are logged and how.

Why this answer

Kubernetes Audit Policy configuration files define what events are recorded and at what log level by the API server audit backend.

Page 4

Page 5 of 5

All pages