Django patches GeoDjango flaw that can lead to file writes and possible RCE
Vulnerability Disclosure · 17 sources · Updated 4mo ago · First seen Aug 4, 2026

The Django project released Django 6.0.8 and Django 5.2.17 to fix four vulnerabilities, led by CVE-2026-15307, a high-severity flaw in GeoDjango spatial lookups. The bug affects cases where untrusted str or dict input is passed to django.contrib.gis.gdal.GDALRaster, allowing attacker-controlled server-side file writes and outbound requests through GDAL virtual filesystem handlers; in some deployments, that file-write primitive can be chained into remote code execution if the written file is later imported by the application. Reports said the issue could be exploited remotely with low privileges, including by a staff user through a Django admin changelist query string.
The same releases also addressed CVE-2026-15337, a low-severity denial-of-service issue in check_for_language(); CVE-2026-15830, a moderate denial-of-service flaw triggered by deeply nested GEOMETRYCOLLECTION objects in GEOSGeometry; and CVE-2026-15920, a moderate stored cross-site scripting issue in Django admin rendering of URLField values. Supported branches including Django main, the 6.1 release candidate, 6.0, and 5.2 received fixes, and the project urged users to upgrade promptly; older unsupported branches such as 5.1.x, 5.0.x, and 4.2.x were not evaluated and may also be affected.
Why it matters
Impact assessment
Django deployments running versions before 6.0.8 or 5.2.17 are exposed, with highest risk concentrated in applications using GeoDjango spatial lookups and environments where the Django admin is accessible to staff users. The most serious issue, CVE-2026-15307, can enable attacker-controlled server-side file writes, SSRF-like outbound requests, and in some deployments possible remote code execution, creating material risk of application compromise, data exposure, and service disruption.
Exposure is broad across supported Django branches, but practical exploitation is more targeted to applications that use GIS features, spatial fields, raster handling, or admin filtering on registered models with spatial fields. No confirmed in-the-wild exploitation was cited in the references, but the vulnerability is remotely reachable with low privileges and should be treated as urgent.
Affected populations and products
- Product: Django
- Affected versions: before 6.0.8 and before 5.2.17
- Supported branches receiving fixes: main, 6.1 release candidate, 6.0, 5.2
- Older unsupported branches not evaluated and possibly affected: 5.1.x, 5.0.x, 4.2.x
- Highest-risk feature areas:
- GeoDjango spatial lookups
GeometryFieldandRasterFieldusage- Django admin exposure to staff users
django.views.i18n.set_language()if enabled- Admin rendering of
URLFieldvalues
Severity and business impact by issue
CVE-2026-15307: high severity; potential application compromise through file write and possible RCE, plus outbound requests from the Django processCVE-2026-15337: low severity; bounded memory-consumption DoSCVE-2026-15830: moderate severity; crafted geometry input can crash GEOS and disrupt application availabilityCVE-2026-15920: moderate severity; stored XSS in Django admin can target administrative users and enable session or workflow abuse
Known exploitation status
- No explicit reports of exploitation in the wild were provided
- Remote exploitation with low privileges was described for
CVE-2026-15307, including staff users with view permission via admin changelist query strings


