Skip to content

Latest commit

 

History

History
59 lines (39 loc) · 1.39 KB

GetSecurityDescriptorOwner.md

File metadata and controls

59 lines (39 loc) · 1.39 KB

Home

Function name : GetSecurityDescriptorOwner

Group: Security - Library: advapi32


The GetSecurityDescriptorOwner function retrieves the owner information from a security descriptor.


Code examples:

GetFileOwner - Get the owner of an NTFS file

Declaration:

BOOL GetSecurityDescriptorOwner(
  PSECURITY_DESCRIPTOR pSecurityDescriptor,
  PSID* pOwner,
  LPBOOL lpbOwnerDefaulted
);
  

FoxPro declaration:

DECLARE INTEGER GetSecurityDescriptorOwner IN advapi32;
	STRING  @ pSecurityDescriptor,;
	INTEGER @ pOwner,;
	INTEGER @ lpbOwnerDefaulted
  

Parameters:

pSecurityDescriptor [in] Pointer to a SECURITY_DESCRIPTOR structure whose owner information the function retrieves.

pOwner [out] Pointer to a pointer to a SID identifying the owner when the function returns.

lpbOwnerDefaulted [out] Pointer to a flag set to the value of the SE_OWNER_DEFAULTED flag in the SECURITY_DESCRIPTOR_CONTROL structure when the function returns.


Return value:

If the function succeeds, the return value is nonzero.


Comments:

If the function fails, the return value is zero. To get extended error information, call GetLastError.