CVE-2026-42554
Description
Fiber is a web framework for Go. Prior to 2.52.12 and 3.1.0, Cross-Site Scripting vulnerability in Go Fiber allows a remote attacker to inject arbitrary HTML/JavaScript by supplying Accept: text/html on any request whose handler passes attacker-influenced data to the AutoFormat() feature. The developer opts into content negotiation by calling AutoFormat(), but does not opt into raw HTML emission for a particular request; Fiber chooses that branch from attacker-controlled Accept. The html branch is the sole outlier in a method whose name (AutoFormat) and symmetrical structure actively telegraph "safe, format-agnostic reply." This vulnerability is fixed in 2.52.12 and 3.1.0.
Weakness
- CWE-79: Improper Neutralization of Input During Web Page Generation
CISA SSVC decision points
| Exploitation | poc |
|---|---|
| Automatable | no |
| Technical impact | partial |
| Scored | 2026-05-15 |
Timeline
- 2026-05-05GitHub advisory published (GHSA-qjv7-627w-8qjv)6 days before publication
- 2026-05-11Published by the CNA21:47 UTC
- 2026-05-15CISA SSVC decision recorded4 days after publication
Exploit and advisory records
GitHub advisory GHSA-qjv7-627w-8qjv, affected packages:
| Package | Vulnerable versions | Fixed in |
|---|---|---|
| Go github.com/gofiber/fiber/v2 | before 2.52.13 | 2.52.13 |
| Go github.com/gofiber/fiber/v3 | before 3.2.0 | 3.2.0 |
Affected products
Products listed as vulnerable. Upgrade to the version under "Fixed in", or a later one.
| Product | Vulnerable versions | Fixed in |
|---|---|---|
| gofiber fiber | before 2.52.12fixed in 2.52.12from 3.0.0 before 3.1.0fixed in 3.1.0 | 2.52.123.1.0 |
References
Get more CVE data from the API.
curl 'https://api.contrastcyber.com/cve_lookup/CVE-2026-42554'curl 'https://api.contrastcyber.com/cve_risk_score/CVE-2026-42554'curl 'https://api.contrastcyber.com/cve_exploit/CVE-2026-42554'curl 'https://api.contrastcyber.com/cve_products/CVE-2026-42554'
Sources
- Vulnerability data from the National Vulnerability Database (NIST) and the CVE Program. CVE records: Copyright © 1999-2026, The MITRE Corporation, used under the CVE Program Terms of Use. CVE® is a registered trademark of The MITRE Corporation.
- CWE definitions: Copyright © 2006-2026, The MITRE Corporation, used under the CWE Terms of Use. CWE is a trademark of The MITRE Corporation.
- OWASP Top 10 categories by the OWASP Foundation (CC BY 3.0).
- EPSS scores by FIRST.org EPSS, used with attribution.
- KEV catalog and SSVC decisions by CISA.
- Advisory data from the GitHub Advisory Database through OSV.dev (CC BY 4.0).
- Exploit metadata from the Exploit Database (GPL-2.0-only, metadata only).
- Nuclei template names from nuclei-templates (MIT).