VDB
Sign up
MEDIUM5.5

PYSEC-2026-2148

Quick fix

PYSEC-2026-2148 — eml-parser: upgrade to the fixed version with the command below.

pip install --upgrade 'eml-parser>=2.0.1'

Details

eml_parser serves as a python module for parsing eml files and returning various information found in the e-mail as well as computed information. Prior to version 2.0.1, the official example script examples/recursively_extract_attachments.py contains a path traversal vulnerability that allows arbitrary file write outside the intended output directory. Attachment filenames extracted from parsed emails are directly used to construct output file paths without any sanitization, allowing an attacker-controlled filename to escape the target directory. This issue has been patched in version 2.0.1.

Are you affected?

Enter the version of the package you're using.

Affected packages

PyPI/eml-parser
Introduced in: 0Fixed in: 2.0.1
Fixpip install --upgrade 'eml-parser>=2.0.1'

References