The RtlGetOwnerSecurityDescriptor routine returns the owner information for a given security descriptor.
NTSYSAPI NTSTATUS RtlGetOwnerSecurityDescriptor( PSECURITY_DESCRIPTOR SecurityDescriptor, PSID *Owner, PBOOLEAN OwnerDefaulted );
Pointer to the security descriptor.
Pointer to an address to receive a pointer to the owner security identifier (SID). If the security descriptor does not currently contain an owner SID, Owner receives NULL.
Pointer to a Boolean variable that receives TRUE if the owner information is derived from a default mechanism, rather than by the original provider of the security descriptor explicitly, FALSE otherwise. Valid only if Owner receives a non-NULL value.
RtlGetOwnerSecurityDescriptor returns STATUS_SUCCESS or an appropriate NTSTATUS value such as one of the following:
||The security descriptor's revision level is not known or is not supported. This is an error code.|
For more information about security and access control, see the documentation on these topics in the Microsoft Windows SDK.
|Minimum supported client||This routine is available on Microsoft Windows 2000 and later.|
|Header||ntifs.h (include Ntifs.h)|
|DLL||NtosKrnl.exe (kernel mode); Ntdll.dll (user mode)|