Skip to content
High 7.5

mail-parserに細工したメールヘッダーで処理が長時間止まる脆弱性

CVE-2026-129295 First seen on SecPulse

Summary

mail-parserの4.2.0から4.6.1までには、攻撃者が細工したメールヘッダーを解析させると、正規表現の処理が極端に長くなり、解析処理が長時間止まる脆弱性があります。小さなメールでも、メールゲートウェイや隔離、アーカイブの解析処理を長く占有するおそれがあります。修正版の4.6.1で対応できるため、利用中のバージョンを確認し、4.6.1以降に更新してください。

AI summary

Produced by SecPulse using an external AI model; it may contain mistakes. Check the original description and references below before acting on it.

mail-parserの4.2.0から4.6.1までには、攻撃者が細工したメールヘッダーを解析させると、正規表現の処理が極端に長くなり、解析処理が長時間止まる脆弱性があります。小さなメールでも、メールゲートウェイや隔離、アーカイブの解析処理を長く占有するおそれがあります。修正版の4.6.1で対応できるため、利用中のバージョンを確認し、4.6.1以降に更新してください。

Affected packages

PackageAffected → Fixed
SpamScopemail-parser —
pipmail-parser
< 4.6.1→ 4.6.1
PyPImail-parser
≥ 4.2.0, < 4.6.1→ 4.6.1
Original description The description as published by the source.

mail-parser is a tool that parses emails by enhancing the Python standard library and extracting message details into a comprehensive object. From 4.2.0 until 4.6.1, attacker-controlled email headers can cause polynomial regular-expression backtracking during ordinary parse_from_string(), parse_from_bytes(), or parse_from_file() calls. In src/mailparser/utils.py, get_addresses() invokes the _ADDR_FALLBACK_RE fallback when strict address parsing yields no usable address, and overlapping quantifiers rescan padded address headers quadratically or cubically. In src/mailparser/const.py, parse_received() applies _CLAUSE_SPLITTER to uncollapsed whitespace in a Received header, causing quadratic backtracking when a whitespace run is not followed by a clause keyword. A small, well-formed message can keep mail gateway, ticketing, quarantine, or archival parsing workers busy for extended periods. This issue is fixed in version 4.6.1.

Source: CVE.org (CVE Program・cvelistV5) NVD GitHub Advisory

References

We use cookies for analytics and ad measurement. This setting applies to all Game co., Ltd. sites. Details