1

Does open_basedir works recursive? For example if I write in php.ini something like: open_basedir=/client3/web3/web Does it include all directories in /client3/web3/web (/client3/web3/web/1, /client3/web3/web/2, )?

B14D3
  • 5,188
  • 15
  • 64
  • 83

2 Answers2

4

From the doc:

open_basedir string

Limit the files that can be opened by PHP to the specified directory-tree

....

When you want to restrict access to only the specified directory, end with a slash.

So, your answer is yes.

Sven
  • 98,649
  • 14
  • 180
  • 226
2

The path supplied to the open_basedir setting is the root of a directory tree.

Limit the files that can be opened by PHP to the specified directory-tree, including the file itself.

So yes anything below will be accessible.

user9517
  • 115,471
  • 20
  • 215
  • 297