ID:               50841
 Comment by:       paul dot sanchez at basicdays dot com
 Reported By:      paul dot sanchez at basicdays dot com
 Status:           Feedback
 Bug Type:         Safe Mode/open_basedir
 Operating System: win32 only - Windows 7
 PHP Version:      5.3.2RC1
 New Comment:

Hi jani:
There does not seem to be a compiled snapshot for windows posted on
windows.php.net at this time. I tried to compile php5.3-latest.tar.gz
myself, however I can't seem to get nmake to finish successfully at
this time. The Visual Studio compilers, bison, and flex were
successfully found.

Hi pajoye:
Open basedir is set to
open_basedir = "C:\inetpub\wwwroot;C:\Users\myname\WIP"

Thanks for your guys' responses.


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

[2010-01-27 01:56:21] [email protected]

What's the value of open basedir?

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

[2010-01-26 07:29:05] [email protected]

Please try using this snapshot:

  http://snaps.php.net/php5.3-latest.tar.gz
 
For Windows:

  http://windows.php.net/snapshots/



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

[2010-01-26 07:07:00] paul dot sanchez at basicdays dot com

Description:
------------
- Using the VC9 x86 Non Thread Safe 5.3.1 version and the 5.3.2RC1
version from windows.php.net
- IIS7 using fast cgi
- Script works when under C:\inetpub\wwwroot
- Script gives warning when it is running under a virtual directory or
application
- Problem does not exist when open_basedir is not set
- Following are some php.ini settings from development ini file
  - cgi.force_redirect = 0
  - cgi.fix_pathinfo = 1
  - fastcgi.impersonate = 1
  - fastcgi.logging = 0

Reproduce code:
---------------
<?php
$root = dirname(__FILE__);
echo $root;
echo 'phpinfo.php: ' . file_exists('test.php') . '<br>';
echo 'junk.php: ' . file_exists('junk.php') . '<br><br>';

echo 'phpinfo.php: ' . file_exists("$root/test.php") . '<br>';
echo 'junk.php: ' . file_exists("$root/junk.php") . '<br><br>';
?>

Expected result:
----------------
C:\Users\myname\WIP\myproject

test.php: 1
junk.php:

test.php: 1
junk.php:

Actual result:
--------------
C:\Users\myname\WIP\myproject

test.php: 1

Warning: file_exists() [function.file-exists.php]: open_basedir
restriction in effect. File(junk.php) is not within the allowed path(s):
(C:\inetpub\wwwroot;C:\Users\myname\WIP) in
C:\Users\myname\WIP\myproject\test.php on line 5
junk.php:

test.php: 1

Warning: file_exists() [function.file-exists.php]: open_basedir
restriction in effect. File(C:\Users\myname\WIP\myproject/junk.php) is
not within the allowed path(s): (C:\inetpub\wwwroot;C:\Users\myname\WIP)
in C:\Users\myname\WIP\myproject\test.php on line 8
junk.php:


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


-- 
Edit this bug report at http://bugs.php.net/?id=50841&edit=1

Reply via email to