If you can't read please download the document
Upload
rubin-azad
View
1.426
Download
0
Embed Size (px)
Citation preview
Violenetsecurity
Red Hat video Series for RHCE & RHCSAPart-5 Permissions
On the basic of User/Group/Other
User -> Creator or Owner of File/Folder.
Group ->users that are in same group to whom the File/Folder Belongs.
Others -> Neighter Owner nor in Group.
Part-5 PermissionsPermissions
There are three type of permissionsRead ( r ) -> 4
Write ( w ) -> 2
Execute ( x ) ->1
Setting up permissions via chmod
Part-5 PermissionsPermissions
Say want to give read and write permission to file1 for group thenchmod g+rw file1
If want to give read and execute permission to file1 from otherschmod o+rw file1
To give read,write and execute permission to file1 for ownerchmod u+rwx file1
Part-5 PermissionsPermissions
Say want to REVOKE read and write permission to file1 for group thenchmod g-rw file1
If want to REVOKE read and execute permission to file1 from otherschmod o-rw file1
To REVOKE read,write and execute permission to file1 for ownerchmod u-rwx file1
Part-5 PermissionsPermissions
If want to give permissions collectively then :chmod u+rwx,g+rw,o+rw file1
To revoke the same :chmod u-rwx,g-rw,o-rw file1
Easy way to give permissions Chmod 766 file1
Part-5 PermissionsCollective Permissions
There are 3 special permissionsSUID ( Super User Id )
SGID ( Super Group Id )
STICKY BIT ( t )
Part-5 PermissionsSpecial Permissions
Super User Id Enables a command to run with super user previleges.
chmod u+s fileLocation
chmod u-s fileLocation
Chmod 4755 fileLoation
Part-5 PermissionsSpecial Permissions
Super Group Id Enables Group Permissions to Folder/Files
chmod g+s file/folder
chmod g-s file/folder
Chmod 2755 fileLoation
Part-5 PermissionsSpecial Permissions
Sticky Bit allows to delete only those files which are being created by themselves
Chmod 1755 file/dir
Chmod o+t file/dir
Part-5 PermissionsSpecial Permissions
End of Part 5