CVE-2017-16876 mistune Cross-site scripting (XSS) vulnerability
Remote attackers can inject arbitrary web script or HTML via the key argument in the Mistune Markdown parser library.
- 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-16876?
CVE-2017-16876 is a medium-severity cross-site scripting vulnerability in Fedoraproject Fedora, published on 29 Dec 2017. 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
Cross-site scripting (XSS) vulnerability in the _keyify function in mistune.py in Mistune before 0.8.1 allows remote attackers to inject arbitrary web script or HTML by leveraging failure to escape the "key" argument.
Weakness: CWE-79
Which versions are affected by CVE-2017-16876?
3 open source packages ship an affected version, including mistune. It affects 2 products.
| Package | Affected | Fixed in |
|---|---|---|
mistune PyPI | All versions | 0.8.1 |
mistune PyPI | All versions | 0.8.1 |
mistune PyPI | All versions | 0.8.1 |
Products include Fedoraproject Fedora, Mistune Project Mistune.
How do I fix CVE-2017-16876?
Upgrade mistune to 0.8.1 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-16876 being exploited?
There is no known exploitation of CVE-2017-16876 in the wild and no public exploit code.
Other vulnerabilities in Fedoraproject Fedora
Sources
Also known as DEBIAN-CVE-2017-16876, GHSA-98gj-wwxm-cj3h, PYSEC-2017-18, UBUNTU-CVE-2017-16876.