CVE-2020-16846 — SaltStack Salt Command Injection in salt
SaltStack Salt Command Injection in netapi ssh client
What Should I Do?
Patch Immediately
This vulnerability is confirmed under active exploitation (CISA KEV). Patch within 24-48 hours if possible.
Does your project use an affected salt version?
Paste your requirements.txt to check it for CVE-2020-16846 and every other known vulnerability, with CISA KEV and EPSS on each finding. Free with no signup for up to 10 packages, or up to 500 per scan with a free account, which also keeps up to 200 packages in saved projects.
Summary
An issue was discovered in SaltStack Salt through 3002. Sending crafted web requests to the Salt API, with the SSH client enabled, can result in shell injection.
Advisory Timeline
- First published May 24, 2022 (1647 days ago).
- Last revised October 22, 2025 — 1247 days after initial publication.
- Added to CISA's Known Exploited Vulnerabilities catalog 203 days before publication.
Remediation
Upgrade to the fixed version using your package manager.
pip install "salt>=2018.3.5"
pip install "salt>=3002.1"
pip install "salt>=2016.3.8"
pip install "salt>=2015.8.13"
pip install "salt>=3000.4"
pip install "salt>=2019.2.6"
pip install "salt>=2017.7.8"
pip install "salt>=3001.2"
pip install "salt>=2016.11.10"
After upgrading, scan your dependencies again to confirm the vulnerability is resolved.
Affected Packages (9)
Affects 1 ecosystem: PyPI (1).
| Package | Fixed In |
|---|---|
| salt PyPI · Affected: 2018.3.0, 2018.3.0rc1, 2018.3.1, 2018.3.2 (+2 more) | 2018.3.5 |
| salt PyPI · Affected: 3002 | 3002.1 |
| salt PyPI · Affected: 2016.3.0, 2016.3.1, 2016.3.2, 2016.3.3 (+4 more) | 2016.3.8 |
| salt PyPI · Affected: 0.10.0, 0.10.1, 0.10.2, 0.10.3 (+106 more) | 2015.8.13 |
| salt PyPI · Affected: 3000, 3000.1, 3000.2, 3000.3 | 3000.4 |
| salt PyPI · Affected: 2019.2.0, 2019.2.1, 2019.2.2, 2019.2.3 (+2 more) | 2019.2.6 |
| salt PyPI · Affected: 2017.7.0, 2017.7.0rc1, 2017.7.1, 2017.7.2 (+5 more) | 2017.7.8 |
| salt PyPI · Affected: 3001, 3001.1 | 3001.2 |
| salt PyPI · Affected: 2016.11.0, 2016.11.1, 2016.11.2, 2016.11.3 (+6 more) | 2016.11.10 |
Vulnerability Classification
Common Weakness Enumeration (CWE) identifiers for this vulnerability type.
- CWE-78OS Command InjectionMITRE
CVSS Score Breakdown
What the CVSS (Common Vulnerability Scoring System) 9.8 score means for each attack dimension.
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H/E:H
References
- https://nvd.nist.gov/vuln/detail/CVE-2020-16846ADVISORY
- https://www.zerodayinitiative.com/advisories/ZDI-20-1383WEB
- https://www.zerodayinitiative.com/advisories/ZDI-20-1382WEB
- https://www.zerodayinitiative.com/advisories/ZDI-20-1381WEB
- https://www.zerodayinitiative.com/advisories/ZDI-20-1380WEB
- https://www.zerodayinitiative.com/advisories/ZDI-20-1379WEB
- https://www.saltstack.com/blog/on-november-3-2020-saltstack-publicly-disclosed-three-new-cvesWEB
- https://www.debian.org/security/2021/dsa-4837WEB
- https://www.cisa.gov/known-exploited-vulnerabilities-catalog?field_cve=CVE-2020-16846WEB
- https://security.gentoo.org/glsa/202011-13WEB
- https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/TPOGB2F6XUAIGFDTOCQDNB2VIXFXHWMAWEB
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/TPOGB2F6XUAIGFDTOCQDNB2VIXFXHWMAWEB
- https://lists.debian.org/debian-lts-announce/2022/01/msg00000.htmlWEB
- https://lists.debian.org/debian-lts-announce/2020/12/msg00007.htmlWEB
- https://github.com/saltstack/salt/releasesWEB
- https://github.com/saltstack/salt/blob/8f9405cf8e6f7d7776d5000841c886dec6d96250/doc/topics/releases/3002.1.rst#L12WEB
- https://github.com/saltstack/salt/blob/8f9405cf8e6f7d7776d5000841c886dec6d96250/doc/topics/releases/3001.2.rst#L10WEB
- https://github.com/saltstack/salt/blob/8f9405cf8e6f7d7776d5000841c886dec6d96250/doc/topics/releases/3000.4.rst#L10WEB
- https://github.com/saltstack/salt/blob/8f9405cf8e6f7d7776d5000841c886dec6d96250/doc/topics/releases/2019.2.6.rst#L10WEB
- https://github.com/saltstack/saltPACKAGE
- https://github.com/pypa/advisory-database/tree/main/vulns/salt/PYSEC-2020-104.yamlWEB
- https://lists.opensuse.org/opensuse-security-announce/2020-11/msg00029.htmlWEB
- https://packetstormsecurity.com/files/160039/SaltStack-Salt-REST-API-Arbitrary-Command-Execution.htmlWEB
Frequently Asked Questions
- What is CVE-2020-16846?
- SaltStack Salt Command Injection in netapi ssh client. This vulnerability has been assigned a severity rating of CRITICAL (CVSS score: 9.8/10).
- How do I check if my project is affected by CVE-2020-16846?
- CVE-2020-16846 affects salt. It has a 99.6% probability of exploitation within 30 days (EPSS score). This vulnerability is listed in CISA's Known Exploited Vulnerabilities (KEV) catalog, meaning it is being actively exploited in the wild. Use GeekWala's free vulnerability scanner to check your dependencies against CVE-2020-16846 and 200,000+ other known vulnerabilities.
Severity & Exploitability
Maximum impact if exploited, often with little effort or access required.
This places it in the top 5% of EPSS-scored vulnerabilities — 100% of tracked vulnerabilities score at or below it, so it is far more likely to be exploited than nearly all other tracked vulnerabilities.
This vulnerability is in CISA's Known Exploited Vulnerabilities (KEV) catalog, indicating active exploitation in the wild.
Added to KEV catalog: November 3, 2021
Remediation deadline: May 3, 2022
Also Known As
Related CVEs
- CVE-2020-25592CRITICAL
SaltStack Salt Improper Validation of eauth credentials and tokens in salt-netapi
- CVE-2024-38824CRITICAL
Salt vulnerable to directory traversal attack in file receiving method
- CVE-2021-3197CRITICAL
SaltStack Salt is vulnerable to shell injection via ProxyCommand argument
- CVE-2021-3148CRITICAL
SaltStack Salt command injection in the Salt-API when using the Salt-SSH client
- CVE-2021-3144CRITICAL
SaltStack Salt eauth tokens can be used once after expiration
- CVE-2021-25283CRITICAL
SaltStack Salt Server Side Template Injection
- CVE-2021-25281CRITICAL
SaltStack Salt Improper Authentication vulnerability
- CVE-2021-25282HIGH
SaltStack Salt Directory Traversal vulnerability