CVE-2026-1285: Denial of service in Django HTML truncation
- Vendor
- Djangoproject
CVE-2026-1285 is an algorithmic-complexity vulnerability in Django's django.utils.text.Truncator.chars() and Truncator.words() methods when html=True, and in the truncatechars_html and truncatewords_html template filters. Crafted input containing many unmatched HTML end tags can cause quadratic-time HTML parsing, potentially allowing a remote attacker to deny service. Affected versions are Django 6.0 before 6.0.2, 5.2 before 5.2.11, and 4.2 before 4.2.28. Earlier unsupported branches, including 5.0.x, 4.1.x, and 3.2.x, were not evaluated and may also be affected.
Impact, mitigation & remediation
What it means and what to do now: patch path, interim mitigations, and the assume-compromise checklist.
Impact
What an attacker gets, and what they’ve been doing with it.
Processing malicious HTML through the affected truncation functions can trigger quadratic-time computation, potentially degrading application responsiveness or causing denial of service.
Mitigation
If you can’t patch tonight, do this now.
Until patched, avoid processing attacker-controlled HTML with the affected HTML-aware truncation methods and template filters. Restrict or sanitize untrusted HTML, limit access to exposed applications, and consider temporarily disabling or rate-limiting endpoints that invoke the vulnerable functionality. These measures reduce exposure but do not replace updating Django.
Remediation
Patch, then assume compromise.
Upgrade Django to 6.0.2 or later in the 6.0 series, 5.2.11 or later in the 5.2 series, or 4.2.28 or later in the 4.2 series. Move unsupported installations to a supported, patched release or install an applicable distributor backport. Debian fixes are available in python-django versions 3:3.2.25-0+deb12u2 for bookworm and 3:4.2.28-0+deb13u1 for trixie. For affected Red Hat deployments, apply RHSA-2026:3958 for Ansible Automation Platform 2.6, RHSA-2026:3959 for version 2.5, RHSA-2026:5970 for Satellite 6.17, or RHSA-2026:5971 for Satellite 6.16.
Exploits
No public exploits tracked yet. Mallory keeps watching.
Affected products & vendors
Products and vendors Mallory has correlated with this vulnerability. Open in Mallory to drill down to specific CPE configurations and version ranges.
References
Frequently asked questions
- Is CVE-2026-1285 exploited in the wild?
- As of Oct 3, 2026, Mallory has no reports of CVE-2026-1285 being exploited in the wild. It is not listed in CISA KEV.
- Is there a public exploit for CVE-2026-1285?
- As of Oct 3, 2026, Mallory has found no public exploit for CVE-2026-1285.
- Is there a patch for CVE-2026-1285?
- Upgrade Django to 6.0.2 or later in the 6.0 series, 5.2.11 or later in the 5.2 series, or 4.2.28 or later in the 4.2 series. Move unsupported installations to a supported, patched release or install an applicable distributor backport.
- What products are affected by CVE-2026-1285?
- Djangoproject Django.
- How severe is CVE-2026-1285?
- CVE-2026-1285 has a CVSS v3.1 score of 7.5 (High) and an EPSS score of 1.1% (67th percentile) as of Oct 3, 2026.
Recent activity
14 sources tracked across advisories, community write-ups, and news. New activity surfaces here as Mallory finds it.