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

Source: https://junglewise.ai/threats/cve-2021-25748-ingress-nginx-path-sanitization-can-be-bypassed-with-newline  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2023-05-24  
License: CC BY 4.0 with a link back

CVE-2021-25748 · Severity: low · CVSS 3.1 · Published 2023-05-24

Ingress-nginx `path` sanitization can be bypassed with newline character

Technologies: [k8s.io/ingress-nginx (Go)](https://junglewise.ai/threats/technologies/k8s-io-ingress-nginx). Vendors: [Go](https://junglewise.ai/threats/vendors/go).

## Quick answers

**Is CVE-2021-25748 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2021-25748 being exploited in the wild.

**How severe is CVE-2021-25748?** Low severity, with a CVSS score of 3.1, published 24 May 2023.

**Which products and versions are affected?** k8s.io/ingress-nginx (Go) SEMVER:introduced=0,fixed=1.2.1.

**Is there a fix for CVE-2021-25748?** Yes. k8s.io/ingress-nginx (Go): upgrade to 1.2.1 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**Am I affected by CVE-2021-25748?** Check whether you run k8s.io/ingress-nginx (Go) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## How to fix

- k8s.io/ingress-nginx (Go): upgrade to 1.2.1 or later

  ```sh
  go get k8s.io/ingress-nginx@v1.2.1
  ```


## Affected products

- k8s.io/ingress-nginx (Go) SEMVER:introduced=0,fixed=1.2.1

## Identifiers

- CVE-2021-25748
- GHSA-863x-868h-968x

## Related threats

- [Kubernetes ingress-nginx configuration injection via annotations](https://junglewise.ai/threats/cve-2026-4342-kubernetes-ingress-nginx-configuration-injection-via-annotations)
- [ingress-nginx's `rules.http.paths.path` Ingress field can be used to inject configuration into nginx](https://junglewise.ai/threats/cve-2026-24512-ingress-nginx-s-rules-http-paths-path-ingress-field-can-be-used)
- [ingress-nginx's `nginx.ingress.kubernetes.io/auth-method` Ingress annotation can be used to inject configuration into nginx](https://junglewise.ai/threats/cve-2026-1580-ingress-nginx-s-nginx-ingress-kubernetes-io-auth-method-ingress)
- [GO-2026-4419 - ingress-nginx has Improper Check for Unusual or Exceptional Conditions in k8s.io/ingress-nginx](https://junglewise.ai/threats/cve-2026-24513-ingress-nginx-has-improper-check-for-unusual-or-exceptional)
- [GO-2026-4417 - ingress-nginx vulnerable to Allocation of Resources Without Limits or Throttling in k8s.io/ingress-nginx](https://junglewise.ai/threats/cve-2026-24514-ingress-nginx-vulnerable-to-allocation-of-resources-without)
