CVE-2026-22702

virtualenv Has TOCTOU Vulnerabilities in Directory Creation

State
Published
Severity
4.5 Medium
Published
Jan 10, 2026
Updated
Jan 12, 2026
Reserved
Jan 8, 2026

Read the record on cve.org

Description

virtualenv is a tool for creating isolated virtual python environments. Prior to version 20.36.1, TOCTOU (Time-of-Check-Time-of-Use) vulnerabilities in virtualenv allow local attackers to perform symlink-based attacks on directory creation operations. An attacker with local access can exploit a race condition between directory existence checks and creation to redirect virtualenv's app_data and lock file operations to attacker-controlled locations. This issue has been patched in version 20.36.1.

Scores

CVSSScoreVectorSource
3.14.5 MediumCVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:L/I:L/A:LGitHub_M

Weaknesses

  • CWE-59 Improper Link Resolution Before File Access ('Link Following')
  • CWE-362 Concurrent Execution using Shared Resource with Improper Synchronization ('Race Condition')

Affected Products

ProductVersions
virtualenvpypa
  • < 20.36.1Affected

References

Every record here comes from the CVE Program’s CVE List. © 1999–2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.