Vulnerabilities in pkg:pypi/django

PACKAGE
Advisory Identifier: GHSA-q238-5cxm-5c9h
Advisory Summary

CVE-2026-15830 is a MODERATE (CVSS 5.3) denial of service vulnerability (CWE-674: Uncontrolled Recursion) affecting Django libraries in the PyPI ecosystem. The issue involves django geodjango vulnerable to denial of service through deeply nested geometry collections. Remediation is available by upgrading affected packages to version 5.2.17, 6.0.8, 6.1.1.

17 Known Advisory Record(s)
Package Vulnerability Intelligence

pkg:pypi/django

17 Known Advisory Record(s)

Vulnerability advisories affecting package pkg:pypi/django. Select an advisory below to view technical details or fixes.

Advisory ID CVE / NVD Severity Summary
GHSA-q238-5cxm-5c9h CVE-2026-15830 MODERATE Django GeoDjango vulnerable to denial of service through deeply nested geometry collections
GHSA-h7pc-vwp9-298g CVE-2026-6873 LOW Django: signed cookies are vulnerable to salt namespace collisions
GHSA-8cjm-8mp7-r2xf CVE-2026-8404 LOW Django: UpdateCacheMiddleware may disclose cached responses due to case-sensitive Cache-Control handling
GHSA-crhf-3pfg-w68w CVE-2026-53877 MODERATE Django: GDALRaster may over-read heap memory when constructed from bytes
GHSA-3h9f-r86x-qvjx CVE-2026-48588 LOW Django: cache middleware may expose private responses when unrelated request cookies are present
GHSA-8qcx-xf44-272x CVE-2026-53878 MODERATE Django: DomainNameValidator permits newline characters that may enable HTTP header injection
GHSA-923m-gv2p-w5qp CVE-2026-48587 LOW Django: has_vary_header may expose cached responses when Vary values contain whitespace
GHSA-qpc8-7fxc-cm4p CVE-2026-35193 LOW Django: UpdateCacheMiddleware may disclose private cached responses by omitting Authorization from Vary
GHSA-mm6v-q8q9-pgcf CVE-2026-7666 LOW Django fails to prevent reuse of a partially-initialized connection after a failed `STARTTLS` handshake
GHSA-frmv-pr5f-9mcr CVE-2025-64459 CRITICAL Django vulnerable to SQL injection via _connector keyword argument in QuerySet and Q objects.
GHSA-qw25-v68c-qjf3 CVE-2025-64458 HIGH Django has a denial-of-service vulnerability in HttpResponseRedirect and HttpResponsePermanentRedirect on Windows
GHSA-q95w-c7qg-hrff CVE-2025-59682 LOW Django vulnerable to partial directory traversal via archives
GHSA-qcgg-j2x8-h9g8 CVE-2024-56374 MODERATE Django has a potential denial-of-service vulnerability in IPv6 validation
GHSA-m9g8-fxxm-xg86 CVE-2024-53908 HIGH Django SQL injection in HasKey(lhs, rhs) on Oracle
GHSA-8498-2h75-472j CVE-2024-53907 MODERATE Django denial-of-service in django.utils.html.strip_tags()
GHSA-6c3j-c64m-qhgq CVE-2019-11358 MODERATE XSS in jQuery as used in Drupal, Backdrop CMS, and other products
GHSA-4894-5vqc-6r2r CVE-2013-4249 MODERATE Django cross-site scripting (XSS) vulnerability in the AdminURLFieldWidget widget

CVE-2026-15830 at a Glance

CVE Identifier CVE-2026-15830
GHSA Identifier GHSA-q238-5cxm-5c9h
Severity MODERATE
CVSS v3.1 Base Score 5.3
CWE Classification CWE-674: Uncontrolled Recursion
Affected Product Django
Package Ecosystem PyPI
Published Date
Last Updated

Security Impact

CVSS: 5.3

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality None (C:N)
Integrity None (I:N)
Availability Low (A:L)

How to Fix CVE-2026-15830

To remediate this vulnerability, upgrade all affected Django dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

django fixed: 5.2.17
pip install django>=5.2.17
django fixed: 6.0.8
pip install django>=6.0.8
django fixed: 6.1.1
pip install django>=6.1.1
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

pip show django

How to Check if You Are Affected

To determine whether your Python environment is affected by CVE-2026-15830, inspect your installed packages using pip:

pip show django

Analyze the terminal output to locate any version of Django in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 5.2.17), your application is affected.

Note: The pip show django command checks currently installed packages in your active Python environment.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-674: Uncontrolled Recursion, where the product does not properly control the amount of recursion that takes place, consuming excessive resources, such as allocated memory or the program stack. In Django, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

An issue was discovered in Django 5.2 before 5.2.17 and 6.0 before 6.0.8. GeoDjango's `django.contrib.gis.geos.GEOSGeometry` is subject to a potential denial-of-service when parsing deeply nested `GEOMETRYCOLLECTION` objects supplied as well-known text (WKT), well-known binary (WKB), or hex-encoded WKB, which triggers unbounded recursion and a segmentation fault in the underlying GEOS library. Spatial field lookups and the `django.contrib.gis.forms.GeometryField` form field are also affected. 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 Andrew MacPherson and kimchunbok_ for reporting this issue.

CVE-2026-15830 Affected Django Versions

3 component(s)
Fixed Versions:
5.2.176.0.86.1.1
Product / Package Ecosystem Affected Versions Fixed Version
django
PyPI
< 5.2.17
5.2.17
django
PyPI
≥ 6.0a1
< 6.0.8
6.0.8
django
PyPI
≥ 6.1a1
< 6.1.1
6.1.1

References

Frequently Asked Questions

What is CVE-2026-15830?
CVE-2026-15830 is a security vulnerability in Django involving Django GeoDjango vulnerable to denial of service through deeply nested geometry collections under CWE-674: Uncontrolled Recursion.
Which Django versions are affected?
Affected versions include releases prior to 5.2.17, 6.0.8, 6.1.1 across affected packages: django.
What version fixes CVE-2026-15830?
Upgrading to 5.2.17, 6.0.8, 6.1.1 (or the latest patched release for your respective branch) resolves the vulnerability.
Is django affected?
Yes, django is affected in releases prior to 5.2.17, 6.0.8, 6.1.1. Upgrade your dependency to 5.2.17, 6.0.8, 6.1.1 or later.
What is the CVSS score of CVE-2026-15830?
CVE-2026-15830 has a CVSS v3.1 base score of 5.3 (MODERATE) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L.
What CWE is associated with CVE-2026-15830?
CVE-2026-15830 is classified under CWE-674: Uncontrolled Recursion (The product does not properly control the amount of recursion that takes place, consuming excessive resources, such as allocated memory or the program stack.).
How can I check PyPI dependencies for CVE-2026-15830?
Run the dependency tree command: 'pip show django'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-q238-5cxm-5c9h",
  "modified" : "2026-10-12T14:36:03Z",
  "published" : "2026-08-04T18:31:27Z",
  "aliases" : [ "CVE-2026-15830" ],
  "summary" : "Django GeoDjango vulnerable to denial of service through deeply nested geometry collections",
  "details" : "An issue was discovered in Django 5.2 before 5.2.17 and 6.0 before 6.0.8.\nGeoDjango's `django.contrib.gis.geos.GEOSGeometry` is subject to a potential denial-of-service when parsing deeply nested `GEOMETRYCOLLECTION` objects supplied as well-known text (WKT), well-known binary (WKB), or hex-encoded WKB, which triggers unbounded recursion and a segmentation fault in the underlying GEOS library. Spatial field lookups and the `django.contrib.gis.forms.GeometryField` form field are also affected.\nEarlier, unsupported Django series (such as 5.1.x, 5.0.x, and 4.2.x) were not evaluated and may also be affected.\nDjango would like to thank Andrew MacPherson and kimchunbok_ for reporting this issue.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L"
  }, {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "django"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "5.2.17"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "django"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "6.0a1"
      }, {
        "fixed" : "6.0.8"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "django"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "6.1a1"
      }, {
        "fixed" : "6.1.1"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-15830"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/django/django/commit/1eafa1a80f1363283f89208ba4499ed54e35f085"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/django/django/commit/4353dfb56f8ba3a6fccc4bdd7f2ef2fbee3aa638"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/django/django/commit/62ef9d40cf4ea75f16518436b44b8ab2515340df"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/django/django/commit/6af5da31775417c610dbf9c3f1b5b8333d42daf6"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/django/django/commit/75d401a1491e04a907ed745c128836d51c982c0f"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/django/django/commit/9e4a3f186b6b07b483bfd9195ea06734663fcd06"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/django/django/commit/ba80833fa656dd09660b97c4429331067db1b080"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/django/django/commit/d2e59b77fe18de318a8272c2a7bbc798d84d1d0d"
  }, {
    "type" : "WEB",
    "url" : "https://docs.djangoproject.com/en/dev/releases/security"
  }, {
    "type" : "ADVISORY",
    "url" : "https://github.com/advisories/GHSA-q238-5cxm-5c9h"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/django/django"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/pypa/advisory-database/tree/main/vulns/django/PYSEC-2026-3717.yaml"
  }, {
    "type" : "WEB",
    "url" : "https://groups.google.com/g/django-announce"
  }, {
    "type" : "WEB",
    "url" : "https://www.djangoproject.com/weblog/2026/aug/04/security-releases"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-674" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-09-30T20:19:00Z",
    "nvd_published_at" : "2026-08-04T17:16:46Z"
  }
}