//
// sub_10062AF6C from 0x10062af6c to 0x10062b0a8 (316 bytes)
//
// 1 xrefs:
// > ??> @ 0x100869e18
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
__int64 __fastcall sub_10062AF6C(__int64 a1, unsigned __int64 a2)
{
__int64 v3; // x20
__int64 v4; // x8
unsigned __int64 v5; // x22
__int64 __src; // [xsp+8h] [xbp-48h] BYREF
unsigned __int8 v8[8]; // [xsp+10h] [xbp-40h] BYREF
v3 = *(_QWORD *)(a1 + 24);
if ( *(_DWORD *)(v3 + 4156) )
{
if ( !*(_DWORD *)(v3 + 4144) && *(_DWORD *)(v3 + 4152) )
{
__src = 0;
sub_10062AC64(a1, (char *)&__src, 8);
}
v4 = *(int *)(v3 + 4152);
if ( (_DWORD)v4 )
{
if ( (int)v4 <= 7 )
bzero((void *)(v3 + v4 + 4136), (unsigned int)(7 - v4) + 1LL);
if ( *(_DWORD *)(v3 + 4148) )
{
if ( *(_DWORD *)(v3 + 4144) == 1024 )
sub_1006275F8((int *)v3, v8);
}
v5 = v3 + 4128;
sub_100626FBC((int *)v3, (unsigned __int8 *)(v3 + 4128), (_BYTE *)(v3 + 4136));
*(_DWORD *)(v3 + 4144) = (*(_DWORD *)(v3 + 4144) & 0x3FF) + 8;
}
else
{
v5 = v3 + 4128;
}
sub_100627400(v5, 32, a2);
return 1;
}
else
{
sub_100624720(140, 116, (__int64)"gost_crypt.c", 569);
return 0;
}
}