# CVE-2024-53899: virtualenv allows command injection through activation scripts for a virtual environment

- Severity: High 8.4 (CVSS:3.1, scored by CISA-ADP) `CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 1.57%, higher than 76% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2024-11-24T00:00:00.000Z
- Modified: 2026-09-10T16:01:48.396Z
- Also known as: GHSA-rqc4-2hc7-8c8v, BIT-VIRTUALENV-2024-53899, PYSEC-2024-187
- Weaknesses: CWE-77, CWE-78
- SSVC (CISA-ADP): exploitation poc, automatable no, technical impact total
- Assigned by: mitre

## Description

virtualenv before 20.26.6 allows command injection through the activation scripts for a virtual environment. Magic template strings are not quoted correctly when replacing. NOTE: this is not the same as CVE-2024-9287.

(As written by CVE List.)

## Affected

- Unspecified product: n/a
- virtualenv virtualenv: before 20.26.6
- virtualenv (PyPI): before 20.26.6
- virtualenv (Bitnami): before 20.26.6

## Every score

- CISA-ADP: CVSS:3.1 8.4 High `CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`
- GitHub: CVSS:3.1 8.4 High `CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`
- NVD: CVSS:3.1 7.8 High `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- PyPA Advisory Database: CVSS:3.1 9.8 Critical `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`
- Bitnami Vulnerability Database: rating High

## References

- <https://github.com/pypa/virtualenv/issues/2768> (exploit, evidence, web)
- <https://github.com/pypa/virtualenv/releases/tag/20.26.6> (article, release-notes, web)
- <https://github.com/pypa/virtualenv/pull/2771> (fix, patch, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2024-53899> (advisory, web)
- <https://github.com/pypa/advisory-database/tree/main/vulns/virtualenv/PYSEC-2024-187.yaml> (web)
- <https://github.com/pypa/virtualenv> (package)
- <https://github.com/advisories/GHSA-rqc4-2hc7-8c8v> (advisory)

## Sources

- CVE List: [CVE-2024-53899](https://www.cve.org/CVERecord?id=CVE-2024-53899), CVE Terms of Use, modified 2024-11-24
- GitHub Advisory Database: [GHSA-rqc4-2hc7-8c8v](https://github.com/advisories/GHSA-rqc4-2hc7-8c8v), CC-BY-4.0, modified 2026-09-10
- NVD: [CVE-2024-53899](https://nvd.nist.gov/vuln/detail/CVE-2024-53899), Public domain, modified 2026-06-17
- PyPA Advisory Database: [PYSEC-2024-187](https://osv.dev/vulnerability/PYSEC-2024-187), CC-BY-4.0, modified 2026-06-10
- Bitnami Vulnerability Database: [BIT-VIRTUALENV-2024-53899](https://osv.dev/vulnerability/BIT-VIRTUALENV-2024-53899), Apache-2.0, modified 2026-09-10

---

Page: https://cve.day/CVE-2024-53899 · Whole record: https://cve.day/CVE-2024-53899.json · Rebuilt by cve.day 2026-11-25T22:58:49.401Z
