Bug 1995162 (CVE-2021-3737) - CVE-2021-3737 python: urllib: HTTP client possible infinite loop on a 100 Continue response
Summary: CVE-2021-3737 python: urllib: HTTP client possible infinite loop on a 100 Con...
Keywords:
Status: CLOSED ERRATA
Alias: CVE-2021-3737
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
low
low
Target Milestone: ---
Assignee: Red Hat Product Security
QA Contact:
URL:
Whiteboard:
Depends On: 1997669 1997670 1997671 1997672 1997673 1997674 1997675 1997676 1997677 1997679 1997680 1997681 1997682 1997683 1997684 1997685 1997686 1997687 1997688 1997689 1997690 1997691 2064450 2189263
Blocks: 1995165 2003969
TreeView+ depends on / blocked
 
Reported: 2021-08-18 14:50 UTC by Pedro Sampaio
Modified: 2023-04-24 15:08 UTC (History)
27 users (show)

Fixed In Version: python 3.6.14, python 3.7.11, python 3.8.11, python 3.9.6
Doc Type: If docs needed, set a value
Doc Text:
A flaw was found in python. An improperly handled HTTP response in the HTTP client code of python may allow a remote attacker, who controls the HTTP server, to make the client script enter an infinite loop, consuming CPU time. The highest threat from this vulnerability is to system availability.
Clone Of:
Environment:
Last Closed: 2022-05-11 09:45:29 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2021:4160 0 None None None 2021-11-09 17:27:24 UTC
Red Hat Product Errata RHSA-2022:1663 0 None None None 2022-05-02 08:05:09 UTC
Red Hat Product Errata RHSA-2022:1764 0 None None None 2022-05-10 13:18:26 UTC
Red Hat Product Errata RHSA-2022:1821 0 None None None 2022-05-10 13:39:26 UTC
Red Hat Product Errata RHSA-2022:1986 0 None None None 2022-05-10 14:44:04 UTC

Description Pedro Sampaio 2021-08-18 14:50:00 UTC
HTTP client can get stuck infinitely reading len(line) < 64k lines after receiving a '100 Continue' HTTP response. This could lead to the client being a bandwidth sink for anyone in control of a server.

References:

https://bugs.python.org/issue44022
https://github.com/python/cpython/pull/25916
https://github.com/python/cpython/pull/26503
https://build.opensuse.org/package/view_file/devel:languages:python:Factory/python/bpo44022-fix-http-client-infinite-line-reading-after-a-HTTP-100-Continue.patch?expand=1
https://bugzilla.redhat.com/show_bug.cgi?id=1991918

Comment 1 Riccardo Schirone 2021-08-25 15:44:39 UTC
Setting CVSS score to 6.5/CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H .

User Interaction (UI) set to Required (R) because the flaw is in the HTTP client code, thus the attack scenario that was considered is that of a user running a python script/tool to erroneously connect to a malicious HTTP server. Libraries or tools that do not require user interaction are assumed to connect to trusted servers which would need to be compromised by an attacker first in order to trigger this vulnerability. In this last case, you'd have UI=N, but AC=H giving a CVSSv3.1 score of 5.9 that is lower than the current 6.5. For this reason we chose to evaluate the worst-case reasonable scenario.


Given the flaw is in the client side and it requires automatically connecting to a compromised but trusted server or manually connecting to a malicious server, the Impact of this flaw has been set to Low. It requires indeed unlikely circumstances to be able to be exploited and when it is it is enough to stop the client or restart it.

Comment 3 Riccardo Schirone 2021-08-25 15:59:28 UTC
Created mingw-python3 tracking bugs for this issue:

Affects: fedora-all [bug 1997670]


Created python2.7 tracking bugs for this issue:

Affects: fedora-all [bug 1997671]


Created python3.10 tracking bugs for this issue:

Affects: fedora-all [bug 1997672]


Created python3.5 tracking bugs for this issue:

Affects: fedora-all [bug 1997673]


Created python3.6 tracking bugs for this issue:

Affects: fedora-all [bug 1997674]


Created python3.7 tracking bugs for this issue:

Affects: fedora-all [bug 1997675]


Created python3.8 tracking bugs for this issue:

Affects: fedora-all [bug 1997676]


Created python3.9 tracking bugs for this issue:

Affects: fedora-all [bug 1997677]


Created python34 tracking bugs for this issue:

Affects: epel-all [bug 1997669]

Comment 6 errata-xmlrpc 2021-11-09 17:27:22 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8

Via RHSA-2021:4160 https://access.redhat.com/errata/RHSA-2021:4160

Comment 7 errata-xmlrpc 2022-05-02 08:05:06 UTC
This issue has been addressed in the following products:

  Red Hat Software Collections for Red Hat Enterprise Linux 7

Via RHSA-2022:1663 https://access.redhat.com/errata/RHSA-2022:1663

Comment 8 errata-xmlrpc 2022-05-10 13:18:23 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8

Via RHSA-2022:1764 https://access.redhat.com/errata/RHSA-2022:1764

Comment 9 errata-xmlrpc 2022-05-10 13:39:22 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8

Via RHSA-2022:1821 https://access.redhat.com/errata/RHSA-2022:1821

Comment 10 errata-xmlrpc 2022-05-10 14:44:01 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8

Via RHSA-2022:1986 https://access.redhat.com/errata/RHSA-2022:1986

Comment 11 Product Security DevOps Team 2022-05-11 09:45:27 UTC
This bug is now closed. Further updates for individual products will be reflected on the CVE page(s):

https://access.redhat.com/security/cve/cve-2021-3737


Note You need to log in before you can comment on or make changes to this bug.