php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #72796 preg_replace crash apache (Segm.fault(11) on Linux, 3221225725 on Windows)
Submitted: 2016-08-09 14:03 UTC Modified: 2016-08-21 04:22 UTC
From: vlczech at vlczech dot cz Assigned: cmb (profile)
Status: No Feedback Package: *Regular Expressions
PHP Version: 5.6.24 OS: Windows / Linux
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2016-08-09 14:03 UTC] vlczech at vlczech dot cz
Description:
------------
preg_replace("#('(\\\\.|[^'\\\\])*')#sU", "$1", $content);
or
preg_replace('#(\'(\\\\.|[^\'\\\\])*\')#sU', '$1', $content);

where $content is content of jquery.min.js of version 1.11.0 (https://code.jquery.com/jquery-1.11.0.min.js), which was loaded to $content by function file_get_contents.

Linux with PHP 5.4.16:
[Tue Aug 09 14:41:26.597648 2016] [core:notice] [pid 1409] AH00052: child pid 13046 exit signal Segmentation fault (11)

Windows 10 with PHP 5.6.12:
Parent: child process 18044 exited with status 3221225725 -- Restarting.


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2016-08-09 16:32 UTC] cmb@php.net
-Status: Open +Status: Feedback -Assigned To: +Assigned To: cmb
 [2016-08-09 16:32 UTC] cmb@php.net
Thank you for this bug report. To properly diagnose the problem, we
need a backtrace to see what is happening behind the scenes. To
find out how to generate a backtrace, please read
http://bugs.php.net/bugs-generating-backtrace.php for *NIX and
http://bugs.php.net/bugs-generating-backtrace-win32.php for Win32

Once you have generated a backtrace, please submit it to this bug
report and change the status back to "Open". Thank you for helping
us make PHP better.

I can't reproduce that with php-5.6.12-nts-Win32-VC11-x86 or
php-5.6.23-nts-Win32-VC11-x86.
 [2016-08-21 04:22 UTC] php-bugs at lists dot php dot net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Mar 29 13:01:29 2024 UTC