Cyber Resilience

CVE-2023-31047

Access Control in Djangoproject Django 3.2 – 3.2.19

Published
07 May 2023
Modified
29 January 2025
Patch / advisory
CVSS Score v3.1 9.8
Click a component to see what it means
Raw vectorCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
EPSS Score 0.014 70th percentile
Risk Priority 74 floored blend · peak EPSS

Summary

CVE-2023-31047 is a critical-severity Improper Input Validation (CWE-20) vulnerability in Djangoproject Django. Its CVSS base score is 9.8 (Critical).

Operationally, exploitation aligns with the MITRE ATT&CK technique Exploitation for Privilege Escalation (T1068); ranked in the top 30% of CVEs by exploit likelihood; it is not currently listed in the CISA KEV catalog.

OWASP Top 10 for Web (2025)

EU & UK References

Vulnerability Data

In Django 3.2 before 3.2.19, 4.x before 4.1.9, and 4.2 before 4.2.1, it was possible to bypass validation when using one form field to upload multiple files. This multiple upload has never been supported by forms.FileField or forms.ImageField (only the…

more

last uploaded file was validated). However, Django's "Uploading multiple files" documentation suggested otherwise.

CWE(s)

Related Threats

MITRE ATT&CK Enterprise Techniques

T1068 Exploitation for Privilege Escalation Privilege Escalation
Adversaries may exploit software vulnerabilities in an attempt to elevate privileges.
T1190 Exploit Public-Facing Application Initial Access
Adversaries may attempt to exploit a weakness in an Internet-facing host or system to initially access a network.
T1210 Exploitation of Remote Services Lateral Movement
Adversaries may exploit remote services to gain unauthorized access to internal systems once inside of a network.
T1036.001 Invalid Code Signature Stealth
Adversaries may attempt to mimic features of valid code signatures to increase the chance of deceiving a user, analyst, or tool.
T1203 Exploitation for Client Execution Execution
Adversaries may exploit software vulnerabilities in client applications to execute code.
T1548 Abuse Elevation Control Mechanism Privilege Escalation
Adversaries may circumvent mechanisms designed to control privilege elevation to gain higher-level permissions.
Derived from this CVE’s CWE(s) via the direct CWE→ATT&CK cross-walk.

CVEs Like This One

CVE-2023-43090Same product: Fedoraproject Fedora
CVE-2021-37976Same product: Fedoraproject Fedora
CVE-2023-3770Shared CWE-20, CWE-862
CVE-2021-21978Shared CWE-20, CWE-862
CVE-2021-39226Same product: Fedoraproject Fedora
CVE-2022-4223Same product: Fedoraproject Fedora
CVE-2024-45058Shared CWE-20, CWE-862
CVE-2025-43838Shared CWE-862
CVE-2023-7268Shared CWE-862
CVE-2024-1158Shared CWE-862

Affected Assets

djangoproject
django
4.2 · 3.2 — 3.2.19 · 4.0 — 4.1.9
fedoraproject
fedora
38

Mitigating Controls

Control response

Prevent
Stop it (NIST 800-53)

Detect
Catch it (NIST detect / respond)

Harden
Shrink the surface (DISA STIG)
  • 11 hardening rules · 3 OS baselines
Validate
Prove the fix (OWASP ASVS)

Likely Mitigating Controls AI

Per-CVE control mapping for this CVE has not run yet; the list below is derived from the weakness types (CWEs) cited in the NVD entry.

addresses: CWE-862

Requiring an access control policy ensures authorization checks are defined and applied for critical functions.

addresses: CWE-862

Reviews of access controls detect missing authorization checks on critical functions or resources.

addresses: CWE-862

Documenting permitted unauthenticated actions prevents missing authorization by making all exceptions explicit and subject to organizational review.

addresses: CWE-862

Requiring attribute association with information prevents authorization from being performed without necessary security or privacy context.

addresses: CWE-862

Mandating authorization prior to allowing remote connections addresses missing authorization for remote access.

addresses: CWE-862

Mandating authorization before wireless connections are allowed prevents missing authorization for wireless access.

addresses: CWE-862

The control requires authorization before allowing mobile device connections, directly mitigating missing authorization for system access.

addresses: CWE-862

Requiring approvals for account creation and specifying authorizations ensures authorization is not missing for system access.

Mitigating Controls (NIST CSF 2.0) AI

Derived directly from the weakness types (CWEs) cited in the NVD entry via our AI-authored CWE→CSF cross-walk (authority under review) — links open the control.

PR.AA-05 full match
prevents

Explicitly requires defining, enforcing, and reviewing authorizations and least privilege, directly preventing missing authorization checks.

PR.PS-06 mostly match
prevents

Secure SDLC practices directly require and enforce input validation during development.

Mitigating Controls (ISO/IEC 27001:2022 Annex A) AI

Derived directly from the weakness types (CWEs) cited in the NVD entry via our AI-authored CWE→ISO cross-walk (authority under review) — links open the control.

finds

Testing against a defined set of requirements and using code review plus vulnerability scanning forces validation of inputs and handling of unanticipated conditions, reducing the chance that malformed data will be accepted.

prevents

Requiring authentication and credentials before any access occurs eliminates the absence of authorization checks that would otherwise allow an unauthenticated actor to reach protected resources.

prevents

Requiring formal authorization of every access request before rights are granted ensures that checks for required permissions are performed, preventing missing authorization checks from being introduced.

prevents

Mandatory authorization checks and central records of granted rights ensure that every access attempt is preceded by an explicit decision rather than relying on missing checks.

mitigates

Segregating the approval of access rights from their implementation provides an independent check that reduces the impact of missing authorization checks in the resulting system configuration.

finds

By requiring competent outsiders to verify that every function enforces the need-to-know principle, the control lowers the likelihood that missing authorization checks persist undetected.

Hardening callouts derived

Configuration rules from DISA STIG baselines that bear on weaknesses of the type cited by this CVE. Each rule is shown with the relationship its mapping actually records, against the CWE it was authored against. Derived via CVE→CWE over `controls_xwalks` (authoritative rows only; rows rated `none` are excluded).

Oracle Linux 8 (2 rules)
  • V-248581 OL 8 must require users to provide a password for privilege escalation. prevents CWE-862
  • V-252656 The OL 8 operating system must not be configured to bypass password requirements for privilege escalation. prevents CWE-862
RHEL 7 (2 rules)
  • V-251704 The Red Hat Enterprise Linux operating system must not be configured to bypass password requirements for privilege escalation. prevents CWE-862
  • V-204429 The Red Hat Enterprise Linux operating system must be configured so that users must provide a password for privilege escalation. prevents CWE-862
RHEL 8 (1 rule)
  • V-230265 RHEL 8 must prevent the installation of software, patches, service packs, device drivers, or operating system components of local packages without verification they have been digitally signed using a certificate that is issued by a Certificate Authority (CA) that is recognized and approved by the organization. prevents CWE-20

References