easyMultiple Choice
CAS-004 Practice Question: A company's development team uses a CI/CD…
A company's development team uses a CI/CD pipeline hosted in a public cloud. The pipeline builds container images, pushes them to a private registry, and deploys them to a Kubernetes cluster. A security engineer must ensure that only signed and vulnerability-scanned images are deployed. The engineer has configured the registry to require signatures and the CI/CD pipeline to scan images. However, deployments are still failing because unsigned images are being pulled. The engineer discovers that developers can push images directly to the registry bypassing the CI/CD pipeline and that Kubernetes nodes can pull images without signature verification. Which of the following should the engineer implement to enforce image signing and scanning?
⚠ Common exam trap
The trap here is that candidates often focus only on the CI/CD pipeline (e.g., scanning or approvals) and overlook the need to restrict direct registry access and enforce signature verification at the cluster level, which are the two distinct vulnerabilities described in the scenario.
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
✓
Restrict registry write access to the CI/CD service account and enable image signature verification via admission controller in Kubernetes.
It addresses both root causes: restricting registry write access to only the CI/CD service account prevents developers from bypassing the pipeline, and enabling image signature verification via an admission controller (e.g., using Kubernetes ImagePolicyWebhook or a tool like Cosign with OCI signatures) ensures that only signed and scanned images are allowed to run in the cluster. This combination enforces the security policy at both the registry and the cluster level, closing the gaps identified in the scenario.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Implement a manual approval step in the pipeline for each deployment.
Why it's wrong here
A manual approval step gates pipeline deployments only; direct registry pushes and unsigned pulls bypass it entirely. It is tempting because approvals add control over releases, but the stem needs cryptographic verification at admission, which manual review cannot provide.
- ✗
Use network policies to block all outbound traffic from developer workstations to the container registry.
Why it's wrong here
Network policies filter pod-to-pod and egress traffic inside the cluster; they cannot verify image signatures or stop unsigned images already pushed to the registry. It is tempting because it restricts developer egress, but admission control and registry-side verification are what enforce signing.
- ✓
Restrict registry write access to the CI/CD service account and enable image signature verification via admission controller in Kubernetes.
Why this is correct
Restricting registry write access to the CI/CD service account prevents developers bypassing the pipeline, while a Kubernetes admission controller rejects unsigned images at deploy time. Together these enforce signing and scanning, closing both gaps the stem describes.
- ✗
Configure the CI/CD pipeline to perform vulnerability scanning after every build.
Why it's wrong here
Scanning after every build is already configured and does nothing about developers pushing directly to the registry or nodes pulling unverified images. It is tempting because scanning is part of the requirement, but the gap is enforcement at admission and registry level, not scan frequency.
Go deeper
Related to this question
About these practice questions
Courseiva writes every CAS-005 question from scratch — 973 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This CAS-005 practice question is part of Courseiva's free CompTIA 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 CAS-005 exam.