//
// ssl3_clear from 0x78e240 to 0x78e330 (240 bytes)
//
// 3 xrefs:
// > tls1_clear @ 0x7ae084
// > dtls1_clear @ 0x7b618c
// > ??> @ 0x5acec
//
// 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 ssl3_clear(int a1)
{
int result; // r0
ssl3_cleanup_key_block();
OPENSSL_sk_pop_free(*(_DWORD *)(*(_DWORD *)(a1 + 104) + 556), X509_NAME_free);
CRYPTO_free(*(_DWORD *)(*(_DWORD *)(a1 + 104) + 592), "ssl/s3_lib.c", 2846);
CRYPTO_clear_free(
*(_DWORD *)(*(_DWORD *)(a1 + 104) + 600),
*(_DWORD *)(*(_DWORD *)(a1 + 104) + 604),
"ssl/s3_lib.c",
2847);
CRYPTO_free(*(_DWORD *)(*(_DWORD *)(a1 + 104) + 616), "ssl/s3_lib.c", 2848);
EVP_PKEY_free(*(_DWORD *)(*(_DWORD *)(a1 + 104) + 532));
EVP_PKEY_free(*(_DWORD *)(*(_DWORD *)(a1 + 104) + 864));
ssl3_free_digest_list(a1);
CRYPTO_free(*(_DWORD *)(*(_DWORD *)(a1 + 104) + 840), "ssl/s3_lib.c", 2857);
CRYPTO_free(*(_DWORD *)(*(_DWORD *)(a1 + 104) + 848), "ssl/s3_lib.c", 2858);
memset(*(void **)(a1 + 104), 0, 0x364u);
ssl_free_wbio_buffer(a1);
*(_DWORD *)a1 = 768;
result = CRYPTO_free(*(_DWORD *)(a1 + 448), "ssl/s3_lib.c", 2868);
*(_DWORD *)(a1 + 448) = 0;
*(_BYTE *)(a1 + 452) = 0;
return result;
}