• 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.

Question Question about umask and file permission for domain

gennolo

Basic Pleskian
Hello,
I ask for help to understand this situation - Sorry for being long :D

I installed a domain with Prestashop 1.7 on a Plesk Onyx Centos 7 box with pretty standard settings
(PHP-FPM server by Apache - Php7 Plesk handler).
Domain is using its own user / webspace with the classic "psacln" group and files/folder with 644/755 permission.

It happens that when I try to add some new modules from the application backoffice
or when the application writes cache files
they are written with 666 permission for files and 777 for folders. This looks like totally insecure, and it never happened with other domains on the same host with different applications with the same domain setting, where I have the expected result (644 for files / 755 for folders).


I see lot of people are reporting this behaviour, and the answer was
"this is due to Symfony framework used in Prestashop 1.7 that uses server umask setting to set files/folder permission , so check / fix your envoriment because you have wrong umask".

I checked my server and #umask command (launched as root) is reporting 0022 that is supposed to be the correct setting to have 644 / 755 permission during uploads.

So my question is : am I missing something about umask or how Plesk is setting this value ?
Is there some umask setting I need to check at web-server user level or in Plesk domain configuration ?
Or is the application that needs to be fixed ?

Thank you !
 
Back
Top