Linux file permissions define which users can read, write, or execute files and directories. They form a core security mechanism in multi-user Linux systems.
Each file and directory has permissions assigned to three different user categories and three basic permission types.
Permissions are evaluated for the following user groups:
The chmod command is used to modify file and directory permissions. It supports symbolic and numeric (octal) notation.
chmod u+x script.sh chmod g-w file.txt chmod o+r file.txt
Each permission has a numeric value:
chmod 755 script.sh chmod 644 config.php
The chown command changes file and directory ownership.
chown user file.txt chown user:group file.txt chown -R user:group /var/www
The -R option applies changes recursively.
Improper file permissions can introduce serious security vulnerabilities, especially on web servers.
From a knowledge base standpoint, Linux file permissions are a fundamental pillar of system security.