//
// sub_10072F58C from 0x10072f58c to 0x10072f7b4 (552 bytes)
//
// 2 xrefs:
// > sub_10072F18C @ 0x10072f1cc
// > sub_1007339DC @ 0x100733a58
//
// 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 11:13:12 +0000
//
void **__fastcall sub_10072F58C(__int64 a1, __int64 a2, void **a3)
{
char *v3; // x0
char *v4; // x1
char *v5; // x1
char *v6; // x0
int *v7; // x8
unsigned __int8 *v8; // x23
int v9; // w8
__int64 v10; // x24
_BYTE v12[5]; // [xsp+2Bh] [xbp-155h] BYREF
void **v13; // [xsp+30h] [xbp-150h] BYREF
char __dst[264]; // [xsp+38h] [xbp-148h] BYREF
v13 = a3;
switch ( *(_DWORD *)a2 )
{
case 0:
v3 = "othername";
v4 = "";
goto LABEL_19;
case 1:
v5 = *(char **)(*(_QWORD *)(a2 + 8) + 8LL);
v6 = "email";
goto LABEL_9;
case 2:
v5 = *(char **)(*(_QWORD *)(a2 + 8) + 8LL);
v6 = "DNS";
goto LABEL_9;
case 3:
v3 = "X400Name";
v4 = "";
goto LABEL_19;
case 4:
sub_10072580C(*(__int64 **)(a2 + 8), __dst, 256);
v3 = "DirName";
goto LABEL_18;
case 5:
v3 = "EdiPartyName";
v4 = "";
goto LABEL_19;
case 6:
v5 = *(char **)(*(_QWORD *)(a2 + 8) + 8LL);
v6 = "URI";
LABEL_9:
sub_10072CF7C(v6, v5, &v13);
return v13;
case 7:
v7 = *(int **)(a2 + 8);
v8 = *((unsigned __int8 **)v7 + 1);
v9 = *v7;
if ( v9 == 16 )
{
v10 = 0;
__dst[0] = 0;
do
{
sub_1007038AC((__int64)v12, 5u, "%X", v8[v10 + 1] | (v8[v10] << 8));
__strcat_chk(__dst, v12, 256);
if ( (_DWORD)v10 == 14 )
break;
__strcat_chk(__dst, ":", 256);
v10 += 2;
}
while ( (_DWORD)v10 != 16 );
v3 = "IP Address";
goto LABEL_18;
}
if ( v9 == 4 )
{
sub_1007038AC((__int64)__dst, 0x100u, "%d.%d.%d.%d", *v8, v8[1], v8[2], v8[3]);
v3 = "IP Address";
LABEL_18:
v4 = __dst;
goto LABEL_19;
}
v3 = "IP Address";
v4 = "";
LABEL_19:
sub_10072CE4C(v3, v4, &v13);
return v13;
case 8:
sub_1007143C0(__dst, 256, *(_QWORD *)(a2 + 8));
v3 = "Registered ID";
goto LABEL_18;
default:
return v13;
}
}