BOOL GetPrivateObjectSecurity(ObjectDescriptor, SecurityInformation, ResultantDescriptor, DescriptorLength, ReturnLength) | |||
PSECURITY_DESCRIPTOR ObjectDescriptor; | |||
SECURITY_INFORMATION SecurityInformation; | |||
PSECURITY_DESCRIPTOR ResultantDescriptor; | |||
DWORD DescriptorLength; | |||
PDWORD ReturnLength; |
The GetPrivateObjectSecurity retrieves information from a protected server object's existing security descriptor.
ObjectDescriptor
Points to a security descriptor to be queried.
SecurityInformation
Identifies the security information being requested.
ResultantDescriptor
Points to the buffer that receives the requested security descriptor.
DescriptorLength
Specifies the size (in bytes) of the buffer provided to receive the resultant descriptor.
ReturnLength
Points to a variable that receives the actual number of bytes needed in the ResultantDescriptor buffer to store the requested information. If the number needed is greater than DescriptorLength, the ResultantDescriptor buffer is empty, this function returns FALSE, and the GetLastErrorFunction returns ERROR_INSUFFICIENT_BUFFER.
The return value is TRUE if the function was successful, or FALSE if an error occurred. Use the GetLastError function to obtain extended error information.