CVE-2023-32681: Unintended leak of Proxy-Authorization header in python-requests
Summary
CVE-2023-32681: Requests is a HTTP library. Affects requests across 2 version ranges.
< 74ea7cf7a6a27a4eeb2ae24e162bcc942a6706d5
< 147c8511ddbfa5e8f71bbf5c18ede0c4ceb3bba4
No fix is published. How to fix ↓
Check if this vulnerability affects your application
Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.
No signup required · Results in about 60 seconds
Background
Python-requests is a popular HTTP library used for making HTTP requests in Python. It provides a simple and intuitive interface for sending HTTP requests and handling responses. The vulnerability identified as CVE-2023-32681 affects version 2.11.1 of the requests package. This vulnerability allows for the unintended leak of the Proxy-Authorization header when redirected to an HTTPS endpoint. The Proxy-Authorization header contains sensitive information such as proxy credentials, which can be exploited by a malicious actor to potentially exfiltrate data. The vulnerability has been assigned a CVSS score of 6.1, indicating a medium severity level.
Vulnerability Detail
The vulnerability arises from the way requests library handles the Proxy-Authorization header when redirecting requests to an HTTPS endpoint. When using HTTP connections sent through a tunnel, the proxy identifies the header in the request and removes it before forwarding it to the destination server. However, when the request is sent over HTTPS, the Proxy-Authorization header must be included in the CONNECT request, as the proxy has no visibility into the tunneled request. This results in the requests library unintentionally forwarding the proxy credentials to the destination server, potentially exposing sensitive information. The vulnerability has been fixed in version 2.31.0 of the requests library.
How To Fix
No fixed version is published for this vulnerability.
Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →
Workaround
There is no known workaround for this vulnerability. It is essential to update to the fixed version of the requests library to mitigate the risk of exploitation.
Conclusion
The vulnerability CVE-2023-32681 in the python-requests package allows for the unintended leak of the Proxy-Authorization header, potentially exposing sensitive information. It is crucial to update to version 2.31.0 or later of the requests library to mitigate the risk of exploitation. For further support on vulnerability remediation, please contact DevNack.com.
See every vulnerability recorded for requests →
FAQ
The vulnerability allows for the unintended leak of sensitive information, such as proxy credentials, to a destination server. This can potentially be exploited by a malicious actor to exfiltrate data or gain unauthorized access.
At the time of this report, there is no known public exploit for this vulnerability. However, it is crucial to update to the fixed version to prevent any potential exploitation.
No, only version 2.11.1 of the requests library is affected by this vulnerability. It has been fixed in version 2.31.0.
Yes, this vulnerability can be exploited remotely. An attacker can send a specially crafted request to a vulnerable server and potentially obtain sensitive information.
Unfortunately, there is no known mitigation if upgrading to the fixed version is not possible. It is highly recommended to update to the latest version to address the vulnerability.
Related vulnerabilities
Recent vulnerabilities recorded for requests.