Reputation: 15857
I searched SO, but only found this for Apache.
In IIS7 for ONE
specific website, how do I restrict PHP 5.3.8 (FASTCGI) so it can only access files within that website's directory.
For example using include (or anything that lists files/directories) won't be able access anything but current and children directories, no parents.
What I have tried:
In IIS7 after clicking the website in the left panel, then in the right panel clicking PHP Manager, I added open_basedir
directive with the path. This worked, with a caveat, it forced this directive on ALL the websites, which broke all of the other PHP websites on the server.
thanks ahead of time.
Upvotes: 1
Views: 117
Reputation: 15857
If someone in IIS7 has this issue, I was able to solve this by opening the php.ini and adding below:
[PATH=C:/inetpub/website1.com/www/]
open_basedir=/www/
Upvotes: 1