Permits on File - use "+" to set permissions and "-" to remove:
Category Command Description
ls -lh show permits
ls /tmp | pr -T5 -W$COLUMNS divide terminal into 5 columns
chmod ugo+rwx directory1 set permissions reading (r), write (w) and (x) access to users owner (u) group (g) and others (o)
chmod go-rwx directory1 remove permits reading (r), write (w) and (x) access to users group (g) and others (o)
chown user1 file1 change owner of a file
chown user1 -R directory1 change user owner of a directory and all the files and directories contained inside
chgrp gruppo1 file1 change group of files
chown user1:gruppo1 file1 change user and group ownership of a file
find / -perm -u+s view all files on the system with SUID configured
chmod u+s /bin/file_eseguibile set SUID bit on a binary file - the user that running that file gets same privileges as owner
chmod u-s /bin/file_binario disable SUID bit on a binary file
chmod g+s /home/public set SGID bit on a directory - similar to SUID but for directory
chmod g-s /home/public disable SGID bit on a directory
chmod o+t /home/comune set STIKY bit on a directory - allows files deletion only to legitimate owners
chmod o-t /home/comune disable STIKY bit on a directory