Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…

CVE-2026-34226: CWE-201: Insertion of Sensitive Information Into Sent Data in capricorn86 happy-dom

0
High
VulnerabilityCVE-2026-34226cvecve-2026-34226cwe-201cwe-359
Published: Fri Mar 27 2026 (03/27/2026, 21:17:24 UTC)
Source: CVE Database V5
Vendor/Project: capricorn86
Product: happy-dom

Description

Happy DOM is a JavaScript implementation of a web browser without its graphical user interface. Versions prior to 20.8.9 may attach cookies from the current page origin (`window.location`) instead of the request target URL when `fetch(..., { credentials: "include" })` is used. This can leak cookies from origin A to destination B. Version 20.8.9 fixes the issue.

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 03/27/2026, 21:44:52 UTC

Technical Analysis

CVE-2026-34226 is a vulnerability identified in the Happy DOM JavaScript library, a headless browser implementation without a graphical user interface. The issue arises in versions prior to 20.8.9, where the library incorrectly attaches cookies from the current page origin (window.location) rather than the intended request target URL when performing fetch requests with the credentials option set to 'include'. This behavior violates the same-origin policy by leaking cookies from one origin (origin A) to another (origin B), potentially exposing sensitive authentication or session cookies to unintended recipients. The vulnerability is classified under CWE-201 (Insertion of Sensitive Information Into Sent Data) and CWE-359 (Exposure of Private Information Through Sent Data). The flaw can be exploited remotely without requiring authentication or user interaction, as the attacker only needs to induce a fetch request in the vulnerable environment. The impact is primarily on confidentiality, as attackers can gain unauthorized access to cookies that may allow session hijacking or impersonation. The vulnerability has a CVSS v3.1 base score of 7.5, indicating high severity due to network attack vector, low attack complexity, no privileges required, and no user interaction needed. The issue was publicly disclosed on March 27, 2026, and fixed in Happy DOM version 20.8.9. No known exploits in the wild have been reported yet. This vulnerability is particularly relevant for organizations using Happy DOM for server-side rendering, automated testing, or other headless browser use cases in JavaScript environments.

Potential Impact

The primary impact of CVE-2026-34226 is the unauthorized disclosure of sensitive cookie data across origins, which can lead to session hijacking, unauthorized access, and impersonation attacks. Organizations relying on Happy DOM for server-side rendering or automated testing may inadvertently expose sensitive session cookies to malicious endpoints, compromising user accounts and internal services. This can result in data breaches, loss of user trust, and potential regulatory penalties if personal data is exposed. Since the vulnerability does not affect integrity or availability, the main concern is confidentiality loss. The ease of exploitation (no authentication or user interaction required) and the network attack vector increase the risk of widespread exploitation if attackers target vulnerable deployments. Although no exploits are currently known in the wild, the high CVSS score and nature of the flaw warrant immediate attention to prevent potential attacks. The scope includes all environments using vulnerable Happy DOM versions, which may include development, testing, and production systems that perform cross-origin fetch requests with credentials included.

Mitigation Recommendations

To mitigate CVE-2026-34226, organizations should immediately upgrade Happy DOM to version 20.8.9 or later, where the cookie handling logic has been corrected. Additionally, review and audit all codebases and CI/CD pipelines to identify usage of vulnerable Happy DOM versions and replace them accordingly. Implement strict Content Security Policies (CSP) to limit cross-origin requests and reduce the risk of cookie leakage. Where possible, avoid using fetch requests with credentials set to 'include' across different origins, or explicitly control cookie scope and SameSite attributes to restrict cookie transmission. Conduct thorough testing of server-side rendering and automated testing environments to ensure no sensitive data is leaked during cross-origin requests. Monitor network traffic for unusual cookie transmissions and implement logging to detect potential exploitation attempts. Finally, educate developers about secure cookie handling practices and the risks of cross-origin data leakage in headless browser environments.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Data Version
5.2
Assigner Short Name
GitHub_M
Date Reserved
2026-03-26T16:22:29.033Z
Cvss Version
3.1
State
PUBLISHED

Threat ID: 69c6f6ca3c064ed76ff81bc0

Added to database: 3/27/2026, 9:29:46 PM

Last enriched: 3/27/2026, 9:44:52 PM

Last updated: 3/28/2026, 1:10:16 AM

Views: 6

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses