How do you secure the ingress controller layer, given recent critical CVEs in ingress controllers?
AdvancedProductionKubernetes Security Posture
Answer
The ingress controller sits on the internet edge and often has cluster-wide read access to Secrets, so a bug there is severe (for example the 2025 ingress-nginx admission webhook RCE, CVE-2025-1974).
- Patch quickly and track the project's support status; ingress-nginx has announced retirement, so plan a move to a maintained controller or Gateway API implementation.
- Never expose the admission webhook outside the cluster; restrict it with NetworkPolicy to the API server.
- Disable risky features such as user-supplied configuration snippets (
allow-snippet-annotations: false). - Scope the controller's RBAC to the namespaces it serves where the controller supports it.
- Put a WAF or CDN in front, and terminate TLS with managed certificates.
More on Kubernetes Security Posture
What is your security baseline for a new production EKS cluster?IntermediateDraw the layered security controls for workloads on Kubernetes.BeginnerHow do you assign Pod Security Admission levels across namespaces in production?BeginnerKyverno, OPA Gatekeeper or ValidatingAdmissionPolicy: how do you choose?IntermediateShow a ValidatingAdmissionPolicy that blocks containers without resource limits.AdvancedHow do you roll out default-deny NetworkPolicies in a running production cluster?Intermediate