3.1.1.13.3 GetUserLogonInfo

 procedure GetUserLogonInfo(
     UserPrincipal: DSNAME,
     ExpandedSids: ARRAY(SID),
     MaxValidityTimeHint: LARGE_INTEGER) : NTSTATUS

UserPrincipal: The principal whose logon information needs to be retrieved.

ExpandedSids: Returns the set of expanded SIDs.

MaxValidityTimeHint: Returns a future timestamp that specifies when the returned results are no longer considered valid; a value of zero signifies that no hint is being returned.

Return Values: This procedure returns STATUS_SUCCESS ([MS-ERREF] section 2.3.1) to indicate success; otherwise, an NTSTATUS error code.

Logical Processing:

 Status: NTSTATUS;
 ShadowPrincipalSids: ARRAY(SID);
 MaxShadowPrincipalValidityTimeHint: LARGE_INTEGER;
  
 /* Invoke ExpandMemberships locally */
 Status := ExpandMemberships(
     UserPrincipal,
     RevMembGetUniversalGroups,
     ExpandedSids, 
     MaxValidityTimeHint);
  
 if (STATUS_SUCCESS != Status)
     return Status;
 endif
  
 /* Invoke ExpandShadowPrincipal locally */
 Status := ExpandShadowPrincipal(
     ExpandedSids,
     ShadowPrincipalSids,
     MaxShadowPrincipalValidityTimeHint);
  
 if (MaxShadowPrincipalValidityTimeHint > 0)
     MaxValidityTimeHint := min(MaxValidityTimeHint, MaxShadowPrincipalValidityTimeHint);
 endif
  
 ExpandedSids := ExpandedSids + ShadowPrincipalSids;
  
 return Status;