virtualenv is vulnerable to Carriage Return Line Feed (CRLF) Injection
37
Low Risk
pyvenv.cfg is a line-based format with no escape syntax, and PyEnvCfg.write() wrote values verbatim while reading parsed the file with str.splitlines(), which recognizes boundaries beyond \n such as \r, \v, and U+2028. A prompt value containing one of those boundaries becomes additional configuration lines, and because reading is last-wins, it overrides keys written earlier such as home, which tooling reads to locate the base interpreter. The prompt is reachable via --prompt, the VIRTUALENV_PROMPT environment variable, or the config file. The fix collapses every recognized line boundary to a space before serializing each value.
You are affected if you are using a version that falls within the vulnerable range and your --prompt value, the VIRTUALENV_PROMPT environment variable, or your config file's prompt setting comes from an untrusted or externally influenced source.
virtualenv is vulnerable to Carriage Return Line Feed (CRLF) Injection in versions 0.0.1 - 21.7.10.
Upgrade the virtualenv library to the patch version.
Connect your repositories to instantly see whether vulnerable or malicious packages exist in your codebase.
Free. No credit card required.

I consent to receiving marketing communications based on Aikido’s Privacy Policy.
SOC 2Compliant
ISO 27001Compliant
ISO 42001Compliant© All Intel data is openly available and commercially licensed.