Homedir inside homedir restricted access

Posted by blid on Super User See other posts from Super User or by blid
Published on 2011-03-09T22:27:20Z Indexed on 2011/03/10 0:12 UTC
Read the original article Hit count: 233

Filed under:
|
|

On my VPS i've installed debian, apache+php.
I have 2 users: foo and bar.
Apache is configured to execute php files from /home/foo/htdocs.

I created dir: /home/foo/htdocs/bar/ and made it home dir for user bar. Hover, I need to make a restriction: bar can't read, write or executre any files outside his own dir, but Apache has to be able execute all php files from /htdocs.

I tried to chown the bar dir only for user bar, also experimented a lot with chmod but without a result so far.

If there's any better way to satisfy my needs don't hesitate to write about it.

Thanks in advance

© Super User or respective owner

Related posts about unix

Related posts about apache