//
// sub_A40650 from 0xa40650 to 0xa406dc (140 bytes)
//
// 1 xrefs:
// > ??> @ 0xc7ff8c
//
// 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:13 +0000
//
int __fastcall sub_A40650(int a1, int a2)
{
int v2; // r4
int v4; // r6
char **v5; // r0
void *v7; // [sp+Ch] [bp-4h] BYREF
v2 = 0;
v7 = nullptr;
v4 = i2d_RSAPublicKey(*(_DWORD *)(a2 + 20), &v7);
if ( v4 > 0 )
{
v5 = OBJ_nid2obj(6u);
if ( !X509_PUBKEY_set0_param(a1, v5, 5, 0, v7, v4) )
{
CRYPTO_free(v7, (int)"crypto/rsa/rsa_ameth.c", 38);
return 0;
}
return 1;
}
return v2;
}