CVE-2023-46695 Django potential denial of service vulnerability in UsernameField on Windows
Attackers can cause denial of service in Django applications on Windows by submitting inputs with many Unicode characters, triggering slow NFKC normalization.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2023-46695?
CVE-2023-46695 is a high-severity denial of service vulnerability in Djangoproject Django, published on 2 Nov 2023. An attacker can exploit it over the internet without logging in, with no action from the victim.
Official description
An issue was discovered in Django 3.2 before 3.2.23, 4.1 before 4.1.13, and 4.2 before 4.2.7. The NFKC normalization is slow on Windows. As a consequence, django.contrib.auth.forms.UsernameField is subject to a potential DoS (denial of service) attack via certain inputs with a very large number of Unicode characters.
Weakness: CWE-770
Which versions are affected by CVE-2023-46695?
8 open source packages ship an affected version, including django and Django. It affects 1 product.
| Package | Affected | Fixed in |
|---|---|---|
django Bitnami | From 3.2.0 | 3.2.23, 4.1.13, 4.2.7 |
django PyPI | From 3.2 | 3.2.23, 4.1.13, 4.2.7 |
django PyPI | From 3.2a1 | 3.2.23 |
django PyPI | From 4.1a1 | 4.1.13 |
django PyPI | From 4.2a1 | 4.2.7 |
Django PyPI | From 3.2a1 | 3.2.23 |
2 more packages
Django PyPI | From 4.1a1 | 4.1.13 |
Django PyPI | From 4.2a1 | 4.2.7 |
Products include Djangoproject Django.
How do I fix CVE-2023-46695?
Upgrade django to a fixed version for your release line: 3.2.23, 4.1.13 or 4.2.7.
Upgrade, then put limits on request size, rate and nesting depth so one client cannot exhaust the service. More about Denial of service.
Is CVE-2023-46695 being exploited?
There is no known exploitation of CVE-2023-46695 in the wild and no public exploit code.
Other vulnerabilities in Djangoproject Django
- CVE-2026-4277 Privilege abuse in GenericInlineModelAdmin
- CVE-2024-53908 Django SQL injection in HasKey(lhs, rhs) on Oracle
- CVE-2024-42005 Django SQL injection vulnerability
- CVE-2023-31047 Django bypasses validation when using one form field to upload multiple files
- CVE-2022-34265 Django `Trunc()` and `Extract()` database functions vulnerable to SQL Injection
Sources
Also known as BIT-django-2023-46695, GHSA-qmf9-6jqf-j8fq, OESA-2023-1846, PYSEC-2023-222.