CVE-2026-61816: zbateson/mail-mime-parser has uncontrolled resource consumption (CPU/memory DoS) parsing untrusted MIME
An uncontrolled resource consumption / algorithmic complexity vulnerability affecting any application that parses untrusted email with this library.
Three independent parsing paths are super-linear in cost, so a byte-size cap on the caller side does not bound the work done. A crafted message under 2 MB can consume seconds of CPU or hundreds of megabytes to multiple gigabytes of memory (leading to an out-of-memory kill), enabling denial of service. The parse is lazy, but the cost is paid on the first getAllParts() or content read.
References
- github.com/advisories/GHSA-f6v3-2qmr-vfjx
- github.com/zbateson/mail-mime-parser/commit/1691e695821f70461f9554e9bb71be2859404a24
- github.com/zbateson/mail-mime-parser/commit/fa44823ba9dd651e0eecec7aa45ac8c8e6afcb78
- github.com/zbateson/mail-mime-parser/releases/tag/3.0.7
- github.com/zbateson/mail-mime-parser/releases/tag/4.0.2
- github.com/zbateson/mail-mime-parser/security/advisories/GHSA-f6v3-2qmr-vfjx
- nvd.nist.gov/vuln/detail/CVE-2026-61816
Code Behaviors & Features
Detect and mitigate CVE-2026-61816 with GitLab Dependency Scanning
Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →