Get Security Descriptor
The following example gets the security descriptor for an item.
- Connect to the configuration web service.
- Specify the unique identifier of the item for which the security descriptor is to be returned.
- The user must have at least read permissions to the item to execute this command.
Code Sample
# Set the item identifier of the item for which the security descriptor is to be returned.
$itemID = 1000;
# Read the security descriptor and enumerate the security entries.
$securityDescriptor = $xia.GET_SecurityDescriptor($itemID);
Write-Host "Inherited: " $securityDescriptor.Inherit;
foreach ($securityEntry in $securityDescriptor.SecurityEntries)
{
Write-Host "Security Entry:";
Write-Host $securityEntry.AccountName;
Write-Host "Full Control: " $securityEntry.FullControl;
Write-Host "Read: "$securityEntry.Read;
Write-Host "Write: "$securityEntry.Write;
}