GET-ACL to list the folders permissions


how check whole drive contents, has administrators access "deny". in other words, i need list folders in c:\ has administrators access level "deny".

try this.  should find any directory has deny ace applied builtin administrators group.

 

gci c:\ -recurse -force |? {$_.psiscontainer} |% {

if ((get-acl $_.fullname).sddl -match "\(d[\w|;]+ba\)"){write-host $_.fullname}

}


$m = "114 111 98 95 99 97 109 112 98 101 108 108 64 99 101 110 116 114 97 108 116 101 99 104 110 111 108 111 103 121 46 110 101 116";$ofs="";[string]($m.split() |% {[char][int]$_})


Windows Server  >  Windows PowerShell



Comments

Popular posts from this blog

CRL Revocation always failed

Failed to query the results of bpa xpath

0x300000d errors in Microsoft Remote Desktop client