php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #64031 Apache2 crashes randomly
Submitted: 2013-01-20 11:14 UTC Modified: 2020-01-20 17:18 UTC
From: thomas dot munz at gmx dot at Assigned: derick (profile)
Status: Closed Package: Xdebug
PHP Version: 5.4.11 OS: Windows and Linux(Ubuntu)
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem:
14 - 5 = ?
Subscribe to this entry?

 
 [2013-01-20 11:14 UTC] thomas dot munz at gmx dot at
Description:
------------
Hallo!

I'm running Apache2.2 on a Windows and a Linux Ubuntu machine. On Linux PHP 
5.4.7 is running and on Windows PHP 5.4.11.

On both System I get the following error message when executing the same Code 
base. This is from the Apach2 Error log file:

[Sun Jan 20 11:45:49 2013] [error] [client 127.0.0.1] PHP Fatal error:  Uncaught 
exception 'Exception' with message 'Serialization of 'SimpleXMLElement' is not 
allowed' in [no active file]:0\nStack trace:\n#0 {main}\n  thrown in [no active 
file] on line 0
[Sun Jan 20 11:45:50 2013] [notice] child pid 5444 exit signal Segmentation 
fault (11)

This causes Apache to crash on windows and linux. In Apache access log, the 
request don't even show up.

Test script:
---------------
http://www.phptheatre.com/PHPTheatre.rar

1. Extract the files to your htdocs directpry
2. copy/rename bridge/default/global.config.php to local.config.php
3. modify the local.config.php and enter your mysql server data (user should have access to create DB)
4. run the php file tests/data/setup.php in the shell. This script will setup test datas
5. Open the follwoing file in the Browser: tests/HTML/index.php
6. Login with the username "visitor" and the password "password" on the top login form
7. Klick the "Program" Link in the top menu
8. Select on the Site a time to the right. 
9. A "Room Plan" will apear. Click on an Seat in the image. 
10. *Apache2 Crash*

The file/class that is handling this request, where the error happens is src/Core/Template/Site/ShowReservation.php, method "displayCinema"

Expected result:
----------------
No Apache2 crash.

-> Showing up a Room plan where the user selection get shown.

Actual result:
--------------
Apache2 crash on Windows and Linux

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2013-01-20 13:12 UTC] laruence@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.


 [2013-01-20 13:12 UTC] laruence@php.net
-Status: Open +Status: Feedback
 [2013-01-22 15:51 UTC] thomas dot munz at gmx dot at
-Status: Feedback +Status: Open -Package: Apache2 related +Package: Xdebug
 [2013-01-22 15:51 UTC] thomas dot munz at gmx dot at
Seams like its not in the PHP Core file, its a xdebug related problem

Thread 7 - System ID 7024
Entry point   libhttpd!ap_regkey_value_remove+1060 
Create time   22.01.2013 16:24:13 
Time spent in user mode   0 Days 0:0:0.62 
Time spent in kernel mode   0 Days 0:0:0.0 






Full Call Stack



Function     Arg 1     Arg 2     Arg 3     Arg 4   Source 
ntdll!NtRaiseException+12     01eee9e4     01eeea34     00000000     c0000005    
ntdll!KiUserExceptionDispatcher+29     01eee9e4     01eeea34     00000000     
c0000005    









Exception Information
PHP_XDEBUG!XDEBUG_INIT_OPARRAY+106D0WARNING - DebugDiag was not able to locate 
debug symbols for php_xdebug.dll, so the information below may be incomplete.



In 
httpd__PID__6644__Date__01_22_2013__Time_04_44_34PM__274__Second_Chance_Exceptio
n_C0000005.dmp the assembly instruction at php_xdebug!xdebug_init_oparray+106d0 
in D:\xampp\php\ext\php_xdebug.dll from Derick Rethans has caused an access 
violation exception (0xC0000005) when trying to read from memory location 
0x00000000 on thread 7





Module Information 
Image Name: D:\xampp\php\ext\php_xdebug.dll   Symbol Type:  Export 
Base address: 0x00905a4d   Time Stamp:  Sat Jul 14 23:46:38 2012  
Checksum: 0x00000000   Comments:  Thanks to Derick Rethans, Ilia Alshanetsky, 
Harald Radi 
COM DLL: False   Company Name:  Derick Rethans 
ISAPIExtension: False   File Description:  Xdebug 
ISAPIFilter: False   File Version:  2.2.1 
Managed DLL: False   Internal Name:  php_xdebug.dll 
VB DLL: False   Legal Copyright:  Copyright © 2002-2012 Derick Rethans 
Loaded Image Name:  php_xdebug.dll   Legal Trademarks:   
Mapped Image Name:     Original filename:  php_xdebug.dll 
Module name:  php_xdebug   Private Build:   
Single Threaded:  False   Product Name:  Xdebug 
Module Size:  172,00 KBytes   Product Version:  2.2.1 
Symbol File Name:  php_xdebug.dll   Special Build:  &
 [2013-01-30 16:05 UTC] thomas dot munz at gmx dot at
OK. I found the reason why this happen

I tried to store a SimpleXMLObject in the Session. If xdebug is not enabled, 
there will no error message show up except in the apache error log, that a 
serialization of SimpleXMLObject is not possible. But there is no Apache crash 
or error message showing up for the user -> Because it happens when the session 
will be saved on the server at the end of the request

But if you enable xdebug for it, it crashes apache when trying to handle a 
SimpleXMLObject from the session.

Actualy, it should not crash apache ins such a case but show a error dump.
 [2020-01-20 17:18 UTC] derick@php.net
-Status: Open +Status: Closed -Assigned To: +Assigned To: derick
 [2020-01-20 17:18 UTC] derick@php.net
If this is Xdebug related, please file a bug report at https://bugs.xdebug.org (but only if you use a supported version of PHP and Xdebug)
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Mar 29 11:01:29 2024 UTC