CVE-2026-113721

GHSA-558c-9hv2-4prj · PYSEC-2026-4380 · published 20 Oct 2026 · updated 18 Nov 2026

virtualenv: Generated files can follow existing destination links

5.5MediumCVSS 4.5EPSS 0%1 public exploits

A public exploit exists; no exploitation in the wild has been reported. EPSS puts the chance of exploitation in the next 30 days at 0%. Fixed in 21.14.9 and virtualenv 21.14.9.

virtualenv is a tool for creating isolated virtual python environments. Prior to 21.14.9, ViaTemplateActivator._generate() removes an existing output only when Path.exists() is true, allowing a dangling symlink to survive and redirect generated activation content, while PyEnvCfg.write() opens pyvenv.cfg without first replacing an existing symbolic or hard link. Another local account that prepares final entries inside the destination can therefore cause environment creation to create or overwrite files outside the requested tree with constrained virtualenv-generated content and the invoking user's permissions. The destination parent must remain controlled by the environment owner during creation; concurrent parent-directory replacement is a separate concern. This issue is fixed in version 21.14.9.

Affected

Vendors, products and packages with version ranges

VendorProductVersionsFixed
pypa<21.14.9
virtualenvvirtualenv>=20.0.0 <21.14.921.14.9
pypi: virtualenv<21.14.9, >=20.0.0 <21.14.921.14.9

Exploit evidence

1 public sources

Timeline

Every event on this vulnerability

Related

Other vulnerabilities in virtualenv (PyPI), strongest first

Embed

A live severity badge for an advisory, README or ticket

CVE-2026-113721 severity on Zeptric[![CVE-2026-113721](https://zeptric.io/badge/cve/CVE-2026-113721.svg)](https://zeptric.io/cve/CVE-2026-113721)