Skip to content
Connect AISign inSign up free
CVE-2026-1158686.1MediumCWE-79

CVE-2026-115868: Potential cross-site scripting vulnerability in truncatechars_html

djangoproject · Django

Vendor fix available · Affected: djangoproject · Exploitation: not established

Verdict

RoutineA fix exists and nothing on record suggests attackers are using it.

  • NoAttacks seen
  • NoPublic exploit code
  • n/aExploit odds: not scored yet
  • YesFix available: Vendor fix available
How we decide

Patch now: attacks are on record (CISA KEV, the EU exploited list, CISA marking exploitation active, or a report of exploitation), or exploit code is public for a flaw reachable over the network with no login that has exploit odds of 10% or more, or is rated critical with odds of at least 1%. Patch this cycle: any other public exploit code, scanning observed, or exploit odds of 10% or more. Routine: a fix exists and none of those. No verdict yet: no fix on record and nothing else known. The verdict says how soon to act, not how severe the flaw is, and it changes when these facts change.

What it isNVD

An issue was discovered in Django 6.1 before 6.1.4, 6.0 before 6.0.11, and 5.2 before 5.2.20. The `truncatechars_html` template filter and the `django.utils.text.Truncator.chars()` method (with `html=True`) are subject to a potential cross-site scripting (XSS) attack when certain inputs whose text length matches the truncation length are processed and rendered in an HTML attribute.

Earlier, unsupported Django series (such as 5.1.x, 5.0.x, and 4.2.x) were not evaluated and may also be affected. Django would like to thank JoeCyberTech for reporting this issue.

Exploit requirementsfrom the CVSS 3.1 vector in the CVE record; NVD has not scored it yet

Where from
Remotely, over the network
Login
None needed
User action
Someone must do something, such as open a link or a file
Conditions
None stated in the score

Also needed, according to the published text

  • The input text length must match the truncation length“when certain inputs whose text length matches the truncation length are processed and rendered in an HTML attribute” · the CVE record
  • The processed output must be rendered in an HTML attribute“are processed and rendered in an HTML attribute” · the CVE record

Are you affected?

The answer appears here.

Or hand it to your AI agent. The prompt carries the facts on this page and only commands that read package and kernel state; it tells the agent to change nothing.

No EPSS score yet. The score appears once FIRST publishes it.

6.1MediumCVSS 3.1
LowMedium
Check your systemsRead-only commands per release

Assess your exposure

Commands that only read package and kernel state, for each release we checked. They change nothing on the host.

The same commands and fixed versions, with instructions to report back without changing anything.

Affected versions, per the CVE record

Not checked: Red Hat, Ubuntu, Debian, SUSE, Alpine. Treat distributions and products not listed as unknown, not unaffected.

ExploitationNot established

ExploitationNot established

Not in CISA KEV as of catalogue 2026.11.30 (30 Nov)

  1. Not establishedNothing in the sources we check

Not seen so far: in CISA KEV · exploited (reported) · scanning observed · proof of concept public.

Weakness and public checksCross-site Scripting

Weakness and public checks

Public check
No public nuclei template
Weakness
Cross-site Scripting
Related CVEsDjango

Other CVEs in Django

Every published CVE for djangoproject Django, by how far exploitation has gone. This one is among them.

As a list
Other CVEs in Django: each mark is one CVE.Drag to move · Ctrl + scroll to zoom · a mark opens that CVE
Coverage1 article · 1 outlet

Coverage1 article · 1 outlet

First in our coverage: The Hacker News, 2 Dec.

  1. Django fixes critical GeoDjango flaw enabling remote code execution
    The Hacker News · first in our coverage · mentions it in passing

New articles also arrive in the RSS feed.

References4 links

References