{"type": "func", "start": 8223500, "end": 8223640, "name": "BN_asc2bn", "pseudocode": "// \n// BN_asc2bn from 0x7d7b0c to 0x7d7b98 (140 bytes)\n// \n// 2 xrefs:\n// > sub_82F944 @ 0x82fbd8\n// > <???> @ 0x5ff1c\n// \n// This function is hookable on this platform!\n// \n// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings\n// \n\nint __fastcall BN_asc2bn(int ***a1, unsigned __int8 *a2)\n{\n  int v2; // r3\n  unsigned __int8 *v3; // r4\n  int result; // r0\n\n  v2 = *a2;\n  v3 = a2;\n  if ( v2 == 45 )\n    v2 = *++a2;\n  if ( v2 == 48 && (a2[1] & 0xDF) == 0x58 )\n  {\n    if ( !BN_hex2bn(a1, a2 + 2) )\n      return 0;\n  }\n  else if ( !BN_dec2bn(a1, a2) )\n  {\n    return 0;\n  }\n  if ( *v3 != 45 )\n    return 1;\n  result = 1;\n  if ( (*a1)[1] )\n    (*a1)[3] = &dword_0 + 1;\n  return result;\n}", "assembly": "; \n; BN_asc2bn from 0x7d7b0c to 0x7d7b98 (140 bytes)\n; \n; 2 xrefs:\n; > sub_82F944 @ 0x82fbd8\n; > <???> @ 0x5ff1c\n; \n; This function is hookable on this platform!\n; \n; Using BromaIDA 8.0.0 @ https:;github.com/Stazzical/BromaIDA\n; Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https:;github.com/geode-sdk/bindings\n; \n\nPUSH            {R3-R5,LR}                                             ; +0x0, 0x7d7b0c\nLDRB            R3, [R1]                                               ; +0x4, 0x7d7b10\nMOV             R4, R1                                                 ; +0x8, 0x7d7b14\nCMP             R3, #0x2D ; '-'                                        ; +0xc, 0x7d7b18\nLDRBEQ          R3, [R4,#1]                                            ; +0x10, 0x7d7b1c\nADDEQ           R1, R1, #1                                             ; +0x14, 0x7d7b20\nMOVNE           R1, R4                                                 ; +0x18, 0x7d7b24\nCMP             R3, #0x30 ; '0'                                        ; +0x1c, 0x7d7b28\nMOV             R5, R0                                                 ; +0x20, 0x7d7b2c\nBEQ             loc_7D7B70                                             ; +0x24, 0x7d7b30\nMOV             R0, R5                                                 ; +0x28, 0x7d7b34\nBL              BN_dec2bn                                              ; +0x2c, 0x7d7b38\nCMP             R0, #0                                                 ; +0x30, 0x7d7b3c\nBEQ             loc_7D7B90                                             ; +0x34, 0x7d7b40\nLDRB            R3, [R4]                                               ; +0x38, 0x7d7b44\nCMP             R3, #0x2D ; '-'                                        ; +0x3c, 0x7d7b48\nBEQ             loc_7D7B58                                             ; +0x40, 0x7d7b4c\nMOV             R0, #1                                                 ; +0x44, 0x7d7b50\nPOP             {R3-R5,PC}                                             ; +0x48, 0x7d7b54\nLDR             R3, [R5]                                               ; +0x4c, 0x7d7b58\nMOV             R0, #1                                                 ; +0x50, 0x7d7b5c\nLDR             R2, [R3,#4]                                            ; +0x54, 0x7d7b60\nCMP             R2, #0                                                 ; +0x58, 0x7d7b64\nSTRNE           R0, [R3,#0xC]                                          ; +0x5c, 0x7d7b68\nPOP             {R3-R5,PC}                                             ; +0x60, 0x7d7b6c\nLDRB            R3, [R1,#1]                                            ; +0x64, 0x7d7b70\nAND             R3, R3, #0xDF                                          ; +0x68, 0x7d7b74\nCMP             R3, #0x58 ; 'X'                                        ; +0x6c, 0x7d7b78\nBNE             loc_7D7B34                                             ; +0x70, 0x7d7b7c\nADD             R1, R1, #2                                             ; +0x74, 0x7d7b80\nBL              BN_hex2bn                                              ; +0x78, 0x7d7b84\nCMP             R0, #0                                                 ; +0x7c, 0x7d7b88\nBNE             loc_7D7B44                                             ; +0x80, 0x7d7b8c\nMOV             R0, #0                                                 ; +0x84, 0x7d7b90\nPOP             {R3-R5,PC}                                             ; +0x88, 0x7d7b94", "xrefs": ["sub_82F944 @ 0x82fbd8", "<???> @ 0x5ff1c"], "is_objc": false, "is_arm32": false, "is_arm64": false, "bida_info": "8.0.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings"}