{"id":"CVE-2026-1287","summary":"Potential SQL injection in column aliases via control characters","details":"An issue was discovered in 6.0 before 6.0.2, 5.2 before 5.2.11, and 4.2 before 4.2.28.\n`FilteredRelation` is subject to SQL injection in column aliases via control characters, using a suitably crafted dictionary, with dictionary expansion, as the `**kwargs` passed to `QuerySet` methods `annotate()`, `aggregate()`, `extra()`, `values()`, `values_list()`, and `alias()`.\nEarlier, unsupported Django series (such as 5.0.x, 4.1.x, and 3.2.x) were not evaluated and may also be affected.\nDjango would like to thank Solomon Kebede for reporting this issue.","aliases":["BIT-django-2026-1287","GHSA-gvg8-93h5-g6qq","PYSEC-2026-46"],"modified":"2026-07-08T08:12:22.970175986Z","published":"2026-02-03T14:36:03.630Z","related":["CGA-5c9q-6m5j-82rh","SUSE-SU-2026:0440-1","openSUSE-SU-2026:10145-1","openSUSE-SU-2026:10160-1","openSUSE-SU-2026:10247-1","openSUSE-SU-2026:20184-1"],"database_specific":{"cna_assigner":"DSF","cwe_ids":["CWE-89"],"osv_generated_from":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/1xxx/CVE-2026-1287.json"},"references":[{"type":"WEB","url":"https://github.com/django/django/"},{"type":"WEB","url":"https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-1287.json"},{"type":"ADVISORY","url":"https://access.redhat.com/errata/RHSA-2026:14835"},{"type":"ADVISORY","url":"https://access.redhat.com/errata/RHSA-2026:2694"},{"type":"ADVISORY","url":"https://access.redhat.com/errata/RHSA-2026:3958"},{"type":"ADVISORY","url":"https://access.redhat.com/errata/RHSA-2026:3959"},{"type":"ADVISORY","url":"https://access.redhat.com/errata/RHSA-2026:3960"},{"type":"ADVISORY","url":"https://access.redhat.com/errata/RHSA-2026:3962"},{"type":"ADVISORY","url":"https://access.redhat.com/errata/RHSA-2026:5970"},{"type":"ADVISORY","url":"https://access.redhat.com/errata/RHSA-2026:5971"},{"type":"ADVISORY","url":"https://access.redhat.com/errata/RHSA-2026:6291"},{"type":"ADVISORY","url":"https://access.redhat.com/security/cve/CVE-2026-1287"},{"type":"ADVISORY","url":"https://docs.djangoproject.com/en/dev/releases/security/"},{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/1xxx/CVE-2026-1287.json"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-1287"},{"type":"ADVISORY","url":"https://www.djangoproject.com/weblog/2026/feb/03/security-releases/"},{"type":"REPORT","url":"https://bugzilla.redhat.com/show_bug.cgi?id=2436339"},{"type":"PACKAGE","url":"https://pypi.org/project/Django/"},{"type":"ARTICLE","url":"https://groups.google.com/g/django-announce"}],"affected":[{"ranges":[{"type":"GIT","repo":"https://github.com/django/django","events":[{"introduced":"97aa3b7f08f51669e118f3af5ca91026e39664c3"},{"fixed":"20c71f6b91324cf401056c72136c14e0ec2bf7bf"},{"introduced":"9e7cc2b628fe8fd3895986af9b7fc9525034c1b0"},{"fixed":"4a96a199bbb1d3dca45ea16bf643216e179cb8bc"},{"introduced":"36b5f39d9372147f0e758f590e35ee2b2bc317dd"},{"fixed":"ba00558ddac694d92b05d12ecd2a5b7fcc1de025"}],"database_specific":{"source":"CPE_RANGE","cpe":"cpe:2.3:a:djangoproject:django:*:*:*:*:*:*:*:*","extracted_events":[{"introduced":"4.2"},{"fixed":"4.2.28"},{"introduced":"5.2"},{"fixed":"5.2.11"},{"introduced":"6.0"},{"fixed":"6.0.2"}]}}],"versions":["6.0.1","5.2.10","6.0","5.2.9","5.2.8","5.2.7","5.2.6","5.2.5","5.2.4","5.2.3","5.2.2","5.2.1","5.2"],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-1287.json"}}],"schema_version":"1.7.5","severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:N"}]}