tagline: Confidence in the Connected World
CIS Logo
HomeResourcesAdvisoriesMultiple Vulnerabilities in PHP Could Allow Arbitrary Code Execution

Multiple Vulnerabilities in PHP Could Allow Arbitrary Code Execution

MS-ISAC ADVISORY NUMBER:

2016-002

DATE(S) ISSUED:

01/07/2016

OVERVIEW:

Multiple vulnerabilities have been discovered in PHP which could allow an attacker to potentially execute arbitrary code. PHP is a programming language originally designed for use in web-based applications with HTML content. PHP supports a wide variety of platforms and is used by numerous web-based software applications. Successfully exploiting these issues may allow remote attackers to execute arbitrary code in the context of a webserver.

THREAT INTELLIGENCE:

There are currently no reports of these vulnerabilities being exploited in the wild. There is known proof-of-concept code for these vulnerabilities.

SYSTEMS AFFECTED:

  • PHP 5.6 prior to 5.6.17
  • PHP 5.5 prior to 5.5.31

RISK:

Government:
  • Large and medium government entities: HIGH
  • Small government entities: HIGH
Businesses:
  • Large and medium business entities: HIGH
  • Small business entities: HIGH
Home Users:
LOW

TECHNICAL SUMMARY:

PHP has released updates that address multiple vulnerabilities that could allow for arbitrary code execution. These vulnerabilities include:

Prior to 5.6.17 and 5.5.31

Bug 70661 - A vulnerability exists in the 'zval_ptr_dtor()' function of the 'wddx/wddx.c' source file. Exploit of this issue can be performed by sending specially crafted 'recordset'.
Bug 70741 - A vulnerability exists in the 'php_wddx_deserialize_ex()' function when performing deserialization on string-type 'ZVAL'.

Successful exploitation of these vulnerabilities may allow remote attackers to execute arbitrary code in the context of the webserver. Other bugs fixed in the PHP Core for these versions may be found below:

Bug 66909 (configure fails utf8_to_mutf7 test).
Bug 70958 (Invalid opcode while using ::class as trait method paramater default value).
Bug 70957 (self::class can not be resolved with reflection for abstract class).
Bug 70944 (try{ } finally{} can create infinite chains of exceptions).
Bug 61751 (SAPI build problem on AIX: Undefined symbol: php_register_internal_extensions).
Bug 70755 (fpm_log.c memory leak and buffer overflow).
Bug 70976 (Memory Read via gdImageRotateInterpolated Array Index Out of Bounds). (emmanuel dot law at gmail dot com).
Bug 68077 (LOAD DATA LOCAL INFILE / open_basedir restriction).
Bug 70900 (SoapClient systematic out of memory error).
Bug 70960 (ReflectionFunction for array_unique returns wrong number of parameters).
Bug 60052 (Integer returned as a 64bit integer on X64_86).
Bug 70728 (Type Confusion Vulnerability in PHP_to_XMLRPC_worker()).

RECOMENDATIONS:

We recommend the following actions be taken:

Upgrade to the latest version of PHP immediately, after appropriate testing.
Apply the principle of Least Privilege to all systems and services.
Remind users not to visit websites or follow links provided by unknown or untrusted sources.
Do not open email attachments from unknown or untrusted sources.
Limit user account privileges to only those required.

REFERENCES:

Get Email Updates When Cyber Threats Like This Arise

Arrow Subscribe to Advisories

Protect Your Systems from Cyber Threats Like This

CIS Controls That Help Avoid This Issue Arrow CIS Control 4: Continuous Vulnerability Assessment and Remediation Arrow CIS Control 18: Application Software Security