Include a non-exist file caused segmentation fault

Bug #186547 reported by Finjon Kiang
4
Affects Status Importance Assigned to Milestone
php5 (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

Binary package hint: libapache2-mod-php5

Test script:
<?php include('this_file_is_not_there.php'); ?>

Apache Error log:
[Mon Jan 28 16:08:33 2008] [notice] child pid 14463 exit signal Segmentation fault (11)

Executed from command line:
php -q test.php

Warning: include(this_file_is_not_there.php): failed to open stream: No such file or directory in /home/kiang/public_html/test.php on line 1

Warning: include(): Failed opening 'this_file_is_not_there.php' for inclusion (include_path='.:/usr/share/php:/usr/share/pear') in /home/kiang/public_html/test.php on line 1

Environments:
dpkg -l | grep php5
ii libapache2-mod-php5 5.2.3-1ubuntu6.3 server-side, HTML-embedded scripting languag
ii php5 5.2.3-1ubuntu6.3 server-side, HTML-embedded scripting languag
rc php5-cgi 5.2.3-1ubuntu6 server-side, HTML-embedded scripting languag
ii php5-cli 5.2.3-1ubuntu6.3 command-line interpreter for the php5 script
ii php5-common 5.2.3-1ubuntu6.3 Common files for packages built from the php
ii php5-curl 5.2.3-1ubuntu6.3 CURL module for php5
ii php5-dev 5.2.3-1ubuntu6.3 Files for PHP5 module development
ii php5-gd 5.2.3-1ubuntu6.3 GD module for php5
ii php5-mcrypt 5.2.3-0ubuntu1 MCrypt module for php5
ii php5-mysql 5.2.3-1ubuntu6.3 MySQL module for php5
rc php5-pgsql 5.2.3-1ubuntu6 PostgreSQL module for php5
dpkg -l | grep apache
ii apache2 2.2.4-3build1 Next generation, scalable, extendable web se
ii apache2-mpm-prefork 2.2.4-3build1 Traditional model for Apache HTTPD
ii apache2-threaded-dev 2.2.4-3build1 development headers for apache2
ii apache2-utils 2.2.4-3build1 utility programs for webservers
ii apache2.2-common 2.2.4-3build1 Next generation, scalable, extendable web se
ii libapache2-mod-php5 5.2.3-1ubuntu6.3 server-side, HTML-embedded scripting languag
ii libapache2-mod-python 3.3.1-2 Apache 2 module that embeds Python within th
ii libapache2-svn 1.4.4dfsg1-1ubuntu3 Subversion server modules for Apache

Revision history for this message
Mathias Gug (mathiaz) wrote : Re: [Bug 186547] [NEW] Include a non-exist file caused segmentation fault

On Mon, Jan 28, 2008 at 08:11:30AM -0000, Finjon Kiang wrote:
> Test script:
> <?php include('this_file_is_not_there.php'); ?>
>
> Apache Error log:
> [Mon Jan 28 16:08:33 2008] [notice] child pid 14463 exit signal Segmentation fault (11)
>
> Executed from command line:
> php -q test.php
>
> Warning: include(this_file_is_not_there.php): failed to open stream: No
> such file or directory in /home/kiang/public_html/test.php on line 1
>
> Warning: include(): Failed opening 'this_file_is_not_there.php' for
> inclusion (include_path='.:/usr/share/php:/usr/share/pear') in
> /home/kiang/public_html/test.php on line 1
>

I cannot reproduce your problem. A test script run under mod_php gives
the expected result (same as the command line output).

Could you post the list of your enabled modules ? (ls -l
/etc/apache2/mods-enabled)
Could you attach your apache configuration ?

  status incomplete

--
Mathias

Changed in php5:
status: New → Incomplete
Revision history for this message
Finjon Kiang (kiange) wrote :

# ls -l /etc/apache2/mods-enabled/
lrwxrwxrwx 1 root root 28 2007-10-16 11:37 alias.conf -> ../mods-available/alias.conf
lrwxrwxrwx 1 root root 28 2007-10-16 11:37 alias.load -> ../mods-available/alias.load
lrwxrwxrwx 1 root root 33 2007-10-16 11:37 auth_basic.load -> ../mods-available/auth_basic.load
lrwxrwxrwx 1 root root 33 2007-10-16 11:37 authn_file.load -> ../mods-available/authn_file.load
lrwxrwxrwx 1 root root 36 2007-10-16 11:37 authz_default.load -> ../mods-available/authz_default.load
lrwxrwxrwx 1 root root 38 2007-10-16 11:37 authz_groupfile.load -> ../mods-available/authz_groupfile.load
lrwxrwxrwx 1 root root 33 2007-10-16 11:37 authz_host.load -> ../mods-available/authz_host.load
lrwxrwxrwx 1 root root 33 2007-10-16 11:37 authz_user.load -> ../mods-available/authz_user.load
lrwxrwxrwx 1 root root 32 2007-10-16 11:37 autoindex.conf -> ../mods-available/autoindex.conf
lrwxrwxrwx 1 root root 32 2007-10-16 11:37 autoindex.load -> ../mods-available/autoindex.load
lrwxrwxrwx 1 root root 26 2008-01-29 09:00 cgi.load -> ../mods-available/cgi.load
lrwxrwxrwx 1 root root 26 2008-01-09 19:06 dav.load -> ../mods-available/dav.load
lrwxrwxrwx 1 root root 30 2008-01-09 19:06 dav_svn.conf -> ../mods-available/dav_svn.conf
lrwxrwxrwx 1 root root 30 2008-01-09 19:06 dav_svn.load -> ../mods-available/dav_svn.load
lrwxrwxrwx 1 root root 26 2007-10-16 11:37 dir.conf -> ../mods-available/dir.conf
lrwxrwxrwx 1 root root 26 2007-10-16 11:37 dir.load -> ../mods-available/dir.load
lrwxrwxrwx 1 root root 26 2007-10-16 11:37 env.load -> ../mods-available/env.load
lrwxrwxrwx 1 root root 27 2007-10-16 11:37 mime.conf -> ../mods-available/mime.conf
lrwxrwxrwx 1 root root 27 2007-10-16 11:37 mime.load -> ../mods-available/mime.load
lrwxrwxrwx 1 root root 33 2008-01-09 18:39 mod_python.load -> ../mods-available/mod_python.load
lrwxrwxrwx 1 root root 34 2007-10-16 11:37 negotiation.conf -> ../mods-available/negotiation.conf
lrwxrwxrwx 1 root root 34 2007-10-16 11:37 negotiation.load -> ../mods-available/negotiation.load
lrwxrwxrwx 1 root root 27 2008-01-29 09:02 php5.conf -> ../mods-available/php5.conf
lrwxrwxrwx 1 root root 27 2008-01-29 09:02 php5.load -> ../mods-available/php5.load
lrwxrwxrwx 1 root root 30 2007-10-25 09:41 rewrite.load -> ../mods-available/rewrite.load
lrwxrwxrwx 1 root root 31 2007-10-16 11:37 setenvif.conf -> ../mods-available/setenvif.conf
lrwxrwxrwx 1 root root 31 2007-10-16 11:37 setenvif.load -> ../mods-available/setenvif.load
lrwxrwxrwx 1 root root 26 2007-10-29 11:03 ssl.conf -> ../mods-available/ssl.conf
lrwxrwxrwx 1 root root 26 2007-10-29 11:03 ssl.load -> ../mods-available/ssl.load
lrwxrwxrwx 1 root root 29 2007-10-16 11:37 status.conf -> ../mods-available/status.conf
lrwxrwxrwx 1 root root 29 2007-10-16 11:37 status.load -> ../mods-available/status.load
lrwxrwxrwx 1 root root 30 2007-10-29 10:42 userdir.conf -> ../mods-available/userdir.conf
lrwxrwxrwx 1 root root 30 2007-10-29 10:42 userdir.load -> ../mods-available/userdir.load

The only file in /etc/apache2/conf.d/ is "charset"

Revision history for this message
Mathias Gug (mathiaz) wrote : Re: [Bug 186547] Re: Include a non-exist file caused segmentation fault

Could you try to disable your Trac configuration ?

Revision history for this message
Finjon Kiang (kiange) wrote :

I tried to remove lines below "Include /etc/apache2/sites-enabled/" in apache2.conf and restart apache. There's the same error.

I also tried to execute the test script both in user directory (/home/kiang/public_html) and root directory (/var/www). Both generated the same error message:

[Thu Jan 31 14:20:13 2008] [notice] child pid 10758 exit signal Segmentation fault (11)
[Thu Jan 31 14:25:19 2008] [notice] child pid 10761 exit signal Segmentation fault (11)

Revision history for this message
Connor Imes (ckimes) wrote :

Thank you for taking the time to report this bug and helping to make Ubuntu better. You reported this bug a while ago and there hasn't been any activity in it recently. We were wondering is this still an issue for you? Can you try with latest Ubuntu release? Thanks in advance.

Revision history for this message
Connor Imes (ckimes) wrote :

We are closing this bug report because it lacks the information we need to investigate the problem, as described in the previous comments. Please reopen it if you can give us the missing information, and don't hesitate to submit bug reports in the future. To reopen the bug report you can click on the current status, under the Status column, and change the Status back to "New". Thanks again!

Changed in php5:
status: Incomplete → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.