PHP Input Validation Flaw in htmlspecialchars() Permits Cross-Site Scripting Attacks
|
|
SecurityTracker Alert ID: 1023372 |
|
SecurityTracker URL: http://securitytracker.com/id/1023372
|
|
CVE Reference:
CVE-2009-4142
(Links to External Site)
|
Date: Dec 18 2009
|
Impact:
Disclosure of authentication information, Disclosure of user information, Execution of arbitrary code via network, Modification of user information
|
Fix Available: Yes Vendor Confirmed: Yes Exploit Included: Yes
|
Version(s): 5.2 prior to 5.2.12
|
Description:
A vulnerability was reported in PHP. A remote user can conduct cross-site scripting attacks.
The htmlspecialchars() function does not properly filter HTML code from user-supplied input before returning the input. A remote user can cause arbitrary scripting code to be executed by the target user's browser. The code will originate from the site running the PHP software and will run in the security context of that site. As a result, the code will be able to access the target user's cookies (including authentication cookies), if any, associated with the site, access data recently submitted by the target user via web form to the site, or take actions on the site acting as the target user.
A demonstration exploit is available at:
http://d.hatena.ne.jp/t_komura/20091004/1254665511
Moriyoshi (hello at iwamot dot com) reported this vulnerability.
|
Impact:
A remote user can access the target user's cookies (including authentication cookies), if any, associated with the site running the PHP software, access data recently submitted by the target user via web form to the site, or take actions on the site acting as the target user.
|
Solution:
The vendor has issued a fix (5.2.12).
|
Vendor URL: www.php.net/ (Links to External Site)
|
Cause:
Input validation error
|
Underlying OS:
Linux (Any), UNIX (Any), Windows (Any)
|
|
Message History:
This archive entry has one or more follow-up message(s) listed below.
|
Source Message Contents
|
Date: Fri, 18 Dec 2009 07:21:44 +0000
Subject: PHP
|
* Fixed bug #49785 (insufficient input string validation of htmlspecialchars()). (CVE-2009-4142, Moriyoshi, hello at iwamot dot com)
|
|