// // RC2_decrypt from 0xa3f19c to 0xa3f2fc (352 bytes) // // 4 xrefs: // > RC2_cbc_encrypt @ 0xa3f57c // > RC2_cbc_encrypt @ 0xa3f67c // > RC2_ecb_encrypt @ 0xa3f954 // > @ 0x7fb5c // // 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:08:12 +0000 // int *__fastcall RC2_decrypt(int *result, int a2) { unsigned int v2; // r3 unsigned int v3; // r4 unsigned int v4; // r5 unsigned int v5; // r12 int v6; // r6 int v7; // r9 int v8; // r8 int v9; // r7 int v10; // t1 int v11; // r2 int v12; // lr int v13; // lr v2 = (unsigned __int16)*result; v3 = HIWORD(*result); v4 = (unsigned __int16)result[1]; v5 = HIWORD(result[1]); v6 = a2 + 252; v7 = *(_DWORD *)(a2 + 252); v8 = 3; v9 = 5; while ( 1 ) { v5 = (unsigned __int16)((((_WORD)v5 << 11) | (v5 >> 5)) - (v2 & ~(_WORD)v4) - (v4 & v3) - v7); v11 = (unsigned __int16)(((_WORD)v4 << 13) | (v4 >> 3)) - (v5 & ~v3) - (v3 & v2) - *(_DWORD *)(v6 - 4); v4 = (unsigned __int16)v11; v12 = (unsigned __int16)(((_WORD)v3 << 14) | (v3 >> 2)) - ((unsigned __int16)v11 & ~v2) - (v5 & v2) - *(_DWORD *)(v6 - 8); v3 = (unsigned __int16)((((_WORD)v3 << 14) | (v3 >> 2)) - (v11 & ~(_WORD)v2) - (v5 & v2) - *(_WORD *)(v6 - 8)); --v9; v13 = v12 & 0x3F; v2 = (unsigned __int16)((((_WORD)v2 << 15) | (v2 >> 1)) - (v3 & ~(_WORD)v5) - (v11 & v5) - *(_WORD *)(v6 - 12)); if ( v9 ) goto LABEL_5; if ( !--v8 ) break; v5 -= *(_DWORD *)(a2 + 4 * (v11 & 0x3F)); v4 = (unsigned __int16)(v11 - *(_DWORD *)(a2 + 4 * v13)); v3 = (unsigned __int16)(v3 - *(_DWORD *)(a2 + 4 * (v2 & 0x3F))); v2 = (unsigned __int16)(v2 - *(_DWORD *)(a2 + 4 * (v5 & 0x3F))); v5 = (unsigned __int16)v5; if ( v8 == 2 ) v9 = 6; else v9 = 5; LABEL_5: v10 = *(_DWORD *)(v6 - 16); v6 -= 16; LOWORD(v7) = v10; } *result = (unsigned __int16)v2 | (v3 << 16); result[1] = (unsigned __int16)v11 | (v5 << 16); return result; }
GD Web Decomp Icon

GD Web Decomp

Raw Source