From: php at kaiundina dot de Operating system: different PHP version: 5.1.2 PHP Bug Type: PCRE related Bug description: Apache crashes when using unicode matches for whitespace and control characters
Description: ------------ The statement in the reproduce code simply crashes my server (Win XP Pro, Apache 2, PHP 5.1.0, default-charset UTF 8) and that of my webhoster (Linux, Apache 2, PHP 5.1.2, default-charset Latin1) - time_limit, which is set to 30 s seems not to work. Executing the script via CLI produces the same result (but can be cancelled by Ctrl-C) The snipped shall look for adjacent blocks, each persisting of a separator character followed by one or more characters that aren't control- or separator-characters. Crashing is independent of the $aName-value and the result, the match would produce. The example is stripped down from a bigger pattern - always having to kill the webserver after each test is quite annoying :( Reproduce code: --------------- <?php $aName = 'My Name'; preg_match('/^(\\p{Z}[^\\p{C}\\p{Z}]+)*$/', $aName); ?> Expected result: ---------------- just nothing happens - the function returns and drops its result (false in this case, but doesn't matter) Actual result: -------------- Server "crashes": CPU usage is at 100% and Apache doesn't respond to a restart (php compiled as module). -- Edit bug report at http://bugs.php.net/?id=36553&edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=36553&r=trysnapshot44 Try a CVS snapshot (PHP 5.1): http://bugs.php.net/fix.php?id=36553&r=trysnapshot51 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=36553&r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=36553&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=36553&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=36553&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=36553&r=needscript Try newer version: http://bugs.php.net/fix.php?id=36553&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=36553&r=support Expected behavior: http://bugs.php.net/fix.php?id=36553&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=36553&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=36553&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=36553&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=36553&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=36553&r=dst IIS Stability: http://bugs.php.net/fix.php?id=36553&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=36553&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=36553&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=36553&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=36553&r=mysqlcfg