//
// SSL_get_peer_certificate from 0x9ab814 to 0x9ab850 (60 bytes)
//
// 2 xrefs:
// > sub_852C2C @ 0x852caa
// > ??> @ 0x67dec
//
// 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:06:53 +0000
//
int __fastcall SSL_get_peer_certificate(int a1)
{
int v1; // r4
if ( !a1 )
return 0;
v1 = *(_DWORD *)(a1 + 240);
if ( v1 )
{
v1 = *(_DWORD *)(v1 + 140);
if ( v1 )
X509_up_ref(v1);
}
return v1;
}