In Unix-based systems, file system modes of files and folders are configured with change mode (chmod) command that allows user set the file permissions to the file or folder.
In miradore, file permissions can be set with the Set file permissions package action. The Set file permissions package action contains field Mode which allows to configure the access permissions to the file or folder that has been defined in the Target field.
Mode is a one to four octal digits (0-7) long value that is used to define the file permissions. Any omitted or blank digits are interpreted to be leading zeros.
The first digit (a.k.a. Sticky bit) is mainly used to configure folders. If the sticky bit has been set for a folder, only the owner of the folder can rename or delete files within that folder. If the sticky bit has not been set, any user with write and execute permission for the directory can rename or delete files from the folder, regardless of the owner. The file permissions can be granted using the following values: Set User ID or SUID (4), Set Group ID or SGID (2), and Sticky bit (1). Additionally, using GUID, the file can be configured to always run under root ownership. Similarly, using SGID a file can be configured to always run with the privileges of the files group owner.
The second digit is used to set file permissions for the user who is the owner of the file or folder.
The third digit is used to set file permissions for the users in the files group.
The fourth digit is used to set file permissions or other users that do not belong to the file's group.
# |
Permission |
7 | Full access |
6 | read and write |
5 | Read and execute |
4 | Read only |
3 | Write and execute |
2 | Write only |
1 | Execute only |
0 | None. |
Configurations in Miradore |
Explanation |
Target: file_1 Mode: 0777 or 777 |
Grants full access (read, write, and execute rights) for all to the file_1. |
Target: file_2 Mode: 0754 or 754 |
Grants full access for file owner, read and execute privileges for file group, and read permissions for other to the file_2. |
Target: file_3 Mode: 0124 or 124 |
Grants execute permission for file owner, write permissions for file group, and read access for other to file_3. |
Target: folder_1 Mode: 1777 |
Grants full access for all to folder_1, but only file owner or root is able to rename or delete the directory or the files inside it. |
Related to