CVE-2026-1287: Potential SQL injection in column aliases via control characters

Published Feb 3, 2026
·
Updated

An issue was discovered in 6.0 before 6.0.2, 5.2 before 5.2.11, and 4.2 before 4.2.28.

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(), valueslist(), and alias(). 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 Solomon Kebede for reporting this issue.

Affected Software

19 affected componentsFixes available
pypi/django<6.0.2, <5.2.11, <4.2.28
pip/django>=4.2a1<4.2.28
4.2.28
pip/django>=5.2a1<5.2.11
5.2.11
pip/django>=6.0a1<6.0.2
6.0.2
djangoproject Django>=4.2<4.2.28
djangoproject Django>=5.2<5.2.11
djangoproject Django>=6.0<6.0.2
alpine/py3-django<4.2.28-r0
4.2.28-r0
alpine/py3-django<4.2.28-r0
4.2.28-r0
IBM API Connect<=V10.0.8.0 - V10.0.8.13
ubuntu/python-django<1.6.11-0ubuntu1.3+esm10
1.6.11-0ubuntu1.3+esm10
ubuntu/python-django<1.8.7-1ubuntu5.15+esm11
1.8.7-1ubuntu5.15+esm11
ubuntu/python-django<1:1.11.11-1ubuntu1.21+esm14
1:1.11.11-1ubuntu1.21+esm14
ubuntu/python-django<2:2.2.12-1ubuntu0.29+esm7
2:2.2.12-1ubuntu0.29+esm7
ubuntu/python-django<2:3.2.12-2ubuntu1.25
2:3.2.12-2ubuntu1.25
ubuntu/python-django<3:4.2.11-1ubuntu1.14
3:4.2.11-1ubuntu1.14
ubuntu/python-django<3:5.2.4-1ubuntu2.3
3:5.2.4-1ubuntu2.3
ubuntu/python-django<3:5.2.9-0ubuntu3
3:5.2.9-0ubuntu3
debian/python-django
2:2.2.28-1~deb11u123:3.2.25-0+deb12u23:4.2.28-0+deb13u13:4.2.28-1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade pip/Django to a version that resolves this vulnerability.

    Fixed in 4.2.28
  2. Upgrade

    Upgrade pip/Django to a version that resolves this vulnerability.

    Fixed in 5.2.11
  3. Upgrade

    Upgrade pip/Django to a version that resolves this vulnerability.

    Fixed in 6.0.2
  4. Upgrade

    Upgrade alpine/py3-django to a version that resolves this vulnerability.

    Fixed in 4.2.28-r0
  5. Upgrade

    Upgrade ubuntu/python-django to a version that resolves this vulnerability.

    Fixed in 1.6.11-0ubuntu1.3+esm10
  6. Upgrade

    Upgrade ubuntu/python-django to a version that resolves this vulnerability.

    Fixed in 1.8.7-1ubuntu5.15+esm11
  7. Upgrade

    Upgrade ubuntu/python-django to a version that resolves this vulnerability.

    Fixed in 1:1.11.11-1ubuntu1.21+esm14
  8. Upgrade

    Upgrade ubuntu/python-django to a version that resolves this vulnerability.

    Fixed in 2:2.2.12-1ubuntu0.29+esm7
  9. Upgrade

    Upgrade ubuntu/python-django to a version that resolves this vulnerability.

    Fixed in 2:3.2.12-2ubuntu1.25
  10. Upgrade

    Upgrade ubuntu/python-django to a version that resolves this vulnerability.

    Fixed in 3:4.2.11-1ubuntu1.14
  11. Upgrade

    Upgrade ubuntu/python-django to a version that resolves this vulnerability.

    Fixed in 3:5.2.4-1ubuntu2.3
  12. Upgrade

    Upgrade ubuntu/python-django to a version that resolves this vulnerability.

    Fixed in 3:5.2.9-0ubuntu3
  13. Upgrade

    Upgrade debian/python-django to a version that resolves this vulnerability.

    Fixed in 2:2.2.28-1~deb11u12Fixed in 3:3.2.25-0+deb12u2Fixed in 3:4.2.28-0+deb13u1Fixed in 3:4.2.28-1

Event History

Feb 3, 2026
CVE Published
via OSV·02:00 PM
Data Sourced
via OSV·02:00 PM
DescriptionSeverityAffected Software
CVE Published
via MITRE·02:36 PM
Data Sourced
via MITRE·02:36 PM
DescriptionWeakness
Data Sourced
via Red Hat·03:01 PM
DescriptionSeverityAffected Software
Data Sourced
via NVD·03:16 PM
DescriptionWeakness
Advisory Published
via GitHub·03:30 PM
Data Sourced
via GitHub·03:30 PM
DescriptionWeaknessAffected Software
Data Sourced
via NVD·05:15 PM
Severity
Feb 4, 2026
Data Sourced
via NVD·05:35 PM
RemedyAffected Software
Feb 9, 2026
News Published
via The Hacker News·12:59 PM
Jun 30, 2026
Updated
via NVD·03:17 AM
SeverityWeakness
Event
via NVD·03:17 AM
Jul 15, 2026
Updated
via NVD·02:18 AM
SeverityWeakness
Nov 10, 2026
Data Sourced
via IBM·12:00 AM
DescriptionAffected Software
Nov 18, 2026
Updated
via IBM·12:00 AM
Affected Software

Parent advisories

This vulnerability appears in the following advisories.

Peer vulnerabilities

Found alongside the following vulnerabilities.

Frequently Asked Questions

1

What is the severity of CVE-2026-1287?

CVE-2026-1287 has a critical severity due to its potential for SQL injection vulnerability.

2

How do I fix CVE-2026-1287?

You can fix CVE-2026-1287 by upgrading to Django version 6.0.2, 5.2.11, or 4.2.28.

3

What versions of Django are affected by CVE-2026-1287?

CVE-2026-1287 affects Django versions prior to 6.0.2, 5.2.11, and 4.2.28.

4

What kind of attack can CVE-2026-1287 facilitate?

CVE-2026-1287 can facilitate SQL injection attacks through improperly handled control characters in column aliases.

5

Is my application vulnerable to CVE-2026-1287?

If your application uses Django versions earlier than 6.0.2, 5.2.11, or 4.2.28, it is likely vulnerable to CVE-2026-1287.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203