//
// sub_10DBA40 from 0x10dba40 to 0x10dbafc (188 bytes)
//
// 2 xrefs:
// > engine_load_openssl_int @ 0x10dc0ac
// > engine_load_openssl_int @ 0x10dc0b4
//
// This function is hookable on this platform (idp: arm, 32 bit: False, 64 bit: True!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 13:17:45 +0000
//
__int64 __fastcall sub_10DBA40(__int64 a1, __int64 *a2, _QWORD *a3, int a4)
{
unsigned int v4; // w3
__int64 v6; // x0
unsigned int *v7; // x0
int v8; // w21
_QWORD *v10; // [xsp+38h] [xbp+38h]
if ( a2 )
{
if ( a4 == 64 )
{
v6 = sub_10DB958();
v4 = 1;
*a2 = v6;
}
else
{
*a2 = 0;
return 0;
}
}
else
{
if ( dword_1568688 )
{
v4 = dword_156868C;
}
else
{
v10 = a3;
v7 = (unsigned int *)sub_10DB958();
a3 = v10;
if ( v7 )
{
v8 = dword_156868C++;
*((_DWORD *)&qword_1568680 + v8 + 4) = EVP_MD_type(v7);
a3 = v10;
}
v4 = dword_156868C;
dword_1568688 = 1;
*((_DWORD *)&qword_1568680 + dword_156868C + 4) = 0;
}
*a3 = &unk_1568690;
}
return v4;
}