Amazon Linux 2 : amazon-ssm-agent (ALAS-2023-2303)

critical Nessus Plugin ID 183477

Synopsis

The remote Amazon Linux 2 host is missing a security update.

Description

The version of amazon-ssm-agent installed on the remote host is prior to 3.2.1705.0-1. It is, therefore, affected by multiple vulnerabilities as referenced in the ALAS2-2023-2303 advisory.

- The x/crypto/ssh package before 0.0.0-20211202192323-5770296d904e of golang.org/x/crypto allows an attacker to panic an SSH server. (CVE-2021-43565)

- A maliciously crafted HTTP/2 stream could cause excessive CPU consumption in the HPACK decoder, sufficient to cause a denial of service from a small number of small requests. (CVE-2022-41723)

- Templates do not properly consider backticks (`) as Javascript string delimiters, and do not escape them as expected. Backticks are used, since ES6, for JS template literals. If a template contains a Go template action within a Javascript template literal, the contents of the action can be used to terminate the literal, injecting arbitrary Javascript code into the Go template. As ES6 template literals are rather complex, and themselves can do string interpolation, the decision was made to simply disallow Go template actions from being used inside of them (e.g. var a = {{.}}), since there is no obviously safe way to allow this behavior. This takes the same approach as github.com/google/safehtml. With fix, Template.Parse returns an Error when it encounters templates like this, with an ErrorCode of value 12. This ErrorCode is currently unexported, but will be exported in the release of Go 1.21. Users who rely on the previous behavior can re-enable it using the GODEBUG flag jstmpllitinterp=1, with the caveat that backticks will now be escaped. This should be used with caution. (CVE-2023-24538)

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

Solution

Run 'yum update amazon-ssm-agent' to update your system.

See Also

https://alas.aws.amazon.com/AL2/ALAS-2023-2303.html

https://alas.aws.amazon.com/faqs.html

https://alas.aws.amazon.com/cve/html/CVE-2021-43565.html

https://alas.aws.amazon.com/cve/html/CVE-2022-41723.html

https://alas.aws.amazon.com/cve/html/CVE-2023-24538.html

https://alas.aws.amazon.com/cve/html/CVE-2023-24540.html

https://alas.aws.amazon.com/cve/html/CVE-2023-29406.html

https://alas.aws.amazon.com/cve/html/CVE-2023-29409.html

https://alas.aws.amazon.com/cve/html/CVE-2023-3978.html

Plugin Details

Severity: Critical

ID: 183477

File Name: al2_ALAS-2023-2303.nasl

Version: 1.1

Type: local

Agent: unix

Published: 10/20/2023

Updated: 10/31/2023

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

Risk Information

VPR

Risk Factor: Medium

Score: 6.7

CVSS v2

Risk Factor: Critical

Base Score: 10

Temporal Score: 7.4

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

CVSS Score Source: CVE-2023-24540

CVSS v3

Risk Factor: Critical

Base Score: 9.8

Temporal Score: 8.5

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:U/RL:O/RC:C

Vulnerability Information

CPE: cpe:/o:amazon:linux:2, p-cpe:/a:amazon:linux:amazon-ssm-agent-debuginfo, p-cpe:/a:amazon:linux:amazon-ssm-agent

Required KB Items: Host/local_checks_enabled, Host/AmazonLinux/release, Host/AmazonLinux/rpm-list

Exploit Ease: No known exploits are available

Patch Publication Date: 10/12/2023

Vulnerability Publication Date: 4/7/2022

Reference Information

CVE: CVE-2021-43565, CVE-2022-41723, CVE-2023-24538, CVE-2023-24540, CVE-2023-29406, CVE-2023-29409, CVE-2023-3978

IAVB: 2023-B-0012-S, 2023-B-0022-S