Amazon Linux AMI : log4j (ALAS-2022-1562)

critical Nessus Plugin ID 156871

Synopsis

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

Description

The version of log4j installed on the remote host is prior to 1.2.17-16.12. It is, therefore, affected by multiple vulnerabilities as referenced in the ALAS-2022-1562 advisory.

It was found that when using remote logging with log4j socket server the log4j server would deserialize any log event received via TCP or UDP. An attacker could use this flaw to send a specially crafted log event that, during deserialization, would execute arbitrary code in the context of the logger application.
(CVE-2017-5645)

A flaw was discovered in Log4j, where a vulnerable SocketServer class may lead to the deserialization of untrusted data. This flaw allows an attacker to remotely execute arbitrary code when combined with a deserialization gadget. (CVE-2019-17571)

A flaw was found in the Java logging library Apache Log4j in version 1.x. JMSAppender in Log4j 1.x is vulnerable to deserialization of untrusted data. This allows a remote attacker to execute code on the server if the deployed application is configured to use JMSAppender and to the attacker's JNDI LDAP endpoint. (CVE-2021-4104)

Tenable has extracted the preceding description block directly from the tested product security advisory.

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 log4j' to update your system.

See Also

https://alas.aws.amazon.com/ALAS-2022-1562.html

https://alas.aws.amazon.com/cve/html/CVE-2017-5645.html

https://alas.aws.amazon.com/cve/html/CVE-2019-17571.html

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

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

Plugin Details

Severity: Critical

ID: 156871

File Name: ala_ALAS-2022-1562.nasl

Version: 1.6

Type: local

Agent: unix

Published: 1/20/2022

Updated: 12/11/2024

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

Risk Information

VPR

Risk Factor: Medium

Score: 6.7

CVSS v2

Risk Factor: High

Base Score: 7.5

Temporal Score: 5.9

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

CVSS Score Source: CVE-2019-17571

CVSS v3

Risk Factor: Critical

Base Score: 9.8

Temporal Score: 8.8

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

Vulnerability Information

CPE: p-cpe:/a:amazon:linux:log4j-javadoc, cpe:/o:amazon:linux, p-cpe:/a:amazon:linux:log4j-manual, p-cpe:/a:amazon:linux:log4j

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

Exploit Available: true

Exploit Ease: Exploits are available

Patch Publication Date: 1/18/2022

Vulnerability Publication Date: 4/17/2017

Reference Information

CVE: CVE-2017-5645, CVE-2019-17571, CVE-2021-4104

ALAS: 2022-1562

IAVA: 0001-A-0650, 2018-A-0030-S, 2018-A-0117-S, 2018-A-0118-S, 2018-A-0225-S, 2018-A-0226-S, 2018-A-0229-S, 2018-A-0335-S, 2018-A-0336-S, 2019-A-0021-S, 2019-A-0025-S, 2019-A-0128, 2019-A-0256-S, 2020-A-0008-S, 2020-A-0140, 2020-A-0324, 2020-A-0326, 2021-A-0573