{"type": "func", "start": 11400360, "end": 11400572, "name": "BN_GF2m_mod_exp", "pseudocode": "// \n// BN_GF2m_mod_exp from 0xadf4a8 to 0xadf57c (212 bytes)\n// \n// 1 xrefs:\n// > <???> @ 0x854bc\n// \n// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!\n// \n// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n// Generated at Fri, 27 Nov 2026 12:09:33 +0000\n// \n\nint __fastcall BN_GF2m_mod_exp(int **a1, int **a2, _DWORD *a3, int **a4, int ***a5)\n{\n  int v9; // r5\n  int *v10; // r10\n  int v11; // r4\n  int v12; // r0\n  _BOOL4 v13; // r12\n\n  v9 = BN_num_bits(a4) + 1;\n  v10 = (int *)CRYPTO_malloc((void *)(4 * v9), (int)\"crypto/bn/bn_gf2m.c\", 964);\n  if ( v10 )\n  {\n    v12 = BN_GF2m_poly2arr(a4, (int)v10, v9);\n    v13 = v12 == 0;\n    if ( v12 > v9 )\n      v13 = 1;\n    v11 = v12;\n    if ( v13 )\n      ERR_put_error(3, 132, 106, (int)\"crypto/bn/bn_gf2m.c\", 968);\n    else\n      v11 = BN_GF2m_mod_exp_arr(a1, a2, a3, v10, a5);\n  }\n  else\n  {\n    v11 = 0;\n  }\n  CRYPTO_free(v10, (int)\"crypto/bn/bn_gf2m.c\", 974);\n  return v11;\n}", "assembly": "; \n; BN_GF2m_mod_exp from 0xadf4a8 to 0xadf57c (212 bytes)\n; \n; 1 xrefs:\n; > <???> @ 0x854bc\n; \n; This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!\n; \n; Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n; Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n; Generated at Fri, 27 Nov 2026 12:09:33 +0000\n; \nPUSH            {R4-R10,LR}                                            ; +0x0, 0xadf4a8\nMOV             R9, R0                                                 ; +0x4, 0xadf4ac\nSUB             SP, SP, #8                                             ; +0x8, 0xadf4b0\nMOV             R0, R3                                                 ; +0xc, 0xadf4b4\nMOV             R4, R3                                                 ; +0x10, 0xadf4b8\nMOV             R8, R1                                                 ; +0x14, 0xadf4bc\nMOV             R7, R2                                                 ; +0x18, 0xadf4c0\nBL              BN_num_bits                                            ; +0x1c, 0xadf4c4\nLDR             R6, =(aCryptoBnBnGf2m - 0xADF4D8); \"crypto/bn/bn_gf2m.c\" ; +0x20, 0xadf4c8\nMOV             R2, #0x3C4                                             ; +0x24, 0xadf4cc\nADD             R6, PC, R6; \"crypto/bn/bn_gf2m.c\"                      ; +0x28, 0xadf4d0\nMOV             R1, R6                                                 ; +0x2c, 0xadf4d4\nADD             R5, R0, #1                                             ; +0x30, 0xadf4d8\nMOV             R0, R5,LSL#2                                           ; +0x34, 0xadf4dc\nBL              CRYPTO_malloc                                          ; +0x38, 0xadf4e0\nSUBS            R10, R0, #0                                            ; +0x3c, 0xadf4e4\nMOVEQ           R4, R10                                                ; +0x40, 0xadf4e8\nBEQ             loc_ADF53C                                             ; +0x44, 0xadf4ec\nMOV             R0, R4                                                 ; +0x48, 0xadf4f0\nMOV             R1, R10                                                ; +0x4c, 0xadf4f4\nMOV             R2, R5                                                 ; +0x50, 0xadf4f8\nBL              BN_GF2m_poly2arr                                       ; +0x54, 0xadf4fc\nCLZ             R12, R0                                                ; +0x58, 0xadf500\nMOV             R12, R12,LSR#5                                         ; +0x5c, 0xadf504\nCMP             R0, R5                                                 ; +0x60, 0xadf508\nORRGT           R12, R12, #1                                           ; +0x64, 0xadf50c\nCMP             R12, #0                                                ; +0x68, 0xadf510\nMOV             R4, R0                                                 ; +0x6c, 0xadf514\nBNE             loc_ADF55C                                             ; +0x70, 0xadf518\nLDR             R3, [SP,#8+arg_0]                                      ; +0x74, 0xadf51c\nSTR             R3, [SP,#8+var_8]                                      ; +0x78, 0xadf520\nMOV             R0, R9                                                 ; +0x7c, 0xadf524\nMOV             R1, R8                                                 ; +0x80, 0xadf528\nMOV             R2, R7                                                 ; +0x84, 0xadf52c\nMOV             R3, R10                                                ; +0x88, 0xadf530\nBL              BN_GF2m_mod_exp_arr                                    ; +0x8c, 0xadf534\nMOV             R4, R0                                                 ; +0x90, 0xadf538\nLDR             R1, =(aCryptoBnBnGf2m - 0xADF54C); \"crypto/bn/bn_gf2m.c\" ; +0x94, 0xadf53c\nMOV             R0, R10                                                ; +0x98, 0xadf540\nADD             R1, PC, R1; \"crypto/bn/bn_gf2m.c\"                      ; +0x9c, 0xadf544\nLDR             R2, =0x3CE                                             ; +0xa0, 0xadf548\nBL              CRYPTO_free                                            ; +0xa4, 0xadf54c\nMOV             R0, R4                                                 ; +0xa8, 0xadf550\nADD             SP, SP, #8                                             ; +0xac, 0xadf554\nPOP             {R4-R10,PC}                                            ; +0xb0, 0xadf558\nMOV             R2, #0x3C8                                             ; +0xb4, 0xadf55c\nSTR             R2, [SP,#8+var_8]                                      ; +0xb8, 0xadf560\nMOV             R3, R6                                                 ; +0xbc, 0xadf564\nMOV             R0, #3                                                 ; +0xc0, 0xadf568\nMOV             R1, #0x84                                              ; +0xc4, 0xadf56c\nMOV             R2, #0x6A ; 'j'                                        ; +0xc8, 0xadf570\nBL              ERR_put_error                                          ; +0xcc, 0xadf574\nB               loc_ADF53C                                             ; +0xd0, 0xadf578", "xrefs": ["<???> @ 0x854bc"], "is_objc": false, "is_32_bit": true, "is_64_bit": false, "idp_name": "arm", "bida_info": "8.3.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings"}