CWE
330 682 400
Advisory Published
Updated

CVE-2020-14422

First published: Thu Jun 18 2020(Updated: )

A vulnerability was found in Lib/ipaddress.py in Python through 3.8.3 improperly computes hash values in the IPv4Interface and IPv6Interface classes, which might allow a remote attacker to cause a denial of service if an application is affected by the performance of a dictionary containing IPv4Interface or IPv6Interface objects, and this attacker can cause many dictionary entries to be created. References: <a href="https://bugs.python.org/issue41004">https://bugs.python.org/issue41004</a> <a href="https://github.com/python/cpython/pull/20956">https://github.com/python/cpython/pull/20956</a>

Credit: cve@mitre.org cve@mitre.org

Affected SoftwareAffected VersionHow to fix
redhat/python3<0:3.6.8-18.el7
0:3.6.8-18.el7
redhat/python3<0:3.6.8-31.el8
0:3.6.8-31.el8
redhat/rh-python36-python<0:3.6.12-1.el6
0:3.6.12-1.el6
redhat/rh-python36-python-pip<0:9.0.1-5.el6
0:9.0.1-5.el6
redhat/rh-python36-python-virtualenv<0:15.1.0-3.el6
0:15.1.0-3.el6
redhat/rh-python36-python<0:3.6.12-1.el7
0:3.6.12-1.el7
redhat/rh-python36-python-pip<0:9.0.1-5.el7
0:9.0.1-5.el7
redhat/rh-python36-python-virtualenv<0:15.1.0-3.el7
0:15.1.0-3.el7
redhat/rh-python38-python<0:3.8.6-1.el7
0:3.8.6-1.el7
redhat/rh-python38-python-psutil<0:5.6.4-5.el7
0:5.6.4-5.el7
redhat/rh-python38-python-urllib3<0:1.25.7-6.el7
0:1.25.7-6.el7
Python Python>=3.0.0<3.5.10
Python Python>=3.6.0<3.6.12
Python Python>=3.7.0<3.7.9
Python Python>=3.8.0<3.8.4
openSUSE Leap=15.1
openSUSE Leap=15.2
Fedoraproject Fedora=31
Fedoraproject Fedora=32
Oracle Enterprise Manager Ops Center=12.4.0.0
ubuntu/python3.4<3.4.3-1ubuntu1~14.04.7+
3.4.3-1ubuntu1~14.04.7+
ubuntu/python3.8<3.8.2-1ubuntu1.2
3.8.2-1ubuntu1.2
ubuntu/python3.8<3.8.4-1
3.8.4-1
ubuntu/python3.5<3.5.2-2ubuntu0~16.04.11
3.5.2-2ubuntu0~16.04.11
ubuntu/python3.6<3.6.9-1~18.04ubuntu1.1
3.6.9-1~18.04ubuntu1.1
debian/python-ipaddress<=1.0.17-1<=1.0.23-1
1.0.17-1+deb10u1
debian/python2.7
2.7.16-2+deb10u1
2.7.16-2+deb10u4
2.7.18-8+deb11u1
debian/python3.7
3.7.3-2+deb10u3
3.7.3-2+deb10u7

Remedy

As a short term solution, if your application is using the IPv4Interface/IPv6Interface classes as keys of a dictionary, it is possible to patch the __hash__ method of those classes to not be constant. ``` IPv4Interface.__hash__ = lambda self: hash((self._ip, self._prefixlen, int(self.network.network_address))) IPv6Interface.__hash__ = lambda self: hash((self._ip, self._prefixlen, int(self.network.network_address))) ```

Never miss a vulnerability like this again

Sign up to SecAlerts for real-time vulnerability data matched to your software, aggregated from hundreds of sources.

Reference Links

Parent vulnerabilities

(Appears in the following advisories)

Frequently Asked Questions

  • What is the vulnerability ID for this issue?

    The vulnerability ID for this issue is CVE-2020-14422.

  • What is the severity of CVE-2020-14422?

    The severity of CVE-2020-14422 is medium with a CVSS score of 5.9.

  • Which versions of Python are affected by this vulnerability?

    Python versions up to and including 3.8.3 are affected by this vulnerability.

  • How does this vulnerability impact applications?

    This vulnerability could allow a remote attacker to cause a denial of service if an application is affected by the performance of a dictionary containing IPv4Interface or IPv6Interface objects.

  • Are there any references for this vulnerability?

    Yes, you can find more information about this vulnerability at the following references: [1], [2], [3].

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2024 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203