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…
EPSS 0.0%top 90%

CVE-2026-40301: CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') in rhukster dom-sanitizer

0
Medium
VulnerabilityCVE-2026-40301cvecve-2026-40301cwe-79
Published: Fri Apr 17 2026 (04/17/2026, 20:51:37 UTC)
Source: CVE Database V5
Vendor/Project: rhukster
Product: dom-sanitizer

Description

DOMSanitizer is a DOM/SVG/MathML Sanitizer for PHP 7.3+. Prior to version 1.0.10, DOMSanitizer::sanitize() allows <style> elements in SVG content but never inspects their text content. CSS url() references and @import rules pass through unfiltered, causing the browser to issue HTTP requests to attacker-controlled hosts when the sanitized SVG is rendered. Version 1.0.10 fixes the issue.

CVSS v3.1

Score 4.7medium

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
Required
Scope
Changed
Confidentiality
Low
Integrity
None
Availability
None
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:N/A:N

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 04/25/2026, 02:56:11 UTC

Technical Analysis

The rhukster dom-sanitizer library for PHP versions prior to 1.0.10 contains a cross-site scripting (CWE-79) vulnerability. Specifically, the sanitize() method permits <style> elements within SVG content without inspecting the CSS text inside them. As a result, CSS constructs such as url() references and @import rules are not filtered, enabling an attacker to cause the browser to issue HTTP requests to attacker-controlled domains when the sanitized SVG is rendered. This behavior can lead to information leakage or other side effects related to cross-origin requests. The issue is resolved in version 1.0.10 of the library.

Potential Impact

The vulnerability allows an attacker to embed malicious CSS within SVG content that is sanitized by vulnerable versions of dom-sanitizer. When the sanitized SVG is rendered in a browser, it can trigger HTTP requests to attacker-controlled servers via CSS url() or @import rules. This can lead to information disclosure such as leaking user browsing context or enabling tracking. The CVSS score of 4.7 reflects a medium severity with low confidentiality impact and no integrity or availability impact.

Mitigation Recommendations

Upgrade to dom-sanitizer version 1.0.10 or later, where the sanitize() method properly inspects and filters CSS content inside <style> elements in SVG. Since the vendor advisory indicates the issue is fixed in version 1.0.10, applying this official fix is the recommended remediation. No other mitigations are specified or required.

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-10T20:22:44.036Z
Cvss Version
3.1
State
PUBLISHED
Remediation Level
null

Threat ID: 69e2a136bdfbbecc59908362

Added to database: 4/17/2026, 9:08:06 PM

Last enriched: 4/25/2026, 2:56:11 AM

Last updated: 6/3/2026, 3:54:33 PM

Views: 67

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