Debian DLA-2815-1 : salt - LTS security update

critical Nessus Plugin ID 155123

Synopsis

The remote Debian host is missing one or more security-related updates.

Description

The remote Debian 9 host has packages installed that are affected by multiple vulnerabilities as referenced in the dla-2815 advisory.

- An issue was discovered in SaltStack Salt before 3002.5. The minion's restartcheck is vulnerable to command injection via a crafted process name. This allows for a local privilege escalation by any user able to create a files on the minion in a non-blacklisted directory. (CVE-2020-28243)

- In SaltStack Salt before 3002.5, authentication to VMware vcenter, vsphere, and esxi servers (in the vmware.py files) does not always validate the SSL/TLS certificate. (CVE-2020-28972)

- In SaltStack Salt before 3002.5, when authenticating to services using certain modules, the SSL certificate is not always validated. (CVE-2020-35662)

- An issue was discovered in through SaltStack Salt before 3002.5. salt-api does not honor eauth credentials for the wheel_async client. Thus, an attacker can remotely run any wheel modules on the master.
(CVE-2021-25281)

- An issue was discovered in through SaltStack Salt before 3002.5. The salt.wheel.pillar_roots.write method is vulnerable to directory traversal. (CVE-2021-25282)

- An issue was discovered in through SaltStack Salt before 3002.5. The jinja renderer does not protect against server side template injection attacks. (CVE-2021-25283)

- An issue was discovered in through SaltStack Salt before 3002.5. salt.modules.cmdmod can log credentials to the info or error log level. (CVE-2021-25284)

- In SaltStack Salt before 3002.5, eauth tokens can be used once after expiration. (They might be used to run command against the salt master or minions.) (CVE-2021-3144)

- An issue was discovered in SaltStack Salt before 3002.5. Sending crafted web requests to the Salt API can result in salt.utils.thin.gen_thin() command injection because of different handling of single versus double quotes. This is related to salt/utils/thin.py. (CVE-2021-3148)

- 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). (CVE-2021-31607)

- An issue was discovered in SaltStack Salt before 3002.5. The salt-api's ssh client is vulnerable to a shell injection by including ProxyCommand in an argument, or via ssh_options provided in an API request.
(CVE-2021-3197)

Note that Nessus has not tested for this issue but has instead relied only on the application's self-reported version number.

Solution

Upgrade the salt packages.

For Debian 9 stretch, these problems have been fixed in version 2016.11.2+ds-1+deb9u7.

See Also

https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=987496

https://security-tracker.debian.org/tracker/source-package/salt

https://www.debian.org/lts/security/2021/dla-2815

https://security-tracker.debian.org/tracker/CVE-2020-28243

https://security-tracker.debian.org/tracker/CVE-2020-28972

https://security-tracker.debian.org/tracker/CVE-2020-35662

https://security-tracker.debian.org/tracker/CVE-2021-25281

https://security-tracker.debian.org/tracker/CVE-2021-25282

https://security-tracker.debian.org/tracker/CVE-2021-25283

https://security-tracker.debian.org/tracker/CVE-2021-25284

https://security-tracker.debian.org/tracker/CVE-2021-3144

https://security-tracker.debian.org/tracker/CVE-2021-3148

https://security-tracker.debian.org/tracker/CVE-2021-31607

https://security-tracker.debian.org/tracker/CVE-2021-3197

https://packages.debian.org/source/stretch/salt

Plugin Details

Severity: Critical

ID: 155123

File Name: debian_DLA-2815.nasl

Version: 1.5

Type: local

Agent: unix

Published: 11/11/2021

Updated: 4/1/2022

Supported Sensors: Agentless Assessment, Frictionless Assessment Agent, Nessus Agent, Nessus

Risk Information

VPR

Risk Factor: High

Score: 7.7

CVSS v2

Risk Factor: High

Base Score: 7.5

Temporal Score: 6.2

Vector: CVSS2#AV:N/AC:L/Au:N/C:P/I:P/A:P

CVSS Score Source: CVE-2021-3197

CVSS v3

Risk Factor: Critical

Base Score: 9.8

Temporal Score: 9.1

Vector: CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Temporal Vector: CVSS:3.0/E:F/RL:O/RC:C

Vulnerability Information

CPE: p-cpe:/a:debian:debian_linux:salt-ssh, cpe:/o:debian:debian_linux:9.0, p-cpe:/a:debian:debian_linux:salt-cloud, p-cpe:/a:debian:debian_linux:salt-common, p-cpe:/a:debian:debian_linux:salt-doc, p-cpe:/a:debian:debian_linux:salt-api, p-cpe:/a:debian:debian_linux:salt-proxy, p-cpe:/a:debian:debian_linux:salt-syndic, p-cpe:/a:debian:debian_linux:salt-minion, p-cpe:/a:debian:debian_linux:salt-master

Required KB Items: Host/local_checks_enabled, Host/Debian/release, Host/Debian/dpkg-l

Exploit Available: true

Exploit Ease: Exploits are available

Patch Publication Date: 11/10/2021

Vulnerability Publication Date: 2/27/2021

Exploitable With

Metasploit (SaltStack Salt API Unauthenticated RCE through wheel_async client)

Reference Information

CVE: CVE-2020-28243, CVE-2020-28972, CVE-2020-35662, CVE-2021-25281, CVE-2021-25282, CVE-2021-25283, CVE-2021-25284, CVE-2021-3144, CVE-2021-3148, CVE-2021-31607, CVE-2021-3197

IAVA: 2021-A-0112-S, 2021-A-0524-S