Vulnerability · Published Nov 6, 2024 · Assigned by GitHub_M
CVE-2024-51757Fixes security vulnerability that allowed for server side code to be executed by a <script> tag
Critical 9.3
In plain English
A critical-severity code injection in happy-dom from capricorn86. Proof-of-concept exploit code is public. The chance it is exploited in the next 30 days is estimated at 0.8% (higher than 56% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.
Official description
happy-dom is a JavaScript implementation of a web browser without its graphical user interface. Versions of happy-dom prior to 15.10.2 may execute code on the host via a script tag. This would execute code in the user context of happy-dom. Users are advised to upgrade to version 15.10.2. There are no known workarounds for this vulnerability.
Affected packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| npm | happy-dom | 15.10.2 | GHSA-96g7-g7g9-jxw8 |
Affected products (as reported)
| Vendor | Product | Versions |
|---|---|---|
| capricorn86 | happy-dom | < 15.10.2 |
Weakness: CWE-94, CWE-79 · Vector: CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
References
- https://github.com/capricorn86/happy-dom/security/advisories/GHSA-96g7-g7g9-jxw8 x_refsource_CONFIRM
- https://github.com/capricorn86/happy-dom/issues/1585 x_refsource_MISC
- https://github.com/capricorn86/happy-dom/pull/1586 x_refsource_MISC
- https://github.com/capricorn86/happy-dom/commit/5ee0b1676d4ce20cc2a70d1c9c8d6f1e3f57efac x_refsource_MISC
- https://github.com/capricorn86/happy-dom/commit/d23834c232f1cf5519c9418b073f1dcec6b2f0fd x_refsource_MISC
- https://github.com/capricorn86/happy-dom/releases/tag/v15.10.2 x_refsource_MISC