Using icacls to set permissions of a folder to inherit recursively

Asken picture Asken · Mar 11, 2014 · Viewed 59.5k times · Source

I want to set a specific folder with specific rights to inherit all rights of it's parent folder. I know I should use icacls.

My folders look like this:

- mp
  - build (set this one to inherit from mp)

Answer

Asken picture Asken · Mar 17, 2014

Like this:

icacls "build\*" /q /c /t /reset

The secret was:

/reset - Replaces ACLs with default inherited ACLs for all matching files.
/t     - Performs the operation on all specified files in the current directory and its subdirectories.

Read more at Microsoft Technet icacls