# CVE-2020-26137: CRLF injection in urllib3

> Attackers can inject CRLF characters into HTTP requests via the request method, potentially leading to request smuggling or header injection.

- **Severity:** Medium 6.5 (`CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:N`)
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Over the internet
- **Victim action needed:** Not needed
- **Fix available:** Yes
- **Published:** 29 Sep 2020
- **Updated:** 4 Aug 2024
- **Also known as:** ALPINE-CVE-2020-26137, ALSA-2021:1631, CLEANSTART-2026-RX33339, CLEANSTART-2026-YH76690, DEBIAN-CVE-2020-26137, GHSA-wqvq-5m8c-6g24, MGASA-2021-0055, MINI-r4gq-q2g4-hj63, PYSEC-2020-148, RHSA-2021:1631, RLSA-2021:1631, ROOT-APP-PYPI-CVE-2020-26137, SUSE-SU-2020:3723-1, SUSE-SU-2021:2817-1, SUSE-SU-2021:3251-1, UBUNTU-CVE-2020-26137, USN-4570-1, openSUSE-SU-2020:2237-1, openSUSE-SU-2020:2282-1, openSUSE-SU-2021:1206-1, openSUSE-SU-2021:2817-1, openSUSE-SU-2024:13212-1, openSUSE-SU-2024:13213-1

## What is CVE-2020-26137?

CVE-2020-26137 is a medium-severity vulnerability in Canonical Ubuntu Linux, published on 29 Sep 2020. An attacker can exploit it over the internet without logging in, with no action from the victim.

### Official description

urllib3 before 1.25.9 allows CRLF injection if the attacker controls the HTTP request method, as demonstrated by inserting CR and LF control characters in the first argument of putrequest(). NOTE: this is similar to CVE-2020-26116.

Weakness: CWE-74 (Improper Neutralization of Special Elements in Output Used by a Downstream Component)

## Which versions are affected by CVE-2020-26137?

3 open source packages ship an affected version, including urllib3. It affects 5 products.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `urllib3` | PyPI | All versions | 1.25.9 |
| `urllib3` | PyPI | All versions | 1.25.9 |
| `urllib3` | PyPI | All versions | 1.25.9 |
| `python3-urllib3` | AlmaLinux:8 | All versions | 1.24.2-5.el8 |
| `python-urllib3` | Red Hat:enterprise_linux:8::baseos | All versions | 0:1.24.2-5.el8 |
| `python3-urllib3` | Red Hat:enterprise_linux:8::baseos | All versions | 0:1.24.2-5.el8 |
| `python-urllib3` | Rocky Linux:8 | All versions | 0:1.24.2-5.el8 |
| `python-asn1crypto` | SUSE:Enterprise Storage 6 | All versions | 0.24.0-3.2.1 |
| `python-boto3` | SUSE:Enterprise Storage 6 | All versions | 1.17.9-19.1 |
| `python-botocore` | SUSE:Enterprise Storage 6 | All versions | 1.20.9-33.1 |
| `python-pyasn1` | SUSE:Enterprise Storage 6 | All versions | 0.4.2-3.2.1 |
| `python-pycparser` | SUSE:Enterprise Storage 6 | All versions | 2.17-3.2.1 |
| `python-urllib3` | SUSE:Enterprise Storage 6 | All versions | 1.25.10-9.14.1 |
| `python-urllib3` | SUSE:HPE Helion OpenStack 8 | All versions | 1.25.10-3.31.2 |
| `python-asn1crypto` | SUSE:Linux Enterprise High Performance Computing 15 SP1-ESPOS | All versions | 0.24.0-3.2.1 |
| `python-boto3` | SUSE:Linux Enterprise High Performance Computing 15 SP1-ESPOS | All versions | 1.17.9-19.1 |
| `python-botocore` | SUSE:Linux Enterprise High Performance Computing 15 SP1-ESPOS | All versions | 1.20.9-33.1 |
| `python-pyasn1` | SUSE:Linux Enterprise High Performance Computing 15 SP1-ESPOS | All versions | 0.4.2-3.2.1 |
| `python-pycparser` | SUSE:Linux Enterprise High Performance Computing 15 SP1-ESPOS | All versions | 2.17-3.2.1 |
| `python-urllib3` | SUSE:Linux Enterprise High Performance Computing 15 SP1-ESPOS | All versions | 1.25.10-9.14.1 |
| `python-asn1crypto` | SUSE:Linux Enterprise High Performance Computing 15 SP1-LTSS | All versions | 0.24.0-3.2.1 |
| `python-boto3` | SUSE:Linux Enterprise High Performance Computing 15 SP1-LTSS | All versions | 1.17.9-19.1 |
| `python-botocore` | SUSE:Linux Enterprise High Performance Computing 15 SP1-LTSS | All versions | 1.20.9-33.1 |
| `python-pyasn1` | SUSE:Linux Enterprise High Performance Computing 15 SP1-LTSS | All versions | 0.4.2-3.2.1 |
| `python-pycparser` | SUSE:Linux Enterprise High Performance Computing 15 SP1-LTSS | All versions | 2.17-3.2.1 |
| `python-urllib3` | SUSE:Linux Enterprise High Performance Computing 15 SP1-LTSS | All versions | 1.25.10-9.14.1 |
| `python-asn1crypto` | SUSE:Linux Enterprise Micro 5.0 | All versions | 0.24.0-3.2.1 |
| `python-cffi` | SUSE:Linux Enterprise Micro 5.0 | All versions | 1.13.2-3.2.5 |
| `python-cryptography` | SUSE:Linux Enterprise Micro 5.0 | All versions | 2.8-10.1 |
| `python-pyOpenSSL` | SUSE:Linux Enterprise Micro 5.0 | All versions | 17.5.0-8.3.1 |
| `python-pyasn1` | SUSE:Linux Enterprise Micro 5.0 | All versions | 0.4.2-3.2.1 |
| `python-pycparser` | SUSE:Linux Enterprise Micro 5.0 | All versions | 2.17-3.2.1 |
| `python-urllib3` | SUSE:Linux Enterprise Micro 5.0 | All versions | 1.25.10-9.14.1 |
| `python-urllib3` | SUSE:Linux Enterprise Module for Basesystem 15 SP1 | All versions | 1.24-9.10.1 |
| `python-asn1crypto` | SUSE:Linux Enterprise Module for Basesystem 15 SP2 | All versions | 0.24.0-3.2.1 |
| `python-boto3` | SUSE:Linux Enterprise Module for Basesystem 15 SP2 | All versions | 1.17.9-19.1 |
| `python-botocore` | SUSE:Linux Enterprise Module for Basesystem 15 SP2 | All versions | 1.20.9-33.1 |
| `python-cffi` | SUSE:Linux Enterprise Module for Basesystem 15 SP2 | All versions | 1.13.2-3.2.5 |
| `python-cryptography` | SUSE:Linux Enterprise Module for Basesystem 15 SP2 | All versions | 2.8-10.1 |
| `python-pyOpenSSL` | SUSE:Linux Enterprise Module for Basesystem 15 SP2 | All versions | 17.5.0-8.3.1 |

Products: Canonical Ubuntu Linux, Debian Debian Linux, Oracle Communications Cloud Native Core Network Function Cloud Native Environment, Oracle Zfs Storage Appliance Kit, Python Urllib3.

## How do I fix CVE-2020-26137?

Upgrade urllib3 to 1.25.9 or later.

## Is CVE-2020-26137 being exploited?

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

## Other vulnerabilities in Canonical Ubuntu Linux

- [CVE-2020-11651](https://insights.sbomify.com/CVE-2020-11651/): SaltStack Salt Authentication Bypass (critical 9.8, exploited in the wild)
- [CVE-2020-7247](https://insights.sbomify.com/CVE-2020-7247/): OpenSMTPD Remote Code Execution (critical 9.8, exploited in the wild)
- [CVE-2019-16928](https://insights.sbomify.com/CVE-2019-16928/): Exim Out-of-bounds Write (critical 9.8, exploited in the wild)
- [CVE-2018-6789](https://insights.sbomify.com/CVE-2018-6789/): Exim Buffer Overflow (critical 9.8, exploited in the wild)
- [CVE-2015-2590](https://insights.sbomify.com/CVE-2015-2590/): Oracle Java SE and Java SE Embedded Remote Code Execution (critical 9.8, exploited in the wild)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2020-26137 and fix it if it is affected.

What it is: CVE-2020-26137 is a medium-severity vulnerability in Canonical Ubuntu Linux, published on 29 Sep 2020. An attacker can exploit it over the internet without logging in, with no action from the victim.
Exploitation: There is no known exploitation of CVE-2020-26137 in the wild and no public exploit code.

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

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-2020-26137/ (Markdown: https://insights.sbomify.com/CVE-2020-26137/index.md)
```

## Sources

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

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