// // sub_7DE960 from 0x7de960 to 0x7dec5c (764 bytes) // // 2 xrefs: // > @ 0xa3094c // > @ 0xa309bc // // 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 sub_7DE960(int a1, int a2, int a3) { _DWORD *v3; // r4 int v6; // r0 int v7; // r7 int v8; // r2 int v10; // r2 int v11; // r2 int v12; // r6 int v13; // r2 const char *v14; // r3 int v15; // r1 int v16; // r2 int v17; // [sp+Ch] [bp-8h] v3 = *(_DWORD **)(a2 + 20); if ( !v3[2] ) { v8 = 67; goto LABEL_5; } BIO_indent(a1, a3, 128); v6 = BN_num_bits((_DWORD *)v3[2]); if ( BIO_printf(a1, "%s: (%d bit)\n", "DH Parameters", v6) <= 0 || (v7 = a3 + 4, !ASN1_bn_print(a1, "private-key:", 0, 0, a3 + 4)) || !ASN1_bn_print(a1, "public-key:", 0, 0, a3 + 4) || !ASN1_bn_print(a1, "prime:", v3[2], 0, a3 + 4) || !ASN1_bn_print(a1, "generator:", v3[3], 0, a3 + 4) || (v10 = v3[9]) != 0 && !ASN1_bn_print(a1, "subgroup order:", v10, 0, a3 + 4) || (v11 = v3[10]) != 0 && !ASN1_bn_print(a1, "subgroup factor:", v11, 0, a3 + 4) ) { LABEL_4: v8 = 7; LABEL_5: ERR_put_error(5, 100, v8, "crypto/dh/dh_ameth.c", 343); return 0; } if ( !v3[11] ) goto LABEL_25; BIO_indent(a1, a3 + 4, 128); v17 = a3 + 8; BIO_puts(a1, (int)"seed:"); v12 = 0; while ( 1 ) { v15 = v3[12]; if ( v12 >= v15 ) break; if ( v12 == 15 * (v12 / 15) ) { if ( BIO_puts(a1, (int)"\n") <= 0 || !BIO_indent(a1, v17, 128) ) goto LABEL_4; v15 = v3[12]; } v13 = *(unsigned __int8 *)(v3[11] + v12++); if ( v12 == v15 ) v14 = &byte_9B1912; else v14 = (const char *)&unk_9B1F30; if ( BIO_printf(a1, "%02x%s", v13, v14) <= 0 ) goto LABEL_4; } if ( BIO_write(a1, (int)"\n", 1) > 0 ) { LABEL_25: v16 = v3[13]; if ( !v16 || ASN1_bn_print(a1, "counter:", v16, 0, v7) ) { if ( !v3[4] ) return 1; BIO_indent(a1, v7, 128); if ( BIO_printf(a1, "recommended-private-length: %d bits\n", v3[4]) > 0 ) return 1; } goto LABEL_4; } return 0; }
GD Web Decomp Icon

GD Web Decomp

Raw Source