CVE-2021-29921
python-ipaddress: Improper input validation of octal strings
Overview
Description
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.
Source: OX vulnerability database
Severity
9.8 · CRITICAL
CVSS 3.1 base score, scored by NVD.
- Attack vector
- Network
- Attack complexity
- Low
- Privileges required
- None
- User interaction
- None
- Scope
- Unchanged
- Confidentiality
- High
- Integrity
- High
- Availability
- High
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Affected packages · 3
| Ecosystem | Package | Vulnerable | Fixed in |
|---|---|---|---|
| Bitnami | libpython | >=3.8.0, <3.8.12>=3.9.0, <3.9.5 | 3.8.123.9.5 |
| Bitnami | python | >=3.8.0, <3.8.12>=3.9.0, <3.9.5 | 3.8.123.9.5 |
| Bitnami | python-min | >=3.8.0, <3.8.12>=3.9.0, <3.9.5 | 3.8.123.9.5 |
Open a package to see all its vulnerabilities.
Operating systems · 305 fixes
Oracle Linux 1 release · 71 packages
fixed 71
python38-wcwidth
python38-pymysql
python39-pymysql
python39-toml
python38-pluggy
python39-pluggy
+65
| Release | Package | Fixed in |
|---|---|---|
| 8 | python38-wcwidth | 0.1.7-16.module+el8.2.0+5579+085cd3bd |
| 8 | python38-pymysql | 0.10.1-1.module+el8.4.0+20068+32a535e2 |
| 8 | python39-pymysql | 0.10.1-2.module+el8.4.0+20109+b7b1db01 |
| 8 | python39-toml | 0.10.1-5.module+el8.4.0+20109+b7b1db01 |
| 8 | python38-pluggy | 0.13.0-3.module+el8.2.0+5579+085cd3bd |
| 8 | python39-pluggy | 0.13.1-3.module+el8.4.0+20109+b7b1db01 |
65 more rows
Photon OS 1 release · 1 package
fixed 1
python3
| Release | Package | Fixed in |
|---|---|---|
| 4.0 | python3 +7 | 3.9.1-5.ph4 |
Red Hat 5 releases · 79 packages
fixed 79
rh-python38-python-urllib3
rh-python38-python-pip
rh-python38-python-jinja2
rh-python38-python-babel
rh-python38-python-cryptography
rh-python38-python
+73
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| 7 | rh-python38-python-urllib3 | 0:1.25.7-7.el7 | RHSA-2021:3254 |
| 7 | rh-python38-python-pip +1 | 0:19.3.1-2.el7 | RHSA-2021:3254 |
| 7 | rh-python38-python-jinja2 | 0:2.10.3-6.el7 | RHSA-2021:3254 |
| 7 | rh-python38-python-babel | 0:2.7.0-12.el7 | RHSA-2021:3254 |
| 7 | rh-python38-python-cryptography | 0:2.8-5.el7 | RHSA-2021:3254 |
| 7 | rh-python38-python +8 | 0:3.8.11-2.el7 | RHSA-2021:3254 |
73 more rows
alma 2 releases · 64 packages
fixed 64
python38-wcwidth
python38-pymysql
python38-pluggy
python38-cython
python38-wheel
python38-markupsafe
+58
| Release | Package | Fixed in |
|---|---|---|
| 8 (python38:3.8) | python38-wcwidth | 0.1.7-16.module_el8.6.0+2778+cd494b30 |
| 8 (python38:3.8) | python38-pymysql | 0.10.1-1.module_el8.6.0+2778+cd494b30 |
| 8 (python38:3.8) | python38-pluggy | 0.13.0-3.module_el8.6.0+2778+cd494b30 |
| 8 (python38:3.8) | python38-cython | 0.29.14-4.module_el8.6.0+2778+cd494b30 |
| 8 (python38:3.8) | python38-wheel +1 | 0.33.6-6.module_el8.6.0+2778+cd494b30 |
| 8 (python38:3.8) | python38-markupsafe | 1.1.1-6.module_el8.6.0+2778+cd494b30 |
58 more rows
alpine 4 releases · 1 package
fixed 4
python3
| Release | Package | Fixed in |
|---|---|---|
| 3.22 | python3 | 3.9.5-r0 |
| 3.23 | python3 | 3.9.5-r0 |
| 3.24 | python3 | 3.9.5-r0 |
| edge | python3 | 3.9.5-r0 |
debian 5 releases · 2 packages
affected 1
fixed 4
pypy3
python3-9
| Release | Package | Fixed in |
|---|---|---|
| 10 | pypy3 | affected |
| 11 | python3-9 | 3.9.2-1+deb11u2 |
| 12 | pypy3 | 7.3.8+dfsg-1 |
| 13 | pypy3 | 7.3.8+dfsg-1 |
| 14 | pypy3 | 7.3.8+dfsg-1 |
echo 1 release · 1 package
fixed 1
pypy3
| Release | Package | Fixed in |
|---|---|---|
| pypy3 | 7.3.8+dfsg-1 |
openSUSE 1 release · 1 package
fixed 1
python39
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Tumbleweed | python39 +5 | 3.9.7-2.1 | openSUSE-SU-2024:11286-1 |
rocky 3 releases · 48 packages
fixed 73
python38-pymysql
python38-wheel
python38-six
python38-numpy
python39-numpy
python39-urllib3
+42
| Release | Package | Fixed in |
|---|---|---|
| 8 | python38-pymysql | 0.10.1-1.module+el8.5.0+672+ab6eb015 |
| 8 | python38-wheel +1 | 0.33.6-6.module+el8.5.0+672+ab6eb015 |
| 8 | python38-six | 1.12.0-10.module+el8.4.0+570+c2eaf144 |
| 8 | python38-numpy +2 | 1.17.3-6.module+el8.5.0+672+ab6eb015 |
| 8 | python39-numpy +2 | 1.19.4-3.module+el8.5.0+673+10283621 |
| 8 | python39-urllib3 | 1.25.10-4.module+el8.5.0+673+10283621 |
67 more rows
root.io debian 1 release · 1 package
fixed 1
python3-9
| Release | Package | Fixed in |
|---|---|---|
| 11 | python3-9 +1 | 3.9.2-1+deb11u2 |
ubuntu 3 releases · 2 packages
fixed 5
python3-8
python3-9
| Release | Package | Fixed in |
|---|---|---|
| 18.04-ESM | python3-8 | 3.8.0-3ubuntu1~18.04.2+esm2 |
| 20.04 | python3-8 | 3.8.10-0ubuntu1~20.04.1 |
| 20.04 | python3-9 | 3.9.5-3~20.04.1 |
| 20.04-ESM | python3-8 | 3.8.10-0ubuntu1~20.04.1 |
| 20.04-ESM | python3-9 | 3.9.5-3~20.04.1 |
References
- access.redhat.com https://access.redhat.com/security/cve/CVE-2021-29921
- bugs.python.org https://bugs.python.org/issue36384
- bugzilla.redhat.com https://bugzilla.redhat.com/show_bug.cgi?id=1772014
- bugzilla.redhat.com https://bugzilla.redhat.com/show_bug.cgi?id=1928707
- bugzilla.redhat.com https://bugzilla.redhat.com/show_bug.cgi?id=1928904
- bugzilla.redhat.com https://bugzilla.redhat.com/show_bug.cgi?id=1935913
- bugzilla.redhat.com https://bugzilla.redhat.com/show_bug.cgi?id=1941534
- bugzilla.redhat.com https://bugzilla.redhat.com/show_bug.cgi?id=1955615
- bugzilla.redhat.com https://bugzilla.redhat.com/show_bug.cgi?id=1957458
- bugzilla.redhat.com https://bugzilla.redhat.com/show_bug.cgi?id=1962856
Show all 47 references
- bugzilla.redhat.com https://bugzilla.redhat.com/show_bug.cgi?id=1968074
- cve.mitre.org https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2019-18874
- cve.mitre.org https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2020-27619
- cve.mitre.org https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2020-28493
- cve.mitre.org https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-20095
- cve.mitre.org https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-23336
- cve.mitre.org https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-28957
- cve.mitre.org https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-29921
- cve.mitre.org https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-33503
- cve.mitre.org https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-3426
- cve.mitre.org https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-3572
- cve.mitre.org https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-42771
- docs.python.org https://docs.python.org/3/library/ipaddress.html
- errata.almalinux.org https://errata.almalinux.org/8/ALSA-2021-4162.html
- errata.rockylinux.org https://errata.rockylinux.org/RLSA-2021:4162
- github.com https://github.com/python/cpython/blob/63298930fb531ba2bb4f23bc3b915dbf1e17e9e1/Misc/NEWS.d/3.8.0a4.rst
- github.com https://github.com/python/cpython/pull/12577
- github.com https://github.com/python/cpython/pull/25099
- github.com https://github.com/sickcodes
- github.com https://github.com/sickcodes/security/blob/master/advisories/SICK-2021-014.md
- linux.oracle.com https://linux.oracle.com/cve/CVE-2021-29921.html
- linux.oracle.com https://linux.oracle.com/errata/ELSA-2021-4162.html
- lists.debian.org https://lists.debian.org/debian-lts-announce/2024/12/msg00000.html
- nvd.nist.gov https://nvd.nist.gov/vuln/detail/CVE-2021-29921
- python-security.readthedocs.io https://python-security.readthedocs.io/vuln/ipaddress-ipv4-leading-zeros.html
- security.gentoo.org https://security.gentoo.org/glsa/202305-02
- security.netapp.com https://security.netapp.com/advisory/ntap-20210622-0003/
- sick.codes https://sick.codes/sick-2021-014
- ubuntu.com https://ubuntu.com/security/notices/USN-4973-1
- ubuntu.com https://ubuntu.com/security/notices/USN-4973-2
- ubuntu.com https://ubuntu.com/security/notices/USN-6891-1
- www.cve.org https://www.cve.org/CVERecord?id=CVE-2021-29921
- www.oracle.com https://www.oracle.com//security-alerts/cpujul2021.html
- www.oracle.com https://www.oracle.com/security-alerts/cpuapr2022.html
- www.oracle.com https://www.oracle.com/security-alerts/cpujan2022.html
- www.oracle.com https://www.oracle.com/security-alerts/cpujul2022.html
- www.oracle.com https://www.oracle.com/security-alerts/cpuoct2021.html
OX Radar and Response Center
Find threats in your stack.
OX Radar can check high-priority threats, like critical package CVEs, against your context.
Each incident is marked Detected or Not Detected with a remediation plan and proof all tracked in the Response Center.