CVE-2023-41338: Vulnerability in Ctx.IsFromLocal() in gofiber
Vulnerability summary
CVE-2023-41338 is a medium (CVSS 5.3) vulnerability in gofiber fiber. EPSS estimates a 0.66% chance of exploitation in the next 30 days, higher than 50.7% of scored vulnerabilities.
Timeline
- 08-09-2023PublishedVulnerability first disclosed.
- 26-09-2024Last modifiedVulnerability information updated.
Description
Fiber is an Express inspired web framework built in the go language. Versions of gofiber prior to 2.49.2 did not properly restrict access to localhost. This issue impacts users of our project who rely on the `ctx.IsFromLocal` method to restrict access to localhost requests. If exploited, it could allow unauthorized access to resources intended only for localhost. Setting `X-Forwarded-For: 127.0.0.1` in a request from a foreign host, will result in true for `ctx.IsFromLocal`. Access is limited to the scope of the affected process. This issue has been patched in version `2.49.2` with commit `b8c9ede6`. Users are advised to upgrade. There are no known workarounds to remediate this vulnerability without upgrading to the patched version.
CVSS metrics
3 scores · 3 sources · 1 version- OSV · GoEcosystem advisory · calculated5.3MediumCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N
- NVDNIST5.3MediumCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N
EPSS trend
Probability
0.66%
Chance of exploitation in the next 30 days
Percentile
51%
Versus all other CVEs
30-day change
No change 0.00 pp
From 0.66% on 22-09-2026
Known exploited
Compare KEV catalogsNot in the CISA KEV catalog.
Not in the ENISA CNW catalog.
Not in the CIRCL catalog.
Public exploits
0 foundNo public exploits indexed.
Weaknesses
CWE · root causeAffected systems
Github.com/gofiber1 product
- fiber≤ 1.14.6
Github.com/gofiber/fiber1 product
- v2< 2.49.2 | < 2.49.2-0.20230906112033-b8c9ede6efa2
Gofiber1 product
- fiber< 2.49.2
3 vendors · 3 products
References
6 links- github.com/gofiber/fiber/security/advisories/GHSA-3q5p-3558-364fX Refsource CONFIRMWEBAdvisoryVendor Advisory
- developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Forwarded-ForX Refsource MISCWEBTechnical Description
- github.com/gofiber/fiberPACKAGE