Quote:
Originally Posted by migabriel.84
the path to the sources is /home/<username>/public_html
the permission of the dir <username> is 711
and the permission to public_html/* are 755
user and group <username>
the httpd user and group is apache
|
Hello,
I have passed into may cases like yours, and the solution I'll give to you will mostly solve it..!!
Now, as your Apache (httpd) runs under the name Apache..
Then, he's accessing data which are owned by another user <username>.
This way, many things would results in a Permission Denies error message.
Any way, there is complicated and there is easy solution for this, but I'll go through the easy one. I guess it will satisfy your needs, since it's a Home Server.
Simply, you either change apache to run under the name <username> which I don't really recommend.
Or, change the the owner of public_html folder to be Apache.
Code:
cd /home/<username>
chown -R apache.apache public_html
After that, give the public folders 755 permission..
and the public files 644.
In my own opinion, I hope I'm not mistaken, this will give you a very good level of security..!!
Other solutions, is to use something like fast_cgi which will run apache under the name of <username>, this is if you have more than one <username>.
Any other opinions are welcomed..