CVE-2025-50181: urllib3 redirects are not disabled when retries are disabled on PoolManager instantiation
(updated )
urllib3 handles redirects and retries using the same mechanism, which is controlled by the Retry
object. The most common way to disable redirects is at the request level, as follows:
resp = urllib3.request("GET", "https://httpbin.org/redirect/1", redirect=False)
print(resp.status)
References
Code Behaviors & Features
Detect and mitigate CVE-2025-50181 with GitLab Dependency Scanning
Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →