# CVE-2026-113715: virtualenv stdlib venv creator configuration injection via line-boundary characters

Source: https://junglewise.ai/threats/cve-2026-113715-virtualenv-is-a-tool-for-creating-isolated-virtual-python  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2026-10-20. Updated: 2026-10-20  
License: CC BY 4.0 with a link back

CVE-2026-113715 · Severity: medium · CVSS 4 · Published 2026-10-20

virtualenv is a Python tool that creates isolated virtual environments for development. When using the stdlib venv creator with an untrusted destination path containing line-boundary characters, an attacker can inject configuration keys to weaken environment isolation or redirect which Python standard-library files the interpreter loads, potentially enabling code execution if the attacker controls the target location.

Technologies: [Pypa Virtualenv](https://junglewise.ai/threats/technologies/pypa-virtualenv), [virtualenv (PyPI)](https://junglewise.ai/threats/technologies/virtualenv). Vendors: [Pypa](https://junglewise.ai/threats/vendors/pypa), [PyPI](https://junglewise.ai/threats/vendors/pypi).

## Quick answers

**Is CVE-2026-113715 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2026-113715 being exploited in the wild.

**How severe is CVE-2026-113715?** Medium severity, with a CVSS score of 4, published 20 October 2026.

**Which products and versions are affected?** Pypa Virtualenv prior to 21.14.9; virtualenv (PyPI) < 21.14.9, ECOSYSTEM:introduced=0,fixed=21.14.9.

**Is there a fix for CVE-2026-113715?** Yes. virtualenv (PyPI): upgrade to 21.14.9 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is CVE-2026-113715 attacked?** It is attacked with local access, in a software library.

**Am I affected by CVE-2026-113715?** Check whether you run Pypa Virtualenv or virtualenv (PyPI) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## How to fix

- virtualenv (PyPI): upgrade to 21.14.9 or later

  ```sh
  pip install "virtualenv>=21.14.9"
  ```


## Technical details

The vulnerability exists in the stdlib venv creator's handling of pyvenv.cfg: venv writes a configuration file with the destination path embedded in the command key, but this file is then re-read by virtualenv using str.splitlines() which treats ten different line-boundary characters (including U+2028) as delimiters. An attacker controlling the destination path can inject these characters to split the file and add malicious key-value pairs (such as home or include-system-site-packages) that override virtualenv's intended configuration. The fix rejects destination paths containing line boundaries before filesystem access and rebuilds pyvenv.cfg from the interpreter and virtualenv options alone, without re-reading the stdlib-written file.

## Affected products

- pypa virtualenv prior to 21.14.9

## Identifiers

- CVE-2026-113715
- GHSA-qmx5-4p3x-wvqf

## Timeline

- 2026-10-20: disclosed

## References

- [https://github.com/pypa/virtualenv/commit/b0008a58885ded9227faf8f910c6c402712c750a](https://github.com/pypa/virtualenv/commit/b0008a58885ded9227faf8f910c6c402712c750a)
- [https://github.com/pypa/virtualenv/pull/3426](https://github.com/pypa/virtualenv/pull/3426)

## Related threats

- [virtualenv bash activate command injection via unescaped prompt](https://junglewise.ai/threats/cve-2026-115586-virtualenv-is-a-tool-for-creating-isolated-virtual-python)
- [virtualenv command injection in activation script template substitution](https://junglewise.ai/threats/cve-2026-113776-virtualenv-is-a-tool-for-creating-isolated-virtual-python)
- [virtualenv command injection in Fish shell activation script](https://junglewise.ai/threats/cve-2026-113732-virtualenv-is-a-tool-for-creating-isolated-virtual-python)
- [pypa virtualenv command injection in bash activate script](https://junglewise.ai/threats/cve-2026-113726-virtualenv-is-a-tool-for-creating-isolated-virtual-python)
- [virtualenv bash activate script command injection in PS1](https://junglewise.ai/threats/cve-2026-113725-virtualenv-is-a-tool-for-creating-isolated-virtual-python)
