Apple has released a security advisory and updated software to address the PHP php5-cgi binary setup remote unsanitized command-line parameter processing vulnerability.
Description
PHP contains a vulnerability that could allow an unauthenticated, remote attacker to disclose sensitive information, cause a denial of service (DoS) condition, or execute arbitrary code.
The vulnerability exists because the affected software performs insufficient sanitization on user-supplied HTTP queries. An unauthenticated, remote attacker could exploit the vulnerability by transmitting crafted HTTP requests to the targeted system. Successful exploitation could allow the attacker to disclose sensitive information, cause a DoS condition, or execute arbitrary code with the privileges of the application.
Functional code that exploits this vulnerability is available as part of the Metasploit framework.
PHP has confirmed this vulnerability and released updated software.
Warning Indicators
PHP versions 5.4.1 and prior are vulnerable.
IntelliShield Analysis
The vulnerability could be exploitable only on installations that use the HTTP server, such as the Apache server, which allows a particular CGI specification while implementing the php-cgi setup.
To exploit this vulnerability, the attacker would need to send crafted requests to the targeted system. To achieve this objective, the attacker may need access to trusted, internal networks. This access requirement decreases the likelihood of a successful exploit.
Vendor Announcements
PHP has released a bug report at the following link: Sec Bug: 61910
Apple has released security advisory at the following link: HT5501
An unauthenticated, remote attacker could exploit the vulnerability to disclose source code information, cause a DoS condition, or execute arbitrary code with application privileges.
Technical Information
The vulnerability is in the /cgi-bin/php5-cgi binary due to insufficient sanitization of user-supplied input. The affected application, when implemented in the CGI-based setup, could incorrectly handle the processed HTTP query string parameter as command-line arguments to the binary and could allow arbitrary command execution.
An unauthenticated, remote attacker could exploit the vulnerability by transmitting crafted HTTP requests with -s, -d, or -c command-line switches to disclose sensitive source code information, cause a DoS condition, or execute arbitrary code with the privileges of the application.
Safeguards
Administrators are advised to apply the appropriate updates.
Administrators may consider using IP-based access control lists (ACLs) to allow only trusted systems to access the affected systems.
Administrators are advised to allow only trusted users to have network access.
Administrators are advised to monitor affected systems.
Patches/Software
PHP has released updated software at the following links:
Version 12, August 23, 2012, 10:48 AM: HP has re-released a security bulletin and updated software to address the PHP php5-cgi binary setup remote unsanitized command-line parameter processing vulnerability.
Version 11, June 29, 2012, 9:55 AM: HP has released an additional security bulletin and updated software to address the PHP php5-cgi binary setup remote unsanitized command-line parameter processing vulnerability.
Version 10, June 15, 2012, 1:59 PM: HP has released a security bulletin and updated software to address the PHP php5-cgi binary setup remote unsanitized command-line parameter processing vulnerability.
Version 9, May 22, 2012, 2:00 PM: FreeBSD has released an additional VuXML document and updated ports collection to address the PHP php5-cgi binary setup remote unsanitized command-line parameter processing vulnerability.
Version 8, May 14, 2012, 9:11 AM: Red Hat has released a security advisory and updated software to address the php5-cgi binary setup remote unsanitized command-line parameter processing vulnerability.
Version 7, May 11, 2012, 9:30 AM: Red Hat has released a security advisory and updated software to address the php5-cgi binary setup remote unsanitized command-line parameter processing vulnerability.
Version 6, May 9, 2012, 9:01 AM: PHP has released updated software to address the php5-cgi binary setup remote unsanitized command-line parameter processing vulnerability.
Version 5, May 8, 2012, 8:21 AM: Red Hat has released additional security advisories and updated packages to address the PHP php5-cgi binary setup remote unsanitized command-line parameter processing vulnerability. CentOS has also released updated packages to address this vulnerability.
Version 4, May 7, 2012, 9:44 AM: FreeBSD has released a VuXML document and updated ports collection to address the PHP php5-cgi binary setup remote unsanitized command-line parameter processing vulnerability.
Version 3, May 4, 2012, 1:40 PM: Functional code that demonstrates an exploit of the php5-cgi binary setup remote unsanitized command-line parameter processing vulnerability is publicly available.
Version 2, May 4, 2012, 1:27 PM: PHP has released a changelog and updated software to address the php5-cgi binary setup remote unsanitized command-line parameter processing vulnerability.
Version 1, May 3, 2012, 2:26 PM: PHP contains a vulnerability that could allow an unauthenticated, remote attacker to execute arbitrary code, disclose sensitive information, or cause a denial of service condition on a targeted system. Updates are not available.
The security vulnerability applies to the following combinations of products.
Primary Products:
php
php
5.0.0 Base | 5.0.1 Base | 5.0.2 Base | 5.0.3 Base | 5.0.4 Base | 5.0.5 Base | 5.1.0 Base | 5.1.1 Base | 5.1.2 Base | 5.1.3 Base | 5.1.4 Base | 5.1.5 Base | 5.1.6 Base | 5.2.0 Base | 5.2.1 Base | 5.2.10 Base | 5.2.11 Base | 5.2.2 Base | 5.2.3 Base | 5.2.4 Base | 5.2.5 Base | 5.2.6 Base | 5.2.7 Base | 5.2.8 Base | 5.2.9 -1 (for Windows), Base | 5.3.0 Base | 5.3.1 Base | 5.3.10 Base | 5.3.11 Base | 5.3.2 Base | 5.3.3 Base | 5.3.4 Base | 5.3.5 Base | 5.3.6 Base | 5.3.7 Base | 5.3.8 Base | 5.3.9 Base | 5.4.0 Base | 5.4.1 Base
Associated Products:
Apple
Mac OS X
10.6.1 Intel, PPC | 10.6.2 Base | 10.6.3 Base | 10.6.4 Base | 10.6.5 Base | 10.6.6 Base | 10.6.7 Base | 10.6.8 Base | 10.7 Base | 10.7.1 Base | 10.7.2 Base | 10.7.3 Base | 10.7.4 Base | 10.8 .1, Base | 10.8.1 Base
Apple
Mac OS X Server
10.6.1 Intel, PPC | 10.6.2 Base | 10.6.3 Base | 10.6.4 Base | 10.6.5 Base | 10.6.6 Base | 10.6.7 Base | 10.6.8 Base | 10.7 Base | 10.7.1 Base | 10.7.2 Base | 10.7.3 Base | 10.7.4 Base | 10.8.0 Base | 10.8.1 Base
6.3 Base | 6.4 Base | 7.0 Base | 7.1 Base | 7.2 Base | 7.3 Base | 7.4 Base | 8.0 Base | 8.1 Base | 8.2 Base | 8.3 Base | 9.0 Base
HP
HP-UX
11.11/11i Base | 11.23 Base | 11.31 Base
HP
HP-UX Web Server Suite (HPUXWSSUITE)
2.0 Base | 2.22 Base | 2.33 Base | 2.34 Base | 2.35 Base | 3.0 Base | 3.12 Base | 3.13 Base | 3.14 Base | 3.15 Base | 3.17 Base | 3.18 Base | 3.19 Base | 3.20 Base | 3.21 Base | 3.22 Base | 3.23 Base
HP
System Management Homepage (SMH)
6.0.0 Base | 6.1 Base | 6.2 Base | 7.0 Base | 7.1 Base
Red Hat, Inc.
Red Hat Application Stack
2 ia-32, x86_64
Red Hat, Inc.
Red Hat Enterprise Linux
5 IA-32, IA-64, PPC, s390x, x86_64
Red Hat, Inc.
Red Hat Enterprise Linux Desktop
6 IA-32, x86_64
Red Hat, Inc.
Red Hat Enterprise Linux Desktop Workstation
5 IA-32, x86-64
Red Hat, Inc.
Red Hat Enterprise Linux EUS (Extended Update Supp
5.6.z IA-32, IA-64, PPC, s390x, x86_64
Red Hat, Inc.
Red Hat Enterprise Linux HPC Node
6 x86_64
Red Hat, Inc.
Red Hat Enterprise Linux Long Life
5.6 i386, ia64, x86_64
Red Hat, Inc.
Red Hat Enterprise Linux Server
6 IA-32, PPC 64, s390x, x86_64
Red Hat, Inc.
Red Hat Enterprise Linux Server AUS
6.2 IA-32, x86_64
Red Hat, Inc.
Red Hat Enterprise Linux Server EUS
6.2.z IA-32, PPC64, s390x, x86_64
Red Hat, Inc.
Red Hat Enterprise Linux Workstation
6 IA-32, x86_64
Alerts and bulletins on the Cisco Security Intelligence Operations Portal are highlighted by analysts in the
Cisco Threat Operations Center and represent a subset of the comprehensive content that is available through Cisco Security IntelliShield Alert Manager Service.
This customizable threat and vulnerability alert service provides security staff with access to timely, accurate, and credible information about threats and vulnerabilities that may affect their environment. Cisco is pleased to offer a free trial of the service.
To register for full access, please visit the IntelliShield trial registration page.
LEGAL DISCLAIMER The urgency and severity ratings of this alert are not tailored to individual users; users may value alerts differently based upon their network configurations and circumstances. THE ALERT, AND INFORMATION CONTAINED THEREIN, ARE PROVIDED ON AN "AS IS" BASIS AND DO NOT IMPLY ANY KIND OF GUARANTEE OR WARRANTY, INCLUDING THE WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR USE. YOUR USE OF THE ALERT, AND INFORMATION CONTAINED THEREIN, OR MATERIALS LINKED FROM THE ALERT, IS AT YOUR OWN RISK. INFORMATION IN THIS ALERT AND ANY RELATED COMMUNICATIONS IS BASED ON OUR KNOWLEDGE AT THE TIME OF PUBLICATION AND IS SUBJECT TO CHANGE WITHOUT NOTICE. CISCO RESERVES THE RIGHT TO CHANGE OR UPDATE ALERTS AT ANY TIME.