CVE-2023-29401

Improper handling of filenames in Content-Disposition HTTP header in github.com/gin-gonic/gin

MEDIUM
4.3
CVSS Score
Published: June 8, 2023 at 08:27 PM UTC
Updated: June 17, 2026 at 05:49 AM UTC
2 products affected across 2 vendorsGinGonic Gin

Using github.com/gin-gonic/gin by github.com/gin-gonic/gin?

Get instant alerts when new vulnerabilities affect github.com/gin-gonic/gin - before attackers find them.

Real-time alertsTrack your software stackFree plan available
Severity
MEDIUM4.3
Exploit prediction
EPSS 0.5%
SSVC
PoC

Description

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.

Affected

Our own answer: ranges merged, affected separated from platform-only, with confidence and review flags.

1.3.1-0.20190301021747-ccb9e902956d ≤ v < 1.9.1
Affected range stops below 1.9.1, so it looks safe — our inference, not a vendor statement
1.3.1-0.20190301021747-ccb9e902956d ≤ v < 1.9.11.3.1-0.20190301021747-ccb9e902956d
Affected range stops below 1.9.1, so it looks safe — our inference, not a vendor statement

Remediation

No guide yet

No remediation guidance has been written for this CVE yet. What the record does show:

Patch and advisory references

SSVC — Action Prioritization

SSVCPoCNot automatablePartial impact

SSVC signals action urgency (what to patch first), separate from CVSS which measures severity.

CVSS

4.3MEDIUMCISA-ADP
Attack Vector
NETWORK
Complexity
LOW
Privileges
NONE
User Interaction
REQUIRED
Scope
UNCHANGED
Confidentiality
NONE
Integrity
LOW
Availability
NONE
Vector?

Quick Info

StatusMODIFIED
CWE
CWE-494

Get alerted

Stop reading CVE feeds looking for your own stack

Track the products you run and VulnTracker tells you when a new CVE affects them — with what is known about fixing it, and nothing about the rest.

Free plan, no card