Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How can I extract all groups and their associated users along with their permissions for 100's of folders? We're using Windows Server 2008 and the amount of groups and folders is staggering. Instead of manually pulling everything out I was hoping there was a program or utility that would allow me to choose a number of folders and view who has access to them. Thanks!

share|improve this question

So, I think you want this:

gci | %{$path = $_.fullname; $_} | get-acl | %{$_.access | select FileSystemRights, Identityreference, @{N="Path";E={$path}}}

This will list all the permissions for all the subdirectories in the folder you are currently in. Looks like this:

               FileSystemRights IdentityReference                       Path
               ---------------- -----------------                       ----
                    FullControl NT SERVICE\TrustedInstaller             C:\Windows\$Reconfig$
                      268435456 NT SERVICE\TrustedInstaller             C:\Windows\$Reconfig$
                    FullControl NT AUTHORITY\SYSTEM                     C:\Windows\$Reconfig$
                      268435456 NT AUTHORITY\SYSTEM                     C:\Windows\$Reconfig$
                    FullControl BUILTIN\Administrators                  C:\Windows\$Reconfig$
                      268435456 BUILTIN\Administrators                  C:\Windows\$Reconfig$
    ReadAndExecute, Synchronize BUILTIN\Users                           C:\Windows\$Reconfig$
                    -1610612736 BUILTIN\Users                           C:\Windows\$Reconfig$
                      268435456 CREATOR OWNER                           C:\Windows\$Reconfig$
                      268435456 CREATOR OWNER                           C:\Windows\ADAM
                      268435456 NT AUTHORITY\SYSTEM                     C:\Windows\ADAM
            Modify, Synchronize NT AUTHORITY\SYSTEM                     C:\Windows\ADAM
                      268435456 BUILTIN\Administrators                  C:\Windows\ADAM
            Modify, Synchronize BUILTIN\Administrators                  C:\Windows\ADAM
                    -1610612736 BUILTIN\Users                           C:\Windows\ADAM
    ReadAndExecute, Synchronize BUILTIN\Users                           C:\Windows\ADAM
                      268435456 NT SERVICE\TrustedInstaller             C:\Windows\ADAM
                    FullControl NT SERVICE\TrustedInstaller             C:\Windows\ADAM
                      268435456 CREATOR OWNER                           C:\Windows\addins
                      268435456 NT AUTHORITY\SYSTEM                     C:\Windows\addins
            Modify, Synchronize NT AUTHORITY\SYSTEM                     C:\Windows\addins
                      268435456 BUILTIN\Administrators                  C:\Windows\addins
            Modify, Synchronize BUILTIN\Administrators                  C:\Windows\addins
                    -1610612736 BUILTIN\Users                           C:\Windows\addins
    ReadAndExecute, Synchronize BUILTIN\Users                           C:\Windows\addins
                      268435456 NT SERVICE\TrustedInstaller             C:\Windows\addins
                    FullControl NT SERVICE\TrustedInstaller             C:\Windows\addins
                    FullControl NT SERVICE\TrustedInstaller             C:\Windows\AppCompat
                      268435456 NT SERVICE\TrustedInstaller             C:\Windows\AppCompat
                    FullControl NT AUTHORITY\SYSTEM                     C:\Windows\AppCompat
                      268435456 NT AUTHORITY\SYSTEM                     C:\Windows\AppCompat
                    FullControl BUILTIN\Administrators                  C:\Windows\AppCompat
                      268435456 BUILTIN\Administrators                  C:\Windows\AppCompat
    ReadAndExecute, Synchronize BUILTIN\Users                           C:\Windows\AppCompat
                    -1610612736 BUILTIN\Users                           C:\Windows\AppCompat
                      268435456 CREATOR OWNER                           ....

If I misunderstood your question, do tell.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.