{"type": "func", "start": 16888244, "end": 16888480, "name": "ENGINE_set_default", "pseudocode": "// \n// ENGINE_set_default from 0x101b1b4 to 0x101b2a0 (236 bytes)\n// \n// 3 xrefs:\n// > sub_E2F060 @ 0xe2f084\n// > ENGINE_set_default_string @ 0x101b2e8\n// > <???> @ 0xfed28\n// \n// This function is hookable on this platform (idp: arm, 32 bit: False, 64 bit: True!\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 13:16:07 +0000\n// \n\nbool __fastcall ENGINE_set_default(__int64 a1, __int16 a2)\n{\n  if ( (a2 & 0x40) != 0 && !(unsigned int)ENGINE_set_default_ciphers() )\n    return 0;\n  if ( (a2 & 0x80) != 0 )\n  {\n    if ( !(unsigned int)ENGINE_set_default_digests(a1) )\n      return 0;\n    if ( (a2 & 1) == 0 )\n    {\nLABEL_4:\n      if ( (a2 & 2) == 0 )\n        goto LABEL_5;\n      goto LABEL_17;\n    }\n  }\n  else if ( (a2 & 1) == 0 )\n  {\n    goto LABEL_4;\n  }\n  if ( !(unsigned int)ENGINE_set_default_RSA(a1) )\n    return 0;\n  if ( (a2 & 2) == 0 )\n  {\nLABEL_5:\n    if ( (a2 & 4) == 0 )\n      goto LABEL_6;\n    goto LABEL_19;\n  }\nLABEL_17:\n  if ( !(unsigned int)ENGINE_set_default_DSA(a1) )\n    return 0;\n  if ( (a2 & 4) == 0 )\n  {\nLABEL_6:\n    if ( (a2 & 0x800) == 0 )\n      goto LABEL_7;\nLABEL_21:\n    if ( !(unsigned int)ENGINE_set_default_EC(a1) )\n      return 0;\n    if ( (a2 & 8) == 0 )\n      goto LABEL_8;\n    goto LABEL_23;\n  }\nLABEL_19:\n  if ( !(unsigned int)ENGINE_set_default_DH(a1) )\n    return 0;\n  if ( (a2 & 0x800) != 0 )\n    goto LABEL_21;\nLABEL_7:\n  if ( (a2 & 8) == 0 )\n  {\nLABEL_8:\n    if ( (a2 & 0x200) == 0 )\n      goto LABEL_9;\nLABEL_25:\n    if ( (unsigned int)ENGINE_set_default_pkey_meths(a1) )\n    {\n      if ( (a2 & 0x400) == 0 )\n        return 1;\n      return (unsigned int)ENGINE_set_default_pkey_asn1_meths(a1) != 0;\n    }\n    return 0;\n  }\nLABEL_23:\n  if ( !(unsigned int)ENGINE_set_default_RAND(a1) )\n    return 0;\n  if ( (a2 & 0x200) != 0 )\n    goto LABEL_25;\nLABEL_9:\n  if ( (a2 & 0x400) == 0 )\n    return 1;\n  return (unsigned int)ENGINE_set_default_pkey_asn1_meths(a1) != 0;\n}", "assembly": "; \n; ENGINE_set_default from 0x101b1b4 to 0x101b2a0 (236 bytes)\n; \n; 3 xrefs:\n; > sub_E2F060 @ 0xe2f084\n; > ENGINE_set_default_string @ 0x101b2e8\n; > <???> @ 0xfed28\n; \n; This function is hookable on this platform (idp: arm, 32 bit: False, 64 bit: True!\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 13:16:07 +0000\n; \nSTP             X29, X30, [SP,#-0x20+var_s0]!                          ; +0x0, 0x101b1b4\nMOV             X29, SP                                                ; +0x4, 0x101b1b8\nSTP             X19, X20, [SP,#var_s10]                                ; +0x8, 0x101b1bc\nMOV             W19, W1                                                ; +0xc, 0x101b1c0\nMOV             X20, X0                                                ; +0x10, 0x101b1c4\nTBNZ            W19, #6, loc_101B1FC                                   ; +0x14, 0x101b1c8\nTBNZ            W19, #7, loc_101B214                                   ; +0x18, 0x101b1cc\nTBNZ            W19, #0, loc_101B224                                   ; +0x1c, 0x101b1d0\nTBNZ            W19, #1, loc_101B234                                   ; +0x20, 0x101b1d4\nTBNZ            W19, #2, loc_101B244                                   ; +0x24, 0x101b1d8\nTBNZ            W19, #0xB, loc_101B254                                 ; +0x28, 0x101b1dc\nTBNZ            W19, #3, loc_101B264                                   ; +0x2c, 0x101b1e0\nTBNZ            W19, #9, loc_101B274                                   ; +0x30, 0x101b1e4\nTBNZ            W19, #0xA, loc_101B284                                 ; +0x34, 0x101b1e8\nMOV             W0, #1                                                 ; +0x38, 0x101b1ec\nLDP             X19, X20, [SP,#var_s10]                                ; +0x3c, 0x101b1f0\nLDP             X29, X30, [SP+var_s0],#0x20                            ; +0x40, 0x101b1f4\nRET                                                                    ; +0x44, 0x101b1f8\nBL              ENGINE_set_default_ciphers                             ; +0x48, 0x101b1fc\nCBNZ            W0, loc_101B1CC                                        ; +0x4c, 0x101b200\nMOV             W0, #0                                                 ; +0x50, 0x101b204\nLDP             X19, X20, [SP,#var_s10]                                ; +0x54, 0x101b208\nLDP             X29, X30, [SP+var_s0],#0x20                            ; +0x58, 0x101b20c\nRET                                                                    ; +0x5c, 0x101b210\nMOV             X0, X20                                                ; +0x60, 0x101b214\nBL              ENGINE_set_default_digests                             ; +0x64, 0x101b218\nCBZ             W0, loc_101B204                                        ; +0x68, 0x101b21c\nTBZ             W19, #0, loc_101B1D4                                   ; +0x6c, 0x101b220\nMOV             X0, X20                                                ; +0x70, 0x101b224\nBL              ENGINE_set_default_RSA                                 ; +0x74, 0x101b228\nCBZ             W0, loc_101B204                                        ; +0x78, 0x101b22c\nTBZ             W19, #1, loc_101B1D8                                   ; +0x7c, 0x101b230\nMOV             X0, X20                                                ; +0x80, 0x101b234\nBL              ENGINE_set_default_DSA                                 ; +0x84, 0x101b238\nCBZ             W0, loc_101B204                                        ; +0x88, 0x101b23c\nTBZ             W19, #2, loc_101B1DC                                   ; +0x8c, 0x101b240\nMOV             X0, X20                                                ; +0x90, 0x101b244\nBL              ENGINE_set_default_DH                                  ; +0x94, 0x101b248\nCBZ             W0, loc_101B204                                        ; +0x98, 0x101b24c\nTBZ             W19, #0xB, loc_101B1E0                                 ; +0x9c, 0x101b250\nMOV             X0, X20                                                ; +0xa0, 0x101b254\nBL              ENGINE_set_default_EC                                  ; +0xa4, 0x101b258\nCBZ             W0, loc_101B204                                        ; +0xa8, 0x101b25c\nTBZ             W19, #3, loc_101B1E4                                   ; +0xac, 0x101b260\nMOV             X0, X20                                                ; +0xb0, 0x101b264\nBL              ENGINE_set_default_RAND                                ; +0xb4, 0x101b268\nCBZ             W0, loc_101B204                                        ; +0xb8, 0x101b26c\nTBZ             W19, #9, loc_101B1E8                                   ; +0xbc, 0x101b270\nMOV             X0, X20                                                ; +0xc0, 0x101b274\nBL              ENGINE_set_default_pkey_meths                          ; +0xc4, 0x101b278\nCBZ             W0, loc_101B204                                        ; +0xc8, 0x101b27c\nTBZ             W19, #0xA, loc_101B1EC                                 ; +0xcc, 0x101b280\nMOV             X0, X20                                                ; +0xd0, 0x101b284\nBL              ENGINE_set_default_pkey_asn1_meths                     ; +0xd4, 0x101b288\nCMP             W0, WZR                                                ; +0xd8, 0x101b28c\nCSET            W0, NE                                                 ; +0xdc, 0x101b290\nLDP             X19, X20, [SP,#var_s10]                                ; +0xe0, 0x101b294\nLDP             X29, X30, [SP+var_s0],#0x20                            ; +0xe4, 0x101b298\nRET                                                                    ; +0xe8, 0x101b29c", "xrefs": ["sub_E2F060 @ 0xe2f084", "ENGINE_set_default_string @ 0x101b2e8", "<???> @ 0xfed28"], "is_objc": false, "is_32_bit": false, "is_64_bit": true, "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"}