{"cve":"CVE-2025-59681","nvd":{"published":"2025-10-01T19:15:36.487","modified":"2026-10-12T15:10:00.207","status":"Modified","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).","cvss_v4":null,"cvss_v3":{"version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","score":9.8},"cwes":["CWE-89"],"references":["https://docs.djangoproject.com/en/dev/releases/security/","https://groups.google.com/g/django-announce","https://www.djangoproject.com/weblog/2025/oct/01/security-releases/","http://www.openwall.com/lists/oss-security/2025/10/01/3"],"products":["djangoproject:django"],"source":"nvd","synced_at":"2026-10-19T22:11:26.888974865+00:00"},"epss":{"cve":"CVE-2025-59681","score":0.00639,"percentile":0.5033,"date":"2026-10-25"},"kev":null,"osv":[{"id":"GHSA-hpr9-3m2g-3j9p","url":"https://osv.dev/vulnerability/GHSA-hpr9-3m2g-3j9p","summary":"Django vulnerable to SQL injection in column aliases","modified":"2026-09-10T03:50:29.812162341Z","packages":[{"ecosystem":"PyPI","name":"django","purl":"pkg:pypi/django","ranges":[">=4.2 <4.2.25"],"fixed":["4.2.25"]},{"ecosystem":"PyPI","name":"django","purl":"pkg:pypi/django","ranges":[">=5.1 <5.1.13"],"fixed":["5.1.13"]},{"ecosystem":"PyPI","name":"django","purl":"pkg:pypi/django","ranges":[">=5.2 <5.2.7"],"fixed":["5.2.7"]}]},{"id":"PYSEC-2025-106","url":"https://osv.dev/vulnerability/PYSEC-2025-106","summary":"","modified":"2026-06-10T17:01:10.861599705Z","packages":[{"ecosystem":"PyPI","name":"django","purl":"pkg:pypi/django","ranges":[">=4.2 <4.2.25",">=5.1 <5.1.13",">=5.2 <5.2.7"],"fixed":["4.2.25","5.1.13","5.2.7"]}]}],"attribution":["This product uses the NVD API but is not endorsed or certified by the NVD.","EPSS scores: FIRST Exploit Prediction Scoring System, https://www.first.org/epss","Known exploited vulnerabilities: CISA Known Exploited Vulnerabilities Catalog, https://www.cisa.gov/known-exploited-vulnerabilities-catalog","Package advisories: OSV (https://osv.dev), from the GitHub Advisory Database, PyPA, Go, RustSec and other ecosystem databases, under CC-BY 4.0 or CC0","CVE records: the CVE Program's CVE List (https://www.cve.org), under its terms of use (https://www.cve.org/Legal/TermsOfUse). CVE is a registered trademark of The MITRE Corporation; this product is not affiliated with the CVE Program."]}