{"type": "func", "start": 8228872, "end": 8228952, "name": "CMAC_CTX_cleanup", "pseudocode": "// \n// CMAC_CTX_cleanup from 0x7d9008 to 0x7d9058 (80 bytes)\n// \n// 2 xrefs:\n// > CMAC_CTX_free @ 0x7d9070\n// > <???> @ 0x6003c\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_BYTE *__fastcall CMAC_CTX_cleanup(int a1)\n{\n  _BYTE *v2; // r5\n  _BYTE *result; // r0\n\n  v2 = (_BYTE *)(a1 + 68);\n  EVP_CIPHER_CTX_free(*(_DWORD *)a1);\n  OPENSSL_cleanse(v2, 0x20u);\n  OPENSSL_cleanse((_BYTE *)(a1 + 4), 0x20u);\n  OPENSSL_cleanse((_BYTE *)(a1 + 36), 0x20u);\n  result = OPENSSL_cleanse((_BYTE *)(a1 + 100), 0x20u);\n  *(_DWORD *)(a1 + 132) = -1;\n  return result;\n}", "assembly": "; \n; CMAC_CTX_cleanup from 0x7d9008 to 0x7d9058 (80 bytes)\n; \n; 2 xrefs:\n; > CMAC_CTX_free @ 0x7d9070\n; > <???> @ 0x6003c\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            {R3-R5,LR}                                             ; +0x0, 0x7d9008\nMOV             R5, R0                                                 ; +0x4, 0x7d900c\nMOV             R4, R0                                                 ; +0x8, 0x7d9010\nLDR             R0, [R5],#0x44                                         ; +0xc, 0x7d9014\nBL              EVP_CIPHER_CTX_free                                    ; +0x10, 0x7d9018\nMOV             R0, R5                                                 ; +0x14, 0x7d901c\nMOV             R1, #0x20 ; ' '                                        ; +0x18, 0x7d9020\nBL              OPENSSL_cleanse                                        ; +0x1c, 0x7d9024\nADD             R0, R4, #4                                             ; +0x20, 0x7d9028\nMOV             R1, #0x20 ; ' '                                        ; +0x24, 0x7d902c\nBL              OPENSSL_cleanse                                        ; +0x28, 0x7d9030\nADD             R0, R4, #0x24 ; '$'                                    ; +0x2c, 0x7d9034\nMOV             R1, #0x20 ; ' '                                        ; +0x30, 0x7d9038\nBL              OPENSSL_cleanse                                        ; +0x34, 0x7d903c\nADD             R0, R4, #0x64 ; 'd'                                    ; +0x38, 0x7d9040\nMOV             R1, #0x20 ; ' '                                        ; +0x3c, 0x7d9044\nBL              OPENSSL_cleanse                                        ; +0x40, 0x7d9048\nMOV             R3, #0xFFFFFFFF                                        ; +0x44, 0x7d904c\nSTR             R3, [R4,#0x84]                                         ; +0x48, 0x7d9050\nPOP             {R3-R5,PC}                                             ; +0x4c, 0x7d9054", "xrefs": ["CMAC_CTX_free @ 0x7d9070", "<???> @ 0x6003c"], "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"}