//
// EVP_PKEY_asn1_find_str from 0x7c21b0 to 0x7c2298 (232 bytes)
//
// 10 xrefs:
// > ssl_load_ciphers @ 0x793990
// > ssl_load_ciphers @ 0x793a10
// > ssl_load_ciphers @ 0x793a8c
// > ssl_load_ciphers @ 0x793b00
// > ssl_load_ciphers @ 0x793b74
// > EVP_PKEY_set_type_str @ 0x805404
// > PEM_bytes_read_bio @ 0x823164
// > PEM_bytes_read_bio @ 0x8231e4
// > PEM_read_bio_PrivateKey @ 0x823588
// > ??> @ 0x5b5ac
//
// 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 EVP_PKEY_asn1_find_str(_DWORD *a1, char *a2, size_t a3)
{
size_t v3; // r7
int str; // r5
int v8; // r4
bool v9; // cc
int v10; // r0
int v11; // r0
int v12; // r5
const char *v13; // r6
int v14; // [sp+4h] [bp-4h] BYREF
v3 = a3;
if ( a3 == -1 )
v3 = strlen(a2);
if ( a1 )
{
str = ENGINE_pkey_asn1_find_str(&v14, a2, v3);
if ( str )
{
if ( !ENGINE_init(v14) )
str = 0;
ENGINE_free(v14);
*a1 = v14;
return str;
}
*a1 = 0;
}
v8 = 0;
while ( 1 )
{
v9 = v8 < EVP_PKEY_asn1_get_count();
v10 = v8++;
if ( !v9 )
return 0;
v11 = EVP_PKEY_asn1_get0(v10);
v12 = v11;
if ( (*(_DWORD *)(v11 + 8) & 1) == 0 )
{
v13 = *(const char **)(v11 + 12);
if ( strlen(v13) == v3 && !strncasecmp(v13, a2, v3) )
break;
}
}
return v12;
}