Reviewed 10 October 2026 against the linked published scope. Domains: setup 15%, cluster hardening 15%, system hardening 10%, microservices 20%, supply chain 20%, runtime 20%.
Memory hook: Reduce access, constrain execution, verify provenance and detect what still gets through.
Read the essentials, cover the answers and explain the decision aloud. Open the topic summaries below whenever a distinction is unclear.
Cluster setup and hardening
- Start with the exact context, version and authorized scope. Protect API access, kubelet endpoints, credentials and etcd. TLS protects transport; authentication identifies a caller; authorization decides allowed API operations; admission evaluates accepted requests before persistence/execution.
- RBAC grants additive permissions. Minimize powerful verbs such as bind, escalate and impersonate, along with Secret access and workload creation that can expose privileged identities. Namespace scope alone is not a hard multitenant isolation guarantee.
- Use dedicated ServiceAccounts and avoid unnecessary token mounts. Limit API-server exposure, verify certificate identities and constrain management paths. Node/kubelet administrative access can undermine workload security.
- NetworkPolicy requires enforcing CNI support. Default-deny ingress and egress need explicit essential allowances, including DNS. A policy cannot automatically control every host-network or node-origin behavior.
- Apply benchmark findings deliberately. Upgrade vulnerable components within compatibility rules; a scanner result is a finding to interpret, not permission to break a cluster blindly.
Host and workload hardening
- Reduce installed services, patch the OS/runtime and constrain host access. Use separate privileges and protect runtime sockets. A container mounting a privileged runtime socket can gain extensive control despite an ordinary-looking image.
- Set nonroot execution, disable privilege escalation, drop unnecessary capabilities and use a read-only root filesystem where suitable. Avoid privileged containers and unnecessary host PID/IPC/network namespaces or hostPath mounts.
- Seccomp restricts system calls; AppArmor and SELinux apply different mandatory-access controls. They complement Linux permissions/capabilities. Confirm the active enforcement mechanism and profile availability on the target nodes.
- Pod Security Admission enforces supported namespace policy levels: privileged, baseline and restricted. Enforce rejects violations; warn advises; audit annotates relevant audit events. Pin policy versions when predictable upgrades matter.
- Secrets need least-privilege access, appropriate encryption at rest and rotation. Base64 encoding is not confidentiality. Projected token/config behavior and volume permissions affect exposure.
- Sandboxed runtimes can add isolation at performance/compatibility cost. RuntimeClass selects a configured handler; it does not install the sandbox. Multi-tenancy may require stronger cluster/node separation.
Supply chain and runtime response
- Build from trusted minimal images, control dependencies and remove unnecessary tooling. Scan images and manifests, prioritize reachable/exploitable findings and rebuild rather than patching running containers manually.
- An immutable digest identifies image content; a signature/provenance attestation supports trusted origin/build claims when properly verified. Neither establishes that the image contains no vulnerabilities or malicious behavior.
- Admission policy can enforce allowed registries, image verification and workload restrictions. Test failure behavior and exemptions. A policy existing in a file is not proof the admission path enforces it.
- Runtime tools detect suspicious behavior such as unexpected shells, sensitive-file reads or anomalous process/network activity. Tune rules to meaningful evidence; a detector does not inherently block the action.
- Audit policy controls recorded API events and detail level. Protect retention/access and avoid logging secret payloads unnecessarily. Application/runtime logs and API audit logs cover different activity.
- During an incident, determine scope, preserve relevant evidence, contain through authorized controls, revoke/rotate exposed credentials and restore from trusted artifacts. Replacing one Pod without fixing the compromised image or identity can recreate the incident.
Practical traps
- Security settings must coexist with a functioning required workload. Test the specified user, path, network flow and failure case.
runAsNonRootalone does not remove every capability or writable host mount.- For host profiles, distinguish a seccomp file path from an AppArmor profile name. Required profiles must exist on all eligible nodes.
- Audit rules stop at the first match. Check mounts, destination records and identity fields; a policy file alone provides no evidence of delivery.
- Pod Security enforcement labels affect admission and do not evict existing Pods. Review current workloads and plan the required rollout.
- Practice using permitted documentation and the booked runtime; curriculum filenames do not guarantee the live environment version.
Kubestronaut exam preparation
CKS supplies security practice for the five-exam Kubestronaut path. Rehearse with the current permitted security references; the list differs from CKA/CKAD. CertSloth is preparation material, not an allowed in-exam reference.
Final active recall
1. What is missing if a base64 Secret is called encrypted?
Actual encryption and key/access controls. Base64 only encodes data.
2. Does an image digest prove a trusted publisher?
No. It identifies content; verified signatures/provenance supply origin/build evidence.
3. What does RuntimeClass install?
Nothing by itself; it selects a preconfigured runtime handler.
4. Can a runtime alert guarantee the attack was blocked?
No. Detection and prevention are different capabilities.
5. A malicious Pod is deleted but returns. Why?
Its controller still desires it; fix the source configuration/image/identity and the broader incident cause.
Sources and further practice
- Official exam scope
- Objective-to-topic coverage map. Each full topic links to its supporting primary technical documentation.
- Kubernetes security
- Current candidate FAQ and environment versions
- Kubestronaut requirements
Every topic at a glance
Open any topic to revisit its essential facts, decisions and exam traps. Use the full topic for active recall and supporting references.
01 · Services, DNS and Network Policy
Memory hook: Selector finds endpoints; policy permits the path.
Must remember
Pods communicate using cluster networking supplied by the CNI. A Service gives stable discovery for a changing set of endpoints. Check labels/selectors, target ports and EndpointSlices when traffic reaches the Service but no application responds.
| Type | Use |
|---|---|
| ClusterIP | Internal stable virtual service address. |
| NodePort | A port exposed on nodes, with the Service forwarding to backends. |
| LoadBalancer | Requests an external load balancer from an available implementation. |
Headless (clusterIP: None) |
DNS discovery of endpoints rather than a normal virtual IP. |
Ingress describes HTTP/S routing, but needs an Ingress controller. TLS certificates normally come from referenced Secrets; matching host/path and backend port matters. Gateway API separates infrastructure ownership (GatewayClass/controller), listeners (Gateway) and application routing (HTTPRoute). Inspect parent references, allowed routes, listener hostnames and cross-namespace ReferenceGrants where needed. Gateway resources also require an implementation.
CoreDNS resolves service names such as api.team.svc.cluster.local, with the actual cluster domain configurable. Test name resolution separately from network reachability. Check namespace search suffixes, CoreDNS Pods/Service, resolv.conf and DNS egress policy before blaming application code.
Gateway routing drill: inspect kubectl get gateway,httproute -n team -o yaml, then trace parentRefs to the listener and backendRefs to the Service. An HTTPRoute backend port is the Service port, not an arbitrary container port. Check host/path matching and the controller's status conditions before testing a request with the intended Host header. A route that exists but never attaches to its Gateway cannot deliver the requested traffic.
NetworkPolicy is enforced only by supporting networking implementations. Policies are additive allow lists. Once a Pod is isolated for ingress or egress, applicable allowed traffic must be specified; when both ends are isolated, both source egress and destination ingress must permit the connection. An empty selector selects all Pods in that namespace. Namespace and Pod selectors in the same peer entry are AND; separate entries are alternatives.
Practical drill: draw client → DNS → Service → endpoint → container. For each arrow, identify one read-only command and one possible configuration fault.
Choose under exam pressure
| Requirement | Choice and reason |
|---|---|
| HTTP host/path routing | Ingress or Gateway API with a working controller. |
| Service has no backends | Inspect selectors, Pod readiness and EndpointSlices. |
| Restrict Pod communication | NetworkPolicies plus a capable CNI implementation. |
Traps
- Creating a LoadBalancer Service does not guarantee a load-balancer implementation exists.
- Default-deny egress can also block DNS.
02 · Cluster Lifecycle, RBAC and Extensions
Memory hook: API decides; controllers reconcile; nodes execute.
Must remember
The API server validates requests and exposes cluster state; etcd persists it. The scheduler assigns unscheduled Pods to nodes; controllers reconcile desired state. Node kubelets supervise Pods through a CRI runtime; CNI provides networking and CSI storage integration.
Before kubeadm installation, verify hostnames, addresses, time, ports, container runtime/cgroups and the version-specific swap requirements. kubeadm init creates a control plane; join information adds nodes. A highly available control plane needs multiple control-plane instances, a stable API endpoint/load balancer and a quorum-safe etcd design. A load balancer alone does not replicate etcd.
Upgrade deliberately: inspect version compatibility and kubeadm's upgrade plan, upgrade control-plane nodes in the documented order, then workers. Drain a node before disruptive maintenance, accounting for PodDisruptionBudgets and local data, and uncordon afterward. Do not force a blocked drain without understanding which workload guarantee it protects. Back up etcd and practise version-appropriate recovery in a sandbox.
RBAC grants verbs on API resources. A Role is namespaced; a ClusterRole can describe broader permissions. A RoleBinding can reference a ClusterRole while granting its namespaced permissions only in the binding's namespace. A ClusterRoleBinding grants cluster-wide scope. Bind users, groups or service accounts; inspect with kubectl auth can-i using the required identity/context.
RBAC permissions are additive: there is no ordinary RBAC deny rule to cancel another grant. Core resources use apiGroups: [""]; Deployments use apps; Pod logs are the separate pods/log subresource. Test the precise verb, resource and namespace, for example kubectl auth can-i get pods --as=system:serviceaccount:team:reader -n team. Impersonation itself requires permission; testing as the administrator does not prove the workload identity can perform the operation.
Helm templates and packages charts into releases with values; inspect rendered manifests, release history and upgrades. Kustomize transforms base YAML with overlays and patches without template substitution; inspect kubectl kustomize PATH. A CRD adds an API kind; an operator includes a controller that acts on custom resources. Installing a CRD alone does not implement reconciliation.
Practical drill: explain the path from an authenticated Deployment request to running containers, naming which component handles each step.
Choose under exam pressure
| Requirement | Choice and reason |
|---|---|
| Grant one namespace access | A RoleBinding with only the required verbs/resources. |
| Configure a packaged application | Helm values and a controlled release. |
| Patch environment-specific YAML | Kustomize overlays. |
| Automate custom-resource behavior | Install the matching operator, not just its CRD. |
Traps
- Namespaces do not by themselves enforce network isolation.
- Deleting or editing etcd data is not an ordinary application troubleshooting step.
03 · Cluster Exposure, Benchmarks and Trust
Memory hook: Close unnecessary paths before trusting the workload.
Must remember
Restrict API-server, kubelet and etcd access to intended clients. Authenticate and authorize control-plane operations; protect certificates, kubeconfigs and encryption keys. A public IP is not the only exposure: a compromised Pod may reach internal administrative endpoints or node metadata if paths are unrestricted.
Use the appropriate CIS benchmark and a tool such as kube-bench to review settings, then understand each finding before changing it. Benchmark versions and managed-provider responsibilities matter. A control marked manual or not applicable is not automatically a failure; document the rationale and verify the real risk.
Protect cloud instance metadata through provider-supported mechanisms and workload network controls. Prefer workload-scoped identity over inheriting broad node privileges. NetworkPolicy enforcement depends on the CNI, and host-network/metadata paths require explicit platform analysis. Test permitted and denied flows, including DNS and required control-plane access.
Ingress TLS needs a matching host/certificate, protected private key and a controller that actually terminates or passes through TLS as intended. TLS at the edge does not automatically encrypt every backend hop. Verify downloaded platform binaries using trusted checksums/signatures from authenticated distribution sources, not a checksum fetched from the same untrusted mirror.
Patch through supported upgrades with compatibility checks, backups and controlled disruption. Hardening that breaks quorum or locks out authorized recovery can reduce availability without delivering the intended security benefit.
Choose under exam pressure
| Requirement | Choice and reason |
|---|---|
| Unexpected node credentials available to a Pod | Inspect metadata reachability and workload identity design. |
| Benchmark finding | Validate version, applicability and component ownership before remediation. |
| Downloaded cluster binary | Verify trusted origin and integrity before installation. |
Traps
- A passed benchmark is not proof against every attack.
- An edge HTTPS padlock says nothing about all internal hops.
04 · Host, Kernel and Container Hardening
Memory hook: Remove privileges, reduce syscalls, constrain filesystem access.
Must remember
Minimize host packages, daemons, remote access and unnecessary network listeners. Patch the OS/runtime, protect SSH/admin access and audit changes. Containers share a host kernel in ordinary runtimes; container isolation is not automatically a VM boundary.
Linux capabilities divide some root privileges. Drop unneeded capabilities and add only a demonstrated requirement. allowPrivilegeEscalation: false limits gaining more privilege through supported mechanisms; privileged containers and host namespace/mount access greatly expand exposure. A read-only root filesystem reduces writable paths but applications still need explicitly provided writable locations.
seccomp filters system calls. AppArmor applies mandatory access-control profiles to supported processes/resources. They address different layers and require supported node configuration. Start from an appropriate runtime/default profile and refine with evidence; denying a required syscall can break a legitimate application.
For current APIs, locate securityContext.seccompProfile and securityContext.appArmorProfile. RuntimeDefault selects the relevant runtime profile; Localhost refers to a profile already available on the node. A seccomp localhost profile is a path relative to the kubelet's seccomp directory; an AppArmor localhost profile names a loaded profile. Confirm support on every eligible node: a valid YAML field does not install the required host profile.
Run as a suitable non-root UID/GID, constrain filesystem permissions and use runtime isolation such as a supported sandbox/RuntimeClass when the threat model warrants it. A RuntimeClass references an installed configured runtime handler; writing its name does not install a sandbox. Stronger multitenancy may require separate nodes or clusters in addition to namespace controls.
Verification drill: inspect the live Pod security context, selected runtime and node support; exercise normal application behavior, then confirm a prohibited action is denied in a disposable environment.
Choose under exam pressure
| Requirement | Choice and reason |
|---|---|
| Reduce syscall attack surface | An appropriate seccomp profile. |
| Constrain supported filesystem/process access | AppArmor profile with node support. |
| Untrusted workload needs a stronger boundary | Evaluate supported sandboxed runtime or stronger infrastructure separation. |
Traps
- Non-root is one control, not a complete security boundary.
- RuntimeClass does not install its runtime handler.
05 · Pod Security, Secrets and Workload Encryption
Memory hook: Admission constrains configuration; identity constrains access.
Must remember
Pod Security Standards define privileged, baseline and restricted profiles. Pod Security Admission namespace labels select enforcement, audit and warning behavior with version choices. Audit/warn modes report issues without necessarily blocking admission; enforce mode rejects noncompliant creation/update as documented. Existing workloads require deliberate review and rollout. Removed PodSecurityPolicy is not the current native admission mechanism.
Memorize the label shape: pod-security.kubernetes.io/enforce=restricted and pod-security.kubernetes.io/enforce-version=v1.35 select a level and policy version; use the version required by the task. The same prefix supports warn and audit. Inspect with kubectl get namespace team --show-labels. Updating a namespace label does not evict its existing Pods; verify the resulting behavior with an appropriately scoped admission test and a controlled workload rollout.
Minimize Secret access, avoid writing secrets to logs/images and disable unused service-account token mounts. Encrypt supported API data at rest and protect encryption-provider keys/configuration. Changing encryption configuration does not automatically rewrite every existing stored object; follow the documented migration/rotation procedure and keep recovery keys available as needed.
Multi-tenant isolation combines RBAC, quotas, network policy, Pod security and suitable node/runtime boundaries. Namespace separation alone does not prevent all cross-tenant access. Test both allowed and denied paths with the actual workload identity.
Service-mesh mTLS can authenticate/encrypt workload traffic when correctly configured. Cilium encryption and Istio mTLS have different implementation scopes; verify which traffic is protected and how identities/keys are managed. Encryption does not decide whether a service is authorized to call another: apply the corresponding authorization policy. Strict-mode rollout must account for workloads that do not yet participate.
Choose under exam pressure
| Requirement | Choice and reason |
|---|---|
| Reject privileged application Pods | Appropriate Pod Security Admission enforcement. |
| Protect persisted Secret objects | Encryption-at-rest configuration plus restricted API/key access. |
| Authenticate service-to-service traffic | Configured workload mTLS plus authorization policy. |
Traps
- Warning labels do not equal enforcement.
- mTLS does not automatically implement business authorization.
06 · Images, SBOMs and Admission Evidence
Memory hook: Know the contents, verify the origin, enforce before execution.
Must remember
Use minimal maintained base images, multi-stage builds and pinned reviewed digests. Remove unused packages and secrets; a smaller image reduces attack surface but does not prove safety. Distroless images can improve runtime minimalism while requiring a separate debugging strategy.
An SBOM inventories software components and versions. Vulnerability scanning compares them and other evidence to known issues; prioritize by exploitability, exposure and business impact. A signature binds an artifact to an identity under a trust policy; provenance describes its build origin/process. None alone proves the application has no malicious logic or unknown flaws.
Protect source review, build runners, dependency sources, registry credentials and promotion. Avoid rebuilding a different artifact for each environment; promote an immutable tested digest. Restrict permitted registries and use signature/attestation verification through an appropriate admission policy/tooling. A registry allow list says where an image came from, not whether its publisher or contents are trustworthy.
Static manifest analysis such as Kubesec or KubeLinter can detect risky configuration before deployment. Image scanning finds a different class of issues. Integrate checks into delivery and define exception ownership/expiry. Re-evaluate deployed images when new vulnerability information appears.
Choose under exam pressure
| Requirement | Choice and reason |
|---|---|
| Understand packaged dependencies | SBOM plus validated inventory. |
| Verify artifact publisher/build evidence | Signature/provenance under a defined trust policy. |
| Block disallowed image sources | Admission enforcement, not only a written guideline. |
Traps
- Signed does not mean vulnerability-free.
- A scan at build time cannot know every vulnerability discovered later.
07 · Audit Logs, Runtime Signals and Response
Memory hook: Observe the action, identify the actor, preserve the evidence.
Must remember
Kubernetes audit policy selects events, stages and detail levels. Metadata-level records capture request context without full bodies; request/response bodies can contain sensitive information and increase volume. Protect audit destinations, retention and access. An application log, node log and API audit event answer different questions.
Audit rules use the first matching rule. Levels are None, Metadata, Request and RequestResponse; place specific exceptions before broad rules. For a static API-server Pod, the audit-policy file and log destination must be reachable inside the container through correct mounts as well as flags. Inspect actual records for user, verb, object, namespace and response status: a configured file alone does not prove the event reached the intended destination.
Runtime tools such as Falco can detect suspicious behavior from supported event sources: unexpected shells, writes to sensitive paths, privilege changes or unusual network activity. A detection rule is a hypothesis requiring context, not automatic proof of compromise. Tune against legitimate workloads while preserving visibility into important deviations.
Correlate Pod, container, node, namespace, service account, image digest and deployment history. Capture volatile evidence where the response process requires it before restarting/removing the workload. Containment may involve isolating traffic, revoking credentials or stopping a compromised workload; follow authorized incident procedures and preserve a record of actions.
Immutable runtime design uses read-only filesystems, controlled writable volumes and replacement from trusted artifacts instead of manual patching inside a live container. A deleted malicious Pod can simply return if the controller template or source image remains compromised. Fix the source, rotate exposed secrets and verify trusted recovery.
Timed drill: explain how to distinguish a legitimate diagnostic shell from an unauthorized shell using audit identity, deployment context, runtime events and change records. Then identify which evidence a blind restart would lose.
Choose under exam pressure
| Requirement | Choice and reason |
|---|---|
| Who changed a Kubernetes resource? | API audit evidence at the configured level. |
| Unexpected process inside a container | Runtime detection plus workload/identity context. |
| Malicious Pod repeatedly returns | Investigate the controller template, image and credentials. |
Traps
- Audit logging does not capture events retrospectively if it was never enabled.
- Removing one Pod does not repair its desired-state controller.