High
Security advisory
In SaltStack Salt 2016.9 through 3002.6, a command injection vulnerability exists in the snapper module that allows for local privilege escalation on a minion. The attack requires that a file is created with a pathname that is backed up by snapper, and that the master calls the snapper.diff function (which executes popen unsafely).
- Products
- Not specified
- Affected versions
- Not specified
- Fixed versions
- Not specified
- CVEs
- CVE-2021-31607
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 1 Nov 2026, 08:21 UTC · Revision 1
Source evidence
In SaltStack Salt 2016.9 through 3002.6, a command injection vulnerability exists in the snapper module that allows for local privilege escalation on a minion. The attack requires that a file is created with a pathname that is backed up by snapper, and that the master calls the snapper.diff function (which executes popen unsafely).
osv:CVE-2021-31607
Complete source record
{
"id": "8a600c3d031c51a280f9eecade420057d472eb9412780b0c59ab83a2ece87d0c",
"url": "https://osv.dev/vulnerability/CVE-2021-31607",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "CVE-2021-31607",
"summary": "In SaltStack Salt 2016.9 through 3002.6, a command injection vulnerability exists in the snapper module that allows for local privilege escalation on a minion. The attack requires that a file is created with a pathname that is backed up by snapper, and that the master calls the snapper.diff function (which executes popen unsafely).",
"evidence": "osv:CVE-2021-31607",
"products": [],
"severity": "high",
"structured": {
"id": "CVE-2021-31607",
"aliases": [
"CVE-2021-31607",
"GHSA-hcjf-rp5h-g5h3",
"PYSEC-2021-56"
],
"metrics": [
{
"type": "CVSS_V3",
"score": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H"
}
],
"affected": [
{
"ranges": [
{
"repo": "https://github.com/saltstack/salt",
"type": "GIT",
"events": [
{
"introduced": "f76dc0f9c06dd0690447a31544b7bd1fe7f5765a"
},
{
"last_affected": "027263b794ac03a5953ac360d7205a69e643b19a"
}
],
"database_specific": {
"extracted_events": [
{
"cpe": "cpe:2.3:a:saltstack:salt:*:*:*:*:*:*:*:*",
"range": [
{
"introduced": "2016.9"
},
{
"last_affected": "3002.6"
}
],
"source": "CPE_RANGE"
}
]
}
}
],
"versions": [
"v3002.6",
"v3002.5",
"v3002.4",
"v3002.3",
"v3002.2",
"v3002",
"v3002rc1",
"v3001.1",
"v3001",
"v3001rc1",
"v3000.1",
"v3000_docs",
"v3000",
"v3000.0rc1",
"v3000.0rc2",
"v2019.2.1",
"v2019.2.1rc1",
"v2019.2",
"v2018.11",
"v2017.7",
"v2017.5",
"v2018.3",
"v2018.2",
"v2016.9",
"v2016.11"
],
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2021-31607.json"
}
}
],
"modified": "2026-10-24T10:31:06.533992902Z",
"provider": "osv",
"references": [
"https://lists.debian.org/debian-lts-announce/2021/11/msg00009.html",
"https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/6BUWUF5VTENNP2ZYZBVFKPSUHLKLUBD5/",
"https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/ACVT7M4YLZRLWWQ6SGRK3C6TOF4FXOXT/",
"https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/LDKMAJXYFHM4USVX3H5V2GCCBGASWUSM/",
"https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/MBAHHSGZLEJRCG4DX6J4RBWJAAWH55RQ/",
"https://security.gentoo.org/glsa/202310-22",
"https://www.debian.org/security/2021/dsa-5011",
"https://sec.stealthcopter.com/saltstack-snapper-minion-privledge-escaltion/"
],
"provider_metadata": {
"unresolved_ranges": [
{
"cpes": [
"cpe:2.3:o:fedoraproject:fedora:33:*:*:*:*:*:*:*",
"cpe:2.3:o:fedoraproject:fedora:34:*:*:*:*:*:*:*",
"cpe:2.3:o:fedoraproject:fedora:35:*:*:*:*:*:*:*"
],
"vendor_product": "fedoraproject:fedora",
"extracted_events": [
{
"range": [
{
"introduced": "33"
},
{
"last_affected": "33"
},
{
"introduced": "34"
},
{
"last_affected": "34"
},
{
"introduced": "35"
},
{
"last_affected": "35"
}
],
"source": "CPE_STRING"
}
]
}
]
}
},
"related_cves": [
{
"value": "CVE-2021-31607",
"evidence": "/id"
}
],
"security_relevant": true,
"severity_evidence": "/severity/0/score"
},
"source_id": "core-osv",
"document_id": 440997,
"published_at": "2021-04-23T06:15:07.893+00:00"
}