MEDIUMCVSS v3.1 6.5Vulnerability

CVE-2026-129296

A path traversal vulnerability was identified in mail-parser when extracting email attachments using the write_attachments() and write_sample() APIs. A specially crafted email containing malicious attachment filenames (for example, using directory traversal sequences such as "../" or absolute filesystem paths) could cause files to be written outside the intended output directory. Depending on how the library was used and the permissions of the executing process, this could result in arbitrary file overwrite. The vulnerability affects mail-parser versions 3.8.0 through 4.5.0. The issue has been addressed by introducing comprehensive filename sanitization and path validation before any file is written to disk. The fix includes: - Sanitization of attachment filenames before writing. - Validation that all output paths remain within the intended destination directory. - Rejection of symbolic link targets. - Normalization of Windows and POSIX path separators. - Validation and rejection of invalid or unsafe filenames. - Protection applied consistently in both write_attachments() and write_sample() APIs. Users are strongly encouraged to upgrade to the patched release. ## Credits The vulnerability was responsibly reported by **Niranjan Ganesan** (Security Insights, https://securityinsights.io/, GitHub: @iam-niranjan). The vulnerability was analyzed, remediated, and the security fix was implemented by **Fedele Mantuano**, maintainer of mail-parser (LinkedIn: https://www.linkedin.com/in/fmantuano/). mail-parser would like to thank Niranjan Ganesan for following a coordinated vulnerability disclosure process and for collaborating throughout the remediation and verification of the fix.

Properties

Summary
mail-parser: Path Traversal vulnerability in attachment extraction
Severity
medium
Nvd fetched at
2026-11-16T22:44:16.771339+00:00
Cvss score
6.5
Cvss severity
MEDIUM
Retrieved at
2026-11-16T22:45:19+00:00
Ghsa published
2026-11-16T22:10:55Z
Source url
https://github.com/advisories/GHSA-fr3h-cpq2-9496
Ghsa updated
2026-11-16T22:10:56Z
Ghsa id
GHSA-fr3h-cpq2-9496
Last source
GitHub Advisory Database
Score
6.5
Cvss version
3.1
Cve id
CVE-2026-129296
Cvss vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:H/A:N
First seen by Signal
2026-11-16T18:35:21+00:00
Is ghsa only
false
Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:H/A:N
Published at
2026-11-16T18:17:30.390
Last modified
2026-11-16T18:17:30.390

Related Entities (4)

AFFECTS (1)

→[Software]pip/mail-parser

VULNERABLE_TO (1)

←[Software]pip/mail-parser

Related research

Explore deeper with Ninja Signal's threat intelligence graph

CVE-2026-129296 (CVSS v3.1 6.5) — Ninja Signal Threat Intelligence | Ninja Signal