Com.googlecode.owasp java html sanitizer:owasp java html sanitizer: OWASP Java HTML Sanitizer is vulnerable to XSS via
Affects com.googlecode.owasp-java-html-sanitizer:owasp-java-html-sanitizerSource GCVE Database
Not known to be exploited · CVSS 8.6 High : upgrade to 20260101.1 soon.
Data as of 3 Dec 2026, 16:31 UTC
Thin evidence
One scorer or none| CNA (GitHub_M) | CVSS 4.0 | 8.6 |
|---|
- Patch
- Available – fixed in 20260101.1
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:N/SC:N/SI:N/SA:NExploitation evidence
Disclosed: evidence found.
CVE published 26 Nov 2025
Detectable: no evidence on record.
No public nuclei template indexed
Weaponized: no evidence on record.
No public exploit code indexed in Metasploit or Exploit-DB
Exploited in the wildExploited: no evidence on record.
Not in CISA KEV and no source reports exploitation
Observed by OffSeq MirageSeen by Mirage: no evidence on record.
No attack traffic recorded by OffSeq Mirage sensors
A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 3 Dec 2026.
What to do
Upgrade com.googlecode.owasp-java-html-sanitizer:owasp-java-html-sanitizer to 20260101.1.
Affected software
| Product | Affected | Fixed in |
|---|---|---|
| Mavencom.googlecode.owasp-java-html-sanitizer:owasp-java-html-sanitizer | Affected
| Fixed in
|
Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.
AI-suggested
Upgrade to version 20260101.1 or later of the OWASP Java HTML Sanitizer library where this vulnerability is fixed. Avoid configurations that allow 'noscript' and 'style' tags with 'allowTextIn' inside the style tag. Review and restrict HtmlPolicyBuilder settings to prevent unsafe tag combinations. Since a patch is available, applying the official fix is the recommended mitigation.
Description
The OWASP Java HTML Sanitizer library is vulnerable to cross-site scripting (XSS) when the HtmlPolicyBuilder configuration allows the 'noscript' and 'style' tags with 'allowTextIn' enabled inside the style tag. This edge case leads to improper sanitization of CSS content, allowing malicious script tags to persist in the sanitized output. The vulnerability arises because the browser interprets the 'noscript' tag wrapping the 'style' tag in a way that enables execution of injected scripts. A proof-of-concept demonstrates that payloads combining 'noscript' and 'style' tags can bypass sanitization and trigger script execution, whereas similar payloads with 'p' tags do not cause XSS. The issue is fixed in version 20260101.1 of the library.
References
- github.com/OWASP/java-html-sanitizer/security/advisories/GHSA-g9gq-3pfx-2gw2 (opens in a new tab)
- nvd.nist.gov/vuln/detail/CVE-2025-66021 (opens in a new tab)
- github.com/OWASP/java-html-sanitizer/issues/363 (opens in a new tab)
- github.com/OWASP/java-html-sanitizer/commit/4149cf02ba84db13e8e9d7ee1b01b3f47238e072 (opens in a new tab)
- github.com/OWASP/java-html-sanitizer/commit/b98cdf1cd5e156a6259b01aa8cdc7372c6efde1e (opens in a new tab)
- github.com/OWASP/java-html-sanitizer/commit/d6e0463ed3b48777ecd187913ffdbe767508ff45 (opens in a new tab)
- github.com/OWASP/java-html-sanitizer (opens in a new tab)