PiAuCreateUserSids

__int64 __fastcall PiAuCreateUserSids(PVOID *a1){
  int v2; 
  PVOID *v3; 
  PVOID *v4; 
  PVOID *v5; 
  PVOID *v6; 
  PVOID *v7; 
  PVOID *v8; 
  UINT8 valid; 
  unsigned int v10; 
  SID_IDENTIFIER_AUTHORITY IdentifierAuthority; 
  SID_IDENTIFIER_AUTHORITY v13; 
  SID_IDENTIFIER_AUTHORITY v14; 
  *(_WORD *)&IdentifierAuthority.Value[4] = 1280;
  *(_DWORD *)IdentifierAuthority.Value = 0;
  *(_DWORD *)v13.Value = 0;
  *(_WORD *)&v13.Value[4] = 256;
  *(_DWORD *)v14.Value = 0;
  *(_WORD *)&v14.Value[4] = 3840;
  memset((INT64)a1, 0i64);
  v2 = PiAuAllocateAndInitializeSid(a1, &IdentifierAuthority, 1ui64);
  if( v2 >= 0 )
  {
    *((_DWORD *)*a1 + 2) = 18;
    if( !RtlValidSid(*a1) )
      return(unsigned int)-1073741595;
    v3 = a1 + 1;
    v2 = PiAuAllocateAndInitializeSid(a1 + 1, &v13, 1ui64);
    if( v2 < 0 )
      return(unsigned int)v2;
    *((_DWORD *)*v3 + 2) = 0;
    if( !RtlValidSid(*v3) )
      return(unsigned int)-1073741595;
    v4 = a1 + 2;
    v2 = PiAuAllocateAndInitializeSid(a1 + 2, &IdentifierAuthority, 2ui64);
    if( v2 < 0 )
      return(unsigned int)v2;
    *((_DWORD *)*v4 + 2) = 32;
    *((_DWORD *)*v4 + 3) = 544;
    if( !RtlValidSid(*v4) )
      return(unsigned int)-1073741595;
    v5 = a1 + 3;
    v2 = PiAuAllocateAndInitializeSid(a1 + 3, &IdentifierAuthority, 1ui64);
    if( v2 < 0 )
      return(unsigned int)v2;
    *((_DWORD *)*v5 + 2) = 2;
    if( !RtlValidSid(*v5) )
      return(unsigned int)-1073741595;
    v6 = a1 + 4;
    v2 = PiAuAllocateAndInitializeSid(a1 + 4, &IdentifierAuthority, 2ui64);
    if( v2 < 0 )
      return(unsigned int)v2;
    *((_DWORD *)*v6 + 2) = 32;
    *((_DWORD *)*v6 + 3) = 545;
    if( !RtlValidSid(*v6) )
      return(unsigned int)-1073741595;
    v7 = a1 + 5;
    v2 = PiAuAllocateAndInitializeSid(a1 + 5, &IdentifierAuthority, 1ui64);
    if( v2 < 0 )
      return(unsigned int)v2;
    *((_DWORD *)*v7 + 2) = 19;
    if( !RtlValidSid(*v7) )
      return(unsigned int)-1073741595;
    v8 = a1 + 6;
    v2 = PiAuAllocateAndInitializeSid(a1 + 6, &IdentifierAuthority, 1ui64);
    if( v2 < 0 )
      return(unsigned int)v2;
    *((_DWORD *)*v8 + 2) = 20;
    if( !RtlValidSid(*v8) )
      return(unsigned int)-1073741595;
    v2 = PiAuAllocateAndInitializeSid(a1 + 7, &v14, 2ui64);
    if( v2 >= 0 )
    {
      *((_DWORD *)a1[7] + 2) = 2;
      *((_DWORD *)a1[7] + 3) = 1;
      valid = RtlValidSid(a1[7]);
      v10 = v2;
      if( !valid )
        return(unsigned int)-1073741595;
      return v10;
    }
  }
  return(unsigned int)v2;
}

Referenced by:

PiAuCreateSecurityObjects