Django4Shell: Django Fixes GeoDjango RCE Flaw CVE-2026-124827

Django 6.1.4, 6.0.11 and 5.2.20 fix seven flaws, including Django4Shell (CVE-2026-124827, CVSS 9.0), a GeoDjango RasterField bug allowing file write and RCE.
Table of Contents
    Add a header to begin generating the table of contents

    The Django project has released security updates that fix seven vulnerabilities, led by a CVSS 9.0 flaw in GeoDjango’s RasterField that researchers have codenamed Django4Shell. The bug, tracked as CVE-2026-124827, allows arbitrary file write and potential remote code execution. Django says it has seen no attacks in the wild.

    Django 6.1.4, 6.0.11 and 5.2.20 Carry the Fixes

    The security release, issued on Dec. 2, covers the 6.1, 6.0 and 5.2 series. Fixed builds are Django 6.1.4, 6.0.11 and 5.2.20. Beyond the headline flaw, the update patches a high-risk SQL injection, CVE-2026-132092, along with the remaining bugs in the set of seven.

    The Django4Shell name comes from researcher Mohamed Fathy of Robusta Technology Group, who found the flaw.

    A Third Attempt at Fixing GeoDjango Raster Parsing

    CVE-2026-124827 is the latest link in a chain of incomplete fixes. It is an incomplete fix for CVE-2026-87890, an SSRF issue involving GDAL VRT payloads, which was patched in October. That flaw was itself an incomplete fix for CVE-2026-15307, a GeoDjango raster-parsing file-write bug patched in August.

    Why the Earlier Guard Fails on the RasterField Path

    The earlier protection does not run on the RasterField assignment path during ModelForm validation. That gap lets an attacker submit a crafted JSON raster body and control the file path, content and name of what gets written to the server.

    From Arbitrary File Write to Remote Code Execution

    Control over a written file opens several routes to code execution. Examples cited in the research include overwriting application source, dropping web shells, or writing a sitecustomize.py file through GDAL’s EHdr driver. Each turns a file-write primitive into execution on the host.

    Exploitation Needs a Staff User Who Can Submit Forms

    SecurityOnline, which covered the research, reports that exploitation requires a staff user able to submit forms. That limits who can reach the vulnerable path, though applications that expose raster fields in the admin or in auto-built forms are the ones in scope.

    Django has confirmed that there are no known attacks in the wild and no weaponized public exploit. A Django4Shell research site does map the attack flow, giving defenders and attackers alike a description of how the technique works without handing over ready-to-run code.

    Seven Fixes Include SQL Injection CVE-2026-132092

    The full release addresses seven bugs in total. The GeoDjango flaw and the SQL injection, CVE-2026-132092, are the two the coverage singles out by identifier. The other five are not described in the available reporting.

    Impact Falls on GeoDjango Applications With Raster Fields

    The affected population is narrow compared with the framework as a whole. Applications that use GeoDjango and expose a RasterField through the admin or through automatically built forms face the exposure. Sites without that feature are not touched by CVE-2026-124827.

    The bug’s lineage is the part that stands out. Three CVEs in about four months trace to the same raster-handling code, each patched on the understanding that it closed the issue. Django’s response to the latest report is to upgrade to 6.1.4, 6.0.11 or 5.2.20, depending on the series in use.

    Three Linked GeoDjango Advisories Between August and December

    The timeline shows how the flaw arrived. CVE-2026-15307, a GeoDjango raster-parsing file-write bug, was patched in August. CVE-2026-87890, the SSRF through GDAL VRT payloads, followed in October. CVE-2026-124827 arrived in the Dec. 2 release, covering the Django 6.1, 6.0 and 5.2 series.

    Each patch closed a specific path, and each left another open. The December flaw exists because the earlier guard did not run on the RasterField assignment path during ModelForm validation. Django says no weaponized public exploit exists, though the Django4Shell research site publishes the attack flow.

    Related Posts