CVE-2019-25225CWE-79
`sanitize-html` prior to version 2.0.0-beta is vulnerable to Cross-site Scripting (XSS)
Medium · published September 8, 2025
What it is
`sanitize-html` prior to version 2.0.0-beta is vulnerable to Cross-site Scripting (XSS). The `sanitizeHtml()` function in `index.js` does not sanitize content when using the custom `transformTags` option, which is intended to convert attribute values into text. As a result, malicious input can be transformed into executable code.
The record
Technical detail
- CVSS v3.1
- 6.1 · MEDIUM
- Vector
- CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
- CVSS v4.0
- Not supplied
- EPSS
- 0.00269 · 18.0th percentile
- Weakness
- CWE-79 · Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
- Published
- 2025-09-08T10:02Z
EPSS history
Timeline