Every request to the Kubernetes API passes through authentication, authorization and then admission. Built-in admission controllers enforce rules such as resource quotas and Pod Security Standards. Two extension points let an organization add its own: mutating admission webhooks, which can change an object (for example by adding default labels or a sidecar), and validating admission webhooks, which can only accept or reject it. Kubernetes also offers ValidatingAdmissionPolicy, which evaluates CEL expressions inside the API server without an external webhook.
How it is used in practice
Admission control is the last point at which a cluster can refuse something before it runs. Teams use it to enforce policy as code on workloads: no privileged containers, no host-path mounts, no images from unapproved registries, required resource limits, and, with a scanner behind the webhook, no images with unacceptable vulnerabilities. Rollouts usually start in an audit or warn mode, which records or displays violations without blocking, and move to enforce once the violations that would have been refused are understood.
Common pitfalls
- Fail-open versus fail-closed. If the webhook cannot be reached, the cluster must decide whether to admit the workload or refuse it. Failing closed can block every deploy, including the fix for whatever broke the webhook; failing open admits unchecked workloads.
- Judging templates, not pods. Defaults injected by a namespace's LimitRange appear on the Pods a controller creates, not on the Deployment template, so some checks are only accurate at Pod admission.
- Blocking on everything. Refusing every image with a mutable tag, or every never-scanned image, stops ordinary deploys and gets the control disabled.
- Unrecorded decisions. Warnings shown in
kubectldisappear unless they are also logged.
How TrustIvan relates to it
A connected cluster can call TrustIvan from its validating admission webhook, which a Helm chart installs together with a small in-cluster relay. The endpoint is off by default per cluster. It first checks the webhook's TrustIvan credential through the same authorization broker as every other endpoint, then judges the pod the request would create against the workload and container checks of the Kubernetes posture catalog, the cluster's trusted-registry list, and the open findings of each image it would run. A mode of audit, warn (the default) or deny decides what happens to a failing workload; in deny, medium-or-higher checks and images with open critical or high findings block, while low-severity checks such as a mutable tag or a missing limit, and never-scanned images, only warn. A separate failure_mode decides what happens when TrustIvan cannot answer: since 2026-10-29 a newly connected cluster fails closed, and the chart's webhook defaults to failurePolicy: Fail, so a workload is refused, with kube-system and the chart's own namespace exempt. That means a TrustIvan outage stops deployments in every other namespace; the documented opt-out is open plus failurePolicy: Ignore, and every un-adjudicated admission is audited. Clusters connected earlier keep their mode. The chart has been tested on a local k3d cluster with TrustIvan unreachable; a review through the relay to a live TrustIvan and back has not been run, and no managed distribution has been tested. See Admission webhook and Cloud and Kubernetes.
Related terms
- Policy as code Policy as code is the practice of expressing security, compliance and operational rules as machine-readable definitions that are versioned, reviewed and evaluated automatically, rather than as prose in a document.
- Container image scanning Container image scanning analyzes the contents of a container image, its operating-system packages, language dependencies and configuration, for known vulnerabilities and other security issues, before or after the image is deployed.
- Image signing (Sigstore and cosign) Container image signing attaches a cryptographic signature to an image's digest so that anyone deploying it can check who published those exact bytes. Sigstore is an open-source project for this, and cosign is its signing tool for containers.
- Service account A service account is an identity created for an application, workload or automation to authenticate as, rather than for a person, and granted permissions through roles or bindings.
- IaC scanning (infrastructure-as-code scanning) Infrastructure-as-code (IaC) scanning analyzes the files that define infrastructure, such as Terraform, CloudFormation, Kubernetes manifests, Helm charts and Dockerfiles, for insecure configuration before it is deployed.
Guides on Admission control
- Kubernetes Admission Control for Image Provenance Sign container images in CI, attest how they were built, and refuse unsigned or unpinned images at admission with Kyverno and ValidatingAdmissionPolicy.
- Least Privilege for CI/CD Identities: GitHub Actions OIDC Replace long-lived cloud keys in CI with GitHub Actions OIDC, then scope the trust policy, the role and GITHUB_TOKEN so a pipeline can do only its own job.
On the platform: Policy engine. All glossary terms