//
// X509_LOOKUP_by_subject from 0x10658ec to 0x1065938 (76 bytes)
//
// 2 xrefs:
// > X509_STORE_CTX_get_by_subject @ 0x1065e9c
// > ??> @ 0x7e7f0
//
// 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:16:53 +0000
//
__int64 __fastcall X509_LOOKUP_by_subject(__int64 a1)
{
__int64 v1; // x4
unsigned int (*v2)(void); // x6
v1 = *(_QWORD *)(a1 + 8);
if ( !v1 )
return (unsigned int)v1;
v2 = *(unsigned int (**)(void))(v1 + 48);
if ( !v2 )
{
LODWORD(v1) = 0;
return (unsigned int)v1;
}
LODWORD(v1) = 0;
if ( *(_DWORD *)(a1 + 4) )
return (unsigned int)v1;
return v2();
}