Cloud Security

3 Pod Security Admission Gaps That Leave Pods Unchecked

November 6, 2026 · 5 min read · By CloudAI Security
3 Pod Security Admission Gaps That Leave Pods Unchecked

Pod security admission gives every supported cluster a built-in gate for Pod Security Standards, and it fails quietly in the same three places: namespaces pinned to warn or audit that never graduate to enforce, workload resources such as Deployments and DaemonSets that skip enforce checks, and exemption rules plus carve-outs for Pod updates that bypass evaluation altogether. Pod Security Admission has been a stable part of Kubernetes since v1.25, so every maintained cluster already has the machinery to enforce Pod Security Standards with namespace labels, and the review below needs nothing beyond kubectl and read access to the admission configuration.

What the labels actually enforce

Each namespace carries its own policy through two label families. The level label, pod-security.kubernetes.io/enforce, /audit or /warn, selects privileged, baseline or restricted for that mode, and a companion version label pins the policy to the exact rules that shipped with a given minor release, so a cluster upgrade never silently rewrites what passes. The modes are not synonyms: enforce rejects the violating Pod, audit writes an annotation into the audit log, and warn shows a user-facing message while still admitting the Pod. A namespace can run all three modes at different levels at once, which is exactly how a careful rollout works — warn and audit first, enforce after the noise dies down.

ModeWhat happens on a violationWhere the signal lands
enforcePod creation is rejectedAPI response; rollout fails at Pod creation
auditAnnotation added to the audit eventCluster audit log only
warnUser-facing warning; Pod still admittedCLI output of the creating user

Gap one: workload objects skip enforcement

The first gap is documented in plain sight and still catches teams during rollouts: enforce mode is not applied to workload resources, only to the resulting Pod objects created from their templates. Audit and warn do evaluate Deployment, Job and DaemonSet templates when the object is created, which is useful for early feedback, but the rejection everyone plans around — the one that blocks a bad template — never happens at the workload layer. The practical consequence: a pipeline that validates manifests only against admission can pass a change that later fails at Pod creation, at rollout time, on someone’s on-call shift. Treat any workload template that has only ever been checked by audit or warn as unverified until a real Pod built from it has been admitted under enforce.

Gap two: namespaces stuck on warn

The second gap accumulates over time. Migration guides recommend labeling namespaces with warn and audit first, then promoting them to enforce, and nothing in the platform nudges you to finish the job. Warn is not enforcement: months later, the label set that was meant as a waypoint has quietly become policy, and a namespace that only warns still admits every violating Pod it complained about. The check is one command — kubectl get namespaces --show-labels — followed by flagging every namespace that carries an audit or warn label but no enforce label. For each hit, decide deliberately: either promote it, with a version pin so the policy does not drift with upgrades, or document why it stays permissive. An unexplained warn-only namespace is indistinguishable from an abandoned migration.

Gap three: exemptions and updates

The third gap is configured, not accidental. Admission exemptions are enumerated explicitly — usernames, runtime class names and whole namespaces — and exempt requests skip every mode, with no warning and no audit record. The Kubernetes documentation carries a caution worth reading twice: exempting a controller service account implicitly exempts every user who can create the matching workload resource, so an exemption intended for one automation quietly widens to everyone able to trigger it. Separately, updates that only touch Pod metadata or tolerations are exempt from policy checks, which is reasonable for evicted Pods but means metadata churn can mask changes that a fresh submission would have flagged.

History explains why this layer deserves a hard line. The kubelet subpath symlink flaw tracked as CVE-2021-25741 was rated High because it could reach files outside a mounted volume, including on the host filesystem, and the advisory notes that environments which had restricted hostPath were the most seriously affected, because subpath offered a path around the restriction. The Baseline level already refuses hostPath volumes, one of the classic escape hatches admission exists to close, and a namespace sitting in privileged or riding an exemption keeps that hatch open. The same advisory lists the fixed release trains, so an unpatched kubelet surfaces as a live finding during this review rather than as an assumption.

A three-pass admission audit

  1. Inventory the labels. Run kubectl get namespaces --show-labels; every namespace should have an explicit enforce label or a recorded exception. Promote warn-only stragglers with a version pin, and write down why any namespace stays permissive.
  2. Verify templates through real Pods. Because enforcement lands at Pod creation, roll each changed workload through a namespace already at enforce before the change leaves staging. A template that has only seen warn and audit has not been tested against the policy that matters.
  3. Read the admission configuration. Pull the admission controller config, list every exemption by username, runtime class and namespace, and watch the pod_security_exemptions_total metric on the API server to see how often each one fires. An exemption that fires daily is a standing hole, not an exception.

Pair this review with the wider monthly habit: the storage exposure drift signals worth reviewing monthly catch misconfiguration that admission never sees, and the discipline behind the runbook for containing a leaked Terraform state file applies just as well when someone’s exemption list ends up in a repository. Admission decides what enters the cluster; these three passes decide whether that decision still matches reality.

Sources