CVE-2026-118661capricorn86 happy-dom
Medium 6.5 No auth needed
Follow: this CVE · capricorn86 · capricorn86 happy-dom We alert you by email or Slack (account required).
- Priority
- 54
- CVSS 3.1
- 6.5
- EPSS
- —
- Auth required
- No
- Published
- Oct 28, 2026
- Updated
- Nov 3, 2026
- Category
- Application · Cross-platform
- Weakness (CWE)
- CWE-565
- SSVC (CISA)
- Exploitation: proof of concept · Automatable: yes · Technical impact: partial
- Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:N
What happens
Happy DOM is a JavaScript implementation of a web browser without its graphical user interface. Prior to 20.14.6, Happy DOM's CookieContainer in src/cookie/CookieContainer.ts does not correctly validate or match Domain cookie attributes. It can accept a Domain unrelated to the origin setting the cookie, including a public suffix, and separately treats an unrelated suffix-sharing hostname as a match because cookieMatchesURL does not enforce a DNS-label boundary. In server-side rendering and prerendering applications that contact attacker-controlled origins and then make requests to a victim origin, these behaviors can plant and deliver a forged cookie, enabling cookie injection or session fixation. This issue is fixed in version 20.14.6.
What to do
- Apply the vendor's security update for happy-dom.
- It can be exploited without authentication: if you cannot patch now, restrict Internet access to the affected service.
Affected packages
| Ecosystem | Package | Affected versions | Fixed in | How to upgrade |
|---|---|---|---|---|
| npm | happy-dom |
< 20.14.6 |
20.14.6 |
npm install happy-dom@20.14.6 |
Per OSV / GitHub Advisories (GHSA-5fpq-26gf-qwcr). Check the version in your lockfile before upgrading.
Affected products
- capricorn86 · happy-dom
As reported by the CNA that published the CVE. NVD has not added CPEs with versions yet.
Official sources
References
Links published by the sources. Open them with care.