Code Injection in Happy DOM - CVE-2026-33943

 

Code Injection in Happy DOM - CVE-2026-33943

Published: April 27, 2026


Vulnerability identifier: #VU128057
CSH Severity: High
CVSS v4.0: CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:A/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:U/U:Amber
CVE-ID: CVE-2026-33943
CWE-ID: CWE-94
Exploitation vector: Remote access
Exploit availability: No public exploit available
Vendor: capricorn86
Affected software:
Happy DOM

Detailed vulnerability description

The vulnerability allows a remote attacker to execute arbitrary code.

The vulnerability exists due to improper control of code generation in ECMAScriptModuleCompiler when processing crafted ES module export declarations in HTML content. A remote attacker can inject a specially crafted JavaScript expression to execute arbitrary code.

Exploitation requires JavaScript evaluation to be enabled and user interaction to process attacker-controlled HTML content.


How to mitigate CVE-2026-33943

Install security update from vendor's website.

Sources