Vulnerability Details : CVE-2023-29401
The filename parameter of the Context.FileAttachment function is not properly sanitized. A maliciously crafted filename can cause the Content-Disposition header to be sent with an unexpected filename value or otherwise modify the Content-Disposition header. For example, a filename of "setup.bat";x=.txt" will be sent as a file named "setup.bat". If the FileAttachment function is called with names provided by an untrusted source, this may permit an attacker to cause a file to be served with a name different than provided. Maliciously crafted attachment file name can modify the Content-Disposition header.
Products affected by CVE-2023-29401
Exploit prediction scoring system (EPSS) score for CVE-2023-29401
0.18%
Probability of exploitation activity in the next 30 days
EPSS Score History
~ 55 %
Percentile, the proportion of vulnerabilities that are scored at or less
CVSS scores for CVE-2023-29401
Base Score | Base Severity | CVSS Vector | Exploitability Score | Impact Score | Score Source | First Seen |
---|---|---|---|---|---|---|
4.3
|
MEDIUM | CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:N |
2.8
|
1.4
|
134c704f-9b21-4f2e-91b3-4a467353bcc0 | 2025-01-06 |
4.3
|
MEDIUM | CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:N |
2.8
|
1.4
|
NIST |
CWE ids for CVE-2023-29401
-
The product downloads source code or an executable from a remote location and executes the code without sufficiently verifying the origin and integrity of the code.Assigned by: nvd@nist.gov (Primary)
References for CVE-2023-29401
-
https://pkg.go.dev/vuln/GO-2023-1737
GO-2023-1737 - Go PackagesThird Party Advisory
-
https://github.com/gin-gonic/gin/pull/3556
fix lack of escaping of filename in Content-Disposition by motoyasu-saburi · Pull Request #3556 · gin-gonic/gin · GitHubIssue Tracking;Patch
-
https://github.com/gin-gonic/gin/releases/tag/v1.9.1
Release v1.9.1 · gin-gonic/gin · GitHubRelease Notes
-
https://github.com/gin-gonic/gin/issues/3555
FileAttachment() is vulnerable to Reflect File Download · Issue #3555 · gin-gonic/gin · GitHubExploit;Issue Tracking
Jump to