{"type": "func", "start": 14177764, "end": 14177860, "name": "DES_set_key_checked", "pseudocode": "// \n// DES_set_key_checked from 0xd855e4 to 0xd85644 (96 bytes)\n// \n// 2 xrefs:\n// > DES_set_key @ 0xd8567c\n// > <???> @ 0x3db30\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\n__int64 __fastcall DES_set_key_checked(void *a1, _DWORD *a2)\n{\n  _BOOL4 is_weak_key; // w19\n\n  if ( DES_check_key_parity((unsigned __int8 *)a1) )\n  {\n    is_weak_key = DES_is_weak_key(a1);\n    if ( is_weak_key )\n      return -2;\n    else\n      DES_set_key_unchecked((unsigned __int64)a1, a2);\n  }\n  else\n  {\n    return -1;\n  }\n  return is_weak_key;\n}", "assembly": "; \n; DES_set_key_checked from 0xd855e4 to 0xd85644 (96 bytes)\n; \n; 2 xrefs:\n; > DES_set_key @ 0xd8567c\n; > <???> @ 0x3db30\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\nSTP             X29, X30, [SP,#var_30]!                                ; +0x0, 0xd855e4\nMOV             X29, SP                                                ; +0x4, 0xd855e8\nSTP             X19, X20, [SP,#0x30+var_20]                            ; +0x8, 0xd855ec\nSTR             X21, [SP,#0x30+var_10]                                 ; +0xc, 0xd855f0\nMOV             X20, X0                                                ; +0x10, 0xd855f4\nMOV             X21, X1                                                ; +0x14, 0xd855f8\nBL              DES_check_key_parity                                   ; +0x18, 0xd855fc\nCBZ             W0, loc_D85634                                         ; +0x1c, 0xd85600\nMOV             X0, X20; void *                                        ; +0x20, 0xd85604\nBL              DES_is_weak_key                                        ; +0x24, 0xd85608\nMOV             W19, W0                                                ; +0x28, 0xd8560c\nCBNZ            W0, loc_D8563C                                         ; +0x2c, 0xd85610\nMOV             X0, X20                                                ; +0x30, 0xd85614\nMOV             X1, X21                                                ; +0x34, 0xd85618\nBL              DES_set_key_unchecked                                  ; +0x38, 0xd8561c\nMOV             W0, W19                                                ; +0x3c, 0xd85620\nLDR             X21, [SP,#0x30+var_10]                                 ; +0x40, 0xd85624\nLDP             X19, X20, [SP,#0x30+var_20]                            ; +0x44, 0xd85628\nLDP             X29, X30, [SP+0x30+var_30],#0x30                       ; +0x48, 0xd8562c\nRET                                                                    ; +0x4c, 0xd85630\nMOV             W19, #0xFFFFFFFF                                       ; +0x50, 0xd85634\nB               loc_D85620                                             ; +0x54, 0xd85638\nMOV             W19, #0xFFFFFFFE                                       ; +0x58, 0xd8563c\nB               loc_D85620                                             ; +0x5c, 0xd85640", "xrefs": ["DES_set_key @ 0xd8567c", "<???> @ 0x3db30"], "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"}