if this has been asked before I apologize.

Usually the advice for setting file permission in wordpress are folder 750 and file 640 with user and group www-data. Based on my understanding if user and group is the same then if somehow outsider can access using www-data he still can read or write,right?

so what's the point on setting up users and group as www-data ? Is there security reason for this ? I think if file / folder is set as user other than www-data then the owner permission can be useful.

  • 1
    It's the typical dilemma with how web servers usually work: If you want convenience (config/updates/uploads over web) it usually needs to be able to write somewhere. – Sebastian Stark Dec 23 '18 at 14:29

It's for flexibility. You could add other users to the www-data group and those users could do whatever is permitted by the group flags (which need not necessarily be the same as the user flags).

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.