I have a static/CGI/PHP app that redirects all domain.com traffic to www.domain.com. With my mad skillz I managed to reset pretty much all permissions recursively in my home folder to 0600, causing the redirect app to stop functioning, giving "403 Forbidden". What permissions should I set to fix the situation? Note to self: create a cronjob that saves full recursive directory listings. Note to self 2: don't mess with permissions when in production. UPDATE I set the following permissions according to David L's advice:
But it still doesn't work. The frontend log says:
What am I missing? Do the permissions of my home directory play a role here - can I even modify them myself? I assume the "chmod -R 0600 .*" would have found its way up there as well. asked 15 Dec '10, 04:08 foob |
As the frontend Apache log suggested, the problem were my home dir's permissions. Thanks to WF support for providing the defaults:
answered 16 Dec '10, 06:14 foob Thanks for posting. This fixed it for me after screwing up my permissions following a bad suggestion on stackexchange trying to get ssh keys working.
(14 Aug '14, 13:41)
morganbird
|
By default, the permissions for newly created files and directories are:
You can probably just fix your redirect's .htaccess file (assuming that's what you're using) permissions. This should kick your app back into life :) answered 15 Dec '10, 04:15 David L ♦♦ |
I believe a .htaccess should be chmodded to 600, otherwise it's considered too loose.
Could you try that and let us know how it goes?
Forgive me for my stupidity, but isn't the frontend apache process owned by somebody else than me? If so, how could it read the .htaccess if I set it to 600?
As the log snippet above shows, apache tries to access .htaccess on my home directory. Is the problem now with my home directory permissions? "ls -ld ~" shows "drwx------+"
Oh, and I tried anyway, didn't help.