Skip to content

Django Path Traversal vulnerability

High severity GitHub Reviewed Published Jul 10, 2024 to the GitHub Advisory Database • Updated Jul 10, 2024

Package

Django (pip)

Affected versions

>= 5.0, < 5.0.7
>= 4.2, < 4.2.14

Patched versions

5.0.7
4.2.14

Description

An issue was discovered in Django 5.0 before 5.0.7 and 4.2 before 4.2.14. Derived classes of the django.core.files.storage.Storage base class, when they override generate_filename() without replicating the file-path validations from the parent class, potentially allow directory traversal via certain inputs during a save() call. (Built-in Storage sub-classes are unaffected.)

References

Published by the National Vulnerability Database Jul 10, 2024
Published to the GitHub Advisory Database Jul 10, 2024
Reviewed Jul 10, 2024
Last updated Jul 10, 2024

Severity

High
7.5
/ 10

CVSS base metrics

Attack vector
Network
Attack complexity
Low
Privileges required
None
User interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
None
Availability
None
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N

Weaknesses

CVE ID

CVE-2024-39330

GHSA ID

GHSA-9jmf-237g-qf46

Source code

Loading Checking history
See something to contribute? Suggest improvements for this vulnerability.