Skip to main content

CVE-2026-61784: CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') in cstigler node-xhtml-purifier

0
Medium
VulnerabilityCVE-2026-61784cvecve-2026-61784cwe-79cwe-116
Published: 09/24/2026 (09/24/2026, 17:35:57 UTC)
Source: CVE Database V5
Vendor/Project: cstigler
Product: node-xhtml-purifier

Description

xhtml-purifier is a Node.js library to take in raw/unknown/untrusted HTML and output cleaned, purified, trusted HTML. Versions prior to 0.4.3 do not HTML-entity-encode attribute values when serializing its sanitized output. In attributeString() (XHTMLPurifier.js, around line 148) the attribute value is concatenated directly into a double-quoted attribute without encoding. As a result, an attacker-controlled value in any allowed attribute (class, style, title, alt, src, href) can include a double-quote character to break out of the attribute and inject an additional attribute, such as a JavaScript event handler (for example onmouseover or onerror). The injected handler survives sanitization and executes when the output is rendered, which is a sanitizer bypass leading to cross-site scripting. The fix in version 0.4.3 HTML-entity-encodes attribute values before serialization.

CVSS v3.1

Score 6.1medium

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

Affected software

cstigler

node-xhtml-purifier

Affected versions
<0.4.3

Technical Details

Data Version
5.2
Assigner Short Name
GitHub_M
Date Reserved
2026-07-10T20:06:05.616Z
Cvss Version
3.1
State
PUBLISHED

Threat ID: 6ab56279f7a7c54106a1f8fb

Added to database: 09/24/2026, 17:48:41 UTC

Last updated: 09/24/2026, 17:48:41 UTC

Views: 1

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

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