@elizaos/core 1.5.12-alpha.1 → 1.5.12-alpha.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -10054,12 +10054,13 @@ var require_algorithms = __commonJS((exports, module) => {
10054
10054
 
10055
10055
  // ../../node_modules/pbkdf2/lib/precondition.js
10056
10056
  var require_precondition = __commonJS((exports, module) => {
10057
+ var $isFinite = isFinite;
10057
10058
  var MAX_ALLOC = Math.pow(2, 30) - 1;
10058
10059
  module.exports = function(iterations, keylen) {
10059
10060
  if (typeof iterations !== "number") {
10060
10061
  throw new TypeError("Iterations not a number");
10061
10062
  }
10062
- if (iterations < 0) {
10063
+ if (iterations < 0 || !$isFinite(iterations)) {
10063
10064
  throw new TypeError("Bad iterations");
10064
10065
  }
10065
10066
  if (typeof keylen !== "number") {
@@ -11317,7 +11318,10 @@ var require_to_buffer = __commonJS((exports, module) => {
11317
11318
  var useArrayBuffer = typeof ArrayBuffer !== "undefined" && typeof Uint8Array !== "undefined";
11318
11319
  var useFromArrayBuffer = useArrayBuffer && (Buffer2.prototype instanceof Uint8Array || Buffer2.TYPED_ARRAY_SUPPORT);
11319
11320
  module.exports = function toBuffer(data2, encoding) {
11320
- if (data2 instanceof Buffer2) {
11321
+ if (Buffer2.isBuffer(data2)) {
11322
+ if (data2.constructor && !("isBuffer" in data2)) {
11323
+ return Buffer2.from(data2);
11324
+ }
11321
11325
  return data2;
11322
11326
  }
11323
11327
  if (typeof data2 === "string") {
@@ -11521,6 +11525,12 @@ var require_async = __commonJS((exports, module) => {
11521
11525
  callback = digest;
11522
11526
  digest = undefined;
11523
11527
  }
11528
+ checkParameters(iterations, keylen);
11529
+ password = toBuffer(password, defaultEncoding, "Password");
11530
+ salt = toBuffer(salt, defaultEncoding, "Salt");
11531
+ if (typeof callback !== "function") {
11532
+ throw new Error("No callback provided to pbkdf2");
11533
+ }
11524
11534
  digest = digest || "sha1";
11525
11535
  var algo = toBrowser[digest.toLowerCase()];
11526
11536
  if (!algo || typeof global.Promise !== "function") {
@@ -11536,12 +11546,6 @@ var require_async = __commonJS((exports, module) => {
11536
11546
  });
11537
11547
  return;
11538
11548
  }
11539
- checkParameters(iterations, keylen);
11540
- password = toBuffer(password, defaultEncoding, "Password");
11541
- salt = toBuffer(salt, defaultEncoding, "Salt");
11542
- if (typeof callback !== "function") {
11543
- throw new Error("No callback provided to pbkdf2");
11544
- }
11545
11549
  resolvePromise(checkNative(algo).then(function(resp) {
11546
11550
  if (resp) {
11547
11551
  return browserPbkdf2(password, salt, iterations, keylen, algo);
@@ -21391,7 +21395,7 @@ var require_parse_asn1 = __commonJS((exports, module) => {
21391
21395
  var aesid = require_aesid();
21392
21396
  var fixProc = require_fixProc();
21393
21397
  var ciphers = require_browserify_aes();
21394
- var compat = require_pbkdf2();
21398
+ var pbkdf2Sync = require_pbkdf2().pbkdf2Sync;
21395
21399
  var Buffer2 = require_safe_buffer().Buffer;
21396
21400
  function decrypt(data2, password) {
21397
21401
  var salt = data2.algorithm.decrypt.kde.kdeparams.salt;
@@ -21400,7 +21404,7 @@ var require_parse_asn1 = __commonJS((exports, module) => {
21400
21404
  var iv = data2.algorithm.decrypt.cipher.iv;
21401
21405
  var cipherText = data2.subjectPrivateKey;
21402
21406
  var keylen = parseInt(algo.split("-")[1], 10) / 8;
21403
- var key = compat.pbkdf2Sync(password, salt, iters, keylen, "sha1");
21407
+ var key = pbkdf2Sync(password, salt, iters, keylen, "sha1");
21404
21408
  var cipher = ciphers.createDecipheriv(algo, key, iv);
21405
21409
  var out = [];
21406
21410
  out.push(cipher.update(cipherText));
@@ -46384,5 +46388,5 @@ export {
46384
46388
  AgentRuntime
46385
46389
  };
46386
46390
 
46387
- //# debugId=5FF25988965CAF1064756E2164756E21
46391
+ //# debugId=4FA07E08EA54221C64756E2164756E21
46388
46392
  //# sourceMappingURL=index.node.js.map