chroot for php
I have a directory structure like this:
/www/site1.com/
/www/site2.com/
/www/site3.com/
My FTP is setup so the user is chrooted to their home dir, /home/user with symlinks to the domains they are allowed in, for example:
/home/user1/site1.com -> /www/site1.com
/home/user1/site3.com -> /www/site3.com
/home/user2/site2.com -> /www/site2.com
Now I want it so when PHP scripts execute, user2 cannot access files in user1's folders, and user1 cannot access files in user2's folder
Not even directory listings
So how, in detail would I do this, or is there a guide to do this (Using apache 2.2 and PHP5).
I would prefer not having all my apache files in 1 directory, but I suppose I could give it a try. I only have 1 active site on my server, so some downtime isn't too big of a deal, but I would still rather not do it that way.
Thanks
-Brandon
|
Recent comments
1 day 17 hours ago
1 day 20 hours ago
2 days 8 hours ago
2 days 10 hours ago
2 days 15 hours ago
2 days 21 hours ago
3 days 6 hours ago
3 days 8 hours ago
3 days 16 hours ago
3 days 18 hours ago