GitHub Advisoryadvisory · Go
GHSA-49w7-5r33-jm9m http-swagger XSS via PUT requests
MEDIUM
Official page ↗
- Aliases
- CVE-2024-25712
- Ecosystem
- Go
- Packages
- github.com/swaggo/http-swagger
- Severity
- Moderate
- CVSS vector
- CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
- Weaknesses
- CWE-79
- Reviewed
- 2024-02-29
Affected packages
• Go github.com/swaggo/http-swagger: < 1.2.6 → fixed in 1.2.6
Description
http-swagger before 1.2.6 allows XSS via PUT requests, because a file that has been uploaded (via httpSwagger.WrapHandler and *webdav.memFile) can subsequently be accessed via a GET request. NOTE: this is independently fixable with respect to CVE-2022-24863, because (if a solution continued to allow PUT requests) large files could have been blocked without blocking JavaScript, or JavaScript could have been blocked without blocking large files.
Related
Alias · CVE (1)
- CVE-2024-25712 http-swagger before 1.2.6 allows XSS via PUT requests, because a file that has been uploaded (via httpSwagger.WrapHandler and… vulnerability
Weakness · CWE (1)
- CWE-79 Improper Neutralization of Input During Web Page Generation weakness
References
- https://nvd.nist.gov/vuln/detail/CVE-2024-25712 advisory
- https://github.com/swaggo/http-swagger/pull/62 web
- https://github.com/swaggo/http-swagger/commit/b7d83e8fba85a7a51aa7e45e8244b4173f15049e web
- https://cosmosofcyberspace.github.io/improper_http_method_leads_to_xss/poc.html web
- https://github.com/swaggo/http-swagger package
- https://github.com/swaggo/http-swagger/releases/tag/v1.2.6 web