|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #55271 open_basedir_include_dir
Submitted: 2011-07-23 09:04 UTC Modified: 2021-05-30 04:22 UTC
Avg. Score:4.5 ± 0.5
Reproduced:2 of 2 (100.0%)
Same Version:0 (0.0%)
Same OS:0 (0.0%)
From: spamik at yum dot pl Assigned: cmb (profile)
Status: No Feedback Package: Safe Mode/open_basedir
PHP Version: 5.3.6 OS:
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: spamik at yum dot pl
New email:
PHP Version: OS:


 [2011-07-23 09:04 UTC] spamik at yum dot pl
I'd like to propose making new php.ini var - open_basedir_include_dir - like 
safe_mode_include_dir , which would allow accessing one dir (files only in it) 
when open_basedir is set to other dir. Usual aplication of this would be "/tmp".

Since 5.3.x php allows tightening open_basedir. However tempnam() function 
( does require as first 
parameter dir name. It does not take it from any php.ini var. So programmers had 
to hardcode in almost every program something like tempnam("/tmp",.... 
This makes open_basedir tightening useless as /tmp will remain unaccessible so 
tempnam() will fails. Solution would be open_basedir_include_dir ...


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2021-05-20 15:27 UTC]
-Status: Open +Status: Feedback -Assigned To: +Assigned To: cmb
 [2021-05-20 15:27 UTC]
Are you aware that openbase_dir can be set to a list of
directories (like PATH)?
 [2021-05-30 04:22 UTC] php-bugs at lists dot php dot net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue May 21 11:01:34 2024 UTC