What’s Vulnerable › Vulnerabilities
CVE-2023-26125
- Severity: high (CVSS 7.3 v3.1)
- Exploited in the wild: not listed in CISA KEV
- EPSS: 0.9% probability of exploitation in the next 30 days
- Public exploit or detection template: yes
- Published: 2023-05-04 · updated 2026-06-17
- Weakness: CWE-20
Description
Versions of the package github.com/gin-gonic/gin before 1.9.0 are vulnerable to Improper Input Validation by allowing an attacker to use a specially crafted request via the X-Forwarded-Prefix header, potentially leading to cache poisoning. **Note:** Although this issue does not pose a significant threat on its own it can serve as an input vector for other more impactful vulnerabilities. However, successful exploitation may depend on the server configuration and whether the header is used in the application logic.
Affected products
- github.com/gin-gonic/gin: before 1.9.0 — fixed in 1.9.0
How to fix
Upgrade to a fixed version: github.com/gin-gonic/gin 1.9.0. Check the vendor advisory for mitigations.
References
- https://github.com/gin-gonic/gin/pull/3500
- https://github.com/gin-gonic/gin/pull/3503
- https://github.com/gin-gonic/gin/releases/tag/v1.9.0
- https://github.com/t0rchwo0d/gin/commit/fd9f98e70fb4107ee68c783482d231d35e60507b
- https://security.snyk.io/vuln/SNYK-GOLANG-GITHUBCOMGINGONICGIN-3324285
- https://github.com/gin-gonic/gin/pull/3500
- https://github.com/gin-gonic/gin/pull/3503
- https://github.com/gin-gonic/gin/releases/tag/v1.9.0
- https://github.com/t0rchwo0d/gin/commit/fd9f98e70fb4107ee68c783482d231d35e60507b
- https://security.snyk.io/vuln/SNYK-GOLANG-GITHUBCOMGINGONICGIN-3324285
Get alerted when CVE-2023-26125 or the next vulnerability affects your stack