Permissions
Here’s a single file from our ls -l
file listing earlier:
-rwxr-xr-x 1 root root 13928 Jul 7 2020 libtiffxx.so.4.3.7
Specifically, look at the permission bits:
-rwxr-xr-x
^^^^^^^^^
They are displayed in three groups of three here. Imagine them separated into three groups, to make it easier:
rwx r-x r-x
Each of these triplets represents read (r
), write (w
), and execute (x
) permissions for a specific set of users, based on the user and group ownership information for that file. If you see a -
character in place of a letter, that action (for the set of users it applies to) is not permitted.
- The first three bits represent the permissions of the file owner. In this case, the file’s owner (
root
) can read, write, and execute the file –rwx
. - The second three bits represent permissions for the group owner of the file, which in this case is also
root
. The permissions here arer-x
, or read and execute (no writing!). But because root is also the user...