Skip to content
FlawDB
Sign in
Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

CVE-2025-61927

HIGH 7.2EPSS 59%

Happy-DOM has VM Context Escape

Also known as GHSA-37j7-fg3j-429f

Mitigation

  • Upgrade happy-dom to 20.0.0 or later.

Who should check

  • Projects that depend on npm package happy-dom (< 20.0.0)
  • Anyone running capricorn86 happy-dom < 20.0.0

Vulnerability facts

Affected
happy-dom < 20.0.0
Fixed in
20.0.0
Exploited in the wild
Not in CISA KEV
Public exploit / PoC
None known
Remote exploitation
Remote, login needed
CVSS
7.2 (v4.0, CNA)CVSS:4.0/AV:N/AC:L/AT:P/PR:H/UI:A/VC:L/VI:H/VA:H/SC:H/SI:H/SA:HOpen in CVSS calculator
Show all 11 CVSS metrics
  • Attack vector: Network
  • Attack complexity: Low
  • Attack requirements: Present
  • Privileges required: High
  • User interaction: Active
  • Confidentiality impact: Low
  • Integrity impact: High
  • Availability impact: High
  • Confidentiality impact on other systems: High
  • Integrity impact on other systems: High
  • Availability impact on other systems: High
EPSS
0.93% chance of exploitation in 30 days (percentile 59, 2026-11-26)
CWE
CWE-94
Published
Modified

Description

Happy DOM is a JavaScript implementation of a web browser without its graphical user interface. Happy DOM v19 and lower contains a security vulnerability that puts the owner system at the risk of RCE (Remote Code Execution) attacks. A Node.js VM Context is not an isolated environment, and if the user runs untrusted JavaScript code within the Happy DOM VM Context, it may escape the VM and get access to process level functionality. It seems like what the attacker can get control over depends on if the process is using ESM or CommonJS. With CommonJS the attacker can get hold of the `require()` function to import modules. Happy DOM has JavaScript evaluation enabled by default. This may not be obvious to the consumer of Happy DOM and can potentially put the user at risk if untrusted code is executed within the environment. Version 20.0.0 patches the issue by changing JavaScript evaluation to be disabled by default.

Affected and fixed versions

Package / productAffectedFixedSource
npm happy-dom< 20.0.020.0.0osv
capricorn86 happy-dom< 20.0.0—cvelist

Check your systems with an agent

Paste this into Claude Code, Cursor or another coding agent. It only reads; it changes nothing.

Check whether anything I run is affected by CVE-2025-61927. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2025-61927.md
Affected: happy-dom < 20.0.0
Fixed in: 20.0.0

Steps:
1. Search this machine and project for happy-dom (npm), capricorn86 happy-dom: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.

References

FAQ

Is CVE-2025-61927 being exploited?

There is no confirmed exploitation: CVE-2025-61927 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.93% chance of exploitation in the next 30 days (as of 2026-11-26).

How serious is CVE-2025-61927?

High: CVSS 7.2 (v4.0, scored by CNA). Remote, login needed. A user has to take an action, such as opening a link, for the attack to work.

Which versions are affected by CVE-2025-61927?

happy-dom < 20.0.0.

Is there a fix for CVE-2025-61927?

Yes. Fixed in 20.0.0. Upgrade happy-dom to 20.0.0 or later.

How do I check if I'm affected by CVE-2025-61927?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

Sponsors