# CVE-2023-37276: aiohttp vulnerable to HTTP request smuggling

> Attackers can smuggle HTTP requests in aiohttp servers, potentially bypassing security controls or accessing unauthorized data.

- **Severity:** Medium 5.3 (`CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/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:** 19 Jul 2023
- **Updated:** 18 Oct 2024
- **Also known as:** CLSA-2025-1754007187, DEBIAN-CVE-2023-37276, GHSA-45c4-8wx5-qw6w, PYSEC-2023-120, UBUNTU-CVE-2023-37276

## What is CVE-2023-37276?

CVE-2023-37276 is a medium-severity vulnerability in aio-libs aiohttp, published on 19 Jul 2023. An attacker can exploit it over the internet without logging in, with no action from the victim.

### Official description

aiohttp is an asynchronous HTTP client/server framework for asyncio and Python. aiohttp v3.8.4 and earlier are bundled with llhttp v6.0.6. Vulnerable code is used by aiohttp for its HTTP request parser when available which is the default case when installing from a wheel. This vulnerability only affects users of aiohttp as an HTTP server (ie `aiohttp.Application`), you are not affected by this vulnerability if you are using aiohttp as an HTTP client library (ie `aiohttp.ClientSession`). Sending a crafted HTTP request will cause the server to misinterpret one of the HTTP header values leading to HTTP request smuggling. This issue has been addressed in version 3.8.5. Users are advised to upgrade. Users unable to upgrade can reinstall aiohttp using `AIOHTTP_NO_EXTENSIONS=1` as an environment variable to disable the llhttp HTTP request parser implementation. The pure Python implementation isn't vulnerable.

Weakness: CWE-444 (Inconsistent Interpretation of HTTP Requests)

## Which versions are affected by CVE-2023-37276?

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


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `aiohttp` | PyPI | All versions | 3.8.5 |
| `aiohttp` | PyPI | All versions | 3.8.5 |
| `aiohttp` | PyPI | All versions | 3.8.5 |

Products: Aiohttp Aiohttp.

## How do I fix CVE-2023-37276?

Upgrade aiohttp to 3.8.5 or later.

## Is CVE-2023-37276 being exploited?

It is not confirmed as exploited in the wild, but public exploit code for CVE-2023-37276 exists.

## Other vulnerabilities in aio-libs aiohttp

- [CVE-2024-52303](https://insights.sbomify.com/CVE-2024-52303/): aiohttp memory leak when middleware is enabled when requesting a resource with a non-allowed method (high 8.7)
- [CVE-2025-69223](https://insights.sbomify.com/CVE-2025-69223/): AIOHTTP's HTTP Parser auto_decompress feature is vulnerable to zip bomb (high 7.5)
- [CVE-2024-30251](https://insights.sbomify.com/CVE-2024-30251/): Denial of service when trying to parse malformed POST requests in aiohttp (high 7.5)
- [CVE-2023-49081](https://insights.sbomify.com/CVE-2023-49081/): aiohttp's ClientSession is vulnerable to CRLF injection via version (high 7.2)
- [CVE-2026-22815](https://insights.sbomify.com/CVE-2026-22815/): AIOHTTP: Uncapped memory usage possible through aiohttp allowing unlimited trailer headers (medium 6.9)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2023-37276 and fix it if it is affected.

What it is: CVE-2023-37276 is a medium-severity vulnerability in aio-libs aiohttp, published on 19 Jul 2023. An attacker can exploit it over the internet without logging in, with no action from the victim.
Exploitation: It is not confirmed as exploited in the wild, but public exploit code for CVE-2023-37276 exists.

Affected packages and fixed versions:
- aiohttp (PyPI): affected all versions; fixed in 3.8.5
- aiohttp (PyPI): affected all versions; fixed in 3.8.5
- aiohttp (PyPI): affected all versions; fixed in 3.8.5

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

## Sources

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

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