drupal: file permissions

File permissions for

sites/all - 755 (or 744 if that will work, on my shared hosting, it doesn't)
sites/all/libraries - 755 - also all subdirectories
sites/all/modules - 755 - also all subdirectories
sites/all/themes - 755 - also all subdirectories

sites/default
sites/default/files - 755 - also all subdirectories
sites/default/libraries - 755 - also all subdirectories
sites/default/modules - 755 - also all subdirectories
sites/default/themes - 755 - also all subdirectories
settings.php - 444 (or default 555 if that does not work, on my shared hosting it does)

Source:
http://drupal.org/node/244924#comment-3651134 (thanks for this comment, the commenter appears to be correct)

default.settings.php can actually be deleted

Setting file permissions "stricter" does not work on my shared hosting, the site won't function properly.

Temporarily setting permissions too strict does not appear to break Drupal permanently, but the site will not work properly. If this happens, panic might be a first reaction, but there's no need for it; go back and change the permissions again. Setting the permissions too "wide" is a security risk.

Comments

Post new comment

  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd> <h2> <h3> <div>
  • Lines and paragraphs break automatically.
  • You may post code using <code>...</code> (generic) or <?php ... ?> (highlighted PHP) tags.

More information about formatting options

CAPTCHA
Thanks for your help in stopping spam.
Fill in the blank