
Cloud Vulnerability DB
A community-led vulnerabilities database
CVE-2026-1207 is an SQL injection vulnerability in Django's RasterField raster lookups (implemented only when using PostGIS) that allows remote attackers to inject arbitrary SQL via the band index parameter. It affects Django versions 6.0 before 6.0.2, 5.2 before 5.2.11, and 4.2 before 4.2.28; earlier unsupported series (5.0.x, 4.1.x, 3.2.x) were not formally evaluated but may also be affected. The vulnerability was reported by Tarek Nakkouch and publicly disclosed on February 3, 2026. It carries a CVSS v3.1 base score of 5.4 (Medium) per Red Hat, though GitHub Advisory rates it 8.1 (High) under CVSS v4 (Red Hat Advisory, GitHub Advisory).
The root cause is improper neutralization of special elements in an SQL command (CWE-89), specifically in the band index parameter used during raster lookups on RasterField objects in Django's GeoDjango module. This feature is only available when the PostGIS spatial database backend is in use, limiting the attack surface to applications that leverage geospatial raster data. An attacker can craft a malicious band index value that is interpolated directly into a SQL query without adequate sanitization, enabling classic SQL injection. The fix is tracked in Django's source repository at commit 81aa529 (GitHub Advisory, Django Changeset).
Successful exploitation allows a remote attacker to inject and execute arbitrary SQL commands against the underlying PostGIS-enabled database. This can result in unauthorized read access to sensitive data (confidentiality breach), unauthorized modification or deletion of database records (integrity breach), and potentially service disruption depending on the injected payload. The attack vector is network-accessible with low complexity and no required user interaction, making it straightforward to exploit in environments using Django with PostGIS raster functionality (Red Hat Advisory, GitHub Advisory).
As of the time of disclosure, there is no confirmed public proof-of-concept exploit or evidence of active in-the-wild exploitation (Red Hat Advisory). The vulnerability is not listed in the CISA Known Exploited Vulnerabilities (KEV) catalog. The EPSS score is approximately 4.96% (Feedly data) to 6.57% (GitHub Advisory), placing it in the 91st percentile for exploitation probability within 30 days. Nuclei detection templates have been developed and merged into the ProjectDiscovery nuclei-templates repository, and Emerging Threats IDS rulesets have been updated to detect exploitation attempts (GitHub Advisory).
RasterField objects. Tools like Shodan, Censys, or manual code review can help identify targets running affected Django versions (6.0 < 6.0.2, 5.2 < 5.2.11, 4.2 < 4.2.28).RasterField lookup query (e.g., MyModel.objects.filter(raster__contains=GDALRaster(...), raster__band_index=<user_input>)).1 OR 1=1-- or 1; DROP TABLE users--) that will be interpolated unsanitized into the generated SQL query.', --, OR 1=1, UNION SELECT) in band index parameters; unexpected outbound database connections or data exfiltration traffic from the application server.UNION SELECT, OR 1=1, or stacked queries originating from the Django application's database user; unauthorized schema changes or data access patterns.Django has released patched versions addressing this vulnerability: 6.0.2, 5.2.11, and 4.2.28. All users running affected versions should upgrade immediately to the appropriate patched release (Django Security Releases). For applications running unsupported Django series (5.0.x, 4.1.x, 3.2.x), upgrading to a supported and patched version is strongly recommended. As a defense-in-depth measure where immediate patching is not possible, restrict network access to endpoints that use PostGIS raster functionality and implement input validation to reject non-integer band index values. Red Hat has issued errata (RHSA-2026:3958, RHSA-2026:3959, RHSA-2026:5970, RHSA-2026:5971, RHSA-2026:2694, RHSA-2026:5971) for affected products including Ansible Automation Platform and Red Hat Satellite (Red Hat Bugzilla).
The Django security team published a blog post on February 4, 2026 discussing recent trends observed by the security team in the context of this and related releases (Django Blog). Security news outlets including GBHackers, CyberSecurityNews, SecurityOnline, and Cyble covered the vulnerability, with several describing it as part of a broader set of critical Django security fixes. CrowdSec tracked the vulnerability and published a vulnerability tracking report. The Emerging Threats community updated its IDS ruleset (v11126 and v11176) to include detection rules for exploitation attempts. Multiple Linux distribution maintainers (Ubuntu, Debian, Fedora, SUSE, Mageia) issued security advisories and package updates in response (Django Security Releases, CrowdSec Report).
Fix availability across major Linux distributions and their releases.
Source: This report was generated using AI
Free Vulnerability Assessment
Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.
Get a personalized demo
"Best User Experience I have ever seen, provides full visibility to cloud workloads."
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
"We know that if Wiz identifies something as critical, it actually is."