GLSA-201910-01 : PHP: Arbitrary code execution

critical Nessus Plugin ID 130329
New! Plugin Severity Now Using CVSS v3

The calculated severity for Plugins has been updated to use CVSS v3 by default. Plugins that do not have a CVSS v3 score will fall back to CVSS v2 for calculating severity. Severity display preferences can be toggled in the settings dropdown.

Synopsis

The remote Gentoo host is missing one or more security-related patches.

Description

The remote host is affected by the vulnerability described in GLSA-201910-01 (PHP: Arbitrary code execution)

A underflow in env_path_info in PHP-FPM under certain configurations can be exploited to gain remote code execution.
Impact :

A remote attacker, by sending special crafted HTTP requests, could possibly execute arbitrary code with the privileges of the process, or cause a Denial of Service condition.
Workaround :

If patching is not feasible, the suggested workaround is to include checks to verify whether or not a file exists before passing to PHP.

Solution

All PHP 5.6 users should upgrade to the latest version:
# emerge --sync # emerge --ask --oneshot --verbose '>=dev-lang/php-5.6.40-r7' All PHP 7.1 users should upgrade to the latest version:
# emerge --sync # emerge --ask --oneshot --verbose '>=dev-lang/php-7.1.33' All PHP 7.2 users should upgrade to the latest version:
# emerge --sync # emerge --ask --oneshot --verbose '>=dev-lang/php-7.2.24' All PHP 7.3 users should upgrade to the latest version:
# emerge --sync # emerge --ask --oneshot --verbose '>=dev-lang/php-7.3.11'

See Also

https://security.gentoo.org/glsa/201910-01

Plugin Details

Severity: Critical

ID: 130329

File Name: gentoo_GLSA-201910-01.nasl

Version: 1.8

Type: local

Published: 10/28/2019

Updated: 6/3/2021

Dependencies: ssh_get_info.nasl

Risk Information

VPR

Risk Factor: Critical

Score: 9

CVSS v2

Risk Factor: High

Base Score: 7.5

Temporal Score: 6.2

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

Temporal Vector: E:F/RL:OF/RC:C

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

Vulnerability Information

CPE: p-cpe:/a:gentoo:linux:php, cpe:/o:gentoo:linux

Required KB Items: Host/local_checks_enabled, Host/Gentoo/release, Host/Gentoo/qpkg-list

Exploit Available: true

Exploit Ease: Exploits are available

Patch Publication Date: 10/25/2019

Vulnerability Publication Date: 10/28/2019

Exploitable With

Metasploit (PHP-FPM Underflow RCE)

Reference Information

CVE: CVE-2019-11043

GLSA: 201910-01

IAVA: 2019-A-0399-S