From:             phpbugs at thequod dot de
Operating system: Ubuntu Linux
PHP version:      5CVS-2006-10-11 (CVS)
PHP Bug Type:     Safe Mode/open_basedir
Bug description:  upload_tmp_dir with trailing slash in open_basedir causes 
uploads to fail

Description:
------------
I have no upload_tmp_dir set, so it seems to use "/tmp".

I have added "/tmp/" to open_basedir (despite the fact 
that this was not necessary before - see 
http://bugs.php.net/38934).

Upload in PHP_5_2 fails with:
[11-Oct-2006 03:26:35] PHP Warning:  Unknown: open_basedir 
restriction in effect. File(/tmp) is not within the 
allowed path(s): 
(/web7/:/var/www/web7/:/tmp/:/var/www/usr/local/share/php/:/usr/local/share/php/)

in Unknown on line 0
[11-Oct-2006 03:26:35] PHP Warning:  File upload error - 
unable to create a temporary file in Unknown on line 0

This is a regression to PHP_5_1, where it works like this!

Setting upload_tmp_dir=/tmp/ (with ending slash) fixes it 
also for PHP_5_2.

Reproduce code:
---------------
Any upload form, there are two in the other bug refered above.

Expected result:
----------------
Upload works.

Actual result:
--------------
Upload does not work.

-- 
Edit bug report at http://bugs.php.net/?id=39123&edit=1
-- 
Try a CVS snapshot (PHP 4.4): 
http://bugs.php.net/fix.php?id=39123&r=trysnapshot44
Try a CVS snapshot (PHP 5.2): 
http://bugs.php.net/fix.php?id=39123&r=trysnapshot52
Try a CVS snapshot (PHP 6.0): 
http://bugs.php.net/fix.php?id=39123&r=trysnapshot60
Fixed in CVS:                 http://bugs.php.net/fix.php?id=39123&r=fixedcvs
Fixed in release:             
http://bugs.php.net/fix.php?id=39123&r=alreadyfixed
Need backtrace:               http://bugs.php.net/fix.php?id=39123&r=needtrace
Need Reproduce Script:        http://bugs.php.net/fix.php?id=39123&r=needscript
Try newer version:            http://bugs.php.net/fix.php?id=39123&r=oldversion
Not developer issue:          http://bugs.php.net/fix.php?id=39123&r=support
Expected behavior:            http://bugs.php.net/fix.php?id=39123&r=notwrong
Not enough info:              
http://bugs.php.net/fix.php?id=39123&r=notenoughinfo
Submitted twice:              
http://bugs.php.net/fix.php?id=39123&r=submittedtwice
register_globals:             http://bugs.php.net/fix.php?id=39123&r=globals
PHP 3 support discontinued:   http://bugs.php.net/fix.php?id=39123&r=php3
Daylight Savings:             http://bugs.php.net/fix.php?id=39123&r=dst
IIS Stability:                http://bugs.php.net/fix.php?id=39123&r=isapi
Install GNU Sed:              http://bugs.php.net/fix.php?id=39123&r=gnused
Floating point limitations:   http://bugs.php.net/fix.php?id=39123&r=float
No Zend Extensions:           http://bugs.php.net/fix.php?id=39123&r=nozend
MySQL Configuration Error:    http://bugs.php.net/fix.php?id=39123&r=mysqlcfg

Reply via email to