#22101 [Bgs]: Wrong behaviour of open_basedir restriction

From: Date: Thu, 13 Feb 2003 06:51:39 +0000
Subject: #22101 [Bgs]: Wrong behaviour of open_basedir restriction
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-32984@lists.php.net to get a copy of this message
ID: 22101 User updated by: cmouse@quakenet.org Reported By: cmouse@quakenet.org Status: Bogus Bug Type: Scripting Engine problem Operating System: Debian linux 2.4.19 PHP Version: 4.3.0 New Comment: Sometimes there is... I only use open_basedir / (formerly though, now it's none) in apache configuration, since phpSysInfo needs to access few places outside the normal basedir /www. But *shrug* none seems to work, which it didn't do on the prev. version I had, 4.1.2 Previous Comments: ------------------------------------------------------------------------ [2003-02-13 00:48:50] sniper@php.net There's no point in putting / as basedir, like Rasmus said. ------------------------------------------------------------------------ [2003-02-13 00:44:59] cmouse@quakenet.org it seems that you can't use '/' as the open_basedir (as you could do in php 4.1.2). Dunno, maybe it's a good 'sanity' restriction, since the bug with defining 'none' as open_basedir has been fixed. Well... it seems that this was perhaps a bug in the user end ------------------------------------------------------------------------ [2003-02-09 14:20:51] d-e-a-t-h@gmx.net I have the same Problem under RedHat 7.1 with PSA (Plesk Server Administrator) 5.x. It seems that PHP 4.3.0 doesn't set the Open_Basedir recursively to Subdirectories. This is really mean because I have to include each Subdirectory which I would have out of the SaveMode, in my httpd.conf. ------------------------------------------------------------------------ [2003-02-06 20:27:37] rasmus@php.net I wouldn't be surprised if an open_basedir set to / wasn't handled correctly. It is one of these non-sensical settings that I suppose we should account for, but it really is meaningless. All you are doing is burning more system calls with absolutely no benefit since everything is under / ------------------------------------------------------------------------ [2003-02-06 19:58:56] cmouse@quakenet.org Warning: Unknown(): open_basedir restriction in effect. File(/www/htdocs/phpSysInfo-2.1/index.php) is not within the allowed path(s): (/) in Unknown on line 0 Warning: Unknown(/www/htdocs/phpSysInfo-2.1/index.php): failed to create stream: Operation not permitted in Unknown on line 0 Warning: Unknown(): Failed opening '/www/htdocs/phpSysInfo-2.1/index.php' for inclusion (include_path='.:/usr/lib/php') in Unknown on line 0 As you can see, /www is in my opinion, inside /, which is my open_basedir for this particular file. The Apache config for this directory: <Directory "/www/htdocs/phpSysInfo-2.1"> php_admin_value open_basedir "/" </Directory> You can get the phpSysInfo-2.1 script yourselves, too long to paste here, and it's not mine anyways. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=22101&edit=1

« previous php.bugs (#32984) next »