CVE-2017-16017 Cross-Site Scripting in sanitize-html
Cross-site scripting vulnerability in sanitize-html allows attackers to inject malicious scripts into web pages viewed by other users.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- A user has to click or open something
- Fix
- Available
What is CVE-2017-16017?
CVE-2017-16017 is a medium-severity cross-site scripting vulnerability in HackerOne sanitize-html node module, published on 4 Jun 2018. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.
Official description
sanitize-html is a library for scrubbing html input for malicious values Versions 1.2.2 and below have a cross site scripting vulnerability.
Weakness: CWE-79
Which versions are affected by CVE-2017-16017?
2 open source packages ship an affected version, including sanitize-html. It affects 1 product.
| Package | Affected | Fixed in |
|---|---|---|
sanitize-html npm | All versions | 1.2.3 |
sanitize-html npm | All versions | 1.2.3 |
Products include Punkave Sanitize-Html.
How do I fix CVE-2017-16017?
Upgrade sanitize-html to 1.2.3 or later.
Escape output for the context it lands in and set a strict Content Security Policy. Upgrading the affected component is the real fix. More about Cross-site scripting.
Is CVE-2017-16017 being exploited?
There is no known exploitation of CVE-2017-16017 in the wild and no public exploit code.
Other vulnerabilities in HackerOne sanitize-html node module
Sources
Also known as GHSA-wg96-3933-j2w5.