#48744 [Fbk->Opn]: Segmentation fault with open_basedir enabled

[email protected] ("tom at ideaweb dot de")
Newsgroups php.bugs
Message-ID <[email protected]>
 ID:               48744
 User updated by:  tom at ideaweb dot de
 Reported By:      tom at ideaweb dot de
-Status:           Feedback
+Status:           Open
 Bug Type:         Safe Mode/open_basedir
 Operating System: Linux Debian Etch
 PHP Version:      5.3.0
 New Comment:

Its really strange, because i have several php53 installations without

any trouble with the same configuration, but only on one dev server it

crashes. if you cannot reproduce, its not a big deal that you can get 
access to our dev server, there are not secrets and no data...

<VirtualHost *:80>

    ServerAdmin [email protected]

    ServerName ecodev.ecolint.ch
    ServerAlias ecm.ideaweb.de
    ServerAlias 217.169.129.40

    #ErrorDocument 404 /

    DocumentRoot /var/www/ecolint.ch/dev/ecolint/trunk/admin

    CustomLog /var/www/ecolint.ch/logs/access_log combined
    ErrorLog /var/www/ecolint.ch/logs/error_log

    <Directory /var/www/ecolint.ch/dev/ecolint/trunk/admin/>
        Options -MultiViews -Indexes -Includes +FollowSymlinks
        AllowOverride All
        Order allow,deny
        Allow from all
    </Directory>

    Alias /mysql/ /var/www/ecolint.ch/mysql/

    <Directory /var/www/ecolint.ch/mysql/>
        Options -MultiViews -Indexes -Includes -FollowSymlinks
        AllowOverride All
        Order allow,deny
        Allow from all
    </Directory>

    php_admin_flag register_globals off
    php_admin_flag magic_quotes_gpc off
    php_admin_flag magic_quotes_runtime off
    php_admin_value default_charset utf-8
    php_admin_value session.save_path /www/htdocs/ecolint.ch/tmp/
    php_admin_value upload_tmp_dir /www/htdocs/ecolint.ch/tmp/
    php_admin_value open_basedir 
/www/htdocs/ecolint.ch/dev:/www/htdocs/ecolint.ch/tmp:/www/htdocs/ecol
int.ch/mysql

    RewriteEngine On
    RewriteCond %{REQUEST_METHOD} ^(TRACE|TRACK)
    RewriteRule .* - [F]

</VirtualHost>


Previous Comments:
------------------------------------------------------------------------

[2009-07-01 05:56:00] [email protected]

I can't reproduce this.  Where in your apache.conf do you have that
line?  As in which config blocks is it inside?

------------------------------------------------------------------------

[2009-06-30 16:40:31] tom at ideaweb dot de

Description:
------------
Segmentation fault if the following line is enabled in apache.conf:

php_admin_value open_basedir 
/www/htdocs/ecolint.ch/dev:/www/htdocs/ecolint.ch/tmp:/www/htdocs/ecol
int.ch/mysql

Maybe i made something wrong or its not a bug in php, because i not 
really understand the debug output, but i hope it helps =)

(gdb) run -X
Starting program: /www/apache/2.2.11/bin/httpd -X
Failed to read a valid object file image from memory.
[Thread debugging using libthread_db enabled]
[New Thread -1212832064 (LWP 4837)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread -1212832064 (LWP 4837)]
0xb757a7b7 in OnUpdateBaseDir (entry=0x824fba0, 
    new_value=0x83b6398 
"/www/htdocs/ecolint.ch/dev:/www/htdocs/ecolint.ch/tmp:/www/htdocs/eco
lint.ch/mysql", 
    new_value_length=82, mh_arg1=0x48, mh_arg2=0xb7b593a0, 
mh_arg3=0x0, stage=4) at /www/src/php-5.3.0/main/fopen_wrappers.c:103
103		if (!*p || !**p) {
(gdb) bt
#0  0xb757a7b7 in OnUpdateBaseDir (entry=0x824fba0, 
    new_value=0x83b6398 
"/www/htdocs/ecolint.ch/dev:/www/htdocs/ecolint.ch/tmp:/www/htdocs/eco
lint.ch/mysql", 
    new_value_length=82, mh_arg1=0x48, mh_arg2=0xb7b593a0, 
mh_arg3=0x0, stage=4) at /www/src/php-5.3.0/main/fopen_wrappers.c:103
#1  0xb75f6d09 in zend_alter_ini_entry_ex (name=0x819a670 
"open_basedir", name_length=13, 
    new_value=0x8228770 
"/www/htdocs/ecolint.ch/dev:/www/htdocs/ecolint.ch/tmp:/www/htdocs/eco
lint.ch/mysql", 
    new_value_length=82, modify_type=4, stage=4, force_change=0) at 
/www/src/php-5.3.0/Zend/zend_ini.c:285
#2  0xb75f6b0f in zend_alter_ini_entry (name=0x819a670 "open_basedir",

name_length=13, 
    new_value=0x8228770 
"/www/htdocs/ecolint.ch/dev:/www/htdocs/ecolint.ch/tmp:/www/htdocs/eco
lint.ch/mysql", 
    new_value_length=82, modify_type=4, stage=4) at /www/src/php-
5.3.0/Zend/zend_ini.c:243
#3  0xb76a86b6 in apply_config (dummy=0x8228df8) at /www/src/php-
5.3.0/sapi/apache2handler/apache_config.c:197
#4  0xb76a7a73 in php_handler (r=0x837fe30) at /www/src/php-
5.3.0/sapi/apache2handler/sapi_apache2.c:547
#5  0x0807dad7 in ap_run_handler (r=0x837fe30) at config.c:157
#6  0x08080bc7 in ap_invoke_handler (r=0x837fe30) at config.c:372
#7  0x080c8658 in ap_process_request (r=0x837fe30) at 
http_request.c:282
#8  0x080c581e in ap_process_http_connection (c=0x836fd40) at 
http_core.c:190
#9  0x08084a87 in ap_run_process_connection (c=0x836fd40) at 
connection.c:43
#10 0x080f846d in child_main (child_num_arg=<value optimized out>) at 
prefork.c:650
#11 0x080f86a5 in make_child (s=0x813d648, slot=0) at prefork.c:690
#12 0x080f944c in ap_mpm_run (_pconf=0x81380a8, plog=0x8188328, 
s=0x813d648) at prefork.c:966
#13 0x0806b44f in main (argc=135487648, argv=0x836db60) at main.c:740




------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=48744&edit=1
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.