// // sub_100549E58 from 0x100549e58 to 0x10054a178 (800 bytes) // // 1 xrefs: // > sub_100566E34 @ 0x100566efc // // 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 sub_100549E58(_QWORD *a1) { const char **v2; // x25 const char *v3; // x20 const char *v4; // x28 const char *v5; // x23 const char *v6; // x0 char *v7; // x27 char *v8; // x24 __int64 v9; // x27 const char *v10; // x21 const char *v11; // x23 const char *v12; // x20 char *v13; // x28 char *v14; // x24 __darwin_ct_rune_t v15; // w0 size_t v16; // x24 __darwin_ct_rune_t v17; // w0 size_t v18; // x24 __int64 v19; // x24 __int64 v20; // x0 __int64 v22; // [xsp+8h] [xbp-288h] __int64 v23; // [xsp+10h] [xbp-280h] unsigned int v24; // [xsp+34h] [xbp-25Ch] BYREF char v25[256]; // [xsp+38h] [xbp-258h] BYREF char v26[264]; // [xsp+138h] [xbp-158h] BYREF v2 = (const char **)a1[245]; if ( !v2 ) { LABEL_38: a1[245] = 0; return 0; } v3 = "%255[^:]:%d"; v4 = "%s:%d"; v5 = "Couldn't parse CURLOPT_RESOLVE removal entry '%s'!\n"; while ( 1 ) { v6 = *v2; if ( !*v2 ) goto LABEL_37; if ( *v6 != 45 ) break; if ( sscanf(v6 + 1, v3, v26, &v24) == 2 ) { v7 = (char *)sub_1005628DC(v4, v26, v24); v8 = v7; if ( !v7 ) return 27; while ( 1 ) { v15 = (unsigned __int8)*v8; if ( !*v8 || v15 == 58 ) break; *v8++ = __tolower(v15); } v16 = strlen(v7); if ( a1[14] ) sub_10056FCA8(a1, 3, 2); sub_10056C0CC(a1[10], v7, v16 + 1); if ( a1[14] ) sub_10056FCF4(a1, 3); off_10085DEB8(v7); } else { sub_1005524A4(a1, v5, *v2, v22, v23); } LABEL_37: v2 = (const char **)v2[1]; if ( !v2 ) goto LABEL_38; } if ( sscanf(v6, "%255[^:]:%d:%255s", v26, &v24, v25) != 3 ) { sub_1005524A4(a1, "Couldn't parse CURLOPT_RESOLVE entry '%s'!\n"); goto LABEL_37; } v9 = sub_100574538(v25); if ( !v9 ) { sub_1005524A4(a1, "Address in '%s' found illegal!\n"); goto LABEL_37; } v10 = v5; v11 = v3; v12 = v4; v13 = (char *)sub_1005628DC(v4, v26, v24); v14 = v13; if ( v13 ) { while ( 1 ) { v17 = (unsigned __int8)*v14; if ( !*v14 || v17 == 58 ) break; *v14++ = __tolower(v17); } v18 = strlen(v13); if ( a1[14] ) sub_10056FCA8(a1, 3, 2); v19 = sub_10056C170(a1[10], v13, v18 + 1); off_10085DEB8(v13); if ( v19 ) { sub_10057413C(v9); v4 = v12; } else { v20 = sub_100549850((__int64)a1, v9, v26, v24); v19 = v20; v4 = v12; if ( v20 ) { *(_QWORD *)(v20 + 8) = 0; --*(_QWORD *)(v20 + 16); } else { v19 = 0; } } v3 = v11; v5 = v10; if ( a1[14] ) sub_10056FCF4(a1, 3); if ( v19 ) { sub_1005524A4(a1, "Added %s:%d:%s to DNS cache\n"); goto LABEL_37; } } sub_10057413C(v9); return 27; }
GD Web Decomp Icon

GD Web Decomp

Raw Source