CVE-2025-59682Djangoproject Django
Medium 6.5
Follow: this CVE · Djangoproject · Djangoproject Django We alert you by email or Slack (account required).
- Priority
- 39
- CVSS 3.1
- 6.5
- EPSS
- —
- Auth required
- Yes
- Published
- Oct 1, 2025
- Updated
- Oct 12, 2026
- Category
- Application · Cross-platform
- Weakness (CWE)
- CWE-23
- SSVC (CISA)
- Exploitation: none · Automatable: no · Technical impact: partial
- Vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N
What happens
An issue was discovered in Django 4.2 before 4.2.25, 5.1 before 5.1.13, and 5.2 before 5.2.7. The django.utils.archive.extract() function, used by the "startapp --template" and "startproject --template" commands, allows partial directory traversal via an archive with file paths sharing a common prefix with the target directory.
What to do
- Apply the vendor's security update for Django.
Affected packages
| Ecosystem | Package | Affected versions | Fixed in | How to upgrade |
|---|---|---|---|---|
| PyPI | django |
≥ 4.2 < 4.2.25 |
4.2.25 |
pip install "django>=4.2.25" |
| PyPI | django |
≥ 5.1 < 5.1.13 |
5.1.13 |
pip install "django>=5.1.13" |
| PyPI | django |
≥ 5.2 < 5.2.7 |
5.2.7 |
pip install "django>=5.2.7" |
| PyPI | django |
≥ 4.2 < 4.2.25 |
4.2.25 |
pip install "django>=4.2.25" |
| PyPI | django |
≥ 5.1 < 5.1.13 |
5.1.13 |
pip install "django>=5.1.13" |
| PyPI | django |
≥ 5.2 < 5.2.7 |
5.2.7 |
pip install "django>=5.2.7" |
Per OSV / GitHub Advisories (GHSA-q95w-c7qg-hrff, PYSEC-2026-1296). Check the version in your lockfile before upgrading.
Affected products (CPE)
| Vendor | Product | Versions |
|---|---|---|
| djangoproject | django | ≥ 4.2.0 < 4.2.25 |
| djangoproject | django | ≥ 5.1 < 5.1.13 |
| djangoproject | django | ≥ 5.2 < 5.2.7 |
Official advisories
- python313-Django5-5.2.16-1.1 on GA media · SUSE · openSUSE-SU-2026:11270-1 · Jul 14, 2026 Critical
- python312-Django6-6.0-1.1 on GA media · SUSE · openSUSE-SU-2026:10005-1 · Jan 3, 2026 Critical
Vendor, CERT and distribution advisories that name this CVE. Original titles.
Official sources
References
Links published by the sources. Open them with care.
- docs.djangoproject.com Vendor Advisory
- groups.google.com Release Notes Vendor Advisory
- www.djangoproject.com Release Notes Vendor Advisory
- www.openwall.com