CVE-2025-26699: Django: Potential denial-of-service in django.utils.text.wrap()

Published Feb 28, 2025
·
Updated

An issue was discovered in Django 5.1 before 5.1.7, 5.0 before 5.0.13, and 4.2 before 4.2.20. The django.utils.text.wrap() method and wordwrap template filter are subject to a potential denial-of-service attack when used with very long strings.

Other sources

The wrap() and :tfilter:wordwrap template filter were subject to a potential denial-of-service attack when used with very long strings.

Affected versions =================

Django main development branch Django 5.2 (currently at beta status) Django 5.1 Django 5.0 Django 4.2

Red Hat

This CVE was automatically created from a reference found in an email or other text. If you are reading this, then this CVE entry is probably erroneous, since this text should be replaced by the official CVE description automatically.

Launchpad

Affected Software

12 affected componentsFixes available
Django Django<5.1.7
Django Django<5.0.13
Django Django<4.2.20
debian/python-django<=2:2.2.28-1~deb11u2, <=2:2.2.28-1~deb11u5, <=3:3.2.19-1+deb12u1
3:4.2.20-1
pip/Django>=5.1<5.1.7
5.1.7
pip/Django>=5.0<5.0.13
5.0.13
pip/Django>=4.2<4.2.20
4.2.20
IBM Storage Defender - Resiliency Service<=2.0.0 - 2.0.12
djangoproject Django>=4.2<4.2.20
djangoproject Django>=5.0<5.0.13
djangoproject Django>=5.1<5.1.7
Debian Debian Linux=11.0

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade debian/python-django to a version that resolves this vulnerability.

    Fixed in 3:4.2.20-1
  2. Upgrade

    Upgrade pip/Django to a version that resolves this vulnerability.

    Fixed in 5.1.7
  3. Upgrade

    Upgrade pip/Django to a version that resolves this vulnerability.

    Fixed in 5.0.13
  4. Upgrade

    Upgrade pip/Django to a version that resolves this vulnerability.

    Fixed in 4.2.20
  5. Upgrade

    Upgrade Django to a version that resolves this vulnerability.

    Fixed in 5.1.7
  6. Upgrade

    Upgrade Django to a version that resolves this vulnerability.

    Fixed in 5.0.13
  7. Upgrade

    Upgrade Django to a version that resolves this vulnerability.

    Fixed in 4.2.20
  8. Compensating control

    Mitigate CVE-2025-26699 by avoiding use of django.utils.text.wrap() / the wordwrap template filter with very long strings (e.g., limit input length) until upgraded to fixed versions (Django 5.1.7, 5.0.13, or 4.2.20).

Event History

Feb 28, 2025
Data Sourced
via Red Hat·09:52 AM
DescriptionSeverityAffected Software
Mar 6, 2025
CVE Published
via MITRE·12:00 AM
Data Sourced
via MITRE·12:00 AM
DescriptionSeverityWeakness
Data Sourced
via NVD·07:15 PM
DescriptionSeverityWeakness
Data Sourced
via NVD·07:15 PM
Affected Software
Advisory Published
via GitHub·09:31 PM
Mar 7, 2025
Data Sourced
via Ubuntu·01:58 PM
RemedyDescriptionSeverityAffected Software
Data Sourced
via Launchpad·01:58 PM
Description

Parent advisories

This vulnerability appears in the following advisories.

Frequently Asked Questions

1

What is the severity of CVE-2025-26699?

CVE-2025-26699 has a moderate severity level due to its potential for denial-of-service attacks.

2

How do I fix CVE-2025-26699?

To fix CVE-2025-26699, upgrade Django to version 5.1.7, 5.0.13, or 4.2.20 or later.

3

Which versions of Django are affected by CVE-2025-26699?

CVE-2025-26699 affects Django versions 5.1 before 5.1.7, 5.0 before 5.0.13, and 4.2 before 4.2.20.

4

What are the potential impacts of CVE-2025-26699?

The potential impacts of CVE-2025-26699 include service disruptions caused by denial-of-service attacks exploiting long string inputs.

5

Is there a workaround for CVE-2025-26699?

No specific workarounds have been provided for CVE-2025-26699, so upgrading to a patched version is recommended.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203