← Road to Kubestronaut

KUBESTRONAUT · 90-MINUTE MULTIPLE-CHOICE · CURRENT CURRICULUM

KCSA — The Kubernetes and Cloud Native Security Associate Cheatsheet.

kuberneteskcsasecuritythreat-modelingexam-prep

Road to Kubestronaut · Certification 2

KCSA: Security foundations

Guide 2 of 5

KCSA tests whether you can reason about cloud native security before operating security tools under pressure. It is a 90-minute, online, proctored, multiple-choice exam with no prerequisite. Current domains: Cloud Native Security 14% · Cluster Component Security 22% · Kubernetes Security Fundamentals 22% · Threat Model 16% · Platform Security 16% · Compliance & Frameworks 10%. Think in trust boundaries, identities, data flows and layered controls.

0. Exam map and the security reasoning loop

DomainWeightAnchor question
Overview of Cloud Native Security14%Which of the 4Cs owns this risk?
Cluster Component Security22%Which component, credential or endpoint is exposed?
Kubernetes Security Fundamentals22%Which identity, policy or admission control applies?
Kubernetes Threat Model16%What boundary is crossed and what is the attack outcome?
Platform Security16%Which supply-chain, network or PKI control reduces the risk?
Compliance & Frameworks10%Which framework defines, measures or automates the control?
  1. Asset: what needs protection—API, etcd data, image, credential, node, workload?
  2. Actor: user, compromised Pod, malicious image, insider, external attacker?
  3. Boundary: registry→cluster, user→API, Pod→Pod, Pod→node, node→cloud metadata?
  4. Control: prevent, detect, respond or recover?
  5. Layer: apply the control as close to the risk as possible, with defense in depth.

1. The 4Cs of cloud native security

The 4Cs are nested: Cloud → Cluster → Container → Code. A weakness in an outer layer can invalidate inner controls, so securing application code cannot compensate for a publicly exposed control plane or compromised node.

LayerTypical risksRepresentative controls
CloudOverbroad IAM, public networks, metadata theftLeast privilege, private endpoints, workload identity, encryption
ClusterWeak API access, unsafe kubelet/etcd, missing segmentationRBAC, admission, CIS hardening, NetworkPolicy, audit
ContainerRoot, capabilities, writable filesystem, vulnerable imageRestricted security context, scanning, signing, sandboxing
CodeInjection, secrets in source, unsafe dependenciesSAST/SCA, secure SDLC, secret scanning, patching
shared responsibilityManaged Kubernetes shifts operation of some control-plane components to the provider; it does not transfer responsibility for RBAC, workload identity, Pod security, images, application code or data.

2. Kubernetes component security

ComponentSensitive surfaceSecure posture
API serverPrimary control-plane entry pointStrong authn, least-privilege authz, admission, TLS, audit, private reachability
etcdEntire cluster state, including Secret objectsMutual TLS, restricted network access, encryption at rest, protected backups
kubeletNode workload control and logs/exec APIsDisable anonymous access, webhook authz, restrict port/network exposure
scheduler/controllersPowerful kubeconfigs and service accountsProtect credentials, use minimal authorization, bind secure endpoints
container runtimeImage execution and host boundaryPatch runtime, restrict socket, use runtime isolation where needed
kube-proxy/CNICluster dataplaneProtect configuration, enforce segmentation, observe flows
clientkubeconfig, tokens and local pluginsProtect files, use short-lived credentials, distrust unknown kubeconfigs

A kubeconfig can reference credential plugins and remote data; treat an untrusted kubeconfig like executable content. Client certificates, bearer tokens and service-account tokens are credentials—not harmless configuration.

3. Authentication, authorization and admission

The request pipeline is ordered: authenticate identity → authorize action → run admission → persist state. Each stage answers a different question.

  • Authentication: Who are you? Certificates, OIDC tokens, service-account tokens.
  • Authorization: May you perform this verb on this resource? Usually RBAC.
  • Admission: Is the requested object acceptable, and should it be mutated? Built-in or webhook controllers.
  • Audit: What request occurred, who made it and how was it handled?
# authorization checks expose effective privilege
kubectl auth can-i create deployments -n team --as=jane
kubectl auth can-i --list --as=system:serviceaccount:team:builder -n team

# inspect bindings and workload identity
kubectl get rolebindings,clusterrolebindings -A
kubectl get serviceaccount -A
kubectl get pod app -o jsonpath='{.spec.serviceAccountName}'
binding determines scopeA ClusterRole can be bound with a RoleBinding to grant its permissions only inside one namespace. A ClusterRoleBinding makes the grant cluster-wide.

4. Pod, Secret and network security

Pod Security Standards

ProfileIntent
PrivilegedUnrestricted; appropriate only for deliberately trusted system workloads
BaselineBlocks known privilege escalation while remaining broadly compatible
RestrictedStrong hardening: non-root, seccomp, capability and volume constraints

Pod Security Admission applies profiles by namespace labels in enforce, audit and warn modes. Roll out with warn/audit first, fix workloads, then enforce.

securityContext:
  runAsNonRoot: true
  seccompProfile: { type: RuntimeDefault }
containers:
- name: app
  securityContext:
    allowPrivilegeEscalation: false
    readOnlyRootFilesystem: true
    capabilities: { drop: ["ALL"] }

Secrets

  • Base64 is encoding, not encryption. Enable encryption at rest and protect encryption keys.
  • Prefer workload identity or short-lived external secret delivery over long-lived static keys.
  • Restrict get/list/watch on Secrets; list can expose every Secret in scope.
  • Do not log Secret values, bake them into images or commit them to Git.

Isolation and NetworkPolicy

NetworkPolicy is allow-list policy for selected Pods. A Pod becomes isolated for a direction when a policy selects it for that direction. Policies are additive: traffic allowed by any applicable rule remains allowed. Enforcement requires a capable CNI.

apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata: { name: default-deny, namespace: team }
spec:
  podSelector: {}
  policyTypes: [Ingress, Egress]

5. Kubernetes threat model

ThreatExample pathPrimary defenses
PersistenceMalicious DaemonSet, webhook or stolen credentialAdmission, RBAC, audit, immutable delivery
Denial of serviceResource exhaustion or API floodingQuotas, limits, priority, rate controls, capacity
Malicious code executionCompromised image or application RCESigned/scanned images, restricted runtime, segmentation
Attacker on networkSniffing, lateral movement, spoofed serviceTLS/mTLS, NetworkPolicy, identity-aware service mesh
Sensitive-data accessReading Secrets, volumes or etcdRBAC, encryption, key management, audit
Privilege escalationHost mount, privileged Pod, dangerous capabilityRestricted PSS, seccomp/AppArmor, policy admission

A useful threat model maps trust boundaries and data flows: user→API server, API server→etcd, scheduler/controller→API, kubelet→runtime, Pod→Service, Pod→node kernel, cluster→cloud APIs, CI→registry→admission→runtime.

6. Supply-chain and image security

The software supply chain spans source, dependencies, build system, artifact, registry, deployment policy and runtime. Controls must preserve provenance across the chain.

  1. Source: protected branches, reviews, signed commits where appropriate, secret scanning.
  2. Dependencies: lockfiles, SCA, trusted sources and timely patching.
  3. Build: isolated, reproducible, least-privilege CI with protected credentials.
  4. Artifact: minimal non-root image, SBOM, vulnerability scan and signature/attestation.
  5. Registry: authentication, immutable tags or digest pinning, retention and audit.
  6. Admission: require trusted provenance, allowed registries and acceptable policy.
  7. Runtime: detect drift and behavior that build-time scanning cannot see.
scan is not trustA vulnerability scan finds known issues in inspected content. A signature proves who signed an artifact and protects integrity. An attestation states a verifiable claim such as provenance. They solve different problems.

7. Platform security: PKI, mesh and observability

  • PKI/TLS authenticates endpoints and protects data in transit. Rotate certificates and protect private keys.
  • Service mesh can provide workload identity, mTLS, authorization and traffic telemetry; it does not fix insecure application logic.
  • Admission policy prevents unsafe configuration before it enters the cluster.
  • Observability combines Kubernetes audit, workload logs, network flow data, metrics and runtime events.
  • Image repository controls limit who can push/pull, preserve immutability and record provenance.

8. Compliance and security frameworks

Framework/controlPurpose
CIS BenchmarksPrescriptive secure-configuration checks for Kubernetes and hosts
NIST Cybersecurity FrameworkOrganizes outcomes across Govern, Identify, Protect, Detect, Respond, Recover
MITRE ATT&CKModels adversary tactics and techniques; includes container-relevant behavior
STRIDEThreat modeling: spoofing, tampering, repudiation, information disclosure, denial of service, elevation of privilege
SLSASupply-chain integrity and build provenance framework
SBOMInventory of software components; evidence input, not a security verdict

Compliance asks whether required controls are defined and evidenced. Security asks whether risk is actually reduced. Automate policy and evidence collection, but keep human ownership of exceptions, risk decisions and incident response.

9. Control types, zero trust and incident readiness

Control typePurposeKubernetes example
PreventiveStop an unsafe actionAdmission rejects privileged Pod; RBAC denies Secret read
DetectiveReveal suspicious or non-compliant behaviorAudit log, runtime alert, drift scan
CorrectiveRemove or repair a discovered weaknessRotate token, patch image, remove binding
RecoveryRestore trusted service and dataTested etcd backup, redeploy from signed artifacts
CompensatingReduce risk when the preferred control is infeasibleIsolate a legacy workload while remediation is pending

Zero trust means no identity or network location is trusted implicitly. Authenticate explicitly, authorize narrowly, encrypt where required, continuously evaluate signals and assume breach. In Kubernetes that becomes workload identity, short-lived credentials, default-deny segmentation, policy at admission, and runtime observation.

Incident readiness must exist before compromise. Know where audit and workload logs live, synchronize time, protect log integrity, define credential-rotation paths, keep tested backups, and preserve evidence. Recovery from an untrusted image or node should use known-good immutable artifacts—not manual repair inside the compromised container.

10. Isolation strength and tenant boundaries

Isolation is a spectrum. Choose strength based on trust:

  1. Process/container controls: namespaces, cgroups, seccomp, AppArmor, capabilities.
  2. Pod and namespace controls: PSS/PSA, quotas, RBAC, NetworkPolicy and separate identities.
  3. Sandboxed runtime: adds a stronger userspace/kernel boundary for less-trusted workloads.
  4. Virtual machine or separate cluster/account: stronger boundary for hostile multi-tenancy or regulatory separation.

A namespace is useful administrative scope but shares the control plane, nodes and often cluster-scoped resources. Hard multi-tenancy requires combined identity, network, admission, resource, data and runtime boundaries—and sometimes separate clusters.

11. Rapid scenario checks

  • Need to stop privileged Pods before persistence? Admission policy / Pod Security Admission.
  • Need to know whether jane may read Secrets? kubectl auth can-i / authorization review.
  • Need to prove an image came from trusted CI? Verify signature and provenance attestation.
  • Need to find who deleted a Secret? Kubernetes audit logs.
  • Need to limit a compromised frontend's lateral movement? NetworkPolicy plus least-privilege identity.
  • Need to harden a node process? Host controls such as least privilege, AppArmor/seccomp and reduced services—not an application ConfigMap.
  • Need confidentiality between workloads? TLS/mTLS; NetworkPolicy alone controls reachability, not encryption.

12. Common exam traps and study order

  • Confusing authentication, authorization and admission.
  • Treating namespaces as sufficient tenant isolation.
  • Calling base64-encoded Secrets encrypted.
  • Assuming a NetworkPolicy encrypts traffic or works without CNI enforcement.
  • Equating image scanning with signature verification.
  • Using a detect control when the question asks to prevent admission.
  • Choosing one magic security product instead of layered controls at different boundaries.

Study in this order: request pipeline and RBAC → component trust boundaries → Pod/Secret/network security → threat scenarios → supply chain → PKI/mesh/observability → compliance frameworks. For every control, be able to name what it prevents, what it detects, and what it cannot do.

Official sources & freshness

This guide was checked against the official Linux Foundation exam page and CNCF curriculum on 19 July 2026. Exam versions and policies can change; re-check the source page before booking.

← prev: KCNA next: CKA →
© cvam — written in plaintext, served warm