CVE-2024-52303
NoneCVSS
—
EPSS
0.6%
Published
Nov 18, 2024
CISA due date
—
Cloudanix analysis
A flaw in a popular Python web library lets attackers slowly drain a server's memory by sending many specially crafted requests, eventually knocking the service offline.
- Exploitation
- Remote Unauthenticated
- Attacker needs
- None
- Complexity
- Trivial
- Impact
- Denial Of Service
- Component
- Library
- Class
- Denial of service
- Remediation
- Upgrade
- Effort
- Medium
- Patch risk
- Low
What it actually does
Memory leak triggered when requests produce MatchInfoError, because each error builds a unique cache entry that is never reused or cleared.
Why it matters to the business
Attackers can exhaust server memory with hundreds of thousands to millions of crafted requests, causing service outages or requiring restarts; the issue affects any deployment using middlewares with aiohttp.web.
How an attack unfolds
An attacker repeatedly sends requests designed to trigger MatchInfoError responses; each request adds a distinct entry to the internal cache, gradually consuming available memory until the server becomes unresponsive.
How to fix it
Upgrade aiohttp to version 3.10.11 or later; organizations using flashplugin-nonfree on Ubuntu 14.04 LTS should apply the listed fixed package version 11.2.202.554ubuntu0.14.04.1.
How to confirm the fix worked
Confirm aiohttp version is at least 3.10.11; run load tests that deliberately trigger MatchInfoError and verify memory usage remains stable instead of growing without bound.
Typical attack path
- Identify an aiohttp.web endpoint protected by middleware
- Craft requests that consistently produce MatchInfoError
- Send a high volume of such requests (hundreds of thousands to millions)
- Monitor memory consumption until the process is exhausted or crashes
How to detect it
Review application and access logs for unusually high volumes of requests that result in 404 or similar error responses; correlate with memory-growth metrics on aiohttp worker processes.
What your security team should do
- Prioritize upgrade of all aiohttp installations to 3.10.11 within the next maintenance window
- Add memory-usage monitoring and alerting for aiohttp processes
- Review middleware configurations to reduce unnecessary MatchInfoError paths where possible
The record
aiohttp is an asynchronous HTTP client/server framework for asyncio and Python. In versions starting with 3.10.6 and prior to 3.10.11, a memory leak can occur when a request produces a MatchInfoError. This was caused by adding an entry to a cache on each request, due to the building of each MatchInfoError producing a unique cache entry. An attacker may be able to exhaust the memory resources of a server by sending a substantial number (100,000s to millions) of such requests. Those who use any middlewares with aiohttp.web should upgrade to version 3.10.11 to receive a patch.
Affected packages
| Ecosystem | Package | Introduced | Fixed |
|---|---|---|---|
| PyPI | aiohttp | 3.10.6 | 3.10.11 |
| Chainguard | airflow | 0 | 2.10.3-r2 |
| Chainguard | airflow-bitnami-compat | 0 | 2.10.3-r2 |
| Chainguard | airflow-compat | 0 | 2.10.3-r2 |
| Chainguard | checkov | 0 | 3.2.432-r0 |
| Chainguard | py3-aiohttp | 0 | 3.10.11-r0 |
| Chainguard | py3-supported-aiohttp | 0 | 3.10.11-r0 |
| Chainguard | py3.10-aiohttp | 0 | 3.10.11-r0 |
| Chainguard | py3.10-vllm-cuda-11.8 | 0 | 0.6.5-r0 |
| Chainguard | py3.10-wheels-vllm-cuda-11.8 | 0 | 0.6.5-r0 |
| Chainguard | py3.11-aiohttp | 0 | 3.10.11-r0 |
| Chainguard | py3.12-aiohttp | 0 | 3.10.11-r0 |
| Chainguard | py3.13-aiohttp | 0 | 3.10.11-r0 |
| Debian:13 | python-aiohttp | 0 | No fix |
| Debian:14 | python-aiohttp | 0 | 3.10.11-1 |
| Ubuntu:20.04:LTS | python-aiohttp | 0 | No fix |
| Ubuntu:22.04:LTS | python-aiohttp | 0 | No fix |
| Ubuntu:24.04:LTS | python-aiohttp | 0 | No fix |
| Ubuntu:24.10 | python-aiohttp | 0 | No fix |
| Ubuntu:25.04 | python-aiohttp | 0 | 3.10.11-1build1 |
| Ubuntu:Pro:16.04:LTS | python-aiohttp | 0 | No fix |
| Ubuntu:Pro:18.04:LTS | python-aiohttp | 0 | No fix |
| Ubuntu:Pro:20.04:LTS | python-aiohttp | 0 | No fix |
| Wolfi | airflow | 0 | 2.10.3-r2 |
| Wolfi | airflow-bitnami-compat | 0 | 2.10.3-r2 |
| Wolfi | airflow-compat | 0 | 2.10.3-r2 |
| Wolfi | checkov | 0 | 3.2.432-r0 |
| Wolfi | py3-aiohttp | 0 | 3.10.11-r0 |
| Wolfi | py3-supported-aiohttp | 0 | 3.10.11-r0 |
| Wolfi | py3.10-aiohttp | 0 | 3.10.11-r0 |
| Wolfi | py3.11-aiohttp | 0 | 3.10.11-r0 |
| Wolfi | py3.12-aiohttp | 0 | 3.10.11-r0 |
| Wolfi | py3.13-aiohttp | 0 | 3.10.11-r0 |
| openSUSE:Tumbleweed | python-aiohttp | 0 | 3.11.9-1.1 |
| pypi | aiohttp | 3.10.6 | No fix |
Related vulnerabilities
- CVE-2025-69229 AIOHTTP is an asynchronous HTTP client/server framework for asyncio and Python. Also affects aiohttp
- CVE-2025-69223 AIOHTTP's HTTP Parser auto_decompress feature is vulnerable to zip bomb Also affects aiohttp
- CVE-2025-69224 AIOHTTP's unicode processing of header values could cause parsing discrepancies Also affects aiohttp
- CVE-2025-69226 AIOHTTP vulnerable to brute-force leak of internal static file path components Also affects aiohttp
- CVE-2025-69225 AIOHTTP has unicode match groups in regexes for ASCII protocol elements Also affects aiohttp
- CVE-2025-69228 AIOHTTP vulnerable to denial of service through large payloads Also affects aiohttp
- CVE-2025-69230 AIOHTTP Vulnerable to Cookie Parser Warning Storm Also affects aiohttp
- CVE-2025-69227 AIOHTTP vulnerable to DoS when bypassing asserts Also affects aiohttp