{"id":"CVE-2024-38513","aliases":["EUVD-2024-2308","GHSA-98j2-3j3p-fw2v","GO-2024-2959"],"status":"published","title":"Fiber Session Middleware Token Injection Vulnerability","description":"Fiber 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 versions 2 and above. This vulnerability allows users to supply their own session_id value, resulting in the creation of a session with that key. If a website relies on the mere presence of a session for security purposes, this can lead to significant security risks, including unauthorized access and session fixation attacks. All users utilizing GoFiber's session middleware in the affected versions are impacted. The issue has been addressed in version 2.52.5. Users are strongly encouraged to upgrade to version 2.52.5 or higher to mitigate this vulnerability. Users who are unable to upgrade immediately can apply the following workarounds to reduce the risk: Either implement additional validation to ensure session IDs are not supplied by the user and are securely generated by the server, or regularly rotate session IDs and enforce strict session expiration policies.","severity":{"version":"3.1","score":10,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H","level":"critical","assessor":"cna","from":"cve"},"epss":{"day":"2026-11-11","score":0.00692,"percentile":0.53315,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":true},"cwes":["CWE-384"],"published":"2024-07-01T18:31:13Z","modified":"2026-10-28T02:30:59Z","fixes":[{"ecosystem":"Go","package":"github.com/gofiber/fiber","fixed_in":["2.52.5"],"sources":["ghsa","osv"]},{"ecosystem":"Go","package":"github.com/gofiber/fiber/v2","fixed_in":["2.52.5"],"sources":["ghsa","osv"]},{"ecosystem":"Go","package":"github.com/gofiber/fiber/v2/middleware/session","fixed_in":["2.52.5"],"sources":["ghsa","osv"]}],"affected":[{"source":"ghsa","ecosystem":"Go","package":"github.com/gofiber/fiber","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"last_affected":"2.52.4"},{"fixed":"2.52.5"}]}]},{"source":"ghsa","ecosystem":"Go","package":"github.com/gofiber/fiber/v2","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"last_affected":"2.52.4"},{"fixed":"2.52.5"}]}]},{"source":"ghsa","ecosystem":"Go","package":"github.com/gofiber/fiber/v2/middleware/session","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"last_affected":"2.52.4"},{"fixed":"2.52.5"}]}]},{"source":"osv","ecosystem":"Go","package":"github.com/gofiber/fiber","ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"2.52.5"}]}]},{"source":"osv","ecosystem":"Go","package":"github.com/gofiber/fiber/v2","ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"2.52.5"}]}]},{"source":"osv","ecosystem":"Go","package":"github.com/gofiber/fiber/v2/middleware/session","ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"2.52.5"}]}]},{"source":"osv","ecosystem":"Go","package":"github.com/gofiber/fiber","ranges":[{"type":"SEMVER","events":[{"introduced":"0"}]}]},{"source":"osv","ecosystem":"Go","package":"github.com/gofiber/fiber/v2","ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"2.52.5"}]}]}],"products":[{"vendor":"gofiber","product":"fiber"}],"references":[{"url":"https://github.com/gofiber/fiber/security/advisories/GHSA-98j2-3j3p-fw2v","tags":["x_refsource_CONFIRM","x_transferred","Vendor Advisory","advisory","web"]},{"url":"https://github.com/gofiber/fiber/commit/66a881441b27322a331f1b526cf1eb6b3358a4d8","tags":["x_refsource_MISC","x_transferred","Patch","fix","web"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2024-38513","tags":["advisory"]},{"url":"https://github.com/gofiber/fiber/commit/7926e5bf4da03e54f62d27d53229d35b264cba8e","tags":["web","fix"]},{"url":"https://github.com/advisories/GHSA-98j2-3j3p-fw2v"},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/38xxx/CVE-2024-38513.json","tags":["advisory"]},{"url":"https://github.com/gofiber/fiber","tags":["package"]}],"sources":{"cve":[{"id":"CVE-2024-38513","title":"Fiber Session Middleware Token Injection Vulnerability","description":"Fiber 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 versions 2 and above. This vulnerability allows users to supply their own session_id value, resulting in the creation of a session with that key. If a website relies on the mere presence of a session for security purposes, this can lead to significant security risks, including unauthorized access and session fixation attacks. All users utilizing GoFiber's session middleware in the affected versions are impacted. The issue has been addressed in version 2.52.5. Users are strongly encouraged to upgrade to version 2.52.5 or higher to mitigate this vulnerability. Users who are unable to upgrade immediately can apply the following workarounds to reduce the risk: Either implement additional validation to ensure session IDs are not supplied by the user and are securely generated by the server, or regularly rotate session IDs and enforce strict session expiration policies.","status":"published","published":"2024-07-01T18:31:13.028Z","modified":"2024-08-02T04:12:25.224Z","cvss":[{"version":"3.1","score":10,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H","level":"critical","assessor":"cna"}],"cwes":["CWE-384"],"updated_at":"2026-11-02T14:34:16.367792Z"}],"euvd":[{"id":"EUVD-2024-2308","description":"Fiber 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 versions 2 and above. This vulnerability allows users to supply their own session_id value, resulting in the creation of a session with that key. If a website relies on the mere presence of a session for security purposes, this can lead to significant security risks, including unauthorized access and session fixation attacks. All users utilizing GoFiber's session middleware in the affected versions are impacted. The issue has been addressed in version 2.52.5. Users are strongly encouraged to upgrade to version 2.52.5 or higher to mitigate this vulnerability. Users who are unable to upgrade immediately can apply the following workarounds to reduce the risk: Either implement additional validation to ensure session IDs are not supplied by the user and are securely generated by the server, or regularly rotate session IDs and enforce strict session expiration policies.","status":"published","published":"2024-07-01T18:31:13Z","modified":"2024-08-02T04:12:25Z","cvss":[{"version":"3.1","score":10,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H","level":"critical"}],"updated_at":"2026-11-03T03:50:18.462935Z"}],"ghsa":[{"id":"GHSA-98j2-3j3p-fw2v","title":"Session Middleware Token Injection Vulnerability","description":"A security vulnerability has been identified in the Fiber session middleware where a user can supply their own session_id value, leading to the creation of a session with that key.\n\n## Impact\nThe identified vulnerability is a session middleware issue in GoFiber versions 2 and above. This vulnerability allows users to supply their own session_id value, resulting in the creation of a session with that key. If a website relies on the mere presence of a session for security purposes, this can lead to significant security risks, including unauthorized access and session fixation attacks. All users utilizing GoFiber's session middleware in the affected versions are impacted.\n\n## Patches\nThe issue has been addressed in the latest patch. Users are strongly encouraged to upgrade to version 2.52.5 or higher to mitigate this vulnerability.\n\n## Workarounds\nUsers who are unable to upgrade immediately can apply the following workarounds to reduce the risk:\n\n1. **Validate Session IDs**: Implement additional validation to ensure session IDs are not supplied by the user and are securely generated by the server.\n2. **Session Management**: Regularly rotate session IDs and enforce strict session expiration policies.\n\n## References\nFor more information on session best practices:\n- [OWASP Session Management Cheat Sheet](https://cheatsheetseries.owasp.org/cheatsheets/Session_Management_Cheat_Sheet.html)\n\nUsers are encouraged to review these references and take immediate action to secure their applications.","status":"published","published":"2024-07-01T20:35:03Z","modified":"2024-07-05T18:00:05Z","cvss":[{"version":"3.1","score":10,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H","level":"critical"}],"cwes":["CWE-384"],"updated_at":"2026-11-02T14:37:55.455438Z"}],"nvd":[{"id":"CVE-2024-38513","description":"Fiber 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 versions 2 and above. This vulnerability allows users to supply their own session_id value, resulting in the creation of a session with that key. If a website relies on the mere presence of a session for security purposes, this can lead to significant security risks, including unauthorized access and session fixation attacks. All users utilizing GoFiber's session middleware in the affected versions are impacted. The issue has been addressed in version 2.52.5. Users are strongly encouraged to upgrade to version 2.52.5 or higher to mitigate this vulnerability. Users who are unable to upgrade immediately can apply the following workarounds to reduce the risk: Either implement additional validation to ensure session IDs are not supplied by the user and are securely generated by the server, or regularly rotate session IDs and enforce strict session expiration policies.","status":"published","published":"2024-07-01T19:15:05.173Z","modified":"2026-06-17T07:40:27.017Z","cvss":[{"version":"3.1","score":10,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H","level":"critical","assessor":"secondary"},{"version":"3.1","score":9.8,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","level":"critical","assessor":"primary"}],"cwes":["CWE-384"],"updated_at":"2026-11-02T14:10:10.545705Z"}],"osv":[{"id":"CVE-2024-38513","title":"Fiber Session Middleware Token Injection Vulnerability","description":"Fiber 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 versions 2 and above. This vulnerability allows users to supply their own session_id value, resulting in the creation of a session with that key. If a website relies on the mere presence of a session for security purposes, this can lead to significant security risks, including unauthorized access and session fixation attacks. All users utilizing GoFiber's session middleware in the affected versions are impacted. The issue has been addressed in version 2.52.5. Users are strongly encouraged to upgrade to version 2.52.5 or higher to mitigate this vulnerability. Users who are unable to upgrade immediately can apply the following workarounds to reduce the risk: Either implement additional validation to ensure session IDs are not supplied by the user and are securely generated by the server, or regularly rotate session IDs and enforce strict session expiration policies.","status":"published","published":"2024-07-01T18:31:13.028Z","modified":"2026-10-28T02:30:59.101600873Z","cvss":[{"version":"3.1","score":10,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H","level":"critical"}],"cwes":["CWE-384"],"updated_at":"2026-11-02T15:44:41.133403Z"},{"id":"GHSA-98j2-3j3p-fw2v","title":"Session Middleware Token Injection Vulnerability","description":"A security vulnerability has been identified in the Fiber session middleware where a user can supply their own session_id value, leading to the creation of a session with that key.\n\n## Impact\nThe identified vulnerability is a session middleware issue in GoFiber versions 2 and above. This vulnerability allows users to supply their own session_id value, resulting in the creation of a session with that key. If a website relies on the mere presence of a session for security purposes, this can lead to significant security risks, including unauthorized access and session fixation attacks. All users utilizing GoFiber's session middleware in the affected versions are impacted.\n\n## Patches\nThe issue has been addressed in the latest patch. Users are strongly encouraged to upgrade to version 2.52.5 or higher to mitigate this vulnerability.\n\n## Workarounds\nUsers who are unable to upgrade immediately can apply the following workarounds to reduce the risk:\n\n1. **Validate Session IDs**: Implement additional validation to ensure session IDs are not supplied by the user and are securely generated by the server.\n2. **Session Management**: Regularly rotate session IDs and enforce strict session expiration policies.\n\n## References\nFor more information on session best practices:\n- [OWASP Session Management Cheat Sheet](https://cheatsheetseries.owasp.org/cheatsheets/Session_Management_Cheat_Sheet.html)\n\nUsers are encouraged to review these references and take immediate action to secure their applications.","status":"published","published":"2024-07-01T20:35:03Z","modified":"2026-09-10T03:50:16.400234889Z","cvss":[{"version":"3.1","score":10,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H","level":"critical"}],"cwes":["CWE-384"],"updated_at":"2026-11-02T15:46:43.524801Z"},{"id":"GO-2024-2959","title":"Session Middleware Token Injection Vulnerability in github.com/gofiber/fiber","description":"Session Middleware Token Injection Vulnerability in github.com/gofiber/fiber","status":"published","published":"2024-07-02T19:19:24Z","modified":"2026-03-03T04:55:32.839465Z","updated_at":"2026-11-02T15:47:01.453823Z"}]}}
