Skip to content

fix: set Django minimum version to 4.2.26 to address CVE-2025-64459 and CVE-2025-57833#85

Open
maycuatroi1 wants to merge 1 commit intoopenstack:masterfrom
maycuatroi1:fix/cve-2025-64459-django-minimum-version
Open

fix: set Django minimum version to 4.2.26 to address CVE-2025-64459 and CVE-2025-57833#85
maycuatroi1 wants to merge 1 commit intoopenstack:masterfrom
maycuatroi1:fix/cve-2025-64459-django-minimum-version

Conversation

@maycuatroi1
Copy link

What

Bumps the Django lower bound from >=4.2 to >=4.2.26 in requirements.txt.

Why

The current constraint Django>=4.2,<4.3 allows installing versions affected by two SQL injection CVEs.

CVE-2025-64459 (CVSS 9.1)

SQL injection via Q() and QuerySet.filter() keyword argument unpacking. If _connector or _negated are present as keys in user-controlled input passed to these methods, an attacker can manipulate the generated SQL WHERE clause. This enables authentication bypass and unauthorized data access.

Fixed in Django 4.2.26, 5.1.14, 5.2.8.

CVE-2025-57833 (CVSS high)

SQL injection via FilteredRelation alias injection through QuerySet.annotate() and QuerySet.alias(). Fixed in Django 4.2.24, 5.1.12, 5.2.6.

Setting >=4.2.26 covers both CVEs for the 4.2.x branch.

Change

- Django>=4.2,<4.3 # BSD
+ Django>=4.2.26,<4.3 # BSD

References:

CVE-2025-57833

The current lower bound Django>=4.2,<4.3 allows installing versions
vulnerable to two SQL injection CVEs:

CVE-2025-64459 (CVSS 9.1): SQL injection via Q() and QuerySet.filter()
keyword argument unpacking. When _connector or _negated are passed as
keys, an attacker can manipulate the WHERE clause logic, enabling
authentication bypass and data exfiltration. Fixed in 4.2.26.

CVE-2025-57833 (CVSS high): SQL injection via FilteredRelation alias
injection in QuerySet.annotate() and QuerySet.alias(). Fixed in 4.2.24.

Bumping to >=4.2.26 ensures both CVEs are addressed under the 4.2.x branch.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant