HTML Injection Vulnerability in Mailgen Node.js Package
CVE-2025-62366
What is CVE-2025-62366?
The Mailgen Node.js package, designed for creating responsive HTML emails, is susceptible to an HTML injection vulnerability in its generatePlaintext method. When user-generated content includes encoded HTML entities, the function fails to strip these entities, leading to unintentional execution of injected JavaScript during rendering. This vulnerability poses a significant risk, especially when the plaintext output is subsequently displayed as HTML. Users of Mailgen versions prior to 2.0.31 are strongly encouraged to upgrade as the newer version contains patches to mitigate this risk. No known workarounds are available.

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.31
References
CVSS V4
Timeline
Vulnerability published
Vulnerability Reserved
