An issue was discovered in Django 3.2 before 3.2.14 and 4.0 before 4.0.6. The Trunc() and Extract() database functions are subject to SQL injection if untrusted data is used as a kind/lookup_name value. Applications that constrain the lookup name and kind choice to a known safe list are unaffected.
https://www.djangoproject.com/weblog/2022/jul/04/security-releases/
https://docs.djangoproject.com/en/4.0/releases/security/
https://groups.google.com/forum/#!forum/django-announce
https://security.netapp.com/advisory/ntap-20220818-0006/
Source: MITRE
Published: 2022-07-04
Updated: 2023-04-28
Type: CWE-89
Base Score: 7.5
Vector: AV:N/AC:L/Au:N/C:P/I:P/A:P
Impact Score: 6.4
Exploitability Score: 10
Severity: HIGH
Base Score: 9.8
Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Impact Score: 5.9
Exploitability Score: 3.9
Severity: CRITICAL