Amazon Linux 2 : httpd (ALAS-2021-1716)

critical Nessus Plugin ID 154179

Synopsis

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

Description

The version of httpd installed on the remote host is prior to 2.4.51-1. It is, therefore, affected by multiple vulnerabilities as referenced in the ALAS2-2021-1716 advisory.

- A crafted method sent through HTTP/2 will bypass validation and be forwarded by mod_proxy, which can lead to request splitting or cache poisoning. This issue affects Apache HTTP Server 2.4.17 to 2.4.48.
(CVE-2021-33193)

- Malformed requests may cause the server to dereference a NULL pointer. This issue affects Apache HTTP Server 2.4.48 and earlier. (CVE-2021-34798)

- A carefully crafted request uri-path can cause mod_proxy_uwsgi to read above the allocated memory and crash (DoS). This issue affects Apache HTTP Server versions 2.4.30 to 2.4.48 (inclusive). (CVE-2021-36160)

- ap_escape_quotes() may write beyond the end of a buffer when given malicious input. No included modules pass untrusted data to these functions, but third-party / external modules may. This issue affects Apache HTTP Server 2.4.48 and earlier. (CVE-2021-39275)

- A crafted request uri-path can cause mod_proxy to forward the request to an origin server choosen by the remote user. This issue affects Apache HTTP Server 2.4.48 and earlier. (CVE-2021-40438)

- While fuzzing the 2.4.49 httpd, a new null pointer dereference was detected during HTTP/2 request processing, allowing an external source to DoS the server. This requires a specially crafted request. The vulnerability was recently introduced in version 2.4.49. No exploit is known to the project.
(CVE-2021-41524)

- A flaw was found in a change made to path normalization in Apache HTTP Server 2.4.49. An attacker could use a path traversal attack to map URLs to files outside the directories configured by Alias-like directives. If files outside of these directories are not protected by the usual default configuration require all denied, these requests can succeed. If CGI scripts are also enabled for these aliased pathes, this could allow for remote code execution. This issue is known to be exploited in the wild. This issue only affects Apache 2.4.49 and not earlier versions. The fix in Apache HTTP Server 2.4.50 was found to be incomplete, see CVE-2021-42013. (CVE-2021-41773)

- It was found that the fix for CVE-2021-41773 in Apache HTTP Server 2.4.50 was insufficient. An attacker could use a path traversal attack to map URLs to files outside the directories configured by Alias-like directives. If files outside of these directories are not protected by the usual default configuration require all denied, these requests can succeed. If CGI scripts are also enabled for these aliased pathes, this could allow for remote code execution. This issue only affects Apache 2.4.49 and Apache 2.4.50 and not earlier versions. (CVE-2021-42013)

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

Solution

Run 'yum update httpd' to update your system.

See Also

https://alas.aws.amazon.com/AL2/ALAS-2021-1716.html

https://access.redhat.com/security/cve/CVE-2021-33193

https://access.redhat.com/security/cve/CVE-2021-34798

https://access.redhat.com/security/cve/CVE-2021-36160

https://access.redhat.com/security/cve/CVE-2021-39275

https://access.redhat.com/security/cve/CVE-2021-40438

https://access.redhat.com/security/cve/CVE-2021-41524

https://access.redhat.com/security/cve/CVE-2021-41773

https://access.redhat.com/security/cve/CVE-2021-42013

Plugin Details

Severity: Critical

ID: 154179

File Name: al2_ALAS-2021-1716.nasl

Version: 1.15

Type: local

Agent: unix

Published: 10/16/2021

Updated: 1/18/2024

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

Risk Information

VPR

Risk Factor: Critical

Score: 9.0

CVSS v2

Risk Factor: High

Base Score: 7.5

Temporal Score: 6.5

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

CVSS Score Source: CVE-2021-42013

CVSS v3

Risk Factor: Critical

Base Score: 9.8

Temporal Score: 9.4

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

Vulnerability Information

CPE: p-cpe:/a:amazon:linux:httpd, p-cpe:/a:amazon:linux:httpd-debuginfo, p-cpe:/a:amazon:linux:httpd-devel, p-cpe:/a:amazon:linux:httpd-filesystem, p-cpe:/a:amazon:linux:httpd-manual, p-cpe:/a:amazon:linux:httpd-tools, p-cpe:/a:amazon:linux:mod_ldap, p-cpe:/a:amazon:linux:mod_md, p-cpe:/a:amazon:linux:mod_proxy_html, p-cpe:/a:amazon:linux:mod_session, p-cpe:/a:amazon:linux:mod_ssl, cpe:/o:amazon:linux:2

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: 10/15/2021

Vulnerability Publication Date: 8/16/2021

CISA Known Exploited Vulnerability Due Dates: 11/17/2021, 12/15/2021

Exploitable With

CANVAS (CANVAS)

Metasploit (Apache 2.4.49/2.4.50 Traversal RCE)

Elliot (Apache 2.4.50 RCE)

Reference Information

CVE: CVE-2021-33193, CVE-2021-34798, CVE-2021-36160, CVE-2021-39275, CVE-2021-40438, CVE-2021-41524, CVE-2021-41773, CVE-2021-42013

ALAS: 2021-1716

IAVA: 2021-A-0440-S, 2021-A-0451-S