//
// X509_NAME_hash_old from 0xa535c0 to 0xa53680 (192 bytes)
//
// 3 xrefs:
// > X509_issuer_name_hash_old @ 0xa53684
// > X509_subject_name_hash_old @ 0xa5368c
// > ??> @ 0x807ec
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// 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 12:08:24 +0000
//
int __fastcall X509_NAME_hash_old(int a1)
{
int *v2; // r4
int v3; // r5
void *v4; // r0
_BYTE v6[20]; // [sp+0h] [bp-14h] BYREF
v2 = (int *)EVP_MD_CTX_new();
if ( !v2 )
return 0;
i2d_X509_NAME(a1, 0);
EVP_MD_CTX_set_flags((int)v2, 8);
v4 = EVP_md5();
if ( EVP_DigestInit_ex(v2, (int)v4, nullptr)
&& EVP_DigestUpdate((int)v2)
&& EVP_DigestFinal_ex((int **)v2, (int)v6, nullptr) )
{
v3 = (v6[2] << 16) | (v6[1] << 8) | v6[0] | (v6[3] << 24);
}
else
{
v3 = 0;
}
EVP_MD_CTX_free(v2);
return v3;
}