{"type": "func", "start": 5794044, "end": 5794516, "name": "AccountLoginLayer::onSubmit", "pseudocode": "// \n// AccountLoginLayer::onSubmit from 0x5868fc to 0x586ad4 (472 bytes)\n// \n// 0 xrefs:\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 11:52:58 +0000\n// \n\nint __fastcall AccountLoginLayer::onSubmit(AccountLoginLayer *this, cocos2d::CCObject *a2)\n{\n  int *v3; // r9\n  _BYTE *v4; // r2\n  int v5; // r3\n  bool v6; // zf\n  int *v7; // r6\n  int v8; // r0\n  int v9; // r1\n  int v10; // r2\n  int v11; // r0\n  int v12; // r1\n  int v13; // r2\n  int v14; // r3\n  unsigned int v15; // r3\n  AccountLoginLayer *v16; // r0\n  int v17; // r1\n  int v18; // r3\n  unsigned int v19; // r3\n  GJAccountManager *v20; // r0\n  int v22; // r0\n  int v23; // r1\n  int v24; // r2\n  GJAccountManager *v25; // r0\n  GJAccountManager *v26; // r10\n  int v27; // r6\n  int v28[3]; // [sp+4h] [bp-1Ch] BYREF\n  int v29; // [sp+10h] [bp-10h] BYREF\n  int v30; // [sp+14h] [bp-Ch]\n  int v31; // [sp+18h] [bp-8h]\n\n  v3 = (int *)((char *)this + 548);\n  AccountLoginLayer::resetLabels(this);\n  AccountLoginLayer::disableNodes(this);\n  CCTextInputNode::getString((CCTextInputNode *)&v29, *((_DWORD *)this + 132));\n  v6 = (*((_BYTE *)this + 548) & 1) == 0;\n  if ( (*((_BYTE *)this + 548) & 1) != 0 )\n  {\n    v4 = *((_BYTE **)this + 139);\n    v5 = 0;\n  }\n  else\n  {\n    *((_BYTE *)this + 549) = 0;\n    *((_BYTE *)this + 548) = 0;\n  }\n  v7 = (int *)((char *)this + 560);\n  if ( !v6 )\n  {\n    *v4 = v5;\n    *((_DWORD *)this + 138) = v5;\n  }\n  std::string::reserve(v3, 0);\n  v8 = v29;\n  v9 = v30;\n  v10 = v31;\n  v29 = 0;\n  v30 = 0;\n  v31 = 0;\n  *v3 = v8;\n  v3[1] = v9;\n  v3[2] = v10;\n  std::string::~string((int)&v29);\n  CCTextInputNode::getString((CCTextInputNode *)&v29, *((_DWORD *)this + 133));\n  if ( (*((_BYTE *)this + 560) & 1) != 0 )\n  {\n    **((_BYTE **)this + 142) = 0;\n    *((_DWORD *)this + 141) = 0;\n  }\n  else\n  {\n    *((_BYTE *)this + 561) = 0;\n    *((_BYTE *)this + 560) = 0;\n  }\n  std::string::reserve((int *)this + 140, 0);\n  v11 = v29;\n  v12 = v30;\n  v13 = v31;\n  v29 = 0;\n  v30 = 0;\n  v31 = 0;\n  *v7 = v11;\n  *((_DWORD *)this + 141) = v12;\n  *((_DWORD *)this + 142) = v13;\n  std::string::~string((int)&v29);\n  v14 = *((unsigned __int8 *)this + 548);\n  if ( (v14 & 1) != 0 )\n    v15 = *((_DWORD *)this + 138);\n  else\n    v15 = v14 >> 1;\n  if ( v15 <= 2 )\n  {\n    v16 = this;\n    v17 = -9;\n    return AccountLoginLayer::updateLabel((int)v16, v17);\n  }\n  v18 = *((unsigned __int8 *)this + 560);\n  if ( (v18 & 1) != 0 )\n    v19 = *((_DWORD *)this + 141);\n  else\n    v19 = v18 >> 1;\n  if ( v19 <= 5 )\n  {\n    v16 = this;\n    v17 = -8;\n    return AccountLoginLayer::updateLabel((int)v16, v17);\n  }\n  v20 = (GJAccountManager *)passwordCharsValid((unsigned __int8 *)this + 560);\n  if ( !v20 )\n  {\n    v16 = this;\n    v17 = -14;\n    return AccountLoginLayer::updateLabel((int)v16, v17);\n  }\n  *(_DWORD *)(GJAccountManager::sharedState(v20) + 308) = (char *)this + 520;\n  std::string::basic_string(v28, (int)this + 560);\n  GJAccountManager::getShaPassword(&v29, (int)v28);\n  if ( (*((_BYTE *)this + 560) & 1) != 0 )\n  {\n    **((_BYTE **)this + 142) = 0;\n    *((_DWORD *)this + 141) = 0;\n  }\n  else\n  {\n    *((_BYTE *)this + 561) = 0;\n    *((_BYTE *)this + 560) = 0;\n  }\n  std::string::reserve((int *)this + 140, 0);\n  v22 = v29;\n  v23 = v30;\n  v24 = v31;\n  v29 = 0;\n  v30 = 0;\n  v31 = 0;\n  *v7 = v22;\n  *((_DWORD *)this + 141) = v23;\n  *((_DWORD *)this + 142) = v24;\n  std::string::~string((int)&v29);\n  v25 = (GJAccountManager *)std::string::~string((int)v28);\n  v26 = (GJAccountManager *)GJAccountManager::sharedState(v25);\n  std::string::basic_string(v28, (int)v3);\n  std::string::basic_string(&v29, (int)this + 560);\n  v27 = GJAccountManager::loginAccount(v26, (int)v28, (int)&v29);\n  std::string::~string((int)&v29);\n  std::string::~string((int)v28);\n  if ( v27 )\n    return AccountLoginLayer::showLoadingUI(this);\n  else\n    return (*(int (__fastcall **)(AccountLoginLayer *, int))(*(_DWORD *)this + 692))(this, -1);\n}", "assembly": "; \n; AccountLoginLayer::onSubmit from 0x5868fc to 0x586ad4 (472 bytes)\n; \n; 0 xrefs:\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 11:52:58 +0000\n; \nPUSH.W          {R4-R10,LR}                                            ; +0x0, 0x5868fc\nSUB             SP, SP, #0x20                                          ; +0x4, 0x586900\nLDR.W           R8, =(__stack_chk_guard_ptr - 0x586912)                ; +0x6, 0x586902\nMOV             R4, R0                                                 ; +0xa, 0x586906\nADD             R5, SP, #0x20+var_10                                   ; +0xc, 0x586908\nADD.W           R9, R4, #0x224                                         ; +0xe, 0x58690a\nADD             R8, PC; __stack_chk_guard_ptr                          ; +0x12, 0x58690e\nLDR.W           R8, [R8]; __stack_chk_guard                            ; +0x14, 0x586910\nLDR.W           R3, [R8]                                               ; +0x18, 0x586914\nSTR             R3, [SP,#0x20+var_4]                                   ; +0x1c, 0x586918\nBL              _ZN17AccountLoginLayer11resetLabelsEv; AccountLoginLayer::resetLabels(void) ; +0x1e, 0x58691a\nMOV             R0, R4; this                                           ; +0x22, 0x58691e\nBL              _ZN17AccountLoginLayer12disableNodesEv; AccountLoginLayer::disableNodes(void) ; +0x24, 0x586920\nMOV             R0, R5; this                                           ; +0x28, 0x586924\nLDR.W           R1, [R4,#0x210]                                        ; +0x2a, 0x586926\nBL              _ZN15CCTextInputNode9getStringEv; CCTextInputNode::getString(void) ; +0x2e, 0x58692a\nLDRB.W          R7, [R4,#0x224]                                        ; +0x32, 0x58692e\nMOV             R0, R9                                                 ; +0x36, 0x586932\nMOVS            R1, #0                                                 ; +0x38, 0x586934\nANDS.W          R6, R7, #1                                             ; +0x3a, 0x586936\nITT EQ                                                                 ; +0x3e, 0x58693a\nSTRBEQ.W        R6, [R4,#0x225]                                        ; +0x40, 0x58693c\nSTRBEQ.W        R6, [R4,#0x224]                                        ; +0x44, 0x586940\nMOV.W           R7, #0                                                 ; +0x48, 0x586944\nITT NE                                                                 ; +0x4c, 0x586948\nLDRNE.W         R2, [R4,#0x22C]                                        ; +0x4e, 0x58694a\nMOVNE           R3, #0                                                 ; +0x52, 0x58694e\nADD.W           R6, R4, #0x230                                         ; +0x54, 0x586950\nITT NE                                                                 ; +0x58, 0x586954\nSTRBNE          R3, [R2]                                               ; +0x5a, 0x586956\nSTRNE.W         R3, [R4,#0x228]                                        ; +0x5c, 0x586958\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE7reserveEj; std::string::reserve(uint) ; +0x60, 0x58695c\nLDM.W           R5, {R0-R2}                                            ; +0x64, 0x586960\nSTR             R7, [SP,#0x20+var_10]                                  ; +0x68, 0x586964\nSTR             R7, [SP,#0x20+var_C]                                   ; +0x6a, 0x586966\nSTR             R7, [SP,#0x20+var_8]                                   ; +0x6c, 0x586968\nSTM.W           R9, {R0-R2}                                            ; +0x6e, 0x58696a\nMOV             R0, R5                                                 ; +0x72, 0x58696e\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev; std::string::~string() ; +0x74, 0x586970\nMOV             R0, R5; this                                           ; +0x78, 0x586974\nLDR.W           R1, [R4,#0x214]                                        ; +0x7a, 0x586976\nBL              _ZN15CCTextInputNode9getStringEv; CCTextInputNode::getString(void) ; +0x7e, 0x58697a\nLDRB.W          R3, [R4,#0x230]                                        ; +0x82, 0x58697e\nMOV             R0, R6                                                 ; +0x86, 0x586982\nMOVS            R1, #0                                                 ; +0x88, 0x586984\nANDS.W          R3, R3, #1                                             ; +0x8a, 0x586986\nITTEE EQ                                                               ; +0x8e, 0x58698a\nSTRBEQ.W        R3, [R4,#0x231]                                        ; +0x90, 0x58698c\nSTRBEQ.W        R3, [R4,#0x230]                                        ; +0x94, 0x586990\nLDRNE.W         R3, [R4,#0x238]                                        ; +0x98, 0x586994\nSTRBNE          R7, [R3]                                               ; +0x9c, 0x586998\nIT NE                                                                  ; +0x9e, 0x58699a\nSTRNE.W         R7, [R4,#0x234]                                        ; +0xa0, 0x58699c\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE7reserveEj; std::string::reserve(uint) ; +0xa4, 0x5869a0\nLDM.W           R5, {R0-R2}                                            ; +0xa8, 0x5869a4\nMOVS            R3, #0                                                 ; +0xac, 0x5869a8\nSTR             R3, [SP,#0x20+var_10]                                  ; +0xae, 0x5869aa\nSTR             R3, [SP,#0x20+var_C]                                   ; +0xb0, 0x5869ac\nSTR             R3, [SP,#0x20+var_8]                                   ; +0xb2, 0x5869ae\nSTM.W           R6, {R0-R2}                                            ; +0xb4, 0x5869b0\nMOV             R0, R5                                                 ; +0xb8, 0x5869b4\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev; std::string::~string() ; +0xba, 0x5869b6\nLDRB.W          R3, [R4,#0x224]                                        ; +0xbe, 0x5869ba\nLSLS            R1, R3, #0x1F                                          ; +0xc2, 0x5869be\nITE PL                                                                 ; +0xc4, 0x5869c0\nASRPL           R3, R3, #1                                             ; +0xc6, 0x5869c2\nLDRMI.W         R3, [R4,#0x228]                                        ; +0xc8, 0x5869c4\nCMP             R3, #2                                                 ; +0xcc, 0x5869c8\nBHI             loc_5869D4                                             ; +0xce, 0x5869ca\nMOV             R0, R4                                                 ; +0xd0, 0x5869cc\nMOV             R1, #0xFFFFFFF7                                        ; +0xd2, 0x5869ce\nB               loc_5869FC                                             ; +0xd6, 0x5869d2\nLDRB.W          R3, [R4,#0x230]                                        ; +0xd8, 0x5869d4\nLSLS            R2, R3, #0x1F                                          ; +0xdc, 0x5869d8\nITE PL                                                                 ; +0xde, 0x5869da\nASRPL           R3, R3, #1                                             ; +0xe0, 0x5869dc\nLDRMI.W         R3, [R4,#0x234]                                        ; +0xe2, 0x5869de\nCMP             R3, #5                                                 ; +0xe6, 0x5869e2\nBHI             loc_5869EE                                             ; +0xe8, 0x5869e4\nMOV             R0, R4                                                 ; +0xea, 0x5869e6\nMOV             R1, #0xFFFFFFF8                                        ; +0xec, 0x5869e8\nB               loc_5869FC                                             ; +0xf0, 0x5869ec\nMOV             R0, R6                                                 ; +0xf2, 0x5869ee\nBL              _Z18passwordCharsValidRKNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEE; passwordCharsValid(std::string const&) ; +0xf4, 0x5869f0\nCBNZ            R0, loc_586A02                                         ; +0xf8, 0x5869f4\nMOV             R0, R4                                                 ; +0xfa, 0x5869f6\nMOV             R1, #0xFFFFFFF2                                        ; +0xfc, 0x5869f8\nBL              _ZN17AccountLoginLayer11updateLabelE12AccountError; AccountLoginLayer::updateLabel(AccountError) ; +0x100, 0x5869fc\nB               loc_586AC0                                             ; +0x104, 0x586a00\nBL              _ZN16GJAccountManager11sharedStateEv; GJAccountManager::sharedState(void) ; +0x106, 0x586a02\nADD             R7, SP, #0x20+var_1C                                   ; +0x10a, 0x586a06\nADD.W           R3, R4, #0x208                                         ; +0x10c, 0x586a08\nMOV             R1, R6                                                 ; +0x110, 0x586a0c\nSTR.W           R3, [R0,#0x134]                                        ; +0x112, 0x586a0e\nMOV             R0, R7                                                 ; +0x116, 0x586a12\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEC2ERKS5_; std::string::basic_string(std::string const&) ; +0x118, 0x586a14\nMOV             R0, R5                                                 ; +0x11c, 0x586a18\nMOV             R1, R7                                                 ; +0x11e, 0x586a1a\nBL              _ZN16GJAccountManager14getShaPasswordENSt6__ndk112basic_stringIcNS0_11char_traitsIcEENS0_9allocatorIcEEEE; GJAccountManager::getShaPassword(std::string) ; +0x120, 0x586a1c\nLDRB.W          R3, [R4,#0x230]                                        ; +0x124, 0x586a20\nMOV             R0, R6                                                 ; +0x128, 0x586a24\nMOVS            R1, #0                                                 ; +0x12a, 0x586a26\nANDS.W          R3, R3, #1                                             ; +0x12c, 0x586a28\nITTEE EQ                                                               ; +0x130, 0x586a2c\nSTRBEQ.W        R3, [R4,#0x231]                                        ; +0x132, 0x586a2e\nSTRBEQ.W        R3, [R4,#0x230]                                        ; +0x136, 0x586a32\nLDRNE.W         R2, [R4,#0x238]                                        ; +0x13a, 0x586a36\nMOVNE           R3, #0                                                 ; +0x13e, 0x586a3a\nITT NE                                                                 ; +0x140, 0x586a3c\nSTRBNE          R3, [R2]                                               ; +0x142, 0x586a3e\nSTRNE.W         R3, [R4,#0x234]                                        ; +0x144, 0x586a40\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE7reserveEj; std::string::reserve(uint) ; +0x148, 0x586a44\nLDM.W           R5, {R0-R2}                                            ; +0x14c, 0x586a48\nMOVS            R3, #0                                                 ; +0x150, 0x586a4c\nSTR             R3, [SP,#0x20+var_10]                                  ; +0x152, 0x586a4e\nSTR             R3, [SP,#0x20+var_C]                                   ; +0x154, 0x586a50\nSTR             R3, [SP,#0x20+var_8]                                   ; +0x156, 0x586a52\nSTM.W           R6, {R0-R2}                                            ; +0x158, 0x586a54\nMOV             R0, R5                                                 ; +0x15c, 0x586a58\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev; std::string::~string() ; +0x15e, 0x586a5a\nMOV             R0, R7                                                 ; +0x162, 0x586a5e\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev; std::string::~string() ; +0x164, 0x586a60\nBL              _ZN16GJAccountManager11sharedStateEv; GJAccountManager::sharedState(void) ; +0x168, 0x586a64\nMOV             R1, R9                                                 ; +0x16c, 0x586a68\nMOV             R10, R0                                                ; +0x16e, 0x586a6a\nMOV             R0, R7                                                 ; +0x170, 0x586a6c\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEC2ERKS5_; std::string::basic_string(std::string const&) ; +0x172, 0x586a6e\nMOV             R0, R5                                                 ; +0x176, 0x586a72\nMOV             R1, R6                                                 ; +0x178, 0x586a74\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEC2ERKS5_; std::string::basic_string(std::string const&) ; +0x17a, 0x586a76\nMOV             R0, R10                                                ; +0x17e, 0x586a7a\nMOV             R1, R7                                                 ; +0x180, 0x586a7c\nMOV             R2, R5                                                 ; +0x182, 0x586a7e\nBL              _ZN16GJAccountManager12loginAccountENSt6__ndk112basic_stringIcNS0_11char_traitsIcEENS0_9allocatorIcEEEES6_; GJAccountManager::loginAccount(std::string,std::string) ; +0x184, 0x586a80\nMOV             R6, R0                                                 ; +0x188, 0x586a84\nMOV             R0, R5                                                 ; +0x18a, 0x586a86\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev; std::string::~string() ; +0x18c, 0x586a88\nMOV             R0, R7                                                 ; +0x190, 0x586a8c\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev; std::string::~string() ; +0x192, 0x586a8e\nCBZ             R6, loc_586A9C                                         ; +0x196, 0x586a92\nMOV             R0, R4; this                                           ; +0x198, 0x586a94\nBL              _ZN17AccountLoginLayer13showLoadingUIEv; AccountLoginLayer::showLoadingUI(void) ; +0x19a, 0x586a96\nB               loc_586AC0                                             ; +0x19e, 0x586a9a\nLDR             R3, [R4]                                               ; +0x1a0, 0x586a9c\nMOV             R0, R4                                                 ; +0x1a2, 0x586a9e\nMOV.W           R1, #0xFFFFFFFF                                        ; +0x1a4, 0x586aa0\nLDR.W           R3, [R3,#0x2B4]                                        ; +0x1a8, 0x586aa4\nBLX             R3                                                     ; +0x1ac, 0x586aa8\nB               loc_586AC0                                             ; +0x1ae, 0x586aaa\nB               loc_586AB6                                             ; +0x1b0, 0x586aac\nMOV             R0, R5                                                 ; +0x1b2, 0x586aae\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev; std::string::~string() ; +0x1b4, 0x586ab0\nB               loc_586AB6                                             ; +0x1b8, 0x586ab4\nMOV             R0, R7                                                 ; +0x1ba, 0x586ab6\nBL              _ZNSt6__ndk112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEED2Ev; std::string::~string() ; +0x1bc, 0x586ab8\nBL              __cxa_end_cleanup                                      ; +0x1c0, 0x586abc\nLDR             R2, [SP,#0x20+var_4]                                   ; +0x1c4, 0x586ac0\nLDR.W           R3, [R8]                                               ; +0x1c6, 0x586ac2\nCMP             R2, R3                                                 ; +0x1ca, 0x586ac6\nBEQ             loc_586ACE                                             ; +0x1cc, 0x586ac8\nBLX             __stack_chk_fail                                       ; +0x1ce, 0x586aca\nADD             SP, SP, #0x20 ; ' '                                    ; +0x1d2, 0x586ace\nPOP.W           {R4-R10,PC}                                            ; +0x1d4, 0x586ad0", "xrefs": [], "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"}