Path traversal in Django

Published: 2021-02-01 | Updated: 2021-07-05
Risk High
Patch available YES
Number of vulnerabilities 1
CVE-ID CVE-2021-3281
Exploitation vector Network
Public exploit Public exploit code for vulnerability #1 is available.
Vulnerable software
Web applications / CMS

Vendor Django Software Foundation

Security Bulletin

This security bulletin contains one high risk vulnerability.

1) Path traversal

EUVDB-ID: #VU50172

Risk: High


CVE-ID: CVE-2021-3281

CWE-ID: CWE-22 - Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')

Exploit availability: Yes


The vulnerability allows a remote attacker to perform directory traversal attacks.

The vulnerability exists due to input validation error when processing directory traversal sequences inside archives with "django.utils.archive.extract()" function. A remote attacker can pass specially crafted archive to the application and write files to arbitrary directory on the system.


Install update from vendor's website.

Vulnerable software versions

Django: 3.0 - 3.1.5, 2.2 - 2.2.17

CPE2.3 External links

Q & A

Can this vulnerability be exploited remotely?

Is there known malware, which exploits this vulnerability?