Live threats

All CVEs / encode

CVE-2025-54121encode starlette

Medium 5.3 No auth needed

Priority
47
CVSS 3.1
5.3
EPSS
—
Auth required
No
Published
Jul 21, 2025
Updated
Jun 17, 2026
Category
Application · Cross-platform
Weakness (CWE)
CWE-770
SSVC (CISA)
Exploitation: proof of concept · Automatable: no · Technical impact: partial
Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L

What happens

Starlette is a lightweight ASGI (Asynchronous Server Gateway Interface) framework/toolkit, designed for building async web services in Python. In versions 0.47.1 and below, when parsing a multi-part form with large files (greater than the default max spool size) starlette will block the main thread to roll the file over to disk. This blocks the event thread which means the application can't accept new connections. The UploadFile code has a minor bug where instead of just checking for self._in_memory, the logic should also check if the additional bytes will cause a rollover. The vulnerability is fixed in version 0.47.2.

Original NVD text.

What to do

  1. Apply the vendor's security update for starlette.
  2. It can be exploited without authentication: if you cannot patch now, restrict Internet access to the affected service.

Affected packages

EcosystemPackageAffected versionsFixed inHow to upgrade
PyPI starlette < 0.47.2 0.47.2 pip install "starlette>=0.47.2"
PyPI starlette < 0.47.2 0.47.2 pip install "starlette>=0.47.2"

Per OSV / GitHub Advisories (GHSA-2c2j-9gv5-cj73, PYSEC-2026-1941). Check the version in your lockfile before upgrading.

Affected products

As reported by the CNA that published the CVE. NVD has not added CPEs with versions yet.

Official advisories

Vendor, CERT and distribution advisories that name this CVE. Original titles.

Official sources

References

Links published by the sources. Open them with care.