//
// sub_872BB8 from 0x872bb8 to 0x872c4c (148 bytes)
//
// 1 xrefs:
// > ??> @ 0xa39ec4
//
// 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
//
int __fastcall sub_872BB8(int a1, int **a2)
{
int *v3; // r2
int v4; // r3
int v5; // r4
if ( a1 == 2 )
{
v3 = *a2;
v4 = **a2;
if ( v4 )
{
if ( v4 == 2 )
{
CRYPTO_clear_free(*(_BYTE **)(v3[1] + 16), *(_DWORD *)(v3[1] + 20), (int)"crypto/cms/cms_asn1.c", 210);
}
else if ( v4 == 3 )
{
CRYPTO_clear_free(*(_BYTE **)(v3[1] + 16), *(_DWORD *)(v3[1] + 20), (int)"crypto/cms/cms_asn1.c", 213);
}
}
else
{
v5 = v3[1];
EVP_PKEY_free(*(_DWORD *)(v5 + 20));
X509_free(*(_DWORD **)(v5 + 16));
EVP_PKEY_CTX_free(*(_DWORD *)(v5 + 24));
}
}
return 1;
}