CVE-2026-129299
Medium 6.5No known exploitationFix availablemail-parser: Uncaught exceptions and silent header loss in mail-parser on attacker-controlled input
Vendor advisory: GHSA-24mq-4vc6-2prf
Record last updated
CVSS score
Medium on a 0 to 10 scale
EPSS, chance of exploitation in 30 days
Higher than 30% of scored CVEs. A prediction, not evidence.
CISA remediation deadline
Not in the KEV catalog
Description
mail-parser is a tool that parses emails by enhancing the Python standard library and extracting message details into a comprehensive object. Prior to 4.6.2, multiple message-processing behaviors can raise exceptions or silently lose content. Headers colliding with methods such as Parse, Message, and Write_Attachments can place bound method objects into parsed output and raise TypeError when a caller requests JSON serialization such as mail_json. When byte input is parsed through parse_from_bytes(), an 8-bit header value returned as email.header.Header can likewise raise TypeError when an X_raw accessor passes the value to json.dumps; both exceptions are outside the MailParserError hierarchy. Separately, rewritten names such as Subject_json and X_Spam_Flag can be substituted or disappear from mail, headers, and JSON output while has_defects remains false, and a headerless message can be treated as falsy before parser state is initialized, causing body and attachment properties to return empty values without an error signal. These behaviors can abort message processing or hide malicious indicators from downstream scanners. This issue is fixed in version 4.6.2.
Weakness: CWE-248, CWE-436
Patching and mitigation
- Patch status
- Fix available (source: GitHub Advisory Database)
- Fix documented (source date)
- Mitigation
- None documented
- Vendor guidance
- github.com (opens in a new tab)
Affected products
| Vendor | Product | Affected versions | Fixed in | Per |
|---|---|---|---|---|
| pip | mail-parser | all versions up to and including 4.6.1 | 4.6.2 | GitHub Advisory Database |
Timeline
Patch
Fix documented by GitHub Advisory Database
Vendor guidance and references
- https://github.com/SpamScope/mail-parser/commit/ce3cf3559db1ff806bda598b378de9f8c2a5be96 (opens in a new tab)
- https://github.com/SpamScope/mail-parser/pull/167 (opens in a new tab)
- https://github.com/SpamScope/mail-parser/releases/tag/4.6.2 (opens in a new tab)
- https://github.com/SpamScope/mail-parser/security/advisories/GHSA-24mq-4vc6-2prf (opens in a new tab)
- GitHub Advisory GHSA-24mq-4vc6-2prf (opens in a new tab)github-advisory