PiDevCfgResolveVariableGenerateGuid

INT64 __fastcall PiDevCfgResolveVariableGenerateGuid(INT64 a1, INT64 a2, INT64 a3){
  int v4; 
  unsigned int v5; 
  UINT8 *PoolWithTag; 
  UINT8 *v7; 
  struct _UNICODE_STRING DestinationString; 
  UUID Uuid; 
  Uuid = 0i64;
  *(_QWORD *)&DestinationString.Length = 0i64;
  DestinationString.Buffer = 0i64;
  v4 = ExUuidCreate(&Uuid);
  if( v4 >= 0 )
  {
    v4 = RtlStringFromGUIDEx(&Uuid, &DestinationString, 1u);
    if( v4 >= 0 )
    {
      v4 = RtlUpcaseUnicodeString(&DestinationString, &DestinationString, 0);
      if( v4 >= 0 )
      {
        v5 = DestinationString.Length + 2;
        PoolWithTag = (UINT8 *)ExAllocatePoolWithTag(PagedPool, v5, 0x63647050ui64);
        v7 = PoolWithTag;
        if( PoolWithTag )
        {
          memmove(PoolWithTag, (UINT8 *)DestinationString.Buffer, v5);
          *(_DWORD *)(a3 + 32) = 1;
          *(_DWORD *)(a3 + 36) = v5;
          *(_QWORD *)(a3 + 40) = v7;
        }
        else
        {
          v4 = -1073741670;
        }
      }
    }
  }
  RtlFreeAnsiString(&DestinationString);
  return(unsigned int)v4;
}

Referenced by:

No references.