//
// _CONF_new_section from 0xe23260 to 0xe23364 (260 bytes)
//
// 4 xrefs:
// > sub_E23A38 @ 0xe23abc
// > sub_E23A38 @ 0xe2422c
// > sub_E23A38 @ 0xe243a0
// > ??> @ 0x9cfd8
//
// 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
//
_QWORD *__fastcall CONF_new_section(__int64 a1, const char *a2)
{
void **v4; // x21
_QWORD *v5; // x19
size_t v6; // x20
void *v7; // x0
__int64 *v8; // x0
v4 = (void **)OPENSSL_sk_new_null();
if ( !v4 || (v5 = CRYPTO_malloc(&off_18, (__int64)"crypto/conf/conf_api.c", 196)) == nullptr )
{
v5 = nullptr;
goto LABEL_7;
}
v6 = (int)(strlen(a2) + 1);
v7 = CRYPTO_malloc((void *)v6, (__int64)"crypto/conf/conf_api.c", 199);
*v5 = v7;
if ( !v7 )
{
LABEL_7:
OPENSSL_sk_free(v4);
CRYPTO_free(v5, (__int64)"crypto/conf/conf_api.c", 212);
return nullptr;
}
memcpy(v7, a2, v6);
v5[1] = 0;
v8 = *(__int64 **)(a1 + 16);
v5[2] = v4;
if ( OPENSSL_LH_insert(v8, v5) )
OPENSSL_die("assertion failed: vv == NULL", "crypto/conf/conf_api.c", 207);
return v5;
}