Skip to main content
← All vulnerabilities
CVE-2026-33979GHSA-3843-RR4G-M8JQ

Express XSS Sanitizer: allowedTags/allowedAttributes bypass leads to permissive sanitization (XSS risk)

Published
Last modified
published
Not listed in CISA KEV
Fix
Fixed in 2.0.2
None on Exploit-DB, Metasploit or GitHub
  • Exploitation: poc
  • Automatable: yes
  • Technical impact: partial

Summary

Express XSS Sanitizer is Express 4.x and 5.x middleware which sanitizes user input data (in req.body, req.query, req.headers and req.params) to prevent Cross Site Scripting (XSS) attack. A vulnerability has been identified in versions prior to 2.0.2 where restrictive sanitization configurations are silently ignored. In version 2.0.2, the validation logic has been updated to respect explicitly provided empty configurations. Now, if allowedTags or allowedAttributes are provided (even if empty), they are passed directly to sanitize-html without being overridden.

Timeline

  1. CVE published
  2. CISA SSVC assessment

    Exploitation: poc · Automatable: yes · Technical impact: partial

  3. Record last updated

Affected versions

  • AhmedAdelFahim express-xss-sanitizer

    fixed in 2.0.2

  • express-xss-sanitizernpm

    fixed in 2.0.2

References 3

GitHub · AhmedAdelFahim/express-xss-sanitizer