Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…

CVE-2026-1207: CWE-89: Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection') in djangoproject Django

0
Medium
VulnerabilityCVE-2026-1207cvecve-2026-1207cwe-89
Published: Tue Feb 03 2026 (02/03/2026, 14:35:33 UTC)
Source: CVE Database V5
Vendor/Project: djangoproject
Product: Django

Description

An issue was discovered in 6.0 before 6.0.2, 5.2 before 5.2.11, and 4.2 before 4.2.28. Raster lookups on ``RasterField`` (only implemented on PostGIS) allows remote attackers to inject SQL via the band index parameter. Earlier, unsupported Django series (such as 5.0.x, 4.1.x, and 3.2.x) were not evaluated and may also be affected. Django would like to thank Tarek Nakkouch for reporting this issue.

AI-Powered Analysis

AILast updated: 02/26/2026, 18:58:48 UTC

Technical Analysis

CVE-2026-1207 is a SQL injection vulnerability classified under CWE-89 that affects the Django web framework's RasterField feature when used with PostGIS databases. Specifically, the vulnerability arises from improper neutralization of special elements in the band index parameter used in raster lookups. This parameter is not adequately sanitized, allowing remote attackers with low privileges to inject arbitrary SQL commands into the database query. The affected Django versions include 6.0 prior to 6.0.2, 5.2 prior to 5.2.11, and 4.2 prior to 4.2.28, with earlier unsupported versions potentially also affected but unevaluated. Exploitation requires network access and some level of privilege (PR:L), but no user interaction is necessary. The impact primarily concerns confidentiality and integrity, as attackers could extract sensitive data or alter database contents through crafted SQL injection payloads. Availability is not impacted. No public exploits are known at this time, but the vulnerability's presence in a widely used web framework and its potential for remote exploitation make it a significant concern. The issue was responsibly disclosed by Tarek Nakkouch and is pending or has patches in the referenced Django versions.

Potential Impact

The vulnerability allows attackers to perform SQL injection attacks remotely on Django applications using the RasterField feature with PostGIS. This can lead to unauthorized disclosure of sensitive geospatial or other database information and potential modification of data, undermining data integrity. Organizations relying on Django for geospatial data processing or mapping services are at risk, especially if they have not applied the security patches. While availability is not directly affected, the breach of confidentiality and integrity can have severe consequences, including data leaks, regulatory non-compliance, and loss of trust. Given Django's widespread use globally, particularly in web applications handling spatial data, the impact can be significant for sectors such as government, urban planning, environmental monitoring, and any enterprise leveraging geospatial analytics. The requirement for low privileges reduces the barrier to exploitation, increasing risk if internal users or compromised accounts exist.

Mitigation Recommendations

1. Upgrade affected Django versions to 6.0.2, 5.2.11, or 4.2.28 or later, where the vulnerability is patched. 2. Review and audit all uses of RasterField in your codebase, especially any custom handling of the band index parameter, to ensure proper input validation and sanitization. 3. Restrict database user privileges to the minimum necessary, limiting the potential damage of SQL injection. 4. Employ Web Application Firewalls (WAFs) with rules targeting SQL injection patterns, particularly those related to PostGIS RasterField queries. 5. Monitor database logs for unusual or suspicious queries involving raster lookups. 6. If immediate patching is not possible, consider disabling or avoiding the use of RasterField features until patched versions are deployed. 7. Educate developers about secure coding practices around database queries and parameter handling in Django applications.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Data Version
5.2
Assigner Short Name
DSF
Date Reserved
2026-01-19T20:14:06.262Z
Cvss Version
null
State
PUBLISHED

Threat ID: 69820d79f9fa50a62fcd6040

Added to database: 2/3/2026, 3:00:09 PM

Last enriched: 2/26/2026, 6:58:48 PM

Last updated: 3/20/2026, 8:33:27 AM

Views: 116

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console in Console -> Billing for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses