Israel Science and Technology Directory

Linux Permissions

Updated on January 20, 2026.

In Linux, each file and folder carries specific attributes - named permissions - defining who can access these entities. For an introduction see Linux file and folder permissions . This page summarizes permissions necessary for operations in folders, and on files.

Directory/Folder permissions 🡱

Files are located in folders (directories). Thus, each request for an operation on a file depends on the permissions of the folder. Therefore, this page presents folder permissions first.

The "Action" column of Table 1 shows some common operations that can be performed within a folder, such as listing the directory, or deleting a file. Seven permission columns show 7 permission possibilities, such as Read only (r--), and Read and execute (r-x). A plus (+) sign indicates that the action can b executed with the permission shown.

The first two columns of permissions in Table 1, show only Read (r--) and only Write (-w-) permissions. The minus sign from top to the bottom rows of the two columns indicate that, none of the actions listed, e.g. cd, rename, delete, can be executed in a folder with these permissions.

Table 1. Directory (Folder) Permissions
Permissions
ActionCMDr−−
4
−w−
2
−−x
1
−wx
3
r−x
5
rw−
6
rwx
7
Notes
List d*ls----+-+Needs r + x
cd into dcd--+++-+Needs x
Rename filesmv---+--+Needs w+x
Create files---+--+Needs w+x
Delete filesrm---+--+Needs w+x
Move files into dmv---+--+Needs w+x
Move files out of dmv---+--+Needs w+x
Open files inside d--+++-+Needs x + file perm.

* The character d is an abbreviation for directory.
NOTE: This table shows 7 options for the permissions of one user.

The third permission, "Execute" (r), can be understood to mean that a file is executable, and that it can be run as a program. However, what is the significance of the "execute" permission for a folder that contains files?

For a folder, 'Execute' permission (x) is required for any action that modifies directory entries. Therefore, the actions listed can be executed only with permissions that include x (for example: --x, -wx, r-x), (Table 1).

An important application of permissions is the limitation of access to folders of a website. For a website, the recommended folder permission is 755 which designates the permission of 5 for the anonymous users (a reminder: third position in the list of three user types). As can be seen in the column for permission 5 (r-x), this allows traversing from folder to folder using cd command, and also allows opening/running a file such as a program or a script, inside the folder. However, this permission prevents other actions such as creating and deleting files. Thus, permission 5 allows the user to jump from page to page but prevents any modification of the content of the folder.

File permissions 🡱

To read and write a file it is necessary for the user to have Read (r--) and Write (-w-) permissions respectively (Table 2). To run (execute) a program or a script file, it must have Execute (--x) permission for the specific user.

Users familiar with the Windows Operating system, know that files that can be run as a program must have a specific extension such as .com, .exe, or .bat.

In Linux, only files that have the "x" attribute can be executed. A file extension, if it exists, does not carry the meaning of "executability" as in Windows.

Permission for other file related operations such as, rename, move or delete depends on the permissions of the folder where the file is located.

Table 2. File Permissions
Permissions
ActionCMDr−−
4
−w−
2
−−x
1
−wx
3
r−x
5
rw−
6
rwx
7
Notes
Read filecat, less+---+++Needs r
Edit filenano, vim-+-+-++Needs w
Execute./file--+++-+Needs x
Create filetouch------- Permission for each action depends on the directory (folder) permissions
Renamemv-------
Movemv-------
Deleterm-------
Change permschmod-------Requires owner, not rwx

NOTE: This table shows 7 options for the permissions of one user.

ADVERTISEMENT