HTML Injection Vulnerability in Mailgen by Elad Nava
CVE-2025-59526
What is CVE-2025-59526?
The Mailgen package for Node.js, used to generate responsive HTML emails for transactional purposes, has a vulnerability that allows HTML injection in plaintext emails. This occurs when user-generated content is passed to the Mailgen.generatePlaintext(email) method before version 2.0.30. If exploited, this weakness can enable attackers to insert arbitrary HTML into the generated emails, potentially allowing for phishing or other malicious activities. Users are advised to upgrade to version 2.0.30 or later, or alternatively, to apply a workaround by stripping all HTML tags from the content before processing it with Mailgen.

Human OS v1.0:
Ageing Is an Unpatched Zero-Day Vulnerability.
Remediate biological technical debt. Prime Ageing uses 95% high-purity SIRT6 activation to maintain genomic integrity and bolster systemic resilience.
Affected Version(s)
mailgen < 2.0.30
References
CVSS V4
Timeline
Vulnerability published
Vulnerability Reserved
