← Vulnerability feed

Vulnerability record · CVE-2024-25124 · published 21 February 2024

CVE-2024-25124: Gofiber fiber origin validation error vulnerability

Gofiber · Fiber

Fiber is a web framework written in go. Prior to version 2.52.1, the CORS middleware allows for insecure configurations that could potentially expose the application to multiple CORS-related vulnerabilities. Specifically, it allows setting the Access-Control-Allow-Origin header to a wildcard (`*`) while also having the Access-Control-Allow-Credentials set to true, which goes against recommended security best practices. The impact of this misconfiguration is high as it can lead to unauthorized access to sensitive user data and expose the system to various types of attacks listed in the PortSwigger article linked in the references. Version 2.52.1 contains a patch for this issue. As a workaround, users may manually validate the CORS configurations in their implementation to ensure that they do not allow a wildcard origin when credentials are enabled. The browser fetch api, as well as browsers and utilities that enforce CORS policies, are not affected by this.

9.8 CVSS 3.1 Critical EPSS 0.66% · top 50.7% CWE-346 · Origin validation errorCWE-942 · CWE-942
9.8CVSS 3.1 base score
0.66%EPSS exploitation probability, 30 days
NoNot in CISA KEV
1Affected product versions listed by NVD
16References, 4 tagged exploit
17 Jun 2026Last modified by NVD

Description

Fiber is a web framework written in go. Prior to version 2.52.1, the CORS middleware allows for insecure configurations that could potentially expose the application to multiple CORS-related vulnerabilities. Specifically, it allows setting the Access-Control-Allow-Origin header to a wildcard (`*`) while also having the Access-Control-Allow-Credentials set to true, which goes against recommended security best practices. The impact of this misconfiguration is high as it can lead to unauthorized access to sensitive user data and expose the system to various types of attacks listed in the PortSwigger article linked in the references. Version 2.52.1 contains a patch for this issue. As a workaround, users may manually validate the CORS configurations in their implementation to ensure that they do not allow a wildcard origin when credentials are enabled. The browser fetch api, as well as browsers and utilities that enforce CORS policies, are not affected by this.

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Affected products

1 vulnerable configurations from NVD's CPE data, grouped by vendor and product.

References

LinkTags
http://blog.portswigger.net/2016/10/exploiting-cors-misconfigurations-for.html ExploitThird Party Advisory
https://codeql.github.com/codeql-query-help/javascript/js-cors-misconfiguration-for-credentials Technical Description
https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS/Errors/CORSNotSupportingCredentials Technical Description
https://fetch.spec.whatwg.org/#cors-protocol-and-credentials Technical Description
https://github.com/gofiber/fiber/commit/f0cd3b44b086544a37886232d0530601f2406c23 Patch
https://github.com/gofiber/fiber/releases/tag/v2.52.1 Release Notes
https://github.com/gofiber/fiber/security/advisories/GHSA-fmg4-x8pw-hjhg ExploitVendor Advisory
https://saturncloud.io/blog/cors-cannot-use-wildcard-in-accesscontrolalloworigin-when-credentials-flag-is-true Broken Link
http://blog.portswigger.net/2016/10/exploiting-cors-misconfigurations-for.html ExploitThird Party Advisory
https://codeql.github.com/codeql-query-help/javascript/js-cors-misconfiguration-for-credentials Technical Description
https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS/Errors/CORSNotSupportingCredentials Technical Description
https://fetch.spec.whatwg.org/#cors-protocol-and-credentials Technical Description
https://github.com/gofiber/fiber/commit/f0cd3b44b086544a37886232d0530601f2406c23 Patch
https://github.com/gofiber/fiber/releases/tag/v2.52.1 Release Notes
https://github.com/gofiber/fiber/security/advisories/GHSA-fmg4-x8pw-hjhg ExploitVendor Advisory
https://saturncloud.io/blog/cors-cannot-use-wildcard-in-accesscontrolalloworigin-when-credentials-flag-is-true Broken Link

Track CVE-2024-25124 inside VULONE

Watch it alongside the ransomware crews, C2 infrastructure and forum chatter that reference it, query it through the API and pull it into your SIEM over TAXII.

Start free Open in platform

Related vulnerabilities

Same products first, then exploited flaws of the same weakness class.

9.8CVE-2024-38513Gofiber fiber vulnerabilityFiber is an Express-inspired web framework written in Go A vulnerability present in versions prior to 2.52.5 is a session middleware issue in GoFiber…EPSS 0.69%9.2CVE-2025-66630Gofiber fiber vulnerabilityFiber is an Express inspired web framework written in Go. Before 2.52.11, on Go versions prior to 1.24, the underlying crypto/rand implementation can…EPSS 0.49%8.8CVE-2023-45128Gofiber fiber improper input validation vulnerabilityFiber is an express inspired web framework written in Go. A Cross-Site Request Forgery (CSRF) vulnerability has been identified in the application, w…EPSS 0.31%8.8CVE-2023-45141Gofiber fiber cross-site request forgery vulnerabilityFiber is an express inspired web framework written in Go. A Cross-Site Request Forgery (CSRF) vulnerability has been identified in the application, w…EPSS 0.27%8.7CVE-2025-54801Gofiber fiber vulnerabilityFiber is an Express inspired web framework written in Go. In versions 2.52.8 and below, when using Fiber's Ctx.BodyParser to parse form data containi…EPSS 0.37%7.7CVE-2026-25891Gofiber fiber path traversal vulnerabilityFiber is an Express inspired web framework written in Go. A Path Traversal (CWE-22) vulnerability in Fiber allows a remote attacker to bypass the sta…EPSS 0.69%7.7CVE-2025-48075Gofiber fiber vulnerabilityFiber is an Express-inspired web framework written in Go. Starting in version 2.52.6 and prior to version 2.52.7, `fiber.Ctx.BodyParser` can map flat…EPSS 0.50%7.5CVE-2026-25899Gofiber fiber allocation without limits vulnerabilityFiber is an Express inspired web framework written in Go. In versions on the v3 branch prior to 3.1.0, the use of the `fiber_flash` cookie can force …EPSS 0.63%

Source: NIST National Vulnerability Database (record CVE-2024-25124), CISA KEV, FIRST EPSS (scores of 2026-09-26). This page is refreshed as NVD updates the record.