Skip to main content

Lab 5.3 - Advanced Permissions

Objectives​

  • Use ACLs (setfacl, getfacl)
  • Understand SUID, SGID, sticky bit
  • Configure granular permissions

Exercise 1: ACLs​

# Install
sudo apt install acl

# Grant permission to a user
sudo setfacl -m u:another-user:rw fichier.txt

# View ACLs
getfacl fichier.txt

Exercise 2: Special Permissions​

# SUID
chmod u+s script.sh

# SGID
chmod g+s dir/

# Sticky bit
chmod +t /tmp

Lab created on: December 2024 - Tested on Ubuntu 24.04