CVE-2009-4142

PHP <5.2.12 - XSS

Title source: llm

Description

The htmlspecialchars function in PHP before 5.2.12 does not properly handle (1) overlong UTF-8 sequences, (2) invalid Shift_JIS sequences, and (3) invalid EUC-JP sequences, which allows remote attackers to conduct cross-site scripting (XSS) attacks by placing a crafted byte sequence before a special character.

Exploits (2)

exploitdb WORKING POC VERIFIED
by [email protected] · phpremotephp
https://www.exploit-db.com/exploits/33415
exploitdb WORKING POC VERIFIED
by [email protected] · phpremotephp
https://www.exploit-db.com/exploits/33414

Scores

EPSS 0.1695
EPSS Percentile 94.9%

Classification

CWE
CWE-79
Status published

Affected Products (50)

php/php < 5.2.11
php/php
php/php
php/php
php/php
php/php
php/php
php/php
php/php
php/php
php/php
php/php
php/php
php/php
php/php
... and 35 more

Timeline

Published Dec 21, 2009
Tracked Since Feb 18, 2026