{"type": "func", "start": 14805824, "end": 14805980, "name": "CMS_stream", "pseudocode": "// \n// CMS_stream from 0xe1eb40 to 0xe1ebdc (156 bytes)\n// \n// 2 xrefs:\n// > sub_E1D530 @ 0xe1d584\n// > <???> @ 0x5be78\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 CMS_stream(_QWORD *a1, __int64 a2)\n{\n  __int64 *result; // x0\n  __int64 *v4; // x19\n  __int64 v5; // x20\n  __int64 v6; // x0\n\n  result = (__int64 *)CMS_get0_content(a2);\n  v4 = result;\n  if ( result )\n  {\n    v5 = *result;\n    if ( *result || (v6 = ASN1_OCTET_STRING_new(), *v4 = v6, (v5 = v6) != 0) )\n    {\n      *(_QWORD *)(v5 + 16) = *(_QWORD *)(v5 + 16) & 0xFFFFFFFFFFFFFFCFLL | 0x10;\n      *a1 = v5 + 8;\n      return (_QWORD *)(dword_0 + 1);\n    }\n    else\n    {\n      ERR_put_error(46, 155, 65, (__int64)\"crypto/cms/cms_io.c\", 31);\n      return nullptr;\n    }\n  }\n  return result;\n}", "assembly": "; \n; CMS_stream from 0xe1eb40 to 0xe1ebdc (156 bytes)\n; \n; 2 xrefs:\n; > sub_E1D530 @ 0xe1d584\n; > <???> @ 0x5be78\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, 0xe1eb40\nMOV             X29, SP                                                ; +0x4, 0xe1eb44\nSTR             X21, [SP,#0x30+var_10]                                 ; +0x8, 0xe1eb48\nMOV             X21, X0                                                ; +0xc, 0xe1eb4c\nMOV             X0, X1                                                 ; +0x10, 0xe1eb50\nSTP             X19, X20, [SP,#0x30+var_20]                            ; +0x14, 0xe1eb54\nBL              CMS_get0_content                                       ; +0x18, 0xe1eb58\nMOV             X19, X0                                                ; +0x1c, 0xe1eb5c\nCBZ             X0, loc_E1EB98                                         ; +0x20, 0xe1eb60\nLDR             X20, [X0]                                              ; +0x24, 0xe1eb64\nCBZ             X20, loc_E1EBA8                                        ; +0x28, 0xe1eb68\nLDR             X1, [X20,#0x10]                                        ; +0x2c, 0xe1eb6c\nADD             X2, X20, #8                                            ; +0x30, 0xe1eb70\nMOV             W0, #1                                                 ; +0x34, 0xe1eb74\nAND             X1, X1, #0xFFFFFFFFFFFFFFDF                            ; +0x38, 0xe1eb78\nORR             X1, X1, #0x10                                          ; +0x3c, 0xe1eb7c\nSTR             X1, [X20,#0x10]                                        ; +0x40, 0xe1eb80\nSTR             X2, [X21]                                              ; +0x44, 0xe1eb84\nLDP             X19, X20, [SP,#0x30+var_20]                            ; +0x48, 0xe1eb88\nLDR             X21, [SP,#0x30+var_10]                                 ; +0x4c, 0xe1eb8c\nLDP             X29, X30, [SP+0x30+var_30],#0x30                       ; +0x50, 0xe1eb90\nRET                                                                    ; +0x54, 0xe1eb94\nLDP             X19, X20, [SP,#0x30+var_20]                            ; +0x58, 0xe1eb98\nLDR             X21, [SP,#0x30+var_10]                                 ; +0x5c, 0xe1eb9c\nLDP             X29, X30, [SP+0x30+var_30],#0x30                       ; +0x60, 0xe1eba0\nRET                                                                    ; +0x64, 0xe1eba4\nBL              ASN1_OCTET_STRING_new                                  ; +0x68, 0xe1eba8\nSTR             X0, [X19]                                              ; +0x6c, 0xe1ebac\nMOV             X20, X0                                                ; +0x70, 0xe1ebb0\nCBNZ            X0, loc_E1EB6C                                         ; +0x74, 0xe1ebb4\nADRP            X3, #aCryptoCmsCmsIo@PAGE; \"crypto/cms/cms_io.c\"       ; +0x78, 0xe1ebb8\nMOV             W0, #0x2E ; '.'                                        ; +0x7c, 0xe1ebbc\nMOV             W1, #0x9B                                              ; +0x80, 0xe1ebc0\nMOV             W2, #0x41 ; 'A'                                        ; +0x84, 0xe1ebc4\nADD             X3, X3, #aCryptoCmsCmsIo@PAGEOFF; \"crypto/cms/cms_io.c\" ; +0x88, 0xe1ebc8\nMOV             W4, #0x1F                                              ; +0x8c, 0xe1ebcc\nBL              ERR_put_error                                          ; +0x90, 0xe1ebd0\nMOV             W0, W20                                                ; +0x94, 0xe1ebd4\nB               loc_E1EB88                                             ; +0x98, 0xe1ebd8", "xrefs": ["sub_E1D530 @ 0xe1d584", "<???> @ 0x5be78"], "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"}