php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #62037 .user.ini ignores open_basedir parameter
Submitted: 2012-05-15 14:33 UTC Modified: 2012-05-16 09:46 UTC
From: karlis dot kisis at gmail dot com Assigned:
Status: Closed Package: Safe Mode/open_basedir
PHP Version: 5.3.13 OS: CentOS 6.2 x86_64
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: karlis dot kisis at gmail dot com
New email:
PHP Version: OS:

 

 [2012-05-15 14:33 UTC] karlis dot kisis at gmail dot com
Description:
------------
open_basedir parameter is ignored in .user.ini:
max_input_time = 333 
open_basedir = "/home"
display_errors = On
include_path = "/home"

the rest of the parameters from above work fine.

php is run as fcgi on apache 2.2.22 with mod_fcgid.c.

according to the docs, open_basedir should be configurable anywhere since version 5.3

Test script:
---------------
changed parameters are shown in phpinfo(), except open_basedir which remains unchanged.

Expected result:
----------------
open_basedir setting from .user.ini to be in effect.


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2012-05-15 15:01 UTC] karlis dot kisis at gmail dot com
turns out that if the master value for open_basedir is None, then .user.ini value works!

seems that .user.ini cannot override the master value from php.ini if open_basedir is defined.

still a bug in my opinion.
 [2012-05-15 15:17 UTC] reeze dot xia at gmail dot com
Please refer: http://cn.php.net/manual/en/ini.core.php#ini.open-basedir

“As of PHP 5.3.0 open_basedir can be tightened at run-time”

This means you can only make the path more deep but can't move back.
if not there will be security problem.

Maybe this is your problem
 [2012-05-15 18:45 UTC] sixd@php.net
-Status: Open +Status: Feedback
 [2012-05-16 09:46 UTC] karlis dot kisis at gmail dot com
I cannot repeat the problem anymore.

As strange as it is, I must will rest my case.

Thank you for your time.
 [2012-05-16 09:46 UTC] karlis dot kisis at gmail dot com
-Status: Feedback +Status: Closed
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Thu Jul 03 12:01:33 2025 UTC