Improper Neutralization of Input During Web Page Generation in LXML
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.
Affected software
Click a technology to see all vulnerabilities affecting it.
| Platform | Package | Vulnerable versions | Fixed in |
|---|---|---|---|
| Python (PyPI) | lxml | < 4.2.5 | 4.2.5 |
References
- https://github.com/lxml/lxml/commit/6be1d081b49c97cfd7b3fbd934a193b668629109
- https://lists.debian.org/debian-lts-announce/2018/12/msg00001.html
- https://usn.ubuntu.com/3841-2/
- https://usn.ubuntu.com/3841-1/
- https://lists.debian.org/debian-lts-announce/2020/11/msg00044.html
- https://github.com/advisories/GHSA-xp26-p53h-6h2p
- https://nvd.nist.gov/vuln/detail/CVE-2018-19787
- https://github.com/lxml/lxml
- https://github.com/pypa/advisory-database/tree/main/vulns/lxml/PYSEC-2018-12.yaml
- https://usn.ubuntu.com/3841-1
- https://usn.ubuntu.com/3841-2
- CVSS vector
CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N- Weakness (CWE)
CWE-79- Platform
- Python (PyPI)
- Package
lxml- Disclosed
- 02.12.2018
- Updated
- 11.10.2026 12:19
Sources and licenses
OSV / GitHub Advisory Database - PYSEC-2018-12 - PyPA Advisory Database; CC BY 4.0
OSV / GitHub Advisory Database - GHSA-xp26-p53h-6h2p - CC BY 4.0
Vulnerability history: lxml
All published vulnerabilities of this package (Python (PyPI)), newest first. Shows whether this is a one-off slip or a package that needs watching.
- Total entries
- 7
- First → latest
- 05.2014 04.2026
- Without a fix
- 0
- Exploited in attacks
- 0
Severity breakdown
- High 1
- Medium 6
Disclosures per year
- 2017: 0
- 2018: 1
- 2019: 0
- 2020: 1
- 2021: 2
- 2022: 1
- 2023: 0
- 2024: 0
- 2025: 0
- 2026: 1
earlier: 1
-
Improper Neutralization of Input During Web Page Generation in LXML this entry
Know which vulnerabilities affect your application
With the DockRay integration and software inventory enabled, DockRay checks reported component versions against known vulnerabilities and notifies you about confirmed matches. Coverage depends on the supported technology and available advisory data.