If you are working through cPanel or on any Linux machine, you may have heard the term permissions. This is odd to hear at first, but essentially these are what determine who has access to what files. For example, if you have your website, you will want visitors to view your website, but not make any changes. This is done through proper permissions to ensure they can only read the files. We will cover the basics of what permissions are and how you can use them to protect your files through your File Manager and is intended for Hostwinds clients using cPanel.
Basic Permissions Overview
Permissions exist within 3 different sections. There is the User section, Group section and the World section. The User section affects how the owner of the file or folder can interact with it. With the Group section, this will determine how other users that exist within the same group can interact with the file or folder. Lastly, the World section says how other users, whether they exist or not, can interact with the file or folder.
In each of those sections, there will be a number associated with the files / folders as well. This will determine the exact permissions that the section has. The number is essentially different permissions that are added up. For reading the contents of the file or folder, this would be a value of 4. Write permissions would be a value of 2. And Executable permissions would be a value of 1. With the permissions that you want for the group you would set this to be those numbers added up. For example, if you wanted the Others to have read and executable rights, but not writable permissions, you would set that to be 5 (Executable plus Readable). Normally though, you would see the permissions listed as a three or four digit number. For example, 755 or 644.
Through cPanel there is a wonderful interface that is available for changing File Permissions. This window is great for visualizing the permissions of a file or folder. It has checkboxes for each setting, and organized in columns for each section. In the image below, you can see what this would look like if the User (Owner) had read only permissions, the Group members had Write only permissions and the World (Others) had Execute only permissions.
What Are The Recommended Permissions?
Usually for a website, it is recommended that certain permissions be setup to increase security. The recommended permissions for directories would be 755. This would allow the owner (Presumably you) to perform any action on the folder, and anyone else the ability to read and execute the folder. With files, it is recommended to have the permissions set to 644. Giving you the ability to read and write to the file and all others the ability to only read the contents of the file.