cve.bz

CVE-2026-5766 djangoproject django

6.3 mediumEPSS 0.4%Fix available

Medium (6.3) in djangoproject django. EPSS 0.4% estimated probability of exploitation activity in the next 30 days. Fixed in django 5.2.14, 6.0.5.

On this page
An issue was discovered in 6.0 before 6.0.5 and 5.2 before 5.2.14. ASGI requests with a missing or understated `Content-Length` header can bypass the `FILE_UPLOAD_MAX_MEMORY_SIZE` limit, potentially loading large files into memory and causing service degradation. As a reminder, Django expects a limit to be configured at the web server level rather than solely relying on `FILE_UPLOAD_MAX_MEMORY_SIZE`. Earlier, unsupported Django series (such as 5.0.x, 4.1.x, and 3.2.x) were not evaluated and may also be affected. Django would like to thank Kyle Agronick for reporting this issue.

Severity

CVSS 4.0

6.3 medium
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N

CVSS 3.1

5.3 medium
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
EPSS
0.4% (unchanged from 0.4% a week ago; 0.5% 30 days ago) estimated probability of exploitation activity in the next 30 days; 37th percentile. Scored 2026-11-15. A forecast for this CVE across the internet, not for your own systems.
CISA's assessment (SSVC)
Exploitation: none · Automatable: no · Technical impact: partial, assessed 2026-05-05. From CISA's Vulnrichment in the CVE List: whether it is exploited, whether exploiting it can be automated, and how much control it gives.
CWE
CWE-130 Improper Handling of Length Parameter Inconsistency
Published
Modified
NVD analysis
Analyzed
Record from
the NVD, synced

Fix and patched versions

Ask an AI about this CVE

Show the promptExplain CVE-2026-5766 for an engineer deciding whether to act. Use https://cve.bz/api/public/cves/CVE-2026-5766?via=ask-ai-copy and https://cve.bz/cve/CVE-2026-5766?via=ask-ai-copy as the source of truth: what is affected and which versions fix it, whether it is in CISA KEV, public exploits, and its EPSS (an internet-wide 30-day estimate of exploitation activity, not a forecast for my systems). If they give no fixed versions, use the CVE record https://cveawg.mitre.org/api/cve/CVE-2026-5766 or the vendor advisory, not third-party mirrors. Tell me how to check whether I am affected and how to verify a fix. Cite the sources and say where they are uncertain.

Opens a third-party assistant; its answer is its own, not cve.bz's. The prompt holds only this CVE's id and public links.

Badge for a README or a site

CVE-2026-5766

An image that stays current: it is drawn from the data each time it is fetched (a host that proxies images, as GitHub does, may show its copy for a while). Markdown:

[![CVE-2026-5766](https://cve.bz/cve/badge/CVE-2026-5766.svg)](https://cve.bz/cve/CVE-2026-5766)

HTML:

<a href="https://cve.bz/cve/CVE-2026-5766"><img src="https://cve.bz/cve/badge/CVE-2026-5766.svg" alt="CVE-2026-5766"></a>

Affected

Versions

From the CNA's record in the CVE List.

ProductAffected
djangoproject Djangofrom 6.0 before 6.0.5
djangoproject Djangofrom 5.2 before 5.2.14

Packages (OSV)

AdvisoryEcosystemPackageAffectedFixed in
GHSA-w26r-rmm8-9c29PyPIdjango>=6.0 <6.0.56.0.5
GHSA-w26r-rmm8-9c29PyPIdjango>=5.2 <5.2.145.2.14
PYSEC-2026-54PyPIdjango>=5.2 <5.2.14
>=6.0 <6.0.5
5.2.14, 6.0.5

Linux distributions

DistributionReleasePackageFixed inAdvisory
Debian12, 13python-djangono fix listedDEBIAN-CVE-2026-5766
Debian14python-django3:5.2.14-1DEBIAN-CVE-2026-5766
Ubuntu22.04:LTSpython-django2:3.2.12-2ubuntu1.27UBUNTU-CVE-2026-5766
Ubuntu24.04:LTSpython-django3:4.2.11-1ubuntu1.16UBUNTU-CVE-2026-5766
Ubuntu25.10python-django3:5.2.4-1ubuntu2.5UBUNTU-CVE-2026-5766
Ubuntu26.04:LTSpython-django3:5.2.9-0ubuntu4.1UBUNTU-CVE-2026-5766
UbuntuPro:14.04:LTS, Pro:16.04:LTS, Pro:18.04:LTS and 1 morepython-djangono fix listedUBUNTU-CVE-2026-5766
openSUSETumbleweedpython-Django5.2.14-1.1openSUSE-SU-2026:10718-1
openSUSETumbleweedpython-Django44.2.30-2.1openSUSE-SU-2026:10708-1
openSUSETumbleweedpython-Django55.2.16-1.1openSUSE-SU-2026:11270-1
openSUSETumbleweedpython-Django66.0.5-1.1openSUSE-SU-2026:10709-1
Alpinev3.24py3-django5.2.14-r0ALPINE-CVE-2026-5766

From the distributions' data via OSV.dev: the Debian Security Tracker; Ubuntu Security Notices © Canonical Ltd., CC BY-SA 4.0; SUSE security data, CC BY 4.0; the Alpine secdb, CC BY-SA 4.0. Modified: reformatted and linked to CVE records. Credits. On the distributions' own pages: Debian · Ubuntu · openSUSE · Alpine.

Red Hat

Red Hat rates this Moderate.

Red Hat's statement

This Moderate flaw in Django can lead to service degradation or a denial of service. A remote attacker can exploit this by sending ASGI requests with a manipulated Content-Length header, bypassing the FILE_UPLOAD_MAX_MEMORY_SIZE and causing large files to be loaded into memory. Red Hat advises implementing content length restrictions at the web server layer, as Django's internal limits are not solely relied upon for protection.

Red Hat's mitigation

To mitigate this issue, configure the web server (e.g., Nginx, Apache) hosting the Django application to enforce strict Content-Length limits for incoming ASGI requests. This ensures that large files cannot be loaded into memory by bypassing Django's internal FILE_UPLOAD_MAX_MEMORY_SIZE setting. Consult your web server's documentation for specific configuration instructions on limiting request body size. A service reload or restart may be required for the changes to take effect, which could temporarily impact service availability.

ProductPackageStateAdvisory
Red Hat Ansible Automation Platform 2ansible-automation-platform-24/lightspeed-rhel8Fix deferred
Red Hat Ansible Automation Platform 2ansible-automation-platform-25/lightspeed-rhel8Fix deferred
Red Hat Ansible Automation Platform 2ansible-automation-platform-26/controller-rhel9Fix deferred
Red Hat Ansible Automation Platform 2ansible-automation-platform-26/eda-controller-rhel9Fix deferred
Red Hat Ansible Automation Platform 2ansible-automation-platform-26/gateway-rhel9Fix deferred
Red Hat Ansible Automation Platform 2ansible-automation-platform-26/hub-rhel9Fix deferred
Red Hat Ansible Automation Platform 2ansible-automation-platform-26/lightspeed-rhel9Fix deferred
Red Hat Ansible Automation Platform 2ansible-automation-platform-27/aap-cloud-billing-rhel9Fix deferred
Red Hat Ansible Automation Platform 2ansible-automation-platform-27/controller-rhel9Fix deferred
Red Hat Ansible Automation Platform 2ansible-automation-platform-27/eda-controller-rhel9Fix deferred
Red Hat Ansible Automation Platform 2ansible-automation-platform-27/gateway-rhel9Fix deferred
Red Hat Ansible Automation Platform 2ansible-automation-platform-27/hub-rhel9Fix deferred
Red Hat Ansible Automation Platform 2ansible-automation-platform-27/lightspeed-rhel9Fix deferred
Red Hat Ansible Automation Platform 2ansible-automation-platform-27/metrics-service-rhel9Fix deferred
Red Hat Ansible Automation Platform 2ansible-automation-platform/automation-dashboard-rhel9Fix deferred
Red Hat Ansible Automation Platform 2ansible-automation-platform-tech-preview/metrics-service-rhel9Fix deferred
Red Hat Ansible Automation Platform 2automation-controllerFix deferred
Red Hat Ansible Automation Platform 2python-djangoFix deferred
Red Hat Discovery 2discovery/discovery-server-rhel9Fix deferred
Red Hat OpenStack Platform 16.2python-django20Fix deferred
7 more in the JSON and on Red Hat's page.

Contains Red Hat Security Data © Red Hat, Inc., licensed under CC BY 4.0. Source: https://access.redhat.com/security/data. Modified: reformatted. Red Hat's page for CVE-2026-5766.

Attack patterns (CAPEC)

  • CAPEC-47 Buffer Overflow via Parameter Expansion Likelihood: Medium · Severity: High

The attack patterns MITRE's CAPEC relates to this record's weaknesses, as MITRE names them. Credits.

References

Check your stackJSON