---
id: "GHSA-24c4-3p7v-29cm"
page: "https://infrastack.ai/live/GHSA-24c4-3p7v-29cm"
kind: "vulnerability"
aliases: ["GHSA-24c4-3p7v-29cm"]
title: "Base64 multipart parts bypass client_max_size"
severity: "medium"
cvss: null
epss: null
exploited: false
status: "open"
category: "package"
products: [{"name": "aiohttp", "fixed": ["3.14.4"], "affected": "<= 3.14.3", "ecosystem": "pypi"}]
ecosystems: ["pypi"]
tags: ["aiohttp", "cwe-400", "package", "python", "self-hosted"]
not_affected_if: ["fixed-version", "no-multipart-handlers"]
published_at: "2026-11-08T18:23:00+00:00"
first_seen_at: "2026-11-09T22:53:22+00:00"
updated_at: "2026-11-09T22:58:35+00:00"
sources: [{"source": "ghsa-repo", "url": "https://github.com/aio-libs/aiohttp/security/advisories/GHSA-24c4-3p7v-29cm", "first_seen_at": "2026-11-09T22:53:22+00:00"}]
exploit_sources: []
---

# Base64 multipart parts bypass client_max_size

Link for people: https://infrastack.ai/live/GHSA-24c4-3p7v-29cm (this .md is for agents)

aiohttp's multipart reader keeps reading base64-encoded parts without a byte limit until the chunk length is a multiple of four. A crafted multipart request can make the server load the whole remaining body into memory or block the event loop.

_Summary, check and fix written by a model from the sources; labelled as such._

## Affected

- pypi:aiohttp affected <= 3.14.3 fixed 3.14.4

## How to check

- Check the installed version with `pip show aiohttp` and see whether it is `3.14.3` or older.
- Look for handlers that call `multipart()` or read `BodyPartReader` data from request bodies.

## Fix

- `aiohttp` `3.14.4`

## Timeline

- 2026-11-09T22:53:22+00:00 ghsa-repo https://github.com/aio-libs/aiohttp/security/advisories/GHSA-24c4-3p7v-29cm

## Documents

- [advisory] Maintainer's advisory: github.com https://github.com/aio-libs/aiohttp/security/advisories/GHSA-24c4-3p7v-29cm

## From the sources

### Summary

When reading a multipart part with `Content-Transfer-Encoding: base64`, `BodyPartReader.read_chunk()` kept reading until the chunk length was a multiple of 4, with no byte limit. A part with a short `Content-Length`, or a long run of whitespace, could cause the entire remaining body to be read into memory within a single call before any size check, or spin on the event loop.

### Impact

An attacker could bypass `client_max_size` to cause excessive memory use, or block the event loop, with a specially crafted multipart request to any handler that reads multipart data.

---

Patch: https://github.com/aio-libs/aiohttp/commit/a555ab698e08e9baea7386d5b4c0761cb8956fdd

---

_Free to read, with fair use of about 60 pages a minute. For higher limits or API access: sales@infrastack.ai_
