# CVE-2025-50181: urllib3 redirects are not disabled when retries are disabled on PoolManager instantiation

> Attackers can bypass SSRF mitigations in urllib3 when redirects are disabled via specific PoolManager retry configurations, affecting applications relying on this setting.

- **Severity:** Medium 5.3 (`CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:N/A:N`)
- **Exploited in the wild:** Not known
- **Login needed:** Any signed-in user
- **Attackable:** Over the internet
- **Victim action needed:** Not needed
- **Fix available:** Yes
- **Published:** 19 Jun 2025
- **Updated:** 22 Dec 2025
- **Also known as:** AZL-64170, AZL-64175, AZL-64218, AZL-64244, AZL-77823, BELL-CVE-2025-50181, CLEANSTART-2026-JF27043, CLSA-2025-1759795964, CLSA-2025-1767053571, DEBIAN-CVE-2025-50181, ECHO-25d6-11bf-b17d, GHSA-pq67-6m6q-mj2v, MGASA-2025-0281, MINI-3276-6vv2-rjfq, MINI-3pxj-fv3g-fcmw, MINI-4wqw-jxcf-vhwx, MINI-5jg9-rf79-w63f, MINI-g8cr-599c-g56j, MINI-hjhw-6xjc-pw7h, MINI-phw3-8mw6-vxx4, MINI-r69p-mxw9-m967, MINI-r6wh-mfm7-qp25, MINI-v6fx-x95x-xqm5, OESA-2025-1958, OESA-2025-2317, PYSEC-2026-1999, ROOT-APP-PYPI-CVE-2025-50181, SUSE-SU-2025:02735-1, SUSE-SU-2025:02736-1, SUSE-SU-2025:02985-1, SUSE-SU-2025:20558-1, SUSE-SU-2025:20856-1, UBUNTU-CVE-2025-50181, USN-7599-2, openSUSE-SU-2025:15284-1

## What is CVE-2025-50181?

CVE-2025-50181 is a medium-severity server-side request forgery vulnerability in urllib3, published on 19 Jun 2025. Any signed-in user can exploit it over the network, with no action from the victim.

### Official description

urllib3 is a user-friendly HTTP client library for Python. Prior to 2.5.0, it is possible to disable redirects for all requests by instantiating a PoolManager and specifying retries in a way that disable redirects. By default, requests and botocore users are not affected. An application attempting to mitigate SSRF or open redirect vulnerabilities by disabling redirects at the PoolManager level will remain vulnerable. This issue has been patched in version 2.5.0.

Weakness: CWE-601 (URL Redirection to Untrusted Site)

## Which versions are affected by CVE-2025-50181?

3 open source packages ship an affected version, including urllib3. It affects 1 product.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `urllib3` | PyPI | All versions | 2.5.0 |
| `urllib3` | PyPI | All versions | 2.5.0 |
| `urllib3` | PyPI | All versions | 2.5.0 |
| `python-urllib3` | SUSE:Linux Enterprise Micro 5.1 | All versions | 1.25.10-150300.4.18.1 |
| `python-urllib3` | SUSE:Linux Enterprise Micro 5.2 | All versions | 1.25.10-150300.4.18.1 |
| `python-urllib3` | SUSE:Linux Enterprise Micro 5.3 | All versions | 1.25.10-150300.4.18.1 |
| `python-urllib3` | SUSE:Linux Enterprise Micro 5.4 | All versions | 1.25.10-150300.4.18.1 |
| `python-urllib3` | SUSE:Linux Enterprise Micro 5.5 | All versions | 1.25.10-150300.4.18.1 |
| `python-urllib3` | SUSE:Linux Enterprise Module for Basesystem 15 SP6 | All versions | 1.25.10-150300.4.18.1 |
| `python-urllib3` | SUSE:Linux Enterprise Module for Basesystem 15 SP7 | All versions | 1.25.10-150300.4.18.1 |
| `python-urllib3` | SUSE:Linux Enterprise Module for Public Cloud 12 | All versions | 1.25.10-3.43.1 |
| `python-urllib3` | SUSE:Linux Enterprise Module for Public Cloud 15 SP4 | All versions | 2.0.7-150400.7.21.1 |
| `python-urllib3` | SUSE:Linux Enterprise Module for Python 3 15 SP6 | All versions | 2.0.7-150400.7.21.1 |
| `python-urllib3` | SUSE:Linux Enterprise Module for Python 3 15 SP7 | All versions | 2.0.7-150400.7.21.1 |
| `python-urllib3` | SUSE:Linux Enterprise Server LTSS Extended Security 12 SP5 | All versions | 1.25.10-3.43.1 |
| `python-urllib3` | SUSE:Linux Micro 6.0 | All versions | 2.1.0-3.1 |
| `python-urllib3` | SUSE:Linux Micro 6.1 | All versions | 2.1.0-slfo.1.1_2.1 |
| `python-urllib3` | openSUSE:Leap 15.6 | All versions | 2.0.7-150400.7.21.1 |
| `python-urllib3_1` | openSUSE:Tumbleweed | All versions | 1.26.20-3.1 |

Products: Python Urllib3.

## How do I fix CVE-2025-50181?

Upgrade urllib3 to 2.5.0 or later.

## Is CVE-2025-50181 being exploited?

There is no known exploitation of CVE-2025-50181 in the wild and no public exploit code.

## Other vulnerabilities in urllib3

- [CVE-2026-97689](https://insights.sbomify.com/CVE-2026-97689/): urllib3: HTTPResponse.stream()/read_chunked() buffers an unbounded chunk-size line into memory (high 8.9)
- [CVE-2026-44432](https://insights.sbomify.com/CVE-2026-44432/): urllib3: Decompression-bomb safeguards bypassed in parts of the streaming API (high 8.9)
- [CVE-2026-21441](https://insights.sbomify.com/CVE-2026-21441/): urllib3 vulnerable to decompression-bomb safeguard bypass when following HTTP redirects (streaming API) (high 8.9)
- [CVE-2025-66418](https://insights.sbomify.com/CVE-2025-66418/): urllib3 allows an unbounded number of links in the decompression chain (high 8.9)
- [CVE-2025-66471](https://insights.sbomify.com/CVE-2025-66471/): urllib3 Streaming API improperly handles highly compressed data (high 8.9)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2025-50181 and fix it if it is affected.

What it is: CVE-2025-50181 is a medium-severity server-side request forgery vulnerability in urllib3, published on 19 Jun 2025. Any signed-in user can exploit it over the network, with no action from the victim.
Exploitation: There is no known exploitation of CVE-2025-50181 in the wild and no public exploit code.

Affected packages and fixed versions:
- urllib3 (PyPI): affected all versions; fixed in 2.5.0
- urllib3 (PyPI): affected all versions; fixed in 2.5.0
- urllib3 (PyPI): affected all versions; fixed in 2.5.0

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/CVE-2025-50181/ (Markdown: https://insights.sbomify.com/CVE-2025-50181/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2025-50181
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2025-50181
- OSV: https://osv.dev/vulnerability/CVE-2025-50181

---
From sbomify Insights: https://insights.sbomify.com/CVE-2025-50181/
Summaries are generated and may contain mistakes; the official description above is the record.
