PHP gdImageCopyResized() buffer overflow
| php-gdimagecopyresized-bo (36383) |
Description:
PHP is vulnerable to a heap-based buffer overflow, caused by an integer overflow error in the gdImageCopyResized() function. By passing overly large integer value parameters to the imagecopyresized() or imagecopyresampled() PHP functions, a remote attacker could overflow a buffer and possibly execute arbitrary code on the system.
*CVSS:
| Base Score: | 10 |
| Access Vector: | Network |
| Access Complexity: | Low |
| Authentication: | None |
| Confidentiality Impact: | Complete |
| Integrity Impact: | Complete |
| Availability Impact: | Complete |
| Temporal Score: | 8.3 |
| Exploitability: | Functional |
| Remediation Level: | Official-Fix |
| Report Confidence: | Confirmed |
Consequences:
Gain Access
Remedy:
Upgrade to the latest version of PHP (5.2.4 or later), available from the PHP Web site. See References.
For Red Hat Linux (PHP):
Refer to RHSA-2007:0890-2 for patch, upgrade, or suggested workaround information. See References.
For other distributions:
Contact your vendor for upgrade or patch information.
References:
- PHP Web site: PHP 5.2.4 Release Announcement.
- SECWEB Web site: PHP ImageCopyResized/ImageCopyResampled Integer Overflow.
- ASA-2007-449: PHP security updates (RHSA-2007-0888 RHSA-2007-0889 & RHSA-2007-0890)
- ASA-2007-478: PHP security update (RHSA-2007-0891)
- CVE-2007-3996: Multiple integer overflows in libgd in PHP before 5.2.4 allow remote attackers to cause a denial of service (application crash) and possibly execute arbitrary code via a large (1) srcW or (2) srcH value to the (a) gdImageCopyResized function, or a large (3) sy (height) or (4) sx (width) value to the (b) gdImageCreate or the (c) gdImageCreateTrueColor function.
- DSA-1613: libgd2 -- multiple vulnerabilities
- GLSA-200710-02: PHP: Multiple vulnerabilities
- MDKSA-2007:187: Updated PHP packages fix numerous vulnerabilities
- MDVSA-2009:264: gd
- RHSA-2007-0888: Moderate: php security update
- RHSA-2007-0889: Moderate: php security update
- RHSA-2007-0890: Moderate: php security update
- RHSA-2007-0891: Moderate: php security update
- RHSA-2007-0917: Moderate: php security update
- SA26642: PHP Multiple Vulnerabilities
- SA27545: Avaya Products PHP Multiple Vulnerabilities
- SUSE-SA:2008:004: php5 php4 Security Problems
- USN-557-1: GD library vulnerability
- USN-720-1: PHP vulnerabilities
- VUPEN/ADV-2007-3023: PHP Multiple Function and Extension Code Execution and Security Bypass Issues
Platforms Affected:
- Canonical Ubuntu 6.06 LTS
- Canonical Ubuntu 6.10
- Canonical Ubuntu 7.04
- Canonical Ubuntu 7.10
- Canonical Ubuntu 8.04 LTS
- Canonical Ubuntu 8.10
- Debian Debian Linux 4.0
- Gentoo Linux
- MandrakeSoft Mandrake Linux 2007
- MandrakeSoft Mandrake Linux 2007 X86_64
- MandrakeSoft Mandrake Linux 2007.1 X86_64
- MandrakeSoft Mandrake Linux 2007.1
- MandrakeSoft Mandrake Linux Corporate Server 3.0
- MandrakeSoft Mandrake Linux Corporate Server 3.0 X86_64
- MandrakeSoft Mandrake Linux Corporate Server 4.0
- MandrakeSoft Mandrake Linux Corporate Server 4.0 X86_64
- MandrakeSoft Mandrake Multi Network Firewall 2.0
- Novell Linux Desktop 9
- Novell Linux Desktop 9 SDK
- Novell Linux POS 9
- Novell Open Enterprise Server
- Novell Open Enterprise Server
- Novell OpenSUSE 10.2
- Novell OpenSUSE 10.3
- Novell SLE SDK 10 SP1
- Novell SLE SDK 10
- Novell SUSE Linux Enterprise Desktop 10 SP1
- Novell SUSE Linux Enterprise Server 10 SP1
- Novell SUSE Linux Enterprise Server 10
- PHP PHP 5.0.0 RC1
- PHP PHP 5.0.0 Beta4
- PHP PHP 5.0.0 Beta3
- PHP PHP 5.0.0 RC2
- PHP PHP 5.0.0 RC3
- PHP PHP 5.0.0 Beta1
- PHP PHP 5.0.0 Beta2
- PHP PHP 5.0.0
- PHP PHP 5.0.1
- PHP PHP 5.0.2
- PHP PHP 5.0.3
- PHP PHP 5.0.4
- PHP PHP 5.0.5
- PHP PHP 5.1.0
- PHP PHP 5.1.1
- PHP PHP 5.1.2
- PHP PHP 5.1.3
- PHP PHP 5.1.4
- PHP PHP 5.1.5
- PHP PHP 5.1.6
- PHP PHP 5.2.0
- PHP PHP 5.2.1
- PHP PHP 5.2.2
- PHP PHP 5.2.3
- RedHat Application Stack v1 for EL AS 4
- RedHat Application Stack v1 for EL ES 4
- RedHat Enterprise Linux 2.1 WS
- RedHat Enterprise Linux 2.1 ES
- RedHat Enterprise Linux 2.1 AS
- RedHat Enterprise Linux 3 AS
- RedHat Enterprise Linux 3 ES
- RedHat Enterprise Linux 3 Desktop
- RedHat Enterprise Linux 3 WS
- RedHat Enterprise Linux 4 AS
- RedHat Enterprise Linux 4 ES
- RedHat Enterprise Linux 4 WS
- RedHat Enterprise Linux 4 Desktop
- RedHat Enterprise Linux 5 Server
- RedHat Enterprise Linux 5
- RedHat Enterprise Linux 5 Client Workstation
- RedHat Enterprise Linux Desktop 5.0
- RedHat Linux Advanced Workstation 2.1 Itanium
- RedHat RHEL Application Stack 2
- SuSE SuSE SLES 9
Reported:
Aug 30, 2007
The information within this database may change without notice. Use of this information constitutes acceptance for use in an AS IS condition. There are NO warranties, implied or otherwise, with regard to this information or its use. Any use of this information is at the user's risk. In no event shall the author/distributor (IBM Internet Security Systems X-Force) be held liable for any damages whatsoever arising out of or in connection with the use or spread of this information.
For corrections or additions please email xforce@iss.net
* According to the Forum of Incident Response and Security Teams (FIRST), the Common Vulnerability Scoring System (CVSS) is an "industry open standard designed to convey vulnerability severity and help to determine urgency and priority of response." IBM PROVIDES THE CVSS SCORES "AS IS" WITHOUT WARRANTY OF ANY KIND, INCLUDING THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. CUSTOMERS ARE RESPONSIBLE FOR ASSESSING THE IMPACT OF ANY ACTUAL OR POTENTIAL SECURITY VULNERABILITY.
The information within this database may change without notice. Use of this information constitutes acceptance for use in an AS IS condition. There are NO warranties, implied or otherwise, with regard to this information or its use. Any use of this information is at the user's risk. In no event shall IBM be held liable for any damages whatsoever arising out of or in connection with the use or spread of this information.
