when you create a file of any kind, you are the owner of that file. as owner, you have the power to set permissions for three kinds of users: yourslef (user or owner) for therest of the users who are in the same grojpu as you, and for any other users who have access ot the system, that is users not in your group.

you can display file permission with the ls command in your directory when you run this command:

ls -l

in the long listing output that appears, the name of theowner and group are the third and fourth fields (if the group name is not displayed, try ls -lg)

the same read, wrtie and execute permissions apply to users who are in the owener's group and to others users.

the middle three posisitons determine the read, write and execute permissions for users who are members of tehs ame group as the owner. this is done so that people working onthe same project can have access to the same files and resources and can also place different restrictions on the reso fo the system's users.

the last three sltos indicate the permissions assigned to everyone who has an account on the system, but who is not the owner nor in the owners' group.

for example, consider the following permssion field:

-rwxr-xr--


the object is a regular file, the user (owner) has read, wrtie and execute permission fo the file:

there are 10 fields they are divided into 4 sections, this is how you break them down:

- slot 1 = this is the first slot which is either a minus sign or a letter, in my exmple, is a minus sing

rwx slots 2,3,4 = this is the user permissions which means the user has read write and execute permissions

r-x slots 5,6,7 = this is the group permissions which means that the group has read and execute permission but NO write permission

r-- slots 8,9,10 = the last three slots are the others group which only have write permissions and NO write or execute permission

usergroupother
rwxr-xr--
the owner of the file users in the same group as the owner (rest of group)Users not in the same gropu as the owner (else)


TRY YOUR SKILLS - now try to populate to two bottom examples to see how much you have learned

permission field TYPE USER GROUP OTHER
drwxr-xxx directory rwxr-x ---
-rw-rw-r--    
-r-xr-----