LiveActive security incident?Get immediate response
CVE Record

CVE-2021-25748: Ingress-nginx `path` sanitization can be bypassed with newline character

A security issue was discovered in ingress-nginx where a user that can create or update ingress objects can use a newline character to bypass the sanitization of the `spec.rules[].http.paths[].path` field of an Ingress object (in the `networking.k8s.io` or `extensions` API group) to obtain the credentials of the ingress-nginx controller. In the default configuration, that credential has access to all secrets in the cluster.

HighCVSS 7.6Not KEV-listedUpdated
Glexia's TakeAutomated analysishigh

Security readout for executives and security teams

Plain-English summary

CVE-2021-25748 affects Kubernetes ingress-nginx. A user who can create or update Ingress objects could abuse a newline in an Ingress path to bypass sanitization and obtain the ingress-nginx controller credentials. In default configuration, those credentials can access all cluster secrets, making this a serious cluster confidentiality risk.

Executive priority

Treat this as high priority for shared or multi-team Kubernetes clusters. The business concern is not website defacement; it is possible exposure of cluster secrets after compromise of a lower-privileged Ingress authoring role.

Technical view

The flaw is improper input validation in ingress-nginx path handling. Sanitization of `spec.rules[].http.paths[].path` can be bypassed with a newline character in Ingress resources from `networking.k8s.io` or `extensions`. Successful abuse can expose the controller credential, which the source states has default access to all cluster secrets.

Likely exposure

Exposure is most likely in Kubernetes clusters using ingress-nginx where tenants, developers, CI systems, or operators can create or update Ingress objects. Risk is higher if the controller runs with broad secret-reading permissions, especially the default described in the CVE source.

Exploitation context

The source does not indicate known active exploitation, and the CVE is not listed as KEV. Exploitation requires authenticated Kubernetes permissions to create or update Ingress objects, but no user interaction is required once that access exists.

Researcher notes

Evidence in the provided bundle does not specify affected or fixed ingress-nginx versions. The key validation path is authorization and credential scope: who can write Ingress objects, and what the controller credential can access if exposed.

Mitigation direction

  • Review vendor security guidance for affected ingress-nginx versions and fixes.
  • Upgrade ingress-nginx if vendor guidance identifies a patched release.
  • Restrict who can create or update Kubernetes Ingress objects.
  • Apply least-privilege RBAC to the ingress-nginx controller service account.
  • Review cluster secret access granted to ingress-related service accounts.

Validation and detection

  • Inventory clusters running Kubernetes ingress-nginx.
  • Audit RBAC subjects with create or update permissions on Ingress resources.
  • Check whether ingress-nginx controller credentials can read secrets cluster-wide.
  • Review existing Ingress path values for newline or unusual control characters.
  • Confirm remediation status against Kubernetes ingress-nginx advisory guidance.
Prepared
Confidence
medium
Sources
4

Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.

Potential ATT&CK relevance

Conservative CVE-to-ATT&CK context

These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.

ATT&CK lookup starting points

Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.

cwe · low confidence lookup

CWE-20: Exact CWE lookup

Use the exact CWE identifier as the starting point before reviewing related ATT&CK behavior. Open the exact CWE lookup page first, then review the ATT&CK searches from that MITRE weakness context. This is a Glexia lookup hint, not an official ATT&CK mapping.

Open ATT&CK lookup
description · low confidence lookup

Credential and access behavior lookup

The CVE wording references authentication or credential exposure, so valid-account and credential-access review may help. This is a Glexia inferred lookup path, not an official MITRE, ATT&CK, or CVE Program mapping.

Open ATT&CK lookup
description · low confidence lookup

Container behavior lookup

The affected technology mentions containers, so container-specific ATT&CK technique review may help. This is a Glexia inferred lookup path, not an official MITRE, ATT&CK, or CVE Program mapping.

Open ATT&CK lookup
cve · low confidence lookup

CVE-2021-25748 mapping review

Open the CVE-to-ATT&CK bridge for reviewed, inferred, or future official mappings tied to this CVE.

Open ATT&CK lookup
Vulnerability profileCVE Program record
Severity
High
CVSS
7.6 (3.1)
Known Exploited
No
Published

Vector: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:L/A:L

Official CVE source material

CNA and ADP enrichment extracted from CVE v5

These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.

1CVSS vectors
0Timeline events
0ADP providers
3Source links

CVSS vector scores

1 official score

We collect every scored CVSS vector available in the official CNA and ADP containers. When more than one version is present, the table keeps the source vectors side by side instead of collapsing them into the highest score.

ScoreVersionSeverityVectorExploitImpactSource
7.6CVSS 3.1HighCVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:L/A:L2.84.7Primary CVE score

Vulnerability scoring details

Base CVSS 3.1 score

7.6High
CVSS 3.1 vector shape for CVE-2021-25748Attack VectorAttack ComplexityPrivileges RequiredUser InteractionScopeConfidentiality ImpactIntegrity ImpactAvailability Impact

Vector: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:L/A:L

Attack Vector
NetworkAdjacentLocalPhysical
Attack Complexity
LowHigh
Privileges Required
NoneLowHigh
User Interaction
NoneRequired
Scope
ChangedUnchanged
Confidentiality Impact
HighLowNone
Integrity Impact
HighLowNone
Availability Impact
HighLowNone
Affected products

Products and packages named in the record

VendorProductVersion / packageStatus
KubernetesKubernetes ingress-nginxunspecifiedListed
Weakness

CWE details

CWE links open Glexia weakness intelligence pages with official CWE context, developer remediation guidance, and related CVE mappings.

CWE-20 · source CWE mapping

Improper Input Validation

Improper Input Validation represents a recurring weakness pattern that can create exploitable paths when design, validation, or implementation controls are missing.