All vulnerabilities

PyPI · Servers and applications

CVE-2026-115868

Potential cross-site scripting vulnerability in truncatechars_html

Severity
Medium 6.1
Published
2 Dec 2026
Last changed
2 Dec 2026
Added to UpHeron
2 Dec 2026
Fixed in
5.2.20, 6.0.11, 6.1.4
Weakness
Cross-site scripting (CWE-79)
Attack
Over the network · No login needed · Needs someone to click or open something
Attacker can
Read some data · Change some data
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
Sources
CVE Program

Description

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.

From the CVE Program.

Affected software

SoftwareAffected versions
DjangoServers and applications · cna:djangoproject|django
  • From 5.2 before 5.2.20
  • From 6.0 before 6.0.11
  • From 6.1 before 6.1.4
DjangoPyPI · osv:PyPI:django
  • From 5.2 before 5.2.20
  • From 6.0 before 6.0.11
  • From 6.1 before 6.1.4

About Django

Python web framework

From Wikidata, CC0 1.0.
Developers who used it in the past year
12.6%Stack Overflow Developer Survey 2025, 2025
Weekly downloads (PyPI)
11,539,052PyPI Stats, 29 Nov 2026
GitHub stars
91,804GitHub, 29 Nov 2026
Forks
35,001GitHub, 29 Nov 2026
Developer
Django Software FoundationWikidata
License
3-clause BSD LicenseWikidata
Written in
PythonWikidata
First released
2004Wikidata
First published on GitHub
28 Apr 2012GitHub

Release lines

ReleaseLatestSecurity fixes
6.16.1.3Until 31 Dec 2027
6.06.0.10Until 30 Apr 2027
5.2 (LTS)LTS5.2.19Until 30 Apr 2028
5.15.1.15Ended 3 Dec 2025
5.05.0.14Ended 2 Apr 2025
4.2 (LTS)LTS4.2.30Ended 7 Apr 2026

From endoflife.date.

References

  • CVE.org https://www.cve.org/CVERecord?id=CVE-2026-115868