//
// PKCS7_stream from 0xa3e7dc to 0xa3e8a8 (204 bytes)
//
// 2 xrefs:
// > sub_A3B130 @ 0xa3b164
// > ??> @ 0x7f48c
//
// 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:12 +0000
//
int __fastcall PKCS7_stream(_DWORD *a1, int a2)
{
int result; // r0
switch ( (unsigned int)OBJ_obj2nid(*(_DWORD *)(a2 + 16)) )
{
case 0x15u:
result = *(_DWORD *)(a2 + 20);
break;
case 0x16u:
result = *(_DWORD *)(*(_DWORD *)(*(_DWORD *)(a2 + 20) + 20) + 20);
if ( !result )
return result;
goto LABEL_8;
case 0x17u:
result = *(_DWORD *)(*(_DWORD *)(*(_DWORD *)(a2 + 20) + 8) + 8);
if ( result )
goto LABEL_8;
result = ASN1_OCTET_STRING_new();
*(_DWORD *)(*(_DWORD *)(*(_DWORD *)(a2 + 20) + 8) + 8) = result;
break;
case 0x18u:
result = *(_DWORD *)(*(_DWORD *)(*(_DWORD *)(a2 + 20) + 20) + 8);
if ( result )
goto LABEL_8;
result = ASN1_OCTET_STRING_new();
*(_DWORD *)(*(_DWORD *)(*(_DWORD *)(a2 + 20) + 20) + 8) = result;
break;
default:
return 0;
}
if ( result )
{
LABEL_8:
*(_DWORD *)(result + 12) |= 0x10u;
*a1 = result + 8;
return 1;
}
return result;
}