• Please be aware: Kaspersky Anti-Virus has been deprecated
    With the upgrade to Plesk Obsidian 18.0.64, "Kaspersky Anti-Virus for Servers" will be automatically removed from the servers it is installed on. We recommend that you migrate to Sophos Anti-Virus for Servers.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

alternate to chmod 777

W

webgurl

Guest
This may be more of a *nix or apache question than just a plesk thing. I'm installing zencart and in the install it requires a whole bunch of folders to have their permissions changed to chmod 777. I usually avoid any scripts that require these permissions since it leaves you open to hackers. I know there must be a way to install these scripts without changing the permssions to 777.

If someone could point me in the right direction (a link, how to, a book) I would greatly appreciate it. So far I'm thinking I should be able to allow access to these folders to my admin users (chown) however I am stuck on how to implement it. Do I need to setup an htaccess file for these directories?

I'll continue investigating, but I'm hoping someone can speed up my research time with some useful resources or tips on how to implement this.

Thanks
 
You can use setgid on directory with specific ownership.groupownership of directory. (chmod 2775).

Good luck.
 
Have you tested this script to make sure it actually 'needs' the folder chmodded to 777? Sometimes script writers default to this in their documentation when actually it only needs to be 666 766 776 or something else less risky. Most of the time these scripts want to write to a folder but don't always need full permissions to it.
 
Alot of times you can just do this for web based application installers:
# chgrp apache /path/to/folder
# chmod 775 /path/to/folder
 
That would be bad to remove the psacln group because then modules such as backup wouldn't be able to control the files.
 
Currently I get an error in PHP that I can't write to a file. This is how my permissions are setup for the file:

-rwxrwxr-x 1 user psacln 20081 date file.php

I thought if I allowed write access to the group it would allow the php file to be written. What am I missing here?
 
Back
Top