A CLI utility for showing and editing permissions on NTFS-formatted volumes.

Basic Syntax

icacls [<Path>...] [/grant[:r] <UserOrGroup>:<Rights>]
        [/deny:<UserOrGroup>:<Rights>]
        [/setowner <OwnerName>]
        [/inheritance:{e|r}]
        [/remove:<UserOrGroup>]
        [/reset]
        [/save <FileName>] [/restore <FileName>]
        [/t] [/c] [/q]

where

  • <Path> can be a file, folder or * for all items in directory.
  • /t recurse into sub-folders
  • /c continue if errors occur.
  • /q quiet mode, i.e. gives no output.

If only <Path> is passed as argument, then it simply displays the permissions of files and folders on <Path>.

Permissions

SymbolMeaning
FFull control
MModify
RXRead & execute (list files and open them)
RRead
WWrite (create, modify, delete files)
DDelete
EEnumerate subfolders & files (used by some tools)
D:PDelete permission with protected flag (prevents inheritance from parent)

Inheritance

Permissions of a parent folder can be inherited by a child sub-folders/file with the following settings:

FlagMeaning
(CI)Container inherit
(OI)Object inherit
(IO)Inherit only
(NP)Do not propagate inherit
(I)Permission inherited from parent container