Amazon Linux 2 : log4j (ALAS-2022-1739)

critical Nessus Plugin ID 180057

Synopsis

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

Description

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

- In Apache Log4j 2.x before 2.8.2, when using the TCP socket server or UDP socket server to receive serialized log events from another application, a specially crafted binary payload can be sent that, when deserialized, can execute arbitrary code. (CVE-2017-5645)

- Included in Log4j 1.2 is a SocketServer class that is vulnerable to deserialization of untrusted data which can be exploited to remotely execute arbitrary code when combined with a deserialization gadget when listening to untrusted network traffic for log data. This affects Log4j versions up to 1.2 up to 1.2.17.
(CVE-2019-17571)

- JMSAppender in Log4j 1.2 is vulnerable to deserialization of untrusted data when the attacker has write access to the Log4j configuration. The attacker can provide TopicBindingName and TopicConnectionFactoryBindingName configurations causing JMSAppender to perform JNDI requests that result in remote code execution in a similar fashion to CVE-2021-44228. Note this issue only affects Log4j 1.2 when specifically configured to use JMSAppender, which is not the default. Apache Log4j 1.2 reached end of life in August 2015. Users should upgrade to Log4j 2 as it addresses numerous other issues from the previous versions. (CVE-2021-4104)

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/AL2/ALAS-2022-1739.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: 180057

File Name: al2_ALAS-2022-1739.nasl

Version: 1.1

Type: local

Agent: unix

Published: 8/23/2023

Updated: 8/24/2023

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: 6.2

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: 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:amazon:linux:log4j-javadoc, p-cpe:/a:amazon:linux:log4j-manual, cpe:/o:amazon:linux:2, 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