//
// cms_pkey_get_ri_type from 0xe1e90c to 0xe1e96c (96 bytes)
//
// 2 xrefs:
// > CMS_add1_recipient_cert @ 0xe1e9bc
// > ??> @ 0xb2e78
//
// 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 cms_pkey_get_ri_type(__int64 a1)
{
__int64 v1; // x1
int (__fastcall *v2)(__int64, __int64, _QWORD, unsigned int *); // x4
unsigned int v4; // [xsp+1Ch] [xbp+1Ch] BYREF
v1 = *(_QWORD *)(a1 + 16);
if ( !v1 )
return 0;
v2 = *(int (__fastcall **)(__int64, __int64, _QWORD, unsigned int *))(v1 + 176);
if ( !v2 )
return 0;
if ( v2(a1, 8, 0, &v4) <= 0 )
return 0;
return v4;
}