Search for packages
Package details: pkg:pypi/lxml@4.4.0
purl pkg:pypi/lxml@4.4.0
Next non-vulnerable version 4.9.1
Latest non-vulnerable version 4.9.1
Risk 4.0
Vulnerabilities affecting this package (4)
Vulnerability Summary Fixed by
VCID-6tqt-q9px-1ka6
Aliases:
CVE-2021-43818
GHSA-55x5-fj6c-h6m8
PYSEC-2021-852
lxml is a library for processing XML and HTML in the Python language. Prior to version 4.6.5, the HTML Cleaner in lxml.html lets certain crafted script content pass through, as well as script content in SVG files embedded using data URIs. Users that employ the HTML cleaner in a security relevant context should upgrade to lxml 4.6.5 to receive a patch. There are no known workarounds available.
4.6.5
Affected by 1 other vulnerability.
VCID-9ym4-6av7-aqe3
Aliases:
CVE-2022-2309
GHSA-wrxv-2j5q-m38w
PYSEC-2022-230
NULL Pointer Dereference allows attackers to cause a denial of service (or application crash). This only applies when lxml is used together with libxml2 2.9.10 through 2.9.14. libxml2 2.9.9 and earlier are not affected. It allows triggering crashes through forged input data, given a vulnerable code sequence in the application. The vulnerability is caused by the iterwalk function (also used by the canonicalize function). Such code shouldn't be in wide-spread use, given that parsing + iterwalk would usually be replaced with the more efficient iterparse function. However, an XML converter that serialises to C14N would also be vulnerable, for example, and there are legitimate use cases for this code sequence. If untrusted input is received (also remotely) and processed via iterwalk function, a crash can be triggered.
4.9.1
Affected by 0 other vulnerabilities.
VCID-fy7w-e8zj-hyas
Aliases:
CVE-2021-28957
GHSA-jq4v-f5q6-mjqq
PYSEC-2021-19
An XSS vulnerability was discovered in python-lxml's clean module versions before 4.6.3. When disabling the safe_attrs_only and forms arguments, the Cleaner class does not remove the formaction attribute allowing for JS to bypass the sanitizer. A remote attacker could exploit this flaw to run arbitrary JS code on users who interact with incorrectly sanitized HTML. This issue is patched in lxml 4.6.3.
4.6.3
Affected by 2 other vulnerabilities.
VCID-kk16-5uu2-puc2
Aliases:
CVE-2020-27783
GHSA-pgww-xf46-h92r
PYSEC-2020-62
A XSS vulnerability was discovered in python-lxml's clean module. The module's parser didn't properly imitate browsers, which caused different behaviors between the sanitizer and the user's page. A remote attacker could exploit this flaw to run arbitrary HTML/JS code.
4.6.2
Affected by 3 other vulnerabilities.
Vulnerabilities fixed by this package (0)
Vulnerability Summary Aliases
This package is not known to fix vulnerabilities.

Date Actor Action Vulnerability Source VulnerableCode Version
2025-08-01T10:41:55.187588+00:00 GitLab Importer Affected by VCID-9ym4-6av7-aqe3 https://gitlab.com/gitlab-org/advisories-community/-/blob/main/pypi/lxml/CVE-2022-2309.yml 37.0.0
2025-08-01T10:08:28.136830+00:00 GitLab Importer Affected by VCID-6tqt-q9px-1ka6 https://gitlab.com/gitlab-org/advisories-community/-/blob/main/pypi/lxml/CVE-2021-43818.yml 37.0.0
2025-08-01T09:50:17.206449+00:00 GitLab Importer Affected by VCID-fy7w-e8zj-hyas https://gitlab.com/gitlab-org/advisories-community/-/blob/main/pypi/lxml/CVE-2021-28957.yml 37.0.0
2025-08-01T09:46:55.657660+00:00 GitLab Importer Affected by VCID-kk16-5uu2-puc2 https://gitlab.com/gitlab-org/advisories-community/-/blob/main/pypi/lxml/CVE-2020-27783.yml 37.0.0
2025-08-01T09:09:40.232754+00:00 GHSA Importer Affected by VCID-9ym4-6av7-aqe3 https://github.com/advisories/GHSA-wrxv-2j5q-m38w 37.0.0
2025-08-01T08:49:23.199322+00:00 PyPI Importer Affected by VCID-9ym4-6av7-aqe3 https://osv-vulnerabilities.storage.googleapis.com/PyPI/all.zip 37.0.0
2025-08-01T08:39:37.811819+00:00 PyPI Importer Affected by VCID-fy7w-e8zj-hyas https://osv-vulnerabilities.storage.googleapis.com/PyPI/all.zip 37.0.0
2025-08-01T08:37:22.452064+00:00 PyPI Importer Affected by VCID-kk16-5uu2-puc2 https://osv-vulnerabilities.storage.googleapis.com/PyPI/all.zip 37.0.0
2025-08-01T08:25:57.661850+00:00 GHSA Importer Affected by VCID-fy7w-e8zj-hyas https://github.com/advisories/GHSA-jq4v-f5q6-mjqq 37.0.0
2025-08-01T08:24:57.251394+00:00 GHSA Importer Affected by VCID-kk16-5uu2-puc2 https://github.com/advisories/GHSA-pgww-xf46-h92r 37.0.0
2025-07-31T08:20:45.826511+00:00 Pypa Importer Affected by VCID-9ym4-6av7-aqe3 https://github.com/pypa/advisory-database/blob/main/vulns/lxml/PYSEC-2022-230.yaml 37.0.0
2025-07-31T08:19:11.148223+00:00 Pypa Importer Affected by VCID-6tqt-q9px-1ka6 https://github.com/pypa/advisory-database/blob/main/vulns/lxml/PYSEC-2021-852.yaml 37.0.0
2025-07-31T08:11:22.398603+00:00 Pypa Importer Affected by VCID-fy7w-e8zj-hyas https://github.com/pypa/advisory-database/blob/main/vulns/lxml/PYSEC-2021-19.yaml 37.0.0
2025-07-31T08:10:24.578790+00:00 Pypa Importer Affected by VCID-kk16-5uu2-puc2 https://github.com/pypa/advisory-database/blob/main/vulns/lxml/PYSEC-2020-62.yaml 37.0.0