CVE-2025-62727: PYSEC-2026-1942 - Starlette vulnerable to O(n^2) DoS via Range header merging in ``starlette.responses.FileResponse``

CVE-2025-62727 · Severity: high · CVSS 7.5 · Published 2025-10-28

Starlette is a lightweight ASGI framework/toolkit. Starting in version 0.39.0 and prior to version 0.49.1 , an unauthenticated attacker can send a crafted HTTP Range header that triggers quadratic-time processing in Starlette's FileResponse Range parsing/merging logic. This enables CPU exhaustion per request, causing denial‑of‑service for endpoints serving files (e.g., StaticFiles or any use of FileResponse). This vulnerability is fixed in 0.49.1.

Technologies: starlette (PyPI). Vendors: PyPI.

Quick answers

Is CVE-2025-62727 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2025-62727 being exploited in the wild.
How severe is CVE-2025-62727?
High severity, with a CVSS score of 7.5, published 28 October 2025.
Which products and versions are affected?
starlette (PyPI) ECOSYSTEM:introduced=0.39.0,fixed=0.49.1.
Is there a fix for CVE-2025-62727?
Yes. starlette (PyPI): upgrade to 0.49.1 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
Am I affected by CVE-2025-62727?
Check whether you run starlette (PyPI) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

How to fix

  • starlette (PyPI): upgrade to 0.49.1 or later
    pip install "starlette>=0.49.1"

Affected products

  • starlette (PyPI) ECOSYSTEM:introduced=0.39.0,fixed=0.49.1

Identifiers

  • CVE-2025-62727
  • GHSA-7f5h-v6xp-fcq8
  • PYSEC-2026-1942

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.