// For flags

CVE-2023-6597

python: Path traversal on tempfile.TemporaryDirectory

Severity Score

7.8
*CVSS v3.1

Exploit Likelihood

*EPSS

Affected Versions

*CPE

Public Exploits

0
*Multiple Sources

Exploited in Wild

-
*KEV

Decision

Track
*SSVC
Descriptions

An issue was found in the CPython `tempfile.TemporaryDirectory` class affecting versions 3.12.1, 3.11.7, 3.10.13, 3.9.18, and 3.8.18 and prior.

The tempfile.TemporaryDirectory class would dereference symlinks during cleanup of permissions-related errors. This means users which can run privileged programs are potentially able to modify permissions of files referenced by symlinks in some circumstances.

Se encontró un problema en la clase CPython `tempfile.TemporaryDirectory` que afecta a las versiones 3.12.2, 3.11.8, 3.10.13, 3.9.18 y 3.8.18 y anteriores. La clase tempfile.TemporaryDirectory eliminaría la referencia a enlaces simbólicos durante la limpieza de errores relacionados con permisos. Esto significa que los usuarios que pueden ejecutar programas privilegiados pueden modificar los permisos de los archivos a los que hacen referencia los enlaces simbólicos en algunas circunstancias.

A flaw was found in the tempfile.TemporaryDirectory class in python3/cpython3. The class may dereference symbolic links during permission-related errors, resulting in users that run privileged programs being able to modify permissions of files referenced by the symbolic link.

*Credits: N/A
CVSS Scores
Attack Vector
Local
Attack Complexity
High
Privileges Required
None
User Interaction
None
Scope
Changed
Confidentiality
High
Integrity
High
Availability
None
* Common Vulnerability Scoring System
SSVC
  • Decision:Track
Exploitation
None
Automatable
No
Tech. Impact
Partial
* Organization's Worst-case Scenario
Timeline
  • 2023-12-07 CVE Reserved
  • 2024-03-19 CVE Published
  • 2024-06-11 EPSS Updated
  • 2024-08-02 CVE Updated
  • ---------- Exploited in Wild
  • ---------- KEV Due Date
  • ---------- First Exploit
CWE
  • CWE-61: UNIX Symbolic Link (Symlink) Following
CAPEC
Affected Vendors, Products, and Versions
Vendor Product Version Other Status
Vendor Product Version Other Status <-- --> Vendor Product Version Other Status
Python Software Foundation
Search vendor "Python Software Foundation"
CPython
Search vendor "Python Software Foundation" for product "CPython"
< 3.8.19
Search vendor "Python Software Foundation" for product "CPython" and version " < 3.8.19"
en
Affected
Python Software Foundation
Search vendor "Python Software Foundation"
CPython
Search vendor "Python Software Foundation" for product "CPython"
>= 3.9.0 < 3.9.19
Search vendor "Python Software Foundation" for product "CPython" and version " >= 3.9.0 < 3.9.19"
en
Affected
Python Software Foundation
Search vendor "Python Software Foundation"
CPython
Search vendor "Python Software Foundation" for product "CPython"
>= 3.10.0 < 3.10.14
Search vendor "Python Software Foundation" for product "CPython" and version " >= 3.10.0 < 3.10.14"
en
Affected
Python Software Foundation
Search vendor "Python Software Foundation"
CPython
Search vendor "Python Software Foundation" for product "CPython"
>= 3.11.0 < 3.11.8
Search vendor "Python Software Foundation" for product "CPython" and version " >= 3.11.0 < 3.11.8"
en
Affected
Python Software Foundation
Search vendor "Python Software Foundation"
CPython
Search vendor "Python Software Foundation" for product "CPython"
>= 3.12.0 < 3.12.1
Search vendor "Python Software Foundation" for product "CPython" and version " >= 3.12.0 < 3.12.1"
en
Affected