Code execution via unvalidated virtualenv activation path
Published May 13, 2020 · Updated Aug 4, 2024
Command injection in Michael Aquilina zsh-autoswitch-virtualenv before 0.16.0 allows local users to execute code via a malicious .venv file. The _maybeworkon function trusts the path named in .venv and sources its bin/activate script into the current Zsh session without rejecting path traversal. Exploitation requires entry into an attacker-controlled directory, after which the script runs with the local user's shell privileges without an additional prompt.
Summary
What happened
Command injection in Michael Aquilina zsh-autoswitch-virtualenv before 0.16.0 allows local users to execute code via a malicious .venv file. The _maybeworkon function trusts the path named in .venv and sources its bin/activate script into the current Zsh session without rejecting path traversal. Exploitation requires entry into an attacker-controlled directory, after which the script runs with the local user's shell privileges without an additional prompt.
The record
- CVE
- CVE-2020-11073
- Published
- May 13, 2020
- Updated
- Aug 4, 2024
- Vendor
- Michael Aquilina
- Product
- zsh-autoswitch-virtualenv
- Classifications
- CWE-77, CWE-22, T1059.004
- Attack vector
- local
- Privileges
- authenticated
Timeline
How it unfolded
- May 13, 2020CVE publishedPublication date reported by the CVE source.
- Aug 4, 2024Record updatedLatest update available in the CVE record.
Exploitability
Present is not the same as exploitable
Compare your product and version with the public record. A matching version still requires validation against your environment.
Is a vulnerable build present?
Compare these published version ranges with your installed build and any vendor patches.
- Affected versionversion=< 0.16.0
What conditions does exploitation require?
What is affected?
Attacks
What attackers are doing with it
Daily unique IPs observed by Shadowserver honeypots for known exploited vulnerabilities (KEVs). Missing observations do not establish an absence of attacks.
Weakness, pattern, technique
Public exploit references
- evil-zsh-autoswitch-virtualenv proof of conceptproof of concept · demonstrated
Labels summarize the accepted research assessment. They do not indicate a test against your environment.
Technologies
Your stack
See the directory against your own environment.
Your stack
Check the software in your environment
Book a demo to see how Hinoki identifies affected software and validates exploitability in your environment.
Book a demo