// // sub_E23490 from 0xe23490 to 0xe2399c (1292 bytes) // // 2 xrefs: // > sub_E23A38 @ 0xe24048 // > sub_E23A38 @ 0xe24200 // // 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_E23490(__int64 a1, const char *a2, void **a3, unsigned __int8 *a4) { _QWORD *v8; // x23 int v9; // w0 int v10; // w4 int v11; // w19 __int64 v12; // x5 __int16 i; // w6 int v14; // w0 unsigned __int8 *v15; // x3 __int64 v16; // x7 __int16 v17; // w8 __int64 v18; // x9 unsigned __int8 *v19; // x6 int v20; // w1 __int64 v21; // x7 unsigned __int8 *v22; // x6 int v23; // w0 int v24; // w6 int v25; // w26 char *v26; // x4 char *v27; // x27 int v28; // t1 char *v29; // x20 char *v30; // x22 char *string; // x25 size_t v32; // x0 char v33; // w1 char *v34; // x0 __int64 v35; // x4 int v36; // t1 char *v37; // x2 __int64 v38; // x1 int v39; // t1 v8 = (_QWORD *)BUF_MEM_new(); if ( !v8 ) return 0; v9 = strlen((const char *)a4); if ( BUF_MEM_grow(v8, v9 + 1) ) { v10 = *a4; v11 = 0; v12 = *(_QWORD *)(a1 + 8); for ( i = *(_WORD *)(v12 + 2LL * *a4); ; i = *(_WORD *)(v12 + 2LL * (unsigned __int8)*v29) ) { while ( 1 ) { while ( 1 ) { while ( 1 ) { while ( (i & 0x40) != 0 ) { while ( 1 ) { v14 = v10; v10 = a4[1]; v15 = a4 + 1; v16 = 2LL * a4[1]; v17 = *(_WORD *)(v12 + v16); if ( (v17 & 8) == 0 ) { if ( v10 == v14 ) break; v18 = v11; while ( 1 ) { v19 = v15; if ( (v17 & 0x20) != 0 ) { v10 = v15[1]; v19 = v15 + 1; v16 = 2LL * v15[1]; if ( (*(_WORD *)(v12 + v16) & 8) != 0 ) break; } ++v11; v15 = v19 + 1; *(_BYTE *)(v8[1] + v18++) = v10; v10 = v19[1]; v12 = *(_QWORD *)(a1 + 8); v16 = 2LL * v19[1]; v17 = *(_WORD *)(v12 + v16); if ( (v17 & 8) != 0 ) goto LABEL_12; if ( v10 == v14 ) goto LABEL_32; } ++v15; } LABEL_12: if ( v10 == v14 ) break; i = *(_WORD *)(v12 + v16); a4 = v15; if ( (i & 0x40) == 0 ) goto LABEL_14; } LABEL_32: v10 = v15[1]; a4 = v15 + 1; i = *(_WORD *)(v12 + 2LL * v15[1]); } LABEL_14: if ( (i & 0x400) == 0 ) break; v20 = v10; v10 = a4[1]; i = *(_WORD *)(v12 + 2LL * a4[1]); if ( (i & 8) != 0 ) { ++a4; LABEL_30: if ( v10 == v20 ) { v10 = *++a4; i = *(_WORD *)(v12 + 2LL * (unsigned __int8)v10); } } else { v21 = v11; ++a4; while ( 1 ) { v22 = a4; if ( v10 == v20 ) { v10 = a4[1]; v22 = a4 + 1; if ( v10 != v20 ) break; } a4 = v22 + 1; ++v11; *(_BYTE *)(v8[1] + v21++) = v10; v10 = v22[1]; v12 = *(_QWORD *)(a1 + 8); i = *(_WORD *)(v12 + 2LL * v22[1]); if ( (i & 8) != 0 ) goto LABEL_30; } ++a4; i = *(_WORD *)(v12 + 2LL * (unsigned __int8)v10); } } if ( (i & 0x20) == 0 ) break; v23 = a4[1]; if ( (*(_WORD *)(v12 + 2LL * a4[1]) & 8) != 0 ) goto LABEL_68; switch ( v23 ) { case 'r': LOBYTE(v23) = 13; break; case 'n': LOBYTE(v23) = 10; break; case 'b': LOBYTE(v23) = 8; break; case 't': LOBYTE(v23) = 9; break; } *(_BYTE *)(v8[1] + v11++) = v23; v10 = a4[2]; a4 += 2; v12 = *(_QWORD *)(a1 + 8); i = *(_WORD *)(v12 + 2LL * (unsigned __int8)v10); } v24 = i & 8; if ( v24 ) { LABEL_68: *(_BYTE *)(v8[1] + v11) = 0; CRYPTO_free(*a3, (__int64)"crypto/conf/conf_def.c", 539); *a3 = (void *)v8[1]; CRYPTO_free(v8, (__int64)"crypto/conf/conf_def.c", 541); return 1; } if ( v10 == 36 ) break; ++a4; *(_BYTE *)(v8[1] + v11++) = v10; v10 = *a4; v12 = *(_QWORD *)(a1 + 8); i = *(_WORD *)(v12 + 2LL * *a4); } v25 = a4[1]; if ( v25 == 123 ) { v24 = 125; } else { if ( v25 != 40 ) { v26 = (char *)(a4 + 1); goto LABEL_40; } v24 = 41; } v26 = (char *)(a4 + 2); v25 = a4[2]; LABEL_40: v27 = v26; if ( (*(_WORD *)(v12 + 2LL * (unsigned __int8)v25) & 0x107) != 0 ) { do { v28 = (unsigned __int8)*++v27; v25 = v28; } while ( (*(_WORD *)(v12 + 2LL * (unsigned __int8)v28) & 0x107) != 0 ); } if ( v25 == 58 && v27[1] == 58 ) { *v27 = 0; v37 = v27 + 2; v25 = (unsigned __int8)v27[2]; v30 = v27 + 2; v38 = *(_QWORD *)(a1 + 8); if ( (*(_WORD *)(v38 + 2LL * (unsigned __int8)v27[2]) & 0x107) != 0 ) { do { v39 = (unsigned __int8)*++v30; v25 = v39; } while ( (*(_WORD *)(v38 + 2LL * (unsigned __int8)v39) & 0x107) != 0 ); } *v30 = 0; if ( v24 ) { if ( v24 != v25 ) { LABEL_69: ERR_put_error(14, 101, 102, (__int64)"crypto/conf/conf_def.c", 491); BUF_MEM_free((__int64)v8); return 0; } v29 = v30 + 1; string = CONF_get_string(a1, v26, v37); } else { v29 = v30; string = CONF_get_string(a1, v26, v37); } *v27 = 58; *v30 = v25; if ( !string ) goto LABEL_62; } else { *v27 = 0; if ( v24 ) { if ( v24 != v25 ) goto LABEL_69; v29 = v27 + 1; v30 = v27; string = CONF_get_string(a1, a2, v26); } else { v29 = v27; v30 = v27; string = CONF_get_string(a1, a2, v26); } *v30 = v25; if ( !string ) { LABEL_62: ERR_put_error(14, 101, 104, (__int64)"crypto/conf/conf_def.c", 511); break; } } v32 = strlen(string); if ( !BUF_MEM_grow_clean(v8, a4 - (unsigned __int8 *)v29 + *v8 + v32) ) { ERR_put_error(14, 101, 65, (__int64)"crypto/conf/conf_def.c", 516); BUF_MEM_free((__int64)v8); return 0; } v33 = *string; if ( *string ) { v34 = string; v35 = v11 - (_QWORD)string; do { ++v11; v34[v35 + v8[1]] = v33; v36 = (unsigned __int8)*++v34; v33 = v36; } while ( v36 ); } *v30 = v25; a4 = (unsigned __int8 *)v29; v10 = (unsigned __int8)*v29; v12 = *(_QWORD *)(a1 + 8); } } BUF_MEM_free((__int64)v8); return 0; }
GD Web Decomp Icon

GD Web Decomp

Raw Source