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-39315: CWE-184: Incomplete List of Disallowed Inputs in unjs unhead

0
Medium
VulnerabilityCVE-2026-39315cvecve-2026-39315cwe-184
Published: Thu Apr 09 2026 (04/09/2026, 17:54:07 UTC)
Source: CVE Database V5
Vendor/Project: unjs
Product: unhead

Description

CVE-2026-39315 is a medium severity vulnerability in unhead, a document head and template manager. Versions prior to 2. 1. 13 contain an incomplete input validation issue in the useHeadSafe() composable, which is recommended for safely rendering user-supplied content in the HTML <head>. The vulnerability arises because the internal hasDangerousProtocol() function decodes HTML entities using regexes with fixed digit caps, but the HTML5 spec allows unlimited leading zeros in numeric character references. This causes some dangerous URI schemes like 'javascript:' to bypass detection and be written raw into server-side rendered HTML. The browser then decodes these entities, enabling blocked URIs to be executed. This issue is fixed in version 2. 1. 13.

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 04/09/2026, 18:36:15 UTC

Technical Analysis

Unhead versions before 2.1.13 have a vulnerability (CWE-184) due to incomplete filtering of dangerous URI schemes in user-supplied content rendered in the document head. The hasDangerousProtocol() function decodes HTML entities with regexes that limit digit length, but HTML5 allows unlimited leading zeros in numeric character references. When an entity exceeds this limit, it is not decoded before checking for blocked schemes like 'javascript:'. As a result, the raw entity is output in SSR HTML, and the browser's native parser decodes it, enabling execution of blocked protocols. This vulnerability is addressed in unhead version 2.1.13.

Potential Impact

The vulnerability allows bypassing of URI scheme filtering in user-supplied content rendered in the document head, potentially enabling injection of dangerous protocols such as 'javascript:'. This can lead to limited confidentiality and integrity impacts as indicated by the CVSS vector (C:L/I:L/A:N). There are no known exploits in the wild. The issue affects unhead versions prior to 2.1.13.

Mitigation Recommendations

This vulnerability is fixed in unhead version 2.1.13. Users should upgrade to version 2.1.13 or later to remediate this issue. No other official remediation or temporary fixes are documented. Patch status is not explicitly confirmed beyond the fix in 2.1.13; users should verify with vendor advisories for the latest guidance.

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-04-06T19:31:07.266Z
Cvss Version
3.1
State
PUBLISHED
Remediation Level
null

Threat ID: 69d7ee091cc7ad14da04a8c9

Added to database: 4/9/2026, 6:20:57 PM

Last enriched: 4/9/2026, 6:36:15 PM

Last updated: 4/9/2026, 9:26:53 PM

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