CVE-2021-25748
MEDIUM 6.5CVSS 3.1Ingress-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.
- Published
- 24 May 2023
- Last modified
- 7 Aug 2026
- Assigned by
- jordan@liggitt.net
- NVD status
- Modified
- Weakness
- CWE-20
- Also known as
- GHSA-863x-868h-968x
- Sources
- NVDJSONOSV GHSA-863x-868h-968xJSON
Scores
| Source | Scored by | Version | Score | Vector / decision |
|---|---|---|---|---|
| NVD | jordan@liggitt.net (Secondary) | CVSS 3.1 | HIGH 7.6 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:L/A:L |
| NVD | nvd@nist.gov (Primary) | CVSS 3.1 | MEDIUM 6.5 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N |
| OSV | GitHub | CVSS 3.1 | MEDIUM 6.5 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N |
Affected
| Source | Vendor / ecosystem | Product / package | Affected versions | Fixed in |
|---|---|---|---|---|
| NVD | kubernetes | ingress-nginxcpe:2.3:a:kubernetes:ingress-nginx:*:*:*:*:*:*:*:* |
< 1.2.1 | 1.2.1 |
| OSV | Go | k8s.io/ingress-nginx | < 1.2.1 | 1.2.1 |
References
- https://github.com/kubernetes/ingress-nginx/issues/8686 · Issue Tracking, Mitigation, Vendor Advisory, WEB
- https://groups.google.com/g/kubernetes-security-announce/c/avaRYa9c7I8 · Mailing List, Mitigation, Vendor Advisory, WEB
- https://nvd.nist.gov/vuln/detail/CVE-2021-25748 · ADVISORY
- https://github.com/kubernetes/ingress-nginx/pull/8623 · WEB
- https://github.com/kubernetes/ingress-nginx · PACKAGE
- https://github.com/kubernetes/ingress-nginx/releases/tag/controller-v1.2.1 · WEB
History
- 25 Nov 2026 20:36 UTC · NVD: first stored (published 24 May 2023)
- 25 Nov 2026 20:13 UTC · OSV: first stored (published 24 May 2023)