//
// sub_7FC0D8 from 0x7fc0d8 to 0x7fc140 (104 bytes)
//
// 3 xrefs:
// > ??> @ 0xa31058
// > ??> @ 0xa311c4
// > ??> @ 0xa31330
//
// 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_7FC0D8(int a1, int a2, int a3, unsigned int a4)
{
unsigned int v8; // r6
int cipher_data; // r0
int v10; // r7
unsigned int v11; // r8
int v12; // r4
int v13; // r0
v8 = EVP_CIPHER_CTX_block_size(a1);
cipher_data = EVP_CIPHER_CTX_get_cipher_data(a1);
if ( v8 <= a4 )
{
v10 = cipher_data;
v11 = a4 - v8;
v12 = a3;
do
{
v13 = v12;
v12 += v8;
(*(void (__fastcall **)(int, int, int))(v10 + 248))(v13, a2, v10);
a2 += v8;
}
while ( v11 >= v12 - a3 );
}
return 1;
}