//
// ossl_statem_server_construct_message from 0xfd27d4 to 0xfd2854 (128 bytes)
//
// 4 xrefs:
// > sub_FC5998 @ 0xfc5b58
// > ??> @ 0xa33d8
// > sub_FC5998 @ 0xfc5ffc
// > ??> @ 0x15448c8
//
// This function is hookable on this platform (idp: arm, 32 bit: False, 64 bit: True!
//
// 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 13:15:30 +0000
//
__int64 __fastcall ossl_statem_server_construct_message(
__int64 a1,
__int64 a2,
__int64 a3,
__int64 a4,
__int64 a5,
__int64 a6,
__int64 a7,
__int64 a8,
char a9)
{
__int64 result; // x0
switch ( *(_DWORD *)(a1 + 92) )
{
case 0x13:
result = tls_construct_hello_request(a1);
break;
case 0x15:
result = dtls_construct_hello_verify_request(a1);
break;
case 0x16:
result = tls_construct_server_hello(a1);
break;
case 0x17:
result = tls_construct_server_certificate(a1);
break;
case 0x18:
result = tls_construct_server_key_exchange(
(_QWORD *)a1,
(unsigned int)(*(_DWORD *)(a1 + 92) - 19),
a3,
a4,
a5,
a6,
a7,
a8,
a9);
break;
case 0x19:
result = tls_construct_certificate_request((_QWORD *)a1);
break;
case 0x1A:
result = tls_construct_server_done(a1);
break;
case 0x21:
result = tls_construct_new_session_ticket(a1);
break;
case 0x22:
result = tls_construct_cert_status(a1);
break;
case 0x23:
if ( (*(_DWORD *)(*(_QWORD *)(*(_QWORD *)(a1 + 8) + 192LL) + 104LL) & 8) != 0 )
result = dtls_construct_change_cipher_spec(a1);
else
result = tls_construct_change_cipher_spec(a1);
break;
case 0x24:
result = tls_construct_finished(a1);
break;
default:
result = 0;
break;
}
return result;
}