CVE-2018-19787: Improper Neutralization of Input During Web Page Generation in LXML

CVE-2018-19787 · Severity: low · CVSS 3 · Published 2018-12-02

An issue was discovered in lxml before 4.2.5. lxml/html/clean.py in the lxml.html.clean module does not remove javascript: URLs that use escaping, allowing a remote attacker to conduct XSS attacks, as demonstrated by "j a v a s c r i p t:" in Internet Explorer. This is a similar issue to CVE-2014-3146.

Technologies: lxml (PyPI). Vendors: PyPI.

Quick answers

Is CVE-2018-19787 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2018-19787 being exploited in the wild.
How severe is CVE-2018-19787?
Low severity, with a CVSS score of 3, published 2 December 2018.
Which products and versions are affected?
lxml (PyPI) ECOSYSTEM:introduced=0,fixed=4.2.5, GIT:introduced=0,fixed=6be1d081b49c97cfd7b3fbd934a193b668629109|ECOSYSTEM:introduced=0,fixed=4.2.5.
Is there a fix for CVE-2018-19787?
Yes. lxml (PyPI): upgrade to 4.2.5 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
Am I affected by CVE-2018-19787?
Check whether you run lxml (PyPI) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

How to fix

  • lxml (PyPI): upgrade to 4.2.5 or later
    pip install "lxml>=4.2.5"

Affected products

  • lxml (PyPI) ECOSYSTEM:introduced=0,fixed=4.2.5, GIT:introduced=0,fixed=6be1d081b49c97cfd7b3fbd934a193b668629109|ECOSYSTEM:introduced=0,fixed=4.2.5

Identifiers

  • CVE-2018-19787
  • GHSA-xp26-p53h-6h2p
  • PYSEC-2018-12

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.