From: jim at centerfuse dot net
Operating system: FreeBSD 4.11
PHP version: 5.1.6
PHP Bug Type: Safe Mode/open_basedir
Bug description: safe_mode_include_dir not honored
Description:
------------
Just upgraded to php 5.1.6, and safe_mode_include_dir doesn't appear to be
honored. I'm running with safe mode = On and one directory in the
include_dir. Trying to include/fopen/etc any file from that directory
results in a safemode UID restriction. phpinfo() shows that PHP is reading
the correct configuration file and that it knows about
safe_mode_include_dir.
Reproduce code:
---------------
//in php.ini: safe_mode_include_dir = "/usr/local/share/FUSE")
$fp = fopen('/usr/local/share/FUSE/FUSE-main.php', 'r')
Expected result:
----------------
fopen should return file pointer
Actual result:
--------------
Warning: fopen() [function.fopen]: SAFE MODE Restriction in effect. The
script whose uid is 1006 is not allowed to access
/usr/local/share/FUSE/FUSE-main.php owned by uid 0 in
/home/context/public_html/test.php on line 13
--
Edit bug report at http://bugs.php.net/?id=39073&edit=1
--
Try a CVS snapshot (PHP 4.4):
http://bugs.php.net/fix.php?id=39073&r=trysnapshot44
Try a CVS snapshot (PHP 5.2):
http://bugs.php.net/fix.php?id=39073&r=trysnapshot52
Try a CVS snapshot (PHP 6.0):
http://bugs.php.net/fix.php?id=39073&r=trysnapshot60
Fixed in CVS: http://bugs.php.net/fix.php?id=39073&r=fixedcvs
Fixed in release:
http://bugs.php.net/fix.php?id=39073&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=39073&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=39073&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=39073&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=39073&r=support
Expected behavior: http://bugs.php.net/fix.php?id=39073&r=notwrong
Not enough info:
http://bugs.php.net/fix.php?id=39073&r=notenoughinfo
Submitted twice:
http://bugs.php.net/fix.php?id=39073&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=39073&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=39073&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=39073&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=39073&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=39073&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=39073&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=39073&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=39073&r=mysqlcfg