Secunia - Stay Secure
Gartner
Home Corporate Website Jobs Updated Mailing Lists RSS Blog  Online Shop Advertise
Software Inspectors
  Scan Online
  Personal (PSI)
  Network (NSI 2.0)

Solutions For
  Security Professionals
  Security Vendors

Free Solutions For
  Open Communities
  Journalists & Media

Secunia Advisories
  Search
  Historic Advisories
  Listed By Product
  Listed By Vendor
  Statistics / Graphs
  Secunia Research
  Report Vulnerability
  About Advisories

Virus Information
  Chronological List
  Last 10 Virus Alerts
  About Virus Information

Secunia Customers
  Customer Area


PHP4 ZVAL Reference Counter Overflow and Cross-Site Scripting Advisory Available in Danish  Advisory Available in German 

Secunia Advisory: SA24356  
Release Date: 2007-03-05
Last Update: 2007-05-04

Critical:
Less critical
Impact: Security Bypass
Cross Site Scripting
Where: Local system
Solution Status: Partial Fix

Software:PHP 4.4.x

CVE reference:CVE-2007-1287 (Secunia mirror)



Description:
Stefan Esser has discovered some vulnerabilities in PHP4, which can be exploited by malicious, local users to bypass certain security restrictions, and by malicious people to conduct cross-site scripting attacks.

1) The vulnerability is caused due to an integer overflow in the handling of ZVAL structures. This can be exploited to corrupt memory and execute arbitrary code therefore bypassing security restrictions like the "disable_functions" directive.

The vulnerability is confirmed in version 4.4.6. Other versions may also be affected.

2) Input passed via array parameters is not properly sanitised before being returned to the user within a "phpinfo()" call. This can be exploited to execute arbitrary HTML and script code in a user's browser session in context of an affected site via a script calling "phpinfo()".

This is related to:
SA17371 (vulnerability #3)
SA19599 (vulnerability #1)

The vulnerability is confirmed in version 4.4.6 and also reported in versions 4.4.3 through 4.4.6. Other versions may also be affected.

Solution:
Update to version 4.4.7 to fix vulnerability #2. Grant only trusted users access to affected systems. PHP scripts calling "phpinfo()" should not be publicly accessible on production systems.

Provided and/or discovered by:
Stefan Esser

Changelog:
2007-03-05: Updated "Description" section. Added information about phpinfo() vulnerability.
2007-03-09: Added CVE reference.
2007-05-04: Updated "Solution" section.

Original Advisory:
PHP:
http://www.php.net/releases/4_4_7.php

MOPB:
1) http://www.php-security.org/MOPB/MOPB-01-2007.html
2) http://www.php-security.org/MOPB/MOPB-08-2007.html



Please note: The information that this Secunia Advisory is based on comes from a third party unless stated otherwise.

Secunia collects, validates, and verifies all vulnerability reports issued by security research groups, vendors, and others.

27 Related Secunia Security Advisories, displaying 10

1. PHP Multiple Vulnerabilities
2. PHP crypt() Race Condition Vulnerability
3. PHP "gdPngReadData()" Truncated PNG Data Denial of Service
4. PHP Multiple Vulnerabilities
5. PHP "readwbmp()" Integer Overflow Vulnerability
6. PHP Multiple Code Execution Vulnerabilities
7. PHP Interbase Extension "isc_attach_database()" Buffer Overflow
8. PHP Session Handling Double Free Vulnerabilities
9. PHP "snmpget()" and "session_decode()" Vulnerabilities
10. PHP MSSQL Extension NTWDBLIB.DLL "dbopen" Buffer Overflow

Show all related advisories


Send Feedback to Secunia

If you have new information regarding this Secunia advisory or a product in our database, please send it to us using either our web form or email us at vuln@secunia.com.

Ideas, suggestions, and other feedback are most welcome.








Secunia PSI
Scan | Patch | Track
Free Download

Secunia Poll

Do you think it's important to read Setup/User Guides for applications for use within your network?


See Results   


Most Popular Advisories

1.
Mozilla Firefox Multiple Vulnerabilities
2.
Opera for Windows Unspecified Code Execution
3.
VLC Media Player WAV Processing Integer Overflow
4.
Mozilla Thunderbird Multiple Vulnerabilities
5.
Opera Canvas Functions Information Disclosure
6.
PCRE pcre_compile.c Buffer Overflow Vulnerability
7.
Novell eDirectory ds.dlm Module Buffer Overflow
8.
Drupal Organic groups Information Disclosure and Script Insertion
9.
UnixWare ReliantHA Privilege Escalation Vulnerabilities
10.
XchangeBoard "boardID" SQL Injection Vulnerability





Vulnerability Management - Terms & Conditions - Copyright 2002-2008 Secunia - Compliance - Contact Secunia