- User and Group management
- id
- useradd
- -c – Full name
- -e – Expiration date
- -s – Default shell
- -d – Home directory
- passwd
- usermod
- -l – rename
- -L – Lock
- -U – unlock
- userdel
- -r – remove user data
- groupadd
- groupmod
- gpasswd [-a -d -A] [user1, user2] [group]
- newgrp [group]
- su vs. su – vs. sudo
- visudo
- File permissions
- UGO – User, Group, Other
- RWX – Read, Write, Execute
- chmod -R g+x (grant recursive execute permission to group)
- r = 4
- w = 2
- x = 1
- – = 0
- rwxrwxrwx = 777
- rw-rw-rw- = 666
- rwxrwxr–- = 774
- rw-rw—- = 660
- rw-r—–- = 640
- chown
- chgrp
- umask
https://www.sluug.org/resources/presentations/2020/2020-02-12_permissions.pdf