CVE-2026-129296 mail-parser: Path Traversal vulnerability in attachment extraction

Medium 6.5 Published Updated

Crafted email attachments can make mail-parser write files outside the output directory, overwriting files in applications extracting attachments.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Over the internet
Victim action needed
A user has to click or open something
Harmful if only installed
No
Needs a specific call
Yes
Fix
Available

What is CVE-2026-129296?

CVE-2026-129296 is a medium-severity path traversal vulnerability in SpamScope mail-parser, published on 16 Nov 2026. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.

Official description

mail-parser is a tool that parses emails by enhancing the Python standard library and extracting message details into a comprehensive object. From 3.8.0 until 4.6.0, the write_attachments() and write_sample() APIs use attacker-controlled attachment filenames without sufficient sanitization and path containment validation. Directory traversal sequences and absolute filesystem paths can cause an attachment to be written outside the intended output directory. An attacker can overwrite files accessible to the parsing process when an application extracts attachments from a crafted message. This issue is fixed in version 4.6.0.

Weakness: CWE-22

Which versions are affected by CVE-2026-129296?

1 open source package ship an affected version, including mail-parser.

An affected version is only exploitable if your software calls write_attachments() or write_sample(). Many projects that include it are not exposed.

PackageAffectedFixed in
mail-parser PyPI
pkg:pypi/mail-parser
From 3.8.04.6.0
Status by vendor (1)
WhoReleaseStatusPackages
Upstreamfixedmail-parser (4.6.0)

How do I fix CVE-2026-129296?

Upgrade mail-parser to 4.6.0 or later.

Upgrade, and resolve every user-supplied path against an allowed base folder before opening it. More about Path traversal.

Is CVE-2026-129296 being exploited?

There is no known exploitation of CVE-2026-129296 in the wild and no public exploit code.

Sources

Also known as GHSA-fr3h-cpq2-9496.

Is CVE-2026-129296 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free