{"type": "func", "start": 14723696, "end": 14723828, "name": "ASN1_INTEGER_set_uint64", "pseudocode": "// \n// ASN1_INTEGER_set_uint64 from 0xe0aa70 to 0xe0aaf4 (132 bytes)\n// \n// 4 xrefs:\n// > PKCS5_pbe2_set_scrypt @ 0xe72f64\n// > PKCS5_pbe2_set_scrypt @ 0xe72f74\n// > PKCS5_pbe2_set_scrypt @ 0xe72f84\n// > <???> @ 0x448c8\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 ASN1_INTEGER_set_uint64(__int64 a1, unsigned __int64 a2)\n{\n  __int64 v2; // x2\n  unsigned __int64 v4; // x4\n  __int64 i; // x3\n  char *v6; // x3\n  char v7[8]; // [xsp+18h] [xbp+18h] BYREF\n\n  *(_DWORD *)(a1 + 4) = 2;\n  if ( a2 <= 0xFF )\n  {\n    LODWORD(v2) = 1;\n    v7[0] = a2;\n    return (unsigned int)ASN1_STRING_set(a1, v7, v2);\n  }\n  v4 = a2;\n  for ( i = 0; ; ++i )\n  {\n    v4 >>= 8;\n    v2 = i + 1;\n    if ( !v4 )\n      break;\n  }\n  v6 = &v7[i];\n  do\n  {\n    *v6-- = a2;\n    a2 >>= 8;\n  }\n  while ( v6 >= v7 );\n  if ( v2 )\n    return (unsigned int)ASN1_STRING_set(a1, v7, v2);\n  return 0;\n}", "assembly": "; \n; ASN1_INTEGER_set_uint64 from 0xe0aa70 to 0xe0aaf4 (132 bytes)\n; \n; 4 xrefs:\n; > PKCS5_pbe2_set_scrypt @ 0xe72f64\n; > PKCS5_pbe2_set_scrypt @ 0xe72f74\n; > PKCS5_pbe2_set_scrypt @ 0xe72f84\n; > <???> @ 0x448c8\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_20]!                                ; +0x0, 0xe0aa70\nMOV             W2, #2                                                 ; +0x4, 0xe0aa74\nCMP             X1, #0xFF                                              ; +0x8, 0xe0aa78\nMOV             X29, SP                                                ; +0xc, 0xe0aa7c\nSTR             W2, [X0,#4]                                            ; +0x10, 0xe0aa80\nB.HI            loc_E0AAAC                                             ; +0x14, 0xe0aa84\nADD             X4, X29, #0x20+arg_0                                   ; +0x18, 0xe0aa88\nMOV             W2, #1                                                 ; +0x1c, 0xe0aa8c\nSTRB            W1, [X4,#-8]!                                          ; +0x20, 0xe0aa90\nMOV             X1, X4; char *                                         ; +0x24, 0xe0aa94\nBL              ASN1_STRING_set                                        ; +0x28, 0xe0aa98\nMOV             W1, W0                                                 ; +0x2c, 0xe0aa9c\nMOV             W0, W1                                                 ; +0x30, 0xe0aaa0\nLDP             X29, X30, [SP+0x20+var_20],#0x20                       ; +0x34, 0xe0aaa4\nRET                                                                    ; +0x38, 0xe0aaa8\nMOV             X4, X1                                                 ; +0x3c, 0xe0aaac\nMOV             X3, #0                                                 ; +0x40, 0xe0aab0\nB               loc_E0AABC                                             ; +0x44, 0xe0aab4\nMOV             X3, X2                                                 ; +0x48, 0xe0aab8\nLSR             X4, X4, #8                                             ; +0x4c, 0xe0aabc\nADD             X2, X3, #1                                             ; +0x50, 0xe0aac0\nCBNZ            X4, loc_E0AAB8                                         ; +0x54, 0xe0aac4\nADD             X4, X29, #0x20+var_8                                   ; +0x58, 0xe0aac8\nADD             X3, X4, X3                                             ; +0x5c, 0xe0aacc\nSTRB            W1, [X3],#-1                                           ; +0x60, 0xe0aad0\nLSR             X1, X1, #8                                             ; +0x64, 0xe0aad4\nCMP             X3, X4                                                 ; +0x68, 0xe0aad8\nB.CS            loc_E0AAD0                                             ; +0x6c, 0xe0aadc\nMOV             W1, #0                                                 ; +0x70, 0xe0aae0\nCBNZ            X2, loc_E0AA94                                         ; +0x74, 0xe0aae4\nMOV             W0, W1                                                 ; +0x78, 0xe0aae8\nLDP             X29, X30, [SP+0x20+var_20],#0x20                       ; +0x7c, 0xe0aaec\nRET                                                                    ; +0x80, 0xe0aaf0", "xrefs": ["PKCS5_pbe2_set_scrypt @ 0xe72f64", "PKCS5_pbe2_set_scrypt @ 0xe72f74", "PKCS5_pbe2_set_scrypt @ 0xe72f84", "<???> @ 0x448c8"], "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"}