Critical severityNVD Advisory· Published Nov 5, 2025· Updated Feb 26, 2026
Potential SQL injection via _connector keyword argument in QuerySet and Q objects
CVE-2025-64459
Description
An issue was discovered in 5.1 before 5.1.14, 4.2 before 4.2.26, and 5.2 before 5.2.8. The methods QuerySet.filter(), QuerySet.exclude(), and QuerySet.get(), and the class Q(), are subject to SQL injection when using a suitably crafted dictionary, with dictionary expansion, as the _connector argument. 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 cyberstan for reporting this issue.
AI Insight
LLM-synthesized narrative grounded in this CVE's description and references.
Affected packages
Versions sourced from the GitHub Security Advisory.
| Package | Affected versions | Patched versions |
|---|---|---|
djangoPyPI | >= 5.2a1, < 5.2.8 | 5.2.8 |
djangoPyPI | >= 5.0a1, < 5.1.14 | 5.1.14 |
djangoPyPI | < 4.2.26 | 4.2.26 |
Affected products
10- osv-coords9 versionspkg:bitnami/djangopkg:pypi/djangopkg:rpm/opensuse/python-Django4&distro=openSUSE%20Tumbleweedpkg:rpm/opensuse/python-Django6&distro=openSUSE%20Tumbleweedpkg:rpm/opensuse/python-Django&distro=openSUSE%20Leap%2015.6pkg:rpm/opensuse/python-Django&distro=openSUSE%20Leap%2016.0pkg:rpm/opensuse/python-Django&distro=openSUSE%20Tumbleweedpkg:rpm/suse/python-Django&distro=SUSE%20Linux%20Enterprise%20Module%20for%20Package%20Hub%2015%20SP6pkg:rpm/suse/python-Django&distro=SUSE%20Linux%20Enterprise%20Module%20for%20Package%20Hub%2015%20SP7
>= 4.2.0, < 4.2.26+ 8 more
- (no CPE)range: >= 4.2.0, < 4.2.26
- (no CPE)range: >= 5.2a1, < 5.2.8
- (no CPE)range: < 4.2.26-1.1
- (no CPE)range: < 6.0-1.1
- (no CPE)range: < 4.2.11-150600.3.41.1
- (no CPE)range: < 5.2.4-bp160.4.1
- (no CPE)range: < 5.2.8-1.1
- (no CPE)range: < 4.2.11-150600.3.41.1
- (no CPE)range: < 4.2.11-150600.3.41.1
- Range: 5.2
Patches
Vulnerability mechanics
References
13- docs.djangoproject.com/en/dev/releases/security/mitrevendor-advisory
- github.com/advisories/GHSA-frmv-pr5f-9mcrghsaADVISORY
- nvd.nist.gov/vuln/detail/CVE-2025-64459ghsaADVISORY
- www.djangoproject.com/weblog/2025/nov/05/security-releases/mitrevendor-advisory
- docs.djangoproject.com/en/dev/releases/securityghsaWEB
- github.com/django/django/commit/06dd38324ac3d60d83d9f3adabf0dcdf423d2a85ghsaWEB
- github.com/django/django/commit/59ae82e67053d281ff4562a24bbba21299f0a7d4ghsaWEB
- github.com/django/django/commit/6703f364d767e949c5b0e4016433ef75063b4f9bghsaWEB
- github.com/django/django/commit/72d2c87431f2ae0431d65d0ec792047f078c8241ghsaWEB
- github.com/pypa/advisory-database/tree/main/vulns/django/PYSEC-2025-108.yamlghsaWEB
- groups.google.com/g/django-announceghsamailing-listWEB
- shivasurya.me/security/django/2025/11/07/django-sql-injection-CVE-2025-64459.htmlghsaWEB
- www.djangoproject.com/weblog/2025/nov/05/security-releasesghsaWEB
News mentions
0No linked articles in our index yet.