CentOS has released updated packages to address the PHP magic_quote_gpc security bypass remote SQL injection vulnerability.
Description
PHP versions 5.3.10 and prior contain a vulnerability that could allow an unauthenticated, remote attacker to conduct SQL injection attacks on an affected system.
The vulnerability exists because the affected software improperly handles imported environment variables. An unauthenticated, remote attacker could exploit this vulnerability to bypass security restrictions and execute arbitrary SQL commands on the affected database. Successful exploitation could allow the attacker to obtain sensitive information or to alter data that is contained in the database on the targeted system.
PHP has confirmed this vulnerability and updates are available.
Warning Indicators
PHP versions 5.3.10 and prior are vulnerable.
IntelliShield Analysis
To exploit this vulnerability, the attacker would need to send crafted requests to the targeted system. To achieve this objective, the attacker would need access to trusted, internal networks. This access requirement decreases the likelihood of a successful exploit.
Vendor Announcements
PHP has released a changelog at the following link: PHP 5.4.1
Apple has released security advisory at the following link: HT5501
Red Hat has released an official CVE statement and a security advisory for bug 789468 at the following links: CVE-2012-0831 and RHSA-2013:0514
Impact
An unauthenticated, remote attacker could exploit this vulnerability to execute arbitrary SQL commands on the affected database. Successful exploitation could allow the attacker to obtain sensitive information or alter data that is contained in the database on the targeted system.
Technical Information
The vulnerability exists because the affected software fails to properly perform a temporary change to the magic_quotes_gpc directive when importing environment variables. An unauthenticated, remote attacker could exploit this vulnerability by sending crafted requests to disable the magic_quotes_gpc setting, bypass security restrictions, and inject arbitrary SQL commands to the affected PHP-based application database.
Successful exploitation could allow the attacker to obtain sensitive information or to alter data that is contained in the affected database on the targeted system.
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 link: PHP 5.4.1 or later
Apple has released updated software at the following links:
CentOS packages can be updated using the up2date or yum command.
FreeBSD has released ports collection updates at the following link: Ports Collection Index
Red Hat has released updated software for registered subscribers at the following link: Red Hat Network
Red Hat packages can be updated on Red Hat Enterprise Linux versions 5 and later using the yum tool.
Alert History
Version 5, February 22, 2013, 8:14 AM: Red Hat has released a security advisory and updated packages to address the PHP magic_quote_gpc security bypass remote SQL injection vulnerability.
Version 4, September 24, 2012, 10:40 AM: Apple has released a security advisory and updated software to address the PHP magic_quote_gpc security bypass remote SQL injection vulnerability.
Version 3, May 1, 2012, 11:26 AM: FreeBSD has released a VuXML document and updated ports collection to address the PHP magic_quote_gpc security bypass remote SQL injection vulnerability.
Version 2, April 26, 2012, 11:43 AM: PHP has released a changelog and updated software to address the PHP magic_quote_gpc security bypass remote SQL injection vulnerability.
Version 1, February 15, 2012, 1:43 PM: PHP contains a vulnerability that could allow an unauthenticated, remote attacker to conduct SQL injection attacks. Updates are not available.
The security vulnerability applies to the following combinations of products.
Primary Products:
php
php
5.3.0 Base | 5.3.1 Base | 5.3.10 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
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 | 9.0 Base
Red Hat, Inc.
Red Hat Enterprise Linux Desktop
6 IA-32, x86_64
Red Hat, Inc.
Red Hat Enterprise Linux HPC Node
6 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 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.