Set-Acl -aclobject $GetACL -Path $Path It applies the group with the correct permissions, but appears as the SID when I look at the rights for the folder. I have checked and the SID that shows up with rights to the folder matches the SID of the group in ADSI Edit that I expected to show up. Is there some issue with my code or something else?
by selko at 2012-11-21 07:09:36
i assume if you it manually with explorer it works.
you can try to to get the users SID and passing the SID to FileSystemAccessRule
SecurityIdentifier UserSID = new SecurityIdentifier(((Byte)user.Properties["objectSid"].Value), 0);
Like so: FileSystemAccessRule($UserSID, $Permission, $Inheri, $Allpropagation, "Allow")