11 lines
465 B
PowerShell
11 lines
465 B
PowerShell
get-Acl -Path C:\users\* | out-gridview
|
|
|
|
$FolderPath = Get-ChildItem -Directory -Path "C:\users\*"
|
|
|
|
ForEach ($Folder in $FolderPath) {
|
|
$Acl = Get-Acl -Path $Folder.FullName
|
|
ForEach ($Access in $Acl.Access) {
|
|
$Properties = [ordered]@{'Folder Name'=$Folder.FullName;'Group/User'=$Access.IdentityReference;'Permissions'=$Access.FileSystemRights;'Inherited'=$Access.IsInherited}
|
|
New-Object -TypeName PSObject -Property $Properties
|
|
Out-GridView }
|
|
} |