{"type": "func", "start": 11047916, "end": 11048016, "name": "CMS_RecipientInfo_kari_set0_pkey", "pseudocode": "// \n// CMS_RecipientInfo_kari_set0_pkey from 0xa893ec to 0xa89450 (100 bytes)\n// \n// 1 xrefs:\n// > <???> @ 0x83e0c\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 12:08:53 +0000\n// \n\nint __fastcall CMS_RecipientInfo_kari_set0_pkey(int a1, int a2)\n{\n  int v2; // r4\n  int *v4; // r0\n  int v5; // r5\n\n  v2 = *(_DWORD *)(a1 + 4);\n  EVP_PKEY_CTX_free(*(_DWORD *)(v2 + 20));\n  *(_DWORD *)(v2 + 20) = 0;\n  if ( !a2 )\n    return 1;\n  v4 = (int *)EVP_PKEY_CTX_new(a2, nullptr);\n  v5 = (int)v4;\n  if ( v4 && EVP_PKEY_derive_init(v4) )\n  {\n    *(_DWORD *)(v2 + 20) = v5;\n    return 1;\n  }\n  else\n  {\n    EVP_PKEY_CTX_free(v5);\n    return 0;\n  }\n}", "assembly": "; \n; CMS_RecipientInfo_kari_set0_pkey from 0xa893ec to 0xa89450 (100 bytes)\n; \n; 1 xrefs:\n; > <???> @ 0x83e0c\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 12:08:53 +0000\n; \nPUSH            {R3-R5,LR}                                             ; +0x0, 0xa893ec\nLDR             R4, [R0,#4]                                            ; +0x4, 0xa893f0\nMOV             R5, R1                                                 ; +0x8, 0xa893f4\nLDR             R0, [R4,#0x14]                                         ; +0xc, 0xa893f8\nBL              EVP_PKEY_CTX_free                                      ; +0x10, 0xa893fc\nMOV             R1, #0                                                 ; +0x14, 0xa89400\nCMP             R5, #0                                                 ; +0x18, 0xa89404\nSTR             R1, [R4,#0x14]                                         ; +0x1c, 0xa89408\nBEQ             loc_A89448                                             ; +0x20, 0xa8940c\nMOV             R0, R5                                                 ; +0x24, 0xa89410\nBL              EVP_PKEY_CTX_new                                       ; +0x28, 0xa89414\nSUBS            R5, R0, #0                                             ; +0x2c, 0xa89418\nBEQ             loc_A8942C                                             ; +0x30, 0xa8941c\nBL              EVP_PKEY_derive_init                                   ; +0x34, 0xa89420\nCMP             R0, #0                                                 ; +0x38, 0xa89424\nBNE             loc_A8943C                                             ; +0x3c, 0xa89428\nMOV             R0, R5                                                 ; +0x40, 0xa8942c\nBL              EVP_PKEY_CTX_free                                      ; +0x44, 0xa89430\nMOV             R0, #0                                                 ; +0x48, 0xa89434\nPOP             {R3-R5,PC}                                             ; +0x4c, 0xa89438\nSTR             R5, [R4,#0x14]                                         ; +0x50, 0xa8943c\nMOV             R0, #1                                                 ; +0x54, 0xa89440\nPOP             {R3-R5,PC}                                             ; +0x58, 0xa89444\nMOV             R0, #1                                                 ; +0x5c, 0xa89448\nPOP             {R3-R5,PC}                                             ; +0x60, 0xa8944c", "xrefs": ["<???> @ 0x83e0c"], "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"}