# CVE-2025-66021: OWASP Java HTML Sanitizer is vulnerable to XSS via noscript tag and improper style tag sanitization

- Priority: **Prioritise**
- Reason: Public exploit (GitHub, Date unknown)
- Next step: Check applicability and the vendor advisory: no fix release is recorded here
- Status: published
- Published: 2025-11-26 · Modified: 2026-12-03
- Aliases: CGA-45f8-2cf8-g6x8, CGA-cmcc-hqmr-2w58, CGA-4j22-r37q-254r, CGA-6m2h-35ph-85pj, CGA-6vmc-27q7-pgxm, CGA-7h87-c6mx-q28j, CGA-7rmf-8m8m-9xm7, CGA-7x2p-hrx8-g89r, CGA-c384-q749-h6fv, CGA-f55g-2352-78j3, CGA-hmjp-c548-h5w2, CGA-j437-882j-pmhg, GHSA-g9gq-3pfx-2gw2, CGA-pwr9-fxjx-vw4j, CGA-vhc7-c968-vx69, CGA-2fcc-rc9g-2pm2, CGA-2g27-qqmc-2qgj, CGA-3p7w-qf8q-984m, CGA-4cmg-wfpw-59f7, CGA-6896-c7mj-cv3q, CGA-6gf5-q5cm-qg2v, CGA-6qjr-47hv-4hfq, CGA-6rf7-rjgj-cqgj, CGA-77j8-gj9v-j796, CGA-8f44-7qrp-g5mx, CGA-8h6h-55fc-9q67, CGA-cjj5-773v-rf69, CGA-hgrf-whgw-vm2w, CGA-hrvv-v6cv-75qw, CGA-jq8m-qmcx-59g6, CGA-jqqw-53gr-rvm5, CGA-jrc9-65v3-gc8c, CGA-jxq8-744v-6h8m, CGA-pv2h-6fx2-pvhq, CGA-rjx4-xrm6-hv68, CGA-wrmj-mqwg-xf72, CGA-4h5f-x8g6-5gvg, CGA-594x-mh2f-3v2x, CGA-682w-jg72-65rr, CGA-763v-rmgc-8r5f, CGA-7rj6-8w4g-4359, CGA-f22c-j479-q34m, CGA-frwg-hh49-94f5, CGA-ghmr-pgm6-w56w, CGA-j727-662w-pg79, CGA-jg99-h7gx-hw53, CGA-mfpv-3jcr-329c, CGA-qgc2-2998-vvh4, CGA-qpp2-v9c3-9q64, CGA-v3xj-4v3v-8222, CGA-vrcq-m6jp-jm35, CGA-wcj4-48fh-24xj, CGA-x86j-4j2g-grj2
- Record: https://cvemate.com/vulnerability/CVE-2025-66021 · JSON: https://cvemate.com/vulnerability/CVE-2025-66021/json

## Description

```text
OWASP Java HTML Sanitizer is a configureable HTML Sanitizer written in Java, allowing inclusion of HTML authored by third-parties in web applications while protecting against XSS. Prior to 20260101.1,  OWASP java html sanitizer is vulnerable to XSS if HtmlPolicyBuilder allows noscript and style tags with allowTextIn inside the style tag. This could lead to XSS if the payload is crafted in such a way that it does not sanitise the CSS and allows tags which is not mentioned in HTML policy. This vulnerability is fixed in 20260101.1.
```

## Signals

- CVSS: 8.6 high (v4.0, CVE.org) CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N
- EPSS: 0.289%, percentile 23.041%, as of 2026-12-04
- Known exploited (KEV): CISA not listed, ENISA not listed, CIRCL not listed
- Ransomware use: none recorded
- Public exploits: 1 (github)

## Affected (first 20 of 33)

- chainguard commercial-elasticsearch-8.17 (Chainguard): All versions (No fix recorded)
- chainguard commercial-elasticsearch-8.19 (Chainguard): All versions (No fix recorded)
- chainguard commercial-elasticsearch-9.3 (Chainguard): All versions (No fix recorded)
- chainguard commercial-elasticsearch-9.4 (Chainguard): All versions (No fix recorded)
- chainguard commercial-elasticsearch-9.5 (Chainguard): All versions (No fix recorded)
- chainguard elasticsearch-8.19 (Chainguard): \< 8.19.26-r1
- chainguard elasticsearch-9.3 (Chainguard): All versions (No fix recorded)
- chainguard elasticsearch-9.3-iamguarded-fips (Chainguard): All versions (No fix recorded)
- chainguard elasticsearch-9.5 (Chainguard): \< 9.5.7-r3
- chainguard elasticsearch-fips-8.19 (Chainguard): \< 8.19.26-r1
- chainguard elasticsearch-fips-9.3 (Chainguard): All versions (No fix recorded)
- chainguard elasticsearch-fips-9.4 (Chainguard): \< 9.4.10-r3
- chainguard elasticsearch-fips-9.5 (Chainguard): \< 9.5.7-r2
- chainguard jenkins-2.555 (Chainguard): All versions (No fix recorded)
- chainguard jenkins-2.555-openjdk-21 (Chainguard): All versions (No fix recorded)
- chainguard jenkins-2.555-openjdk-25 (Chainguard): All versions (No fix recorded)
- chainguard jenkins-2.568 (Chainguard): All versions (No fix recorded)
- chainguard jenkins-2.568-openjdk-21 (Chainguard): All versions (No fix recorded)
- chainguard jenkins-2.568-openjdk-25 (Chainguard): All versions (No fix recorded)
- chainguard keycloak-26.2 (Chainguard): All versions (No fix recorded)

## References

- <https://github.com/OWASP/java-html-sanitizer/security/advisories/GHSA-g9gq-3pfx-2gw2>
- <https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/66xxx/CVE-2025-66021.json>
- <https://nvd.nist.gov/vuln/detail/CVE-2025-66021>
- <https://github.com/OWASP/java-html-sanitizer/issues/363>
- <https://github.com/OWASP/java-html-sanitizer/commit/4149cf02ba84db13e8e9d7ee1b01b3f47238e072>
- <https://github.com/OWASP/java-html-sanitizer/commit/b98cdf1cd5e156a6259b01aa8cdc7372c6efde1e>
- <https://github.com/OWASP/java-html-sanitizer/commit/d6e0463ed3b48777ecd187913ffdbe767508ff45>
- <https://github.com/OWASP/java-html-sanitizer>

---

Data as of 2026-12-05T07:50:04.562Z. The priority label is CveMate's own model from public evidence, not an official rating, and it knows nothing about your assets. How labels are decided: https://cvemate.com/faq#priority
