CVE-2025-59681

State
Published
Severity
7.1 High
Published
Oct 1, 2025
Updated
Nov 4, 2025
Reserved
Sep 18, 2025

Read the record on cve.org

Description

An issue was discovered in Django 4.2 before 4.2.25, 5.1 before 5.1.13, and 5.2 before 5.2.7. QuerySet.annotate(), QuerySet.alias(), QuerySet.aggregate(), and QuerySet.extra() are subject to SQL injection in column aliases, when using a suitably crafted dictionary, with dictionary expansion, as the **kwargs passed to these methods (on MySQL and MariaDB).

Scores

CVSSScoreVectorSource
3.17.1 HighCVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:L/A:Nmitre

Weaknesses

  • CWE-89 Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection')

Affected Products

ProductVersions
Djangodjangoproject
  • 4.2 to before 4.2.25Affected
  • 5.1 to before 5.1.13Affected
  • 5.2 to before 5.2.7Affected

References

Every record here comes from the CVE Program’s CVE List. © 1999–2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.