//
// sub_855058 from 0x855058 to 0x85510c (180 bytes)
//
// 2 xrefs:
// > sub_855114 @ 0x8551ea
// > sub_855B74 @ 0x855b74
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// 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 12:02:35 +0000
//
int __fastcall sub_855058(_BYTE *a1, int a2)
{
int v2; // r4
unsigned int v5; // r0
int v6; // r1
int v7; // r5
unsigned int v9; // r2
char v10; // [sp+14h] [bp-8h] BYREF
char v11; // [sp+15h] [bp-7h]
char v12; // [sp+16h] [bp-6h]
v2 = 0;
v12 = 0;
v11 = 0;
v5 = OpenSSL_version_num();
if ( v5 <= 0x905FFF )
{
v7 = 1;
v10 = 0;
v6 = 1;
}
else if ( (v5 & 0xFF0) != 0 )
{
v9 = (unsigned __int8)(v5 >> 4);
if ( v9 <= 0x1A )
{
v6 = v5 >> 28;
v10 = v9 + 96;
v7 = (unsigned __int8)(v5 >> 20);
v2 = (unsigned __int8)(v5 >> 12);
}
else
{
v10 = 122;
v7 = (unsigned __int8)(v5 >> 20);
v6 = v5 >> 28;
v2 = (unsigned __int8)(v5 >> 12);
v11 = (int)(v9 - 1) % 26 + 98;
}
}
else
{
v6 = v5 >> 28;
v7 = (unsigned __int8)(v5 >> 20);
v2 = (unsigned __int8)(v5 >> 12);
v10 = 0;
}
return sub_8346C0(a1, a2, "%s/%lx.%lx.%lx%s", "OpenSSL", v6, v7, v2, &v10);
}