//
// ssl_add_clienthello_renegotiate_ext from 0xd5bcdc to 0xd5bd68 (140 bytes)
//
// 3 xrefs:
// > ssl_add_clienthello_tlsext @ 0xd59020
// > ssl_add_clienthello_tlsext @ 0xd59098
// > ??> @ 0x2f160
//
// 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 __fastcall ssl_add_clienthello_renegotiate_ext(__int64 a1, _BYTE *a2, _DWORD *a3, int a4)
{
int v6; // w0
if ( !a2 )
goto LABEL_4;
v6 = *(unsigned __int8 *)(*(_QWORD *)(a1 + 144) + 896LL);
if ( v6 < a4 )
{
*a2 = v6;
memcpy(a2 + 1, (const void *)(*(_QWORD *)(a1 + 144) + 832LL), *(unsigned __int8 *)(*(_QWORD *)(a1 + 144) + 896LL));
LABEL_4:
*a3 = *(unsigned __int8 *)(*(_QWORD *)(a1 + 144) + 896LL) + 1;
return 1;
}
ERR_put_error(20, 298, 335, "ssl/t1_reneg.c", 21);
return 0;
}