# CVE-2026-33979: Express XSS Sanitizer: allowedTags/allowedAttributes bypass leads to permissive sanitization (XSS risk)

- Severity: High 8.2 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:H/A:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.42%, higher than 38% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2026-03-27T17:56:45.000Z
- Modified: 2026-06-17T10:38:22.467Z
- Also known as: GHSA-3843-rr4g-m8jq
- Weaknesses: CWE-79, CWE-183
- SSVC (CISA-ADP): exploitation poc, automatable yes, technical impact partial
- Assigned by: GitHub_M

## Description

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.

(As written by CVE List.)

## Affected

- AhmedAdelFahim express-xss-sanitizer: < 2.0.2
- express-xss-sanitizer (npm): before 2.0.2
- express_xss_sanitizer_project express_xss_sanitizer: before 2.0.2

## Every score

- GitHub_M: CVSS:3.1 8.2 High `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:H/A:N`
- GitHub: CVSS:3.1 8.2 High `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:H/A:N`

## References

- <https://github.com/AhmedAdelFahim/express-xss-sanitizer/security/advisories/GHSA-3843-rr4g-m8jq> (exploit, mitigation, vendor-advisory, web)
- <https://github.com/AhmedAdelFahim/express-xss-sanitizer/commit/5623009ef11dcf095c163a38dea07b9cc22ad19f> (patch, web)
- <https://github.com/AhmedAdelFahim/express-xss-sanitizer/releases/tag/v2.0.2> (product, release-notes, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2026-33979> (advisory)
- <https://github.com/AhmedAdelFahim/express-xss-sanitizer> (package)

## Sources

- CVE List: [CVE-2026-33979](https://www.cve.org/CVERecord?id=CVE-2026-33979), CVE Terms of Use, modified 2026-03-31
- GitHub Advisory Database: [GHSA-3843-rr4g-m8jq](https://github.com/advisories/GHSA-3843-rr4g-m8jq), CC-BY-4.0, modified 2026-03-30
- NVD: [CVE-2026-33979](https://nvd.nist.gov/vuln/detail/CVE-2026-33979), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2026-33979 · Whole record: https://cve.day/CVE-2026-33979.json · Rebuilt by cve.day 2026-11-25T22:59:17.455Z
