//
// ssl_cert_new from 0xd39e34 to 0xd39f00 (204 bytes)
//
// 2 xrefs:
// > SSL_CTX_new @ 0xd414ec
// > ??> @ 0x56670
//
// 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 ssl_cert_new()
{
__int64 v0; // x0
__int64 v1; // x19
__int64 v2; // x22
__int64 v3; // x0
v0 = CRYPTO_zalloc(488, "ssl/ssl_cert.c", 59);
v1 = v0;
if ( v0 )
{
*(_DWORD *)(v0 + 472) = 1;
v2 = v0;
*(_QWORD *)v0 = v0 + 32;
*(_QWORD *)(v0 + 440) = sub_D39A90;
*(_DWORD *)(v0 + 448) = 1;
*(_QWORD *)(v0 + 456) = 0;
v3 = CRYPTO_THREAD_lock_new();
*(_QWORD *)(v1 + 480) = v3;
if ( !v3 )
{
v2 = 0;
ERR_put_error(20, 162, 65, "ssl/ssl_cert.c", 73);
CRYPTO_free(v1, "ssl/ssl_cert.c", 74);
}
}
else
{
v2 = 0;
ERR_put_error(20, 162, 65, "ssl/ssl_cert.c", 62);
}
return v2;
}