CVE-2021-42521
VTK NULL pointer dereference vulnerability
There is a NULL pointer dereference vulnerability in VTK before 9.2.5, and it lies in IO/Infovis/vtkXMLTreeReader.cxx. The vendor didn't check the return value of libxml2 API 'xmlDocGetRootElement', and try to dereference it. It is unsafe as the return value can be NULL and that NULL pointer dereference may crash the application.
Attack profile
How easy it is to exploit
- Attack vector
- Network
- Complexity
- Low
- Privileges needed
- None
- User interaction
- None
What an attacker can affect
- Confidentiality
- None
- Integrity
- None
- Availability
- High
Exploit likelihood
What each source reports
NVD Score used
7.5
There is a NULL pointer dereference vulnerability in VTK before 9.2.5, and it lies in IO/Infovis/vtkXMLTreeReader.cxx. The vendor didn't check the return value of libxml2 API 'xmlDocGetRootElement', and try to dereference it. It is unsafe as the return value can be NULL and that NULL pointer dereference may crash the application.
- Record
CVE-2021-42521- CVSS 3.1
- 7.5 High
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H - Weakness
- CWE-400, CWE-476
- Updated
- 2026-11-02
CVE List No score
There is a NULL pointer dereference vulnerability in VTK before 9.2.5, and it lies in IO/Infovis/vtkXMLTreeReader.cxx. The vendor didn't check the return value of libxml2 API 'xmlDocGetRootElement', and try to dereference it. It is unsafe as the return value can be NULL and that NULL pointer dereference may crash the application.
- Record
CVE-2021-42521- Weakness
- CWE-400
- Updated
- 2026-11-02
EUVDEUVD-2022-0352 No score
There is a NULL pointer dereference vulnerability in VTK before 9.2.5, and it lies in IO/Infovis/vtkXMLTreeReader.cxx. The vendor didn't check the return value of libxml2 API 'xmlDocGetRootElement', and try to dereference it. It is unsafe as the return value can be NULL and that NULL pointer dereference may crash the application.
- Record
EUVD-2022-0352- Updated
- 2026-11-03
GitHub AdvisoriesGHSA-xfhg-9pjg-xg7g
8.7
VTK NULL pointer dereference vulnerability
There is a NULL pointer dereference vulnerability in VTK, and it lies in IO/Infovis/vtkXMLTreeReader.cxx. The vendor didn't check the return value of libxml2 API 'xmlDocGetRootElement', and try to dereference it. It is unsafe as the return value can be NULL and that NULL pointer dereference may crash the application.
- Record
GHSA-xfhg-9pjg-xg7g- CVSS 4.0
- 8.7 High
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N - CVSS 3.1
- 7.5 High
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H - Weakness
- CWE-400, CWE-476
- Updated
- 2026-11-02
OSV
7.5
There is a NULL pointer dereference vulnerability in VTK before 9.2.5, and it lies in IO/Infovis/vtkXMLTreeReader.cxx. The vendor didn't check the return value of libxml2 API 'xmlDocGetRootElement', and try to dereference it. It is unsafe as the return value can be NULL and that NULL pointer dereference may crash the application.
- Record
CVE-2021-42521- CVSS 3.1
- 7.5 High
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H - Updated
- 2026-11-02
OSVDEBIAN-CVE-2021-42521
7.5
There is a NULL pointer dereference vulnerability in VTK before 9.2.5, and it lies in IO/Infovis/vtkXMLTreeReader.cxx. The vendor didn't check the return value of libxml2 API 'xmlDocGetRootElement', and try to dereference it. It is unsafe as the return value can be NULL and that NULL pointer dereference may crash the application.
- Record
DEBIAN-CVE-2021-42521- CVSS 3.1
- 7.5 High
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H - Updated
- 2026-11-02
OSVGHSA-xfhg-9pjg-xg7g
8.7
VTK NULL pointer dereference vulnerability
There is a NULL pointer dereference vulnerability in VTK, and it lies in IO/Infovis/vtkXMLTreeReader.cxx. The vendor didn't check the return value of libxml2 API 'xmlDocGetRootElement', and try to dereference it. It is unsafe as the return value can be NULL and that NULL pointer dereference may crash the application.
- Record
GHSA-xfhg-9pjg-xg7g- CVSS 4.0
- 8.7 High
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N - CVSS 3.1
- 7.5 High
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H - Weakness
- CWE-400, CWE-476
- Updated
- 2026-11-02
OSVUBUNTU-CVE-2021-42521
7.5
There is a NULL pointer dereference vulnerability in VTK before 9.2.5, and it lies in IO/Infovis/vtkXMLTreeReader.cxx. The vendor didn't check the return value of libxml2 API 'xmlDocGetRootElement', and try to dereference it. It is unsafe as the return value can be NULL and that NULL pointer dereference may crash the application.
- Record
UBUNTU-CVE-2021-42521- CVSS 3.1
- 7.5 High
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H - Updated
- 2026-11-02
OSVPYSEC-2022-255 No score
There is a NULL pointer dereference vulnerability in VTK, and it lies in IO/Infovis/vtkXMLTreeReader.cxx. The vendor didn't check the return value of libxml2 API 'xmlDocGetRootElement', and try to dereference it. It is unsafe as the return value can be NULL and that NULL pointer dereference may crash the application.
- Record
PYSEC-2022-255- Updated
- 2026-11-02
Affected products
Affected packages
| Package | Affected | Fixed |
|---|---|---|
vtkPyPI |
before 9.0.1 | 9.0.1 |
vtk9Debian:12 |
All versions, plus listed versions 9.1.0+really9.1.0+dfsg2-59.1.0+really9.1.0+dfsg2-5+deb12u19.1.0+really9.1.0+dfsg2-69.1.0+really9.1.0+dfsg2-79.1.0+really9.1.0+dfsg2-7.1 Show 45 moreShow less9.1.0+really9.1.0+dfsg2-89.2.6+dfsg1-1+exp19.2.6+dfsg1-1+exp29.3.0+dfsg1-19.3.0+dfsg1-1.19.3.0+dfsg1-1~exp19.3.0+dfsg1-1~exp29.3.0+dfsg1-1~exp39.3.0+dfsg1-1~exp49.3.0+dfsg1-29.3.0+dfsg1-39.3.0+dfsg1-3+hurd.19.3.0+dfsg1-49.3.0+dfsg1-4+m68k9.3.0+dfsg1-4.1+hurd.19.3.0+dfsg1-59.3.0+dfsg1-69.3.0+dfsg1-79.5.2+dfsg1-1~exp19.5.2+dfsg2-19.5.2+dfsg2-1~exp19.5.2+dfsg2-1~exp29.5.2+dfsg2-1~exp39.5.2+dfsg2-1~exp49.5.2+dfsg2-29.5.2+dfsg2-39.5.2+dfsg2-49.5.2+dfsg3-19.5.2+dfsg3-29.5.2+dfsg3-39.5.2+dfsg3-49.5.2+dfsg3-59.5.2+dfsg3-69.5.2+dfsg3-79.5.2+dfsg3-89.5.2+dfsg4-19.5.2+dfsg4-29.5.2+dfsg4-39.5.2+dfsg4-49.5.2+dfsg4-59.6.2+dfsg1-1exp19.6.2+dfsg1-1exp29.6.2+dfsg1-1exp39.6.2+dfsg1-1exp49.6.2+dfsg1-1exp5 |
None known |
vtk9Debian:13 |
before 9.1.0+really9.1.0+dfsg2-8 | 9.1.0+really9.1.0+dfsg2-8 |
vtk9Debian:14 |
before 9.1.0+really9.1.0+dfsg2-8 | 9.1.0+really9.1.0+dfsg2-8 |
vtkPyPI |
before 9.0.1, plus listed versions 8.1.08.1.18.1.29.0.0 |
9.0.1 |
vtkUbuntu:Pro:14.04:LTS |
All versions, plus listed versions 5.8.0-14ubuntu15.8.0-14ubuntu35.8.0-14.1ubuntu25.8.0-14.1ubuntu35.8.0-14.1ubuntu3+esm1 |
None known |
vtk6Ubuntu:14.04:LTS |
All versions, plus listed versions 6.0.0-16.0.0-26.0.0-36.0.0-46.0.0-6 |
None known |
vtkUbuntu:Pro:16.04:LTS |
All versions, plus listed versions 5.10.1+dfsg-25.10.1+dfsg-2build35.10.1+dfsg-2.1build15.10.1+dfsg-2.1ubuntu0.1~esm1 |
None known |
vtk6Ubuntu:Pro:16.04:LTS |
All versions, plus listed versions 6.2.0+dfsg1-4ubuntu56.2.0+dfsg1-4ubuntu66.2.0+dfsg1-86.2.0+dfsg1-96.2.0+dfsg1-10build16.2.0+dfsg1-10ubuntu0.16.2.0+dfsg1-10ubuntu0.1+esm1 |
None known |
vtk6Ubuntu:18.04:LTS |
All versions, plus listed versions 6.3.0+dfsg1-10build16.3.0+dfsg1-10build26.3.0+dfsg1-10build36.3.0+dfsg1-116.3.0+dfsg1-11build1 |
None known |
Show 6 moreShow less
| Package | Affected | Fixed |
|---|---|---|
vtk7Ubuntu:18.04:LTS |
All versions, plus listed versions 7.1.1+dfsg1-2 |
None known |
vtk6Ubuntu:20.04:LTS |
All versions, plus listed versions 6.3.0+dfsg2-2build76.3.0+dfsg2-4build16.3.0+dfsg2-56.3.0+dfsg2-5build16.3.0+dfsg2-5build2 |
None known |
vtk7Ubuntu:20.04:LTS |
All versions, plus listed versions 7.1.1+dfsg1-12build27.1.1+dfsg2-17.1.1+dfsg2-1build17.1.1+dfsg2-1ubuntu37.1.1+dfsg2-2ubuntu1 |
None known |
vtk7Ubuntu:22.04:LTS |
All versions, plus listed versions 7.1.1+dfsg2-107.1.1+dfsg2-10ubuntu27.1.1+dfsg2-10ubuntu37.1.1+dfsg2-10.17.1.1+dfsg2-10.1build1 |
None known |
vtk9Ubuntu:22.04:LTS |
All versions, plus listed versions 9.0.1+dfsg1-89.1.0+really9.0.3+dfsg1-49.1.0+really9.0.3+dfsg1-4build19.1.0+really9.1.0+dfsg2-39.1.0+really9.1.0+dfsg2-3build1 |
None known |
vtk9Ubuntu:24.04:LTS |
All versions, plus listed versions 9.1.0+really9.1.0+dfsg2-79.1.0+really9.1.0+dfsg2-7build19.1.0+really9.1.0+dfsg2-7.1build29.1.0+really9.1.0+dfsg2-7.1build3 |
None known |
History
| Recorded | Changed | Sources |
|---|---|---|
| aliases | EUVD | |
| first indexed | CVE List, GitHub Advisories, NVD, OSV |
Dates are when Every CVE recorded each change. Upstream dates may differ.
In short
CVE-2021-42521 is a high vulnerability (CVSS 7.5) in Vtk, published August 25, 2022. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 1.32%, the 70th percentile. Fixed in vtk 9.0.1.
References
gitlab.kitware.com/vtk/vtk/issues/17818
discourse.vtk.org/t/vtk-9-2-5-is-out/10549
lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/PCTMSAAVP4BW2HTZLDWMGKZ2WEC5OFLK
nvd.nist.gov/vuln/detail/CVE-2021-42521
github.com/pypa/advisory-database/tree/main/vulns/vtk/PYSEC-2022-255.yaml
lists.fedoraproject.org/archives/list/[email protected]/message/PCTMSAAVP4BW2HTZLDWMGKZ2WEC5OFLK
Left out here: 11 versions. The JSON record has them.