{"type": "func", "start": 8283900, "end": 8284176, "name": "EC_GROUP_get_ecpkparameters", "pseudocode": "// \n// EC_GROUP_get_ecpkparameters from 0x7e66fc to 0x7e6810 (276 bytes)\n// \n// 3 xrefs:\n// > i2d_ECPKParameters @ 0x7e73a8\n// > i2d_ECPrivateKey @ 0x7e7914\n// > <???> @ 0x6144c\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_DWORD *__fastcall EC_GROUP_get_ecpkparameters(_DWORD *a1, int a2)\n{\n  _DWORD *v2; // r4\n  _DWORD *asn1_flag; // r1\n  _DWORD *ecparameters; // r0\n  int curve_name; // r0\n  _DWORD *v8; // r0\n  int v9; // r0\n\n  v2 = (_DWORD *)a2;\n  if ( a2 )\n  {\n    if ( !*(_DWORD *)a2 )\n    {\n      ASN1_OBJECT_free(*(_DWORD **)(a2 + 4));\n      asn1_flag = (_DWORD *)EC_GROUP_get_asn1_flag(a1);\n      if ( !asn1_flag )\n        goto LABEL_5;\nLABEL_7:\n      curve_name = EC_GROUP_get_curve_name(a1);\n      if ( !curve_name )\n        goto LABEL_8;\n      *v2 = 0;\n      v9 = OBJ_nid2obj(curve_name);\n      v2[1] = v9;\n      if ( !v9 )\n        goto LABEL_8;\n      return v2;\n    }\n    if ( *(_DWORD *)a2 == 1 )\n    {\n      v8 = *(_DWORD **)(a2 + 4);\n      if ( v8 )\n      {\n        ECPARAMETERS_free(v8);\n        asn1_flag = (_DWORD *)EC_GROUP_get_asn1_flag(a1);\n        if ( asn1_flag )\n          goto LABEL_7;\nLABEL_5:\n        *v2 = 1;\n        ecparameters = EC_GROUP_get_ecparameters(a1, asn1_flag);\n        v2[1] = ecparameters;\n        if ( !ecparameters )\n        {\nLABEL_8:\n          ECPKPARAMETERS_free(v2);\n          return nullptr;\n        }\n        return v2;\n      }\n    }\nLABEL_4:\n    asn1_flag = (_DWORD *)EC_GROUP_get_asn1_flag(a1);\n    if ( !asn1_flag )\n      goto LABEL_5;\n    goto LABEL_7;\n  }\n  v2 = ECPKPARAMETERS_new();\n  if ( v2 )\n    goto LABEL_4;\n  ERR_put_error(16, 262, 65, \"crypto/ec/ec_asn1.c\", 559);\n  return nullptr;\n}", "assembly": "; \n; EC_GROUP_get_ecpkparameters from 0x7e66fc to 0x7e6810 (276 bytes)\n; \n; 3 xrefs:\n; > i2d_ECPKParameters @ 0x7e73a8\n; > i2d_ECPrivateKey @ 0x7e7914\n; > <???> @ 0x6144c\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            {R4,R5,LR}                                             ; +0x0, 0x7e66fc\nSUBS            R4, R1, #0                                             ; +0x4, 0x7e6700\nSUB             SP, SP, #0xC                                           ; +0x8, 0x7e6704\nMOV             R5, R0                                                 ; +0xc, 0x7e6708\nBEQ             loc_7E67DC                                             ; +0x10, 0x7e670c\nLDR             R3, [R4]                                               ; +0x14, 0x7e6710\nCMP             R3, #0                                                 ; +0x18, 0x7e6714\nBEQ             loc_7E6780                                             ; +0x1c, 0x7e6718\nCMP             R3, #1                                                 ; +0x20, 0x7e671c\nBEQ             loc_7E679C                                             ; +0x24, 0x7e6720\nMOV             R0, R5                                                 ; +0x28, 0x7e6724\nBL              EC_GROUP_get_asn1_flag                                 ; +0x2c, 0x7e6728\nSUBS            R1, R0, #0                                             ; +0x30, 0x7e672c\nBNE             loc_7E675C                                             ; +0x34, 0x7e6730\nMOV             R3, #1                                                 ; +0x38, 0x7e6734\nMOV             R0, R5                                                 ; +0x3c, 0x7e6738\nSTR             R3, [R4]                                               ; +0x40, 0x7e673c\nBL              EC_GROUP_get_ecparameters                              ; +0x44, 0x7e6740\nCMP             R0, #0                                                 ; +0x48, 0x7e6744\nSTR             R0, [R4,#4]                                            ; +0x4c, 0x7e6748\nBEQ             loc_7E676C                                             ; +0x50, 0x7e674c\nMOV             R0, R4                                                 ; +0x54, 0x7e6750\nADD             SP, SP, #0xC                                           ; +0x58, 0x7e6754\nPOP             {R4,R5,PC}                                             ; +0x5c, 0x7e6758\nMOV             R0, R5                                                 ; +0x60, 0x7e675c\nBL              EC_GROUP_get_curve_name                                ; +0x64, 0x7e6760\nCMP             R0, #0                                                 ; +0x68, 0x7e6764\nBNE             loc_7E67C0                                             ; +0x6c, 0x7e6768\nMOV             R0, R4                                                 ; +0x70, 0x7e676c\nBL              ECPKPARAMETERS_free                                    ; +0x74, 0x7e6770\nMOV             R0, #0                                                 ; +0x78, 0x7e6774\nADD             SP, SP, #0xC                                           ; +0x7c, 0x7e6778\nPOP             {R4,R5,PC}                                             ; +0x80, 0x7e677c\nLDR             R0, [R4,#4]                                            ; +0x84, 0x7e6780\nBL              ASN1_OBJECT_free                                       ; +0x88, 0x7e6784\nMOV             R0, R5                                                 ; +0x8c, 0x7e6788\nBL              EC_GROUP_get_asn1_flag                                 ; +0x90, 0x7e678c\nSUBS            R1, R0, #0                                             ; +0x94, 0x7e6790\nBEQ             loc_7E6734                                             ; +0x98, 0x7e6794\nB               loc_7E675C                                             ; +0x9c, 0x7e6798\nLDR             R0, [R4,#4]                                            ; +0xa0, 0x7e679c\nCMP             R0, #0                                                 ; +0xa4, 0x7e67a0\nBEQ             loc_7E6724                                             ; +0xa8, 0x7e67a4\nBL              ECPARAMETERS_free                                      ; +0xac, 0x7e67a8\nMOV             R0, R5                                                 ; +0xb0, 0x7e67ac\nBL              EC_GROUP_get_asn1_flag                                 ; +0xb4, 0x7e67b0\nSUBS            R1, R0, #0                                             ; +0xb8, 0x7e67b4\nBEQ             loc_7E6734                                             ; +0xbc, 0x7e67b8\nB               loc_7E675C                                             ; +0xc0, 0x7e67bc\nMOV             R3, #0                                                 ; +0xc4, 0x7e67c0\nSTR             R3, [R4]                                               ; +0xc8, 0x7e67c4\nBL              OBJ_nid2obj                                            ; +0xcc, 0x7e67c8\nCMP             R0, #0                                                 ; +0xd0, 0x7e67cc\nSTR             R0, [R4,#4]                                            ; +0xd4, 0x7e67d0\nBNE             loc_7E6750                                             ; +0xd8, 0x7e67d4\nB               loc_7E676C                                             ; +0xdc, 0x7e67d8\nBL              ECPKPARAMETERS_new                                     ; +0xe0, 0x7e67dc\nSUBS            R4, R0, #0                                             ; +0xe4, 0x7e67e0\nBNE             loc_7E6724                                             ; +0xe8, 0x7e67e4\nLDR             R3, =0x22F                                             ; +0xec, 0x7e67e8\nSTR             R3, [SP,#0xC+var_C]                                    ; +0xf0, 0x7e67ec\nLDR             R3, =(aCryptoEcEcAsn1 - 0x7E6808); \"crypto/ec/ec_asn1.c\" ; +0xf4, 0x7e67f0\nMOV             R0, #0x10                                              ; +0xf8, 0x7e67f4\nLDR             R1, =0x106                                             ; +0xfc, 0x7e67f8\nMOV             R2, #0x41 ; 'A'                                        ; +0x100, 0x7e67fc\nADD             R3, PC, R3; \"crypto/ec/ec_asn1.c\"                      ; +0x104, 0x7e6800\nBL              ERR_put_error                                          ; +0x108, 0x7e6804\nMOV             R0, R4                                                 ; +0x10c, 0x7e6808\nB               loc_7E6754                                             ; +0x110, 0x7e680c", "xrefs": ["i2d_ECPKParameters @ 0x7e73a8", "i2d_ECPrivateKey @ 0x7e7914", "<???> @ 0x6144c"], "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"}