Can some kind person point me to where I might find correct chmod settings for Revo.
I’m using a Linux-based VPS running CentOS 5.
It also seems I need to set the /modx/core/cache directory to chmod = 777
I thought 777 was bad security?
Can someone more knowledgable comment?
There are other directories/files that I needed to chmod to 777 (755 resulted in a handful of errors).
Thanks.
As a side note, files/directories saved via *.tar.gz are able to preserve chmod settings .. no?
So it would be nice to see a *.tar.gz alongside the zip on the downloads page.
Radified,
VPS guide, Revo 206 Traditional, PHP 534, suPHP, MySQL 5151, Apache 2217, CentOS 5.5 on Virtuozzo VPS.
you can chgrp the directories that need to be writable
I am trying to find a list of the directories & files that need to be writable. Where might that info be located?
Radified,
VPS guide, Revo 206 Traditional, PHP 534, suPHP, MySQL 5151, Apache 2217, CentOS 5.5 on Virtuozzo VPS.
Quote from: xeeter at Dec 30, 2009, 09:47 PM
you can chgrp the directories that need to be writable
I am trying to find a list of the directories & files that need to be writable. Where might that info be located?
http://svn.modxcms.com/docs/display/revolution/Fresh+Installation
Thanks.
Now we’re cooking with plutonium.
Radified,
VPS guide, Revo 206 Traditional, PHP 534, suPHP, MySQL 5151, Apache 2217, CentOS 5.5 on Virtuozzo VPS.
This completely depends on your environment and how the web server is configured to execute PHP. If PHP executes as your shell account, then 755 for directories should be fine. If PHP executes as your web server user account, you can chgrp the directories that need to be writable to the web server user account and use 775. The only reason you would ever need to use 777 is if you could not chgrp the directories that need to be writable; in that case you have to make them world writable (777) in order to allow the PHP process to write to them.
From my web hosting provider:
A more accurate way to describe this would be to refer to the PHP handler used on your server. If your handler is suPHP, then all PHP scripts will be executed as the owner of that PHP script, so for example, radified.com’s PHP would be run as user.
If you use DSO/CGI PHP handler (current setting on host.radified.com), then all PHP scripts are executed as the web server’s user (nobody), so if a script needs to write to a file on your server, this file would need to have less restrictive permissions or its ownership would need to be changed to nobody.
I advise against changing the ownership though, as this will interfere with cPanel’s ability to back up your files.
Comment? I am not groking exactly what he’s saying.
Radified,
VPS guide, Revo 206 Traditional, PHP 534, suPHP, MySQL 5151, Apache 2217, CentOS 5.5 on Virtuozzo VPS.
Okay, thanks. This helped a lot. I’m starting to get somewhere.
Radified,
VPS guide, Revo 206 Traditional, PHP 534, suPHP, MySQL 5151, Apache 2217, CentOS 5.5 on Virtuozzo VPS.
-
☆ A M B ☆
- 427 Posts
You may find it easier in the long run to simply use the suPHP, if it is available.
-
MODX Staff
- 10,725 Posts
Just make the group owner your web server user and give the group write permissions (i.e. 775, or 664 for files); you do not have to give world-writable permissions if you can control group ownership of the files on your server. Please note you should never set files to 777 or 775, only folders; files should generally be 666 or 664. Even better you can control permissions symbolically on most systems, e.g. to give the group write permissions you would use chmod g+w and so on...