Chapter 1
System Management
Course: Comptia Linux Xk0 006
Subject: Comptia Linux Xk0 006
Chapter: Security
1. File Permissions
Linux file permissions determine who can read, write, or execute a file or directory. The system uses a user-group-other (UGO) model with rwx (read, write, execute) flags.
Each file or directory has:
- User (owner) permissions
- Group permissions
- Other (everyone else) permissions
Basic Permission Example:
bash
ls -l file.txt -rw-r--r-- 1 alice devs 1234 Apr 10 09:12 file.txt
- rw-: Owner alice can read/write
- r--: Group devs can only read
- r--: Others can only read
Use chmod, chown, and chgrp to modify basic permissions and ownership.
1.1 Access Control List (ACL)
ACLs allow for fine-grained access control, enabling multiple users or groups to have different access levels to a single file or directory. This is useful in complex, collaborative environments.