Kubernetes Admission Control in 2026: Moving Checks Into the API Server

A Dev.to guide argues that Kubernetes teams should move most admission checks into kube-apiserver and keep external webhooks for tasks that truly need them.

Kubernetes Admission Control in 2026: Moving Checks Into the API Server
Source: Dev.to

The author says external admission webhooks, once the default for hardening clusters, cause several problems. A webhook set to failurePolicy: Fail can deadlock a cluster after a cold boot, every webhook call adds latency to API requests, and each one widens the attack surface. The guide points to IngressNightmare (CVE-2025-1974), disclosed in March 2025, where an unauthenticated webhook endpoint on the pod network let a compromised container reach remote code execution in the ingress-nginx controller and dump cluster Secrets.

The recommended approach is layered. Pod Security Admission, built into kube-apiserver, serves as a baseline and should enforce the restricted profile in application namespaces. Synchronous rules can then be written in Common Expression Language using ValidatingAdmissionPolicy, which reached GA in Kubernetes 1.30, and MutatingAdmissionPolicy, which reached GA in 1.36. Kyverno 1.16 or later remains useful for tasks that need external calls or background work, such as image signature and SLSA verification and generating default-deny NetworkPolicies for each namespace.

The guide also warns about admission ordering. The ServiceAccount plugin runs before MutatingAdmissionPolicy on Pod creation, so changing automountServiceAccountToken on a Pod afterward does not remove the token volume. Setting the default on ServiceAccounts instead avoids this. Any webhook that remains should be locked down with a NetworkPolicy so that only kube-apiserver can reach its ingress port.

Source: Dev.to


Posted

in

by