
CVE catalog
CVE-2021-29921
In Python before 3,9,5, the ipaddress library mishandles leading zero characters in the octets of an IP address string. This (in some situations) allows attackers to bypass access control that is base
- Severity
- Critical · CVSS 9.8
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H - Published
- Updated
- Source
- [NVD] · [CVE record]
- EPSS
- 6.88% · Oct 25, 2026
In Python before 3,9,5, the ipaddress library mishandles leading zero characters in the octets of an IP address string. This (in some situations) allows attackers to bypass access control that is based on IP addresses.
Vulnerable and fixed packages
Distribution-reported package versions and fixes. These do not depend on matching against the OpenFactory package catalog.
| Distribution | Package | Release | Version | Status |
|---|---|---|---|---|
| Debian | pypy3 | sid | 8.0.1+dfsg-1 | fixed |
| Debian | pypy3 | forky | 8.0.1+dfsg-1 | fixed |
| Debian | pypy3 | trixie | 7.3.19+dfsg-2 | fixed |
| Debian | pypy3 | bookworm | 7.3.11+dfsg-2+deb12u3 | fixed |
| Cpe | python | Not reported | 3.8.12 | fixed |
| Cpe | python | Not reported | 3.9.5 | fixed |
| Cpe | communications_cloud_native_core_automated_test_suite | Not reported | Not reported | unknown |
| Cpe | communications_cloud_native_core_binding_support_function | Not reported | Not reported | unknown |
| Cpe | communications_cloud_native_core_network_slice_selection_function | Not reported | Not reported | unknown |
| Cpe | graalvm | Not reported | Not reported | unknown |
| Cpe | graalvm | Not reported | Not reported | unknown |
| Cpe | zfs_storage_appliance_kit | Not reported | Not reported | unknown |
| Alpine | python3 | 3.15 | 3.9.5-r0 | fixed |
| Alpine | python3 | 3.16 | 3.9.5-r0 | fixed |
| Alpine | python3 | 3.17 | 3.9.5-r0 | fixed |
| Alpine | python3 | 3.18 | 3.9.5-r0 | fixed |
| Alpine | python3 | 3.19 | 3.9.5-r0 | fixed |
| Alpine | python3 | 3.20 | 3.9.5-r0 | fixed |
| Alpine | python3 | 3.21 | 3.9.5-r0 | fixed |
| Alpine | python3 | 3.22 | 3.9.5-r0 | fixed |
| Alpine | python3 | 3.23 | 3.9.5-r0 | fixed |
| Alpine | python3 | 3.24 | 3.9.5-r0 | fixed |
| Ubuntu | python3.8 | pro | 3.8.0-3~18.04 | vulnerable |
| Ubuntu | python3.8 | pro | 3.8.0-3~18.04.1 | vulnerable |
| Ubuntu | python3.8 | pro | 3.8.0-3ubuntu1~18.04.2 | vulnerable |
| Ubuntu | python3.8 | pro | 3.8.0-3ubuntu1~18.04.2+esm1 | vulnerable |
| Ubuntu | python3.8 | pro | 3.8.0-3ubuntu1~18.04.2+esm2 | fixed |
| Ubuntu | python3.8 | 20.04 | 3.8.0-1 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.0-2 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.0-3 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.0-4 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.0-5 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.1-2ubuntu3 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.2~rc1-1ubuntu1 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.2-1 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.2-1ubuntu1 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.2-1ubuntu1.1 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.2-1ubuntu1.2 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.5-1~20.04 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.5-1~20.04.2 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.5-1~20.04.3 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.10-0ubuntu1~20.04 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.10-0ubuntu1~20.04.1 | fixed |
| Ubuntu | python3.9 | 20.04 | 3.9.0~rc1-1~20.04 | vulnerable |
| Ubuntu | python3.9 | 20.04 | 3.9.0-5~20.04 | vulnerable |
| Ubuntu | python3.9 | 20.04 | 3.9.5-3~20.04.1 | fixed |
| Ubuntu | python3.8 | 20.04 | 3.8.0-1 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.0-2 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.0-3 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.0-4 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.0-5 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.1-2ubuntu3 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.2~rc1-1ubuntu1 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.2-1 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.2-1ubuntu1 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.2-1ubuntu1.1 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.2-1ubuntu1.2 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.5-1~20.04 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.5-1~20.04.2 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.5-1~20.04.3 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.10-0ubuntu1~20.04 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.10-0ubuntu1~20.04.1 | fixed |
| Ubuntu | python3.8 | 20.04 | 3.8.0-1 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.0-2 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.0-3 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.0-4 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.0-5 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.1-2ubuntu3 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.2~rc1-1ubuntu1 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.2-1 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.2-1ubuntu1 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.2-1ubuntu1.1 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.2-1ubuntu1.2 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.5-1~20.04 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.5-1~20.04.2 | vulnerable |
| Ubuntu | python3.8 | 20.04 | 3.8.5-1~20.04.3 | fixed |
| Suse | python39 | linux enterprise module for basesystem 15 sp3 | 3.9.6-4.3.4 | fixed |
| Suse | python39-core | linux enterprise module for basesystem 15 sp3 | 3.9.6-4.3.3 | fixed |
| Suse | python39-core | linux enterprise module for development tools 15 sp3 | 3.9.6-4.3.3 | fixed |
Fixed-version evidence
| Distribution | Package | Type | Release | Fixed version | Urgency | Origin | Bugs |
|---|---|---|---|---|---|---|---|
| Debian | pypy3 | source | sid | 7.3.8+dfsg-1 | not yet assigned | Not reported | Not reported |
| Debian | pypy3 | source | forky | 7.3.8+dfsg-1 | not yet assigned | Not reported | Not reported |
| Debian | pypy3 | source | trixie | 7.3.8+dfsg-1 | not yet assigned | Not reported | Not reported |
| Debian | pypy3 | source | bookworm | 7.3.8+dfsg-1 | not yet assigned | Not reported | Not reported |
| Cpe | python | cpe | Not reported | 3.8.12 | Not reported | NVD-CVE-2021-29921 | Not reported |
| Cpe | python | cpe | Not reported | 3.9.5 | Not reported | NVD-CVE-2021-29921 | Not reported |
| Alpine | python3 | apk | 3.15 | 3.9.5-r0 | Not reported | ALPINE-CVE-2021-29921 | Not reported |
| Alpine | python3 | apk | 3.16 | 3.9.5-r0 | Not reported | ALPINE-CVE-2021-29921 | Not reported |
| Alpine | python3 | apk | 3.17 | 3.9.5-r0 | Not reported | ALPINE-CVE-2021-29921 | Not reported |
| Alpine | python3 | apk | 3.18 | 3.9.5-r0 | Not reported | ALPINE-CVE-2021-29921 | Not reported |
| Alpine | python3 | apk | 3.19 | 3.9.5-r0 | Not reported | ALPINE-CVE-2021-29921 | Not reported |
| Alpine | python3 | apk | 3.20 | 3.9.5-r0 | Not reported | ALPINE-CVE-2021-29921 | Not reported |
| Alpine | python3 | apk | 3.21 | 3.9.5-r0 | Not reported | ALPINE-CVE-2021-29921 | Not reported |
| Alpine | python3 | apk | 3.22 | 3.9.5-r0 | Not reported | ALPINE-CVE-2021-29921 | Not reported |
| Alpine | python3 | apk | 3.23 | 3.9.5-r0 | Not reported | ALPINE-CVE-2021-29921 | Not reported |
| Alpine | python3 | apk | 3.24 | 3.9.5-r0 | Not reported | ALPINE-CVE-2021-29921 | Not reported |
| Ubuntu | python3.8 | deb | pro | 3.8.0-3ubuntu1~18.04.2+esm2 | Not reported | UBUNTU-CVE-2021-29921 | Not reported |
| Ubuntu | python3.8 | deb | 20.04 | 3.8.10-0ubuntu1~20.04.1 | Not reported | UBUNTU-CVE-2021-29921 | Not reported |
| Ubuntu | python3.9 | deb | 20.04 | 3.9.5-3~20.04.1 | Not reported | UBUNTU-CVE-2021-29921 | Not reported |
| Ubuntu | python3.8 | deb | 20.04 | 3.8.10-0ubuntu1~20.04.1 | Not reported | USN-4973-2 | Not reported |
| Ubuntu | python3.8 | deb | 20.04 | 3.8.5-1~20.04.3 | Not reported | USN-4973-1 | Not reported |
| Suse | python39 | rpm | linux enterprise module for basesystem 15 sp3 | 3.9.6-4.3.4 | Not reported | SUSE-SU-2021:2940-1 | Not reported |
| Suse | python39-core | rpm | linux enterprise module for basesystem 15 sp3 | 3.9.6-4.3.3 | Not reported | SUSE-SU-2021:2940-1 | Not reported |
| Suse | python39-core | rpm | linux enterprise module for development tools 15 sp3 | 3.9.6-4.3.3 | Not reported | SUSE-SU-2021:2940-1 | Not reported |
OpenFactory catalog packages
[Debian 12 (Bookworm)]
- [pypy3]Fixed
Details (2)
7.3.11+dfsg-2+deb12u3· amd64 · bookwormFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · bookworm; nvd · pypy3 · debian · 12
7.3.11+dfsg-2+deb12u3· arm64 · bookwormFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · bookworm; nvd · pypy3 · debian · 12
- [pypy3-dev]Fixed
Source package: [pypy3]
Details (2)
7.3.11+dfsg-2+deb12u3· all · bookwormFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · bookworm; nvd · pypy3 · debian · 12
7.3.11+dfsg-2+deb12u3· all · bookwormFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · bookworm; nvd · pypy3 · debian · 12
- [pypy3-doc]Fixed
Source package: [pypy3]
Details (2)
7.3.11+dfsg-2+deb12u3· all · bookwormFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · bookworm; nvd · pypy3 · debian · 12
7.3.11+dfsg-2+deb12u3· all · bookwormFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · bookworm; nvd · pypy3 · debian · 12
- [pypy3-lib]Fixed
Source package: [pypy3]
Details (2)
7.3.11+dfsg-2+deb12u3· amd64 · bookwormFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · bookworm; nvd · pypy3 · debian · 12
7.3.11+dfsg-2+deb12u3· arm64 · bookwormFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · bookworm; nvd · pypy3 · debian · 12
- [pypy3-lib-testsuite]Fixed
Source package: [pypy3]
Details (2)
7.3.11+dfsg-2+deb12u3· all · bookwormFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · bookworm; nvd · pypy3 · debian · 12
7.3.11+dfsg-2+deb12u3· all · bookwormFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · bookworm; nvd · pypy3 · debian · 12
- [pypy3-tk]Fixed
Source package: [pypy3]
Details (2)
7.3.11+dfsg-2+deb12u3· amd64 · bookwormFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · bookworm; nvd · pypy3 · debian · 12
7.3.11+dfsg-2+deb12u3· arm64 · bookwormFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · bookworm; nvd · pypy3 · debian · 12
- [pypy3-venv]Fixed
Source package: [pypy3]
Details (2)
7.3.11+dfsg-2+deb12u3· all · bookwormFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · bookworm; nvd · pypy3 · debian · 12
7.3.11+dfsg-2+deb12u3· all · bookwormFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · bookworm; nvd · pypy3 · debian · 12
[Debian 13 (Trixie)]
- [pypy3]Fixed
Details (2)
7.3.19+dfsg-2· amd64 · trixieFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · 13
7.3.19+dfsg-2· arm64 · trixieFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · 13
- [pypy3-dev]Fixed
Source package: [pypy3]
Details (2)
7.3.19+dfsg-2· all · trixieFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · 13
7.3.19+dfsg-2· all · trixieFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · 13
- [pypy3-doc]Fixed
Source package: [pypy3]
Details (2)
7.3.19+dfsg-2· all · trixieFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · 13
7.3.19+dfsg-2· all · trixieFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · 13
- [pypy3-lib]Fixed
Source package: [pypy3]
Details (2)
7.3.19+dfsg-2· amd64 · trixieFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · 13
7.3.19+dfsg-2· arm64 · trixieFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · 13
- [pypy3-lib-testsuite]Fixed
Source package: [pypy3]
Details (2)
7.3.19+dfsg-2· all · trixieFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · 13
7.3.19+dfsg-2· all · trixieFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · 13
- [pypy3-tk]Fixed
Source package: [pypy3]
Details (2)
7.3.19+dfsg-2· amd64 · trixieFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · 13
7.3.19+dfsg-2· arm64 · trixieFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · 13
- [pypy3-venv]Fixed
Source package: [pypy3]
Details (2)
7.3.19+dfsg-2· all · trixieFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · 13
7.3.19+dfsg-2· all · trixieFixed · Fixed:
7.3.8+dfsg-1nvd · pypy3 · debian · 13
Observed:
References
- [https://ftp.suse.com/pub/projects/security/csaf/suse-su-2021_2940-1.json]
- [https://nvd.nist.gov/vuln/detail/CVE-2021-29921]
- [https://osv.dev/vulnerability/ALPINE-CVE-2021-29921]
- [https://osv.dev/vulnerability/DEBIAN-CVE-2021-29921]
- [https://osv.dev/vulnerability/SUSE-SU-2021:2940-1]
- [https://osv.dev/vulnerability/UBUNTU-CVE-2021-29921]
- [https://osv.dev/vulnerability/USN-4973-1]
- [https://osv.dev/vulnerability/USN-4973-2]
- [https://security-tracker.debian.org/tracker/CVE-2021-29921]
- [https://security.access.redhat.com/data/csaf/v2/vex/2021/cve-2021-29921.json]
- [https://wid.cert-bund.de/.well-known/csaf/white/2021/wid-sec-w-2023-2460.json]
[CERT-Bund public advisories] · [Debian Security Tracker] · [FIRST EPSS] · [National Vulnerability Database (NVD)] · [OSV Package Vulnerability Database] · [Red Hat security advisories and VEX] · [SUSE security advisories and VEX]