From: [EMAIL PROTECTED]
Operating system: FreeBSD 4.7-STABLE
PHP version: 4.3.0
PHP Bug Type: Apache related
Bug description: can't turn open_basedir off anymore since 4.2.3 -> 4.3.0
I have this in my php.ini as default:
open_basedir = /var/www
I have a virtualhost block like this:
<VirtualHost 192.168.0.1>
ServerName "host.example.com"
DocumentRoot "/var/www/host.example.com/root"
<Directory "/var/www/host.example.com/root/admin">
Options Indexes ExecCgi
php_admin_value safe_mode 0
php_admin_value open_basedir "/"
</Directory>
</VirtualHost>
The goal is to force a default open_basedir of "/var/www" to everything,
except the explicitly specified /admin directory and contents (same with
safe_mode).
First, I read that setting the open_basedir to "/" doesn't work anymore in
http://bugs.php.net/bug.php?id=22101. Seems kinda weird as the
documentation states:
[The restriction specified with open_basedir is actually a prefix, not a
directory name. This means that "open_basedir = /dir/incl" also allows
access to "/dir/include" and "/dir/incls" if they exist. When you want to
restrict access to only the specified directory, end with a slash. For
example: "open_basedir = /dir/incl/"]
But besides that, specifying 'none' as open basedir in the virtualhost
doesn't turn it off, it uses the default of /var/www, and I haven't found
a way to set the open_basedir to NULL.
So, as I see it either the 'none' setting isn't working correctly and
needs to be fixed or the possibility of setting the open_basedir to "/"
needs to be put back in.
Unless I'm overseeing some very trivial way of turning the open_basedir
restriction off of course.
Thanks in advance.
--
Edit bug report at http://bugs.php.net/?id=22220&edit=1
--
Try a CVS snapshot: http://bugs.php.net/fix.php?id=22220&r=trysnapshot
Fixed in CVS: http://bugs.php.net/fix.php?id=22220&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=22220&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=22220&r=needtrace
Try newer version: http://bugs.php.net/fix.php?id=22220&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=22220&r=support
Expected behavior: http://bugs.php.net/fix.php?id=22220&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=22220&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=22220&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=22220&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=22220&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=22220&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=22220&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=22220&r=gnused