Back to list

virtualenv writes prompt values into pyvenv.cfg without sanitizing line boundaries, allowing configuration injection — GHSA-9H9J-4VRJ-GF7G

GitHub · GitHub · GHSA-9H9J-4VRJ-GF7G

ID
GHSA-9H9J-4VRJ-GF7G
Date
Source
GitHub
Vendor
GitHub
Threat
medium
CVSS
5.8

Summary

### Summary `pyvenv.cfg` is a line-based format with no escape syntax. `PyEnvCfg.write()` wrote values verbatim, while `PyEnvCfg._read_values()` parses the file with `str.splitlines()`. A value containing a line boundary therefore became additional configuration lines, and because reading is last-wins, the injected keys replaced any key written earlier in the file. ### Impact The `prompt` value is the reachable…

Timeline

Published by source
2026-09-30

Risk context

  • Reported severity or threat level: medium.
  • Reported CVSS score: 5.8 out of 10.
  • Review exposure for the affected product or family: pip: virtualenv.

Product

pip: virtualenv

What to do

General, cautious steps (verify details in the official source):

  • Review exposure and plan remediation based on risk and environment.
  • Identify affected product versions in your inventory and verify whether you are impacted.
  • Apply vendor patches/updates or recommended mitigations as soon as available.
  • Read the official advisory for exact affected versions and remediation steps.

Official advisory

Evidence and provenance

Canonical advisory ID
GHSA-9H9J-4VRJ-GF7G
Source
GitHub
Vendor
GitHub
Published by source
2026-09-30
Last source activity
2026-09-30
Additional identifiers
CVE-2026-102938
Curated by
hlukh.ch

Related advisories and connections

These advisories are connected by shared CVE, product, vendor, source, or time signals.