|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #27566 open_basedir errors but isn't active on vhost
Submitted: 2004-03-11 08:56 UTC Modified: 2005-01-31 22:52 UTC
From: foo at bserved dot nl Assigned:
Status: Closed Package: Safe Mode/open_basedir
PHP Version: 4.3.4 OS: RH Linux 7.3
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: foo at bserved dot nl
New email:
PHP Version: OS:


 [2004-03-11 08:56 UTC] foo at bserved dot nl
Webserver version: Apache/2.0.48 (Unix) mod_ssl/2.0.48 OpenSSL/0.9.6b PHP/4.3.4 

Not sure whether this _IS_ a php bug, but I guess it is..

Sometimes I get an error while opening a website on our server, when refreshing however, the error is gone.

We do have open_basedir set, but only on 1 vhost as you can see below.

Reproduce code:
The vhost used:

<VirtualHost *>
    RewriteEngine on
    RewriteOptions inherit
    DocumentRoot /usr/local/apache/htdocs
    ErrorLog /var/log/httpd/
    CustomLog /var/log/httpd/ common

The vhost with the open_basedir: 

   ServerAdmin root
   DocumentRoot /home/sites/xxxx
   ServerName xxxx
   php_admin_value open_basedir /home/sites/xxxx
   php_admin_value safe_mode On

Expected result:
No error, i guess.

Actual result:
Warning: Unknown(): open_basedir restriction in effect. File(/usr/local/apache/htdocs/-/index.php) is not within the allowed path(s): (/home/sites/xxxx) in Unknown on line 0

Warning: Unknown(/usr/local/apache/htdocs/-/index.php): failed to open stream: Operation not permitted in Unknown on line 0

Warning: (null)(): Failed opening '/usr/local/apache/htdocs/-/index.php' for inclusion (include_path='.:/usr/local/lib/php') in Unknown on line


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2004-03-11 09:00 UTC]
Please try using this CVS snapshot:
For Windows:

Sounds like configuration option leak problem that was 
 [2004-03-11 09:01 UTC] foo at bserved dot nl
nvm, already mentioned, sorry
 [2004-03-11 09:03 UTC] foo at bserved dot nl
Yes it indeed was fixed in 4.3.5, excuse me for being so ignorant.. :|
PHP Copyright © 2001-2020 The PHP Group
All rights reserved.
Last updated: Sat Feb 29 10:01:27 2020 UTC