Back to course

33. Analyzing Permissions: The 10-Character String

Linux Basics: From Zero to CLI Hero

The Permissions Matrix

When you use ls -l, the first column displays a 10-character string that defines the file type and permissions.

bash -rw-r--r--

Character Breakdown

PositionMeaningOptions
1stFile Type- (regular file), d (directory), l (link)
2nd - 4thUser (Owner) Permissionsrwx (read, write, execute)
5th - 7thGroup Permissionsrwx (read, write, execute)
8th - 10thOthers (World) Permissionsrwx (read, write, execute)

Permissions Explained

  • r (Read): Allows viewing file contents (files) or listing directory contents (directories).
  • w (Write): Allows modifying file contents (files) or creating/deleting files within the directory (directories).
  • x (Execute): Allows running a file as a program (files) or entering/traversing the directory (directories).