Vulnerability · Published Jul 8, 2026 · Assigned by GitHub_M
CVE-2026-45045Fiber: X-Real-IP Spoofing via Header.Add() in BalancerForward
Medium 5.3
In plain English
A medium-severity authentication bypass by spoofing in fiber from gofiber. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.5% (higher than 40% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.
Official description
Fiber is an Express inspired web framework written in Go. Prior to 3.3.0 and 2.52.14, the BalancerForward proxy helper in middleware/proxy/proxy.go uses Header.Add() instead of Header.Set() when injecting X-Real-IP, allowing an attacker-supplied first X-Real-IP value to be forwarded to upstream servers for logging, rate limiting, and access control. This issue is fixed in version 3.3.0 and 2.52.14.
Affected packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| Go | github.com/gofiber/fiber/v2 | 2.52.14 | GHSA-gcfq-8gqf-4876 |
| Go | github.com/gofiber/fiber/v3 | 3.3.0 | GHSA-gcfq-8gqf-4876 |
| Go | github.com/gofiber/fiber/v3 | 3.3.0 | GO-2026-5887 |
| Ubuntu:26.10 | golang-github-gofiber-fiber | no fix listed | UBUNTU-CVE-2026-45045 |
| Ubuntu:26.10 | golang-github-gofiber-fiber-v2 | no fix listed | UBUNTU-CVE-2026-45045 |
Affected products (as reported)
Weakness: CWE-290 · Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N
References
- https://github.com/gofiber/fiber/security/advisories/GHSA-gcfq-8gqf-4876 x_refsource_CONFIRM
- https://github.com/gofiber/fiber/pull/4260 x_refsource_MISC
- https://github.com/gofiber/fiber/pull/4495 x_refsource_MISC
- https://github.com/gofiber/fiber/commit/1403cc8292da3220e9316960b4030cc722a0f396 x_refsource_MISC
- https://github.com/gofiber/fiber/commit/33c9501288ab47a429c8b5e701493f0c3c0af37d x_refsource_MISC
- https://github.com/gofiber/fiber/releases/tag/v2.52.14 x_refsource_MISC
- https://github.com/gofiber/fiber/releases/tag/v3.3.0 x_refsource_MISC