Harden NGINX against malicious backends
Author: DemiMarieCreated Sep 15, 2026Updated Sep 16, 2026
Labelsenhancementneeds-refinement
Feature Overview
I would like NGINX to be secure against malicious backends.
Alternatives Considered
Leave NGINX insecure against untrusted backends, preventing the use of Nginx Gateway in multi-tenant Kubernetes clusters with untrusted workloads confined via Kata or similar.
Additional Context
I’m not sure what is required for this. The most obvious fixes needed are:
- Rejecting status codes other than 101 and 103.
- Refusing NUL bytes in HTTP status text.
- Refusing 101 responses without an Upgrade header.
- Refusing 1xx responses in FastCGI.
These are all trivial.
Adding response limits might also be needed. I don’t know which ones already exist.
Source: nginx/nginx