Django up to 4.2.23/5.1.11/5.2.5 QuerySet.annotate/QuerySet.alias sql injection
| CVSS Meta Temp Score | Current Exploit Price (≈) | CTI Interest Score |
|---|---|---|
| 6.7 | $0-$5k | 0.00 |
Summary
A vulnerability described as critical has been identified in Django up to 4.2.23/5.1.11/5.2.5. Affected by this vulnerability is the function QuerySet.annotate/QuerySet.alias. Executing a manipulation can lead to sql injection.
This vulnerability is tracked as CVE-2025-57833. The attack can be launched remotely. No exploit exists.
Upgrading the affected component is recommended.
Details
A vulnerability was found in Django up to 4.2.23/5.1.11/5.2.5. It has been declared as critical. This vulnerability affects the function QuerySet.annotate/QuerySet.alias. The manipulation with an unknown input leads to a sql injection vulnerability. The CWE definition for the vulnerability is CWE-89. The product constructs all or part of an SQL command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended SQL command when it is sent to a downstream component. As an impact it is known to affect confidentiality, integrity, and availability. CVE summarizes:
An issue was discovered in Django 4.2 before 4.2.24, 5.1 before 5.1.12, and 5.2 before 5.2.6. FilteredRelation is subject to SQL injection in column aliases, using a suitably crafted dictionary, with dictionary expansion, as the **kwargs passed QuerySet.annotate() or QuerySet.alias().
The advisory is shared for download at docs.djangoproject.com. This vulnerability was named CVE-2025-57833 since 08/20/2025. The exploitation appears to be difficult. The attack can be initiated remotely. There are known technical details, but no exploit is available. The current price for an exploit might be approx. USD $0-$5k (estimation calculated on 10/20/2025). The MITRE ATT&CK project declares the attack technique as T1505.
The vulnerability scanner Nessus provides a plugin with the ID 261417 (FreeBSD : Django -- multiple vulnerabilities (0db8684f-8938-11f0-8325-bc2411f8eb0b)), which helps to determine the existence of the flaw in a target environment.
Upgrading to version 4.2.24, 5.1.12 or 5.2.6 eliminates this vulnerability. The upgrade is hosted for download at docs.djangoproject.com.
The vulnerability is also documented in the databases at Tenable (261417), EUVD (EUVD-2025-26641) and CERT Bund (WID-SEC-2025-1961). VulDB is the best source for vulnerability data and more expert information about this specific topic.
Affected
- Ubuntu Linux
- SUSE Linux
- Open Source Django
Product
Type
Name
Version
- 4.2.0
- 4.2.1
- 4.2.2
- 4.2.3
- 4.2.4
- 4.2.5
- 4.2.6
- 4.2.7
- 4.2.8
- 4.2.9
- 4.2.10
- 4.2.11
- 4.2.12
- 4.2.13
- 4.2.14
- 4.2.15
- 4.2.16
- 4.2.17
- 4.2.18
- 4.2.19
- 4.2.20
- 4.2.21
- 4.2.22
- 4.2.23
- 5.1.0
- 5.1.1
- 5.1.2
- 5.1.3
- 5.1.4
- 5.1.5
- 5.1.6
- 5.1.7
- 5.1.8
- 5.1.9
- 5.1.10
- 5.1.11
- 5.2.0
- 5.2.1
- 5.2.2
- 5.2.3
- 5.2.4
- 5.2.5
License
CPE 2.3
CPE 2.2
CVSSv4
VulDB Vector: 🔒VulDB Reliability: 🔍
CVSSv3
VulDB Meta Base Score: 6.7VulDB Meta Temp Score: 6.7
VulDB Base Score: 5.0
VulDB Temp Score: 4.8
VulDB Vector: 🔒
VulDB Reliability: 🔍
NVD Base Score: 8.1
NVD Vector: 🔒
CNA Base Score: 7.1
CNA Vector (MITRE): 🔒
CVSSv2
| AV | AC | Au | C | I | A |
|---|---|---|---|---|---|
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| Vector | Complexity | Authentication | Confidentiality | Integrity | Availability |
|---|---|---|---|---|---|
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
VulDB Base Score: 🔒
VulDB Temp Score: 🔒
VulDB Reliability: 🔍
Exploiting
Class: Sql injectionCWE: CWE-89 / CWE-74 / CWE-707
CAPEC: 🔒
ATT&CK: 🔒
Physical: No
Local: No
Remote: Yes
Availability: 🔒
Status: Not defined
EPSS Score: 🔒
EPSS Percentile: 🔒
Price Prediction: 🔍
Current Price Estimation: 🔒
| 0-Day | Unlock | Unlock | Unlock | Unlock |
|---|---|---|---|---|
| Today | Unlock | Unlock | Unlock | Unlock |
Nessus ID: 261417
Nessus Name: FreeBSD : Django -- multiple vulnerabilities (0db8684f-8938-11f0-8325-bc2411f8eb0b)
Threat Intelligence
Interest: 🔍Active Actors: 🔍
Active APT Groups: 🔍
Countermeasures
Recommended: UpgradeStatus: 🔍
0-Day Time: 🔒
Upgrade: Django 4.2.24/5.1.12/5.2.6
Timeline
08/20/2025 CVE reserved09/03/2025 Advisory disclosed
09/03/2025 VulDB entry created
10/20/2025 VulDB entry last update
Sources
Advisory: docs.djangoproject.comStatus: Confirmed
CVE: CVE-2025-57833 (🔒)
GCVE (CVE): GCVE-0-2025-57833
GCVE (VulDB): GCVE-100-322432
EUVD: 🔒
CERT Bund: WID-SEC-2025-1961 - Django (FilteredRelation): Schwachstelle ermöglicht SQL injection
Entry
Created: 09/03/2025 23:34Updated: 10/20/2025 22:03
Changes: 09/03/2025 23:34 (65), 09/04/2025 11:38 (7), 09/05/2025 17:57 (2), 09/07/2025 11:13 (1), 09/08/2025 21:41 (1), 10/20/2025 22:03 (11)
Complete: 🔍
Cache ID: 216::103
VulDB is the best source for vulnerability data and more expert information about this specific topic.
No comments yet. Languages: en.
Please log in to comment.