{"id":"CVE-2022-2309","published":"2022-07-05T09:00:12Z","modified":"2025-11-04T16:09:31Z","title":"NULL Pointer Dereference in lxml/lxml","vendor":"lxml","product":"lxml/lxml","tier":"tail","description":{"text":"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.","provenance":"source","from":"CVE.org"},"cvss":{"score":5.3,"severity":"MEDIUM","version":"3.0","vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.02448,"percentile":0.84755,"provenance":"source"},"cwes":[{"id":"CWE-476","name":"NULL Pointer Dereference"}],"references":[{"url":"https://huntr.dev/bounties/8264e74f-edda-4c40-9956-49de635105ba","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/lxml/lxml/commit/86368e9cf70a0ad23cccd5ee32de847149af0c6f","tags":["x_refsource_MISC"]},{"url":"https://security.gentoo.org/glsa/202208-06","tags":["vendor-advisory","x_refsource_GENTOO"]},{"url":"https://security.netapp.com/advisory/ntap-20220915-0006/","tags":["x_refsource_CONFIRM"]},{"url":"https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/URHHSIBTPTALXMECRLAC2EVDNAFSR5NO/","tags":["vendor-advisory","x_refsource_FEDORA"]},{"url":"https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/HGYC6L7ENH5VEGN3YWFBYMGKX6WNS7HZ/","tags":["vendor-advisory","x_refsource_FEDORA"]},{"url":"https://lists.debian.org/debian-lts-announce/2024/09/msg00021.html","tags":[]}],"priority":{"score":20.7,"factors":[{"name":"EPSS percentile","points":16.95},{"name":"CVSS severity","points":3.71}]},"vendorSlug":"lxml","affectedVersions":[{"vendor":"lxml","product":"lxml/lxml","versions":[">= unspecified, < 4.9.1"]}],"affected":[{"ecosystem":"PyPI","package":"lxml","vulnerableRanges":["<4.9.1"],"patched":["4.9.1"],"from":["GHSA-wrxv-2j5q-m38w","PYSEC-2022-230"],"provenance":"source"}],"summary":{"text":"The flaw is a NULL pointer dereference in the iterwalk function of lxml/lxml, which is also used by canonicalize, and it only applies when lxml is used with libxml2 versions 2.9.10 through 2.9.14. An attacker who can supply untrusted input, including remotely, can crash an application that processes that input through iterwalk, provided the application uses a vulnerable code sequence and requires no authentication or user interaction.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T07:15:29Z"},"euvd":{"id":"EUVD-2022-0148","exploited":false,"provenance":"source"},"lineage":{"packageHistory":[{"cve":"CVE-2020-27783","published":"2020-12-03","fixed":"4.6.2","kev":false},{"cve":"CVE-2021-28957","published":"2021-03-21","fixed":"4.6.3","kev":false},{"cve":"CVE-2021-43818","published":"2021-12-13","fixed":"4.6.5","kev":false,"link":{"from":"CVE-2021-43818","to":"CVE-2022-2309","relation":"successor","confidence":"low","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"PyPI:lxml","fromFixed":"4.6.5","toFixed":"4.9.1","daysApart":204}]}},{"cve":"CVE-2022-2309","published":"2022-07-05","fixed":"4.9.1","kev":false},{"cve":"CVE-2026-41066","published":"2026-04-24","fixed":"6.1.0","kev":false}],"package":"PyPI:lxml"}}