@sentio/sdk-bundle 2.61.0-rc.2 → 2.61.0-rc.4

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.
Files changed (93) hide show
  1. package/lib/aptos/builtin/0x1.js +5 -7
  2. package/lib/aptos/builtin/0x3.js +6 -8
  3. package/lib/aptos/builtin/0x4.js +6 -8
  4. package/lib/aptos/builtin/index.js +7 -9
  5. package/lib/aptos/builtin/index.js.map +1 -1
  6. package/lib/aptos/ext/index.js +5 -7
  7. package/lib/aptos/ext/index.js.map +1 -1
  8. package/lib/aptos/index.js +5 -7
  9. package/lib/btc/index.js +2 -3
  10. package/lib/btc/index.js.map +1 -1
  11. package/lib/{chunk-OD6FL4VS.js → chunk-3U72IHGI.js} +3 -5
  12. package/lib/{chunk-OD6FL4VS.js.map → chunk-3U72IHGI.js.map} +1 -1
  13. package/lib/{chunk-4BUIMDJ2.js → chunk-63C2SM23.js} +3 -5
  14. package/lib/{chunk-4BUIMDJ2.js.map → chunk-63C2SM23.js.map} +1 -1
  15. package/lib/{chunk-43HP4DQZ.js → chunk-B4NQDXHJ.js} +51 -3
  16. package/lib/chunk-B4NQDXHJ.js.map +1 -0
  17. package/lib/{chunk-SA6EVEF3.js → chunk-FSFHO32Q.js} +8 -12
  18. package/lib/{chunk-SA6EVEF3.js.map → chunk-FSFHO32Q.js.map} +1 -1
  19. package/lib/{chunk-DHPXVIOI.js → chunk-GXWFPPVN.js} +3 -5
  20. package/lib/{chunk-DHPXVIOI.js.map → chunk-GXWFPPVN.js.map} +1 -1
  21. package/lib/{chunk-742S42NO.js → chunk-HFODIGHI.js} +449 -1
  22. package/lib/chunk-HFODIGHI.js.map +1 -0
  23. package/lib/{chunk-63RPKHNV.js → chunk-JM77GOBI.js} +5 -5
  24. package/lib/{chunk-GNJ4FJ6M.js → chunk-NEDO74L4.js} +2 -2
  25. package/lib/{chunk-AIRBHETL.js → chunk-NF66PTSR.js} +4 -4
  26. package/lib/{chunk-Y4VWRXPJ.js → chunk-O2FX3ST4.js} +2 -2
  27. package/lib/{chunk-5LEP7IFP.js → chunk-OUQN675E.js} +16 -16
  28. package/lib/{chunk-2UBTY7RU.js → chunk-P4MCMQEQ.js} +2 -2
  29. package/lib/{chunk-LP3F7TLM.js → chunk-PSLT5TLU.js} +554 -3
  30. package/lib/chunk-PSLT5TLU.js.map +1 -0
  31. package/lib/{chunk-C33DZMWZ.js → chunk-RNKAUU7M.js} +3 -3
  32. package/lib/{chunk-KORR4KWH.js → chunk-RQEJ6VYV.js} +1684 -267
  33. package/lib/chunk-RQEJ6VYV.js.map +1 -0
  34. package/lib/{chunk-DNXKWX3C.js → chunk-TBCNZKOI.js} +15 -15
  35. package/lib/{chunk-23ATGE5K.js → chunk-V7GMUFEU.js} +11 -11
  36. package/lib/{chunk-GQ543QK7.js → chunk-VOZ7XW36.js} +2 -2
  37. package/lib/{chunk-XBLI6KNQ.js → chunk-W5VWFQZQ.js} +18 -18
  38. package/lib/{chunk-6RTCDLBK.js → chunk-XLNIFS5I.js} +2 -2
  39. package/lib/eth/builtin/eacaggregatorproxy.js +2 -3
  40. package/lib/eth/builtin/erc1155.js +3 -4
  41. package/lib/eth/builtin/erc20.js +2 -3
  42. package/lib/eth/builtin/erc721.js +2 -3
  43. package/lib/eth/builtin/index.js +4 -5
  44. package/lib/eth/builtin/index.js.map +1 -1
  45. package/lib/eth/builtin/weth9.js +3 -4
  46. package/lib/eth/index.js +2 -3
  47. package/lib/fuel/index.js +2 -3
  48. package/lib/iota/builtin/0x1.js +11 -6
  49. package/lib/iota/builtin/0x2.js +12 -7
  50. package/lib/iota/builtin/0x3.js +13 -8
  51. package/lib/iota/builtin/index.js +13 -8
  52. package/lib/iota/builtin/index.js.map +1 -1
  53. package/lib/iota/ext/index.js +5 -8
  54. package/lib/iota/ext/index.js.map +1 -1
  55. package/lib/iota/index.js +10 -5
  56. package/lib/stark/index.js +2 -4
  57. package/lib/stark/index.js.map +1 -1
  58. package/lib/sui/builtin/0x1.js +9 -13
  59. package/lib/sui/builtin/0x2.js +10 -14
  60. package/lib/sui/builtin/0x3.js +11 -15
  61. package/lib/sui/builtin/index.js +11 -15
  62. package/lib/sui/builtin/index.js.map +1 -1
  63. package/lib/sui/ext/index.js +5 -7
  64. package/lib/sui/ext/index.js.map +1 -1
  65. package/lib/sui/index.js +10 -14
  66. package/lib/testing/index.js +18 -23
  67. package/lib/testing/index.js.map +1 -1
  68. package/lib/utils/index.js +2 -3
  69. package/package.json +2 -2
  70. package/lib/chunk-43HP4DQZ.js.map +0 -1
  71. package/lib/chunk-742S42NO.js.map +0 -1
  72. package/lib/chunk-KORR4KWH.js.map +0 -1
  73. package/lib/chunk-LP3F7TLM.js.map +0 -1
  74. package/lib/chunk-OZTZ5YWM.js +0 -456
  75. package/lib/chunk-OZTZ5YWM.js.map +0 -1
  76. package/lib/chunk-P7O6NN6M.js +0 -562
  77. package/lib/chunk-P7O6NN6M.js.map +0 -1
  78. package/lib/chunk-XEXUSO2Q.js +0 -1469
  79. package/lib/chunk-XEXUSO2Q.js.map +0 -1
  80. package/lib/chunk-Z2CE3JTO.js +0 -56
  81. package/lib/chunk-Z2CE3JTO.js.map +0 -1
  82. /package/lib/{chunk-63RPKHNV.js.map → chunk-JM77GOBI.js.map} +0 -0
  83. /package/lib/{chunk-GNJ4FJ6M.js.map → chunk-NEDO74L4.js.map} +0 -0
  84. /package/lib/{chunk-AIRBHETL.js.map → chunk-NF66PTSR.js.map} +0 -0
  85. /package/lib/{chunk-Y4VWRXPJ.js.map → chunk-O2FX3ST4.js.map} +0 -0
  86. /package/lib/{chunk-5LEP7IFP.js.map → chunk-OUQN675E.js.map} +0 -0
  87. /package/lib/{chunk-2UBTY7RU.js.map → chunk-P4MCMQEQ.js.map} +0 -0
  88. /package/lib/{chunk-C33DZMWZ.js.map → chunk-RNKAUU7M.js.map} +0 -0
  89. /package/lib/{chunk-DNXKWX3C.js.map → chunk-TBCNZKOI.js.map} +0 -0
  90. /package/lib/{chunk-23ATGE5K.js.map → chunk-V7GMUFEU.js.map} +0 -0
  91. /package/lib/{chunk-GQ543QK7.js.map → chunk-VOZ7XW36.js.map} +0 -0
  92. /package/lib/{chunk-XBLI6KNQ.js.map → chunk-W5VWFQZQ.js.map} +0 -0
  93. /package/lib/{chunk-6RTCDLBK.js.map → chunk-XLNIFS5I.js.map} +0 -0
@@ -1,456 +0,0 @@
1
- import { createRequire as createRequireSdkShim } from 'module'; const require = createRequireSdkShim(import.meta.url);
2
- import {
3
- __name
4
- } from "./chunk-R7PMHHKJ.js";
5
-
6
- // ../../node_modules/.pnpm/@noble+hashes@1.8.0/node_modules/@noble/hashes/esm/cryptoNode.js
7
- import * as nc from "node:crypto";
8
- var crypto = nc && typeof nc === "object" && "webcrypto" in nc ? nc.webcrypto : nc && typeof nc === "object" && "randomBytes" in nc ? nc : void 0;
9
-
10
- // ../../node_modules/.pnpm/@noble+hashes@1.8.0/node_modules/@noble/hashes/esm/utils.js
11
- function isBytes(a) {
12
- return a instanceof Uint8Array || ArrayBuffer.isView(a) && a.constructor.name === "Uint8Array";
13
- }
14
- __name(isBytes, "isBytes");
15
- function anumber(n) {
16
- if (!Number.isSafeInteger(n) || n < 0)
17
- throw new Error("positive integer expected, got " + n);
18
- }
19
- __name(anumber, "anumber");
20
- function abytes(b, ...lengths) {
21
- if (!isBytes(b))
22
- throw new Error("Uint8Array expected");
23
- if (lengths.length > 0 && !lengths.includes(b.length))
24
- throw new Error("Uint8Array expected of length " + lengths + ", got length=" + b.length);
25
- }
26
- __name(abytes, "abytes");
27
- function ahash(h) {
28
- if (typeof h !== "function" || typeof h.create !== "function")
29
- throw new Error("Hash should be wrapped by utils.createHasher");
30
- anumber(h.outputLen);
31
- anumber(h.blockLen);
32
- }
33
- __name(ahash, "ahash");
34
- function aexists(instance, checkFinished = true) {
35
- if (instance.destroyed)
36
- throw new Error("Hash instance has been destroyed");
37
- if (checkFinished && instance.finished)
38
- throw new Error("Hash#digest() has already been called");
39
- }
40
- __name(aexists, "aexists");
41
- function aoutput(out, instance) {
42
- abytes(out);
43
- const min = instance.outputLen;
44
- if (out.length < min) {
45
- throw new Error("digestInto() expects output buffer of length at least " + min);
46
- }
47
- }
48
- __name(aoutput, "aoutput");
49
- function u32(arr) {
50
- return new Uint32Array(arr.buffer, arr.byteOffset, Math.floor(arr.byteLength / 4));
51
- }
52
- __name(u32, "u32");
53
- function clean(...arrays) {
54
- for (let i = 0; i < arrays.length; i++) {
55
- arrays[i].fill(0);
56
- }
57
- }
58
- __name(clean, "clean");
59
- function createView(arr) {
60
- return new DataView(arr.buffer, arr.byteOffset, arr.byteLength);
61
- }
62
- __name(createView, "createView");
63
- function rotr(word, shift) {
64
- return word << 32 - shift | word >>> shift;
65
- }
66
- __name(rotr, "rotr");
67
- function rotl(word, shift) {
68
- return word << shift | word >>> 32 - shift >>> 0;
69
- }
70
- __name(rotl, "rotl");
71
- var isLE = /* @__PURE__ */ (() => new Uint8Array(new Uint32Array([287454020]).buffer)[0] === 68)();
72
- function byteSwap(word) {
73
- return word << 24 & 4278190080 | word << 8 & 16711680 | word >>> 8 & 65280 | word >>> 24 & 255;
74
- }
75
- __name(byteSwap, "byteSwap");
76
- var swap8IfBE = isLE ? (n) => n : (n) => byteSwap(n);
77
- function byteSwap32(arr) {
78
- for (let i = 0; i < arr.length; i++) {
79
- arr[i] = byteSwap(arr[i]);
80
- }
81
- return arr;
82
- }
83
- __name(byteSwap32, "byteSwap32");
84
- var swap32IfBE = isLE ? (u) => u : byteSwap32;
85
- var hasHexBuiltin = /* @__PURE__ */ (() => (
86
- // @ts-ignore
87
- typeof Uint8Array.from([]).toHex === "function" && typeof Uint8Array.fromHex === "function"
88
- ))();
89
- var hexes = /* @__PURE__ */ Array.from({ length: 256 }, (_, i) => i.toString(16).padStart(2, "0"));
90
- function bytesToHex(bytes) {
91
- abytes(bytes);
92
- if (hasHexBuiltin)
93
- return bytes.toHex();
94
- let hex = "";
95
- for (let i = 0; i < bytes.length; i++) {
96
- hex += hexes[bytes[i]];
97
- }
98
- return hex;
99
- }
100
- __name(bytesToHex, "bytesToHex");
101
- var asciis = { _0: 48, _9: 57, A: 65, F: 70, a: 97, f: 102 };
102
- function asciiToBase16(ch) {
103
- if (ch >= asciis._0 && ch <= asciis._9)
104
- return ch - asciis._0;
105
- if (ch >= asciis.A && ch <= asciis.F)
106
- return ch - (asciis.A - 10);
107
- if (ch >= asciis.a && ch <= asciis.f)
108
- return ch - (asciis.a - 10);
109
- return;
110
- }
111
- __name(asciiToBase16, "asciiToBase16");
112
- function hexToBytes(hex) {
113
- if (typeof hex !== "string")
114
- throw new Error("hex string expected, got " + typeof hex);
115
- if (hasHexBuiltin)
116
- return Uint8Array.fromHex(hex);
117
- const hl = hex.length;
118
- const al = hl / 2;
119
- if (hl % 2)
120
- throw new Error("hex string expected, got unpadded hex of length " + hl);
121
- const array = new Uint8Array(al);
122
- for (let ai = 0, hi = 0; ai < al; ai++, hi += 2) {
123
- const n1 = asciiToBase16(hex.charCodeAt(hi));
124
- const n2 = asciiToBase16(hex.charCodeAt(hi + 1));
125
- if (n1 === void 0 || n2 === void 0) {
126
- const char = hex[hi] + hex[hi + 1];
127
- throw new Error('hex string expected, got non-hex character "' + char + '" at index ' + hi);
128
- }
129
- array[ai] = n1 * 16 + n2;
130
- }
131
- return array;
132
- }
133
- __name(hexToBytes, "hexToBytes");
134
- function utf8ToBytes(str) {
135
- if (typeof str !== "string")
136
- throw new Error("string expected");
137
- return new Uint8Array(new TextEncoder().encode(str));
138
- }
139
- __name(utf8ToBytes, "utf8ToBytes");
140
- function toBytes(data) {
141
- if (typeof data === "string")
142
- data = utf8ToBytes(data);
143
- abytes(data);
144
- return data;
145
- }
146
- __name(toBytes, "toBytes");
147
- function kdfInputToBytes(data) {
148
- if (typeof data === "string")
149
- data = utf8ToBytes(data);
150
- abytes(data);
151
- return data;
152
- }
153
- __name(kdfInputToBytes, "kdfInputToBytes");
154
- function concatBytes(...arrays) {
155
- let sum = 0;
156
- for (let i = 0; i < arrays.length; i++) {
157
- const a = arrays[i];
158
- abytes(a);
159
- sum += a.length;
160
- }
161
- const res = new Uint8Array(sum);
162
- for (let i = 0, pad = 0; i < arrays.length; i++) {
163
- const a = arrays[i];
164
- res.set(a, pad);
165
- pad += a.length;
166
- }
167
- return res;
168
- }
169
- __name(concatBytes, "concatBytes");
170
- function checkOpts(defaults, opts) {
171
- if (opts !== void 0 && {}.toString.call(opts) !== "[object Object]")
172
- throw new Error("options should be object or undefined");
173
- const merged = Object.assign(defaults, opts);
174
- return merged;
175
- }
176
- __name(checkOpts, "checkOpts");
177
- var Hash = class {
178
- static {
179
- __name(this, "Hash");
180
- }
181
- };
182
- function createHasher(hashCons) {
183
- const hashC = /* @__PURE__ */ __name((msg) => hashCons().update(toBytes(msg)).digest(), "hashC");
184
- const tmp = hashCons();
185
- hashC.outputLen = tmp.outputLen;
186
- hashC.blockLen = tmp.blockLen;
187
- hashC.create = () => hashCons();
188
- return hashC;
189
- }
190
- __name(createHasher, "createHasher");
191
- function createOptHasher(hashCons) {
192
- const hashC = /* @__PURE__ */ __name((msg, opts) => hashCons(opts).update(toBytes(msg)).digest(), "hashC");
193
- const tmp = hashCons({});
194
- hashC.outputLen = tmp.outputLen;
195
- hashC.blockLen = tmp.blockLen;
196
- hashC.create = (opts) => hashCons(opts);
197
- return hashC;
198
- }
199
- __name(createOptHasher, "createOptHasher");
200
- function randomBytes(bytesLength = 32) {
201
- if (crypto && typeof crypto.getRandomValues === "function") {
202
- return crypto.getRandomValues(new Uint8Array(bytesLength));
203
- }
204
- if (crypto && typeof crypto.randomBytes === "function") {
205
- return Uint8Array.from(crypto.randomBytes(bytesLength));
206
- }
207
- throw new Error("crypto.getRandomValues must be defined");
208
- }
209
- __name(randomBytes, "randomBytes");
210
-
211
- // ../../node_modules/.pnpm/@noble+hashes@1.8.0/node_modules/@noble/hashes/esm/_u64.js
212
- var U32_MASK64 = /* @__PURE__ */ BigInt(2 ** 32 - 1);
213
- var _32n = /* @__PURE__ */ BigInt(32);
214
- function fromBig(n, le = false) {
215
- if (le)
216
- return { h: Number(n & U32_MASK64), l: Number(n >> _32n & U32_MASK64) };
217
- return { h: Number(n >> _32n & U32_MASK64) | 0, l: Number(n & U32_MASK64) | 0 };
218
- }
219
- __name(fromBig, "fromBig");
220
- function split(lst, le = false) {
221
- const len = lst.length;
222
- let Ah = new Uint32Array(len);
223
- let Al = new Uint32Array(len);
224
- for (let i = 0; i < len; i++) {
225
- const { h, l } = fromBig(lst[i], le);
226
- [Ah[i], Al[i]] = [h, l];
227
- }
228
- return [Ah, Al];
229
- }
230
- __name(split, "split");
231
- var shrSH = /* @__PURE__ */ __name((h, _l, s) => h >>> s, "shrSH");
232
- var shrSL = /* @__PURE__ */ __name((h, l, s) => h << 32 - s | l >>> s, "shrSL");
233
- var rotrSH = /* @__PURE__ */ __name((h, l, s) => h >>> s | l << 32 - s, "rotrSH");
234
- var rotrSL = /* @__PURE__ */ __name((h, l, s) => h << 32 - s | l >>> s, "rotrSL");
235
- var rotrBH = /* @__PURE__ */ __name((h, l, s) => h << 64 - s | l >>> s - 32, "rotrBH");
236
- var rotrBL = /* @__PURE__ */ __name((h, l, s) => h >>> s - 32 | l << 64 - s, "rotrBL");
237
- var rotr32H = /* @__PURE__ */ __name((_h, l) => l, "rotr32H");
238
- var rotr32L = /* @__PURE__ */ __name((h, _l) => h, "rotr32L");
239
- var rotlSH = /* @__PURE__ */ __name((h, l, s) => h << s | l >>> 32 - s, "rotlSH");
240
- var rotlSL = /* @__PURE__ */ __name((h, l, s) => l << s | h >>> 32 - s, "rotlSL");
241
- var rotlBH = /* @__PURE__ */ __name((h, l, s) => l << s - 32 | h >>> 64 - s, "rotlBH");
242
- var rotlBL = /* @__PURE__ */ __name((h, l, s) => h << s - 32 | l >>> 64 - s, "rotlBL");
243
- function add(Ah, Al, Bh, Bl) {
244
- const l = (Al >>> 0) + (Bl >>> 0);
245
- return { h: Ah + Bh + (l / 2 ** 32 | 0) | 0, l: l | 0 };
246
- }
247
- __name(add, "add");
248
- var add3L = /* @__PURE__ */ __name((Al, Bl, Cl) => (Al >>> 0) + (Bl >>> 0) + (Cl >>> 0), "add3L");
249
- var add3H = /* @__PURE__ */ __name((low, Ah, Bh, Ch) => Ah + Bh + Ch + (low / 2 ** 32 | 0) | 0, "add3H");
250
- var add4L = /* @__PURE__ */ __name((Al, Bl, Cl, Dl) => (Al >>> 0) + (Bl >>> 0) + (Cl >>> 0) + (Dl >>> 0), "add4L");
251
- var add4H = /* @__PURE__ */ __name((low, Ah, Bh, Ch, Dh) => Ah + Bh + Ch + Dh + (low / 2 ** 32 | 0) | 0, "add4H");
252
- var add5L = /* @__PURE__ */ __name((Al, Bl, Cl, Dl, El) => (Al >>> 0) + (Bl >>> 0) + (Cl >>> 0) + (Dl >>> 0) + (El >>> 0), "add5L");
253
- var add5H = /* @__PURE__ */ __name((low, Ah, Bh, Ch, Dh, Eh) => Ah + Bh + Ch + Dh + Eh + (low / 2 ** 32 | 0) | 0, "add5H");
254
-
255
- // ../../node_modules/.pnpm/@noble+hashes@1.8.0/node_modules/@noble/hashes/esm/_md.js
256
- function setBigUint64(view, byteOffset, value, isLE2) {
257
- if (typeof view.setBigUint64 === "function")
258
- return view.setBigUint64(byteOffset, value, isLE2);
259
- const _32n2 = BigInt(32);
260
- const _u32_max = BigInt(4294967295);
261
- const wh = Number(value >> _32n2 & _u32_max);
262
- const wl = Number(value & _u32_max);
263
- const h = isLE2 ? 4 : 0;
264
- const l = isLE2 ? 0 : 4;
265
- view.setUint32(byteOffset + h, wh, isLE2);
266
- view.setUint32(byteOffset + l, wl, isLE2);
267
- }
268
- __name(setBigUint64, "setBigUint64");
269
- function Chi(a, b, c) {
270
- return a & b ^ ~a & c;
271
- }
272
- __name(Chi, "Chi");
273
- function Maj(a, b, c) {
274
- return a & b ^ a & c ^ b & c;
275
- }
276
- __name(Maj, "Maj");
277
- var HashMD = class extends Hash {
278
- static {
279
- __name(this, "HashMD");
280
- }
281
- constructor(blockLen, outputLen, padOffset, isLE2) {
282
- super();
283
- this.finished = false;
284
- this.length = 0;
285
- this.pos = 0;
286
- this.destroyed = false;
287
- this.blockLen = blockLen;
288
- this.outputLen = outputLen;
289
- this.padOffset = padOffset;
290
- this.isLE = isLE2;
291
- this.buffer = new Uint8Array(blockLen);
292
- this.view = createView(this.buffer);
293
- }
294
- update(data) {
295
- aexists(this);
296
- data = toBytes(data);
297
- abytes(data);
298
- const { view, buffer, blockLen } = this;
299
- const len = data.length;
300
- for (let pos = 0; pos < len; ) {
301
- const take = Math.min(blockLen - this.pos, len - pos);
302
- if (take === blockLen) {
303
- const dataView = createView(data);
304
- for (; blockLen <= len - pos; pos += blockLen)
305
- this.process(dataView, pos);
306
- continue;
307
- }
308
- buffer.set(data.subarray(pos, pos + take), this.pos);
309
- this.pos += take;
310
- pos += take;
311
- if (this.pos === blockLen) {
312
- this.process(view, 0);
313
- this.pos = 0;
314
- }
315
- }
316
- this.length += data.length;
317
- this.roundClean();
318
- return this;
319
- }
320
- digestInto(out) {
321
- aexists(this);
322
- aoutput(out, this);
323
- this.finished = true;
324
- const { buffer, view, blockLen, isLE: isLE2 } = this;
325
- let { pos } = this;
326
- buffer[pos++] = 128;
327
- clean(this.buffer.subarray(pos));
328
- if (this.padOffset > blockLen - pos) {
329
- this.process(view, 0);
330
- pos = 0;
331
- }
332
- for (let i = pos; i < blockLen; i++)
333
- buffer[i] = 0;
334
- setBigUint64(view, blockLen - 8, BigInt(this.length * 8), isLE2);
335
- this.process(view, 0);
336
- const oview = createView(out);
337
- const len = this.outputLen;
338
- if (len % 4)
339
- throw new Error("_sha2: outputLen should be aligned to 32bit");
340
- const outLen = len / 4;
341
- const state = this.get();
342
- if (outLen > state.length)
343
- throw new Error("_sha2: outputLen bigger than state");
344
- for (let i = 0; i < outLen; i++)
345
- oview.setUint32(4 * i, state[i], isLE2);
346
- }
347
- digest() {
348
- const { buffer, outputLen } = this;
349
- this.digestInto(buffer);
350
- const res = buffer.slice(0, outputLen);
351
- this.destroy();
352
- return res;
353
- }
354
- _cloneInto(to) {
355
- to || (to = new this.constructor());
356
- to.set(...this.get());
357
- const { blockLen, buffer, length, finished, destroyed, pos } = this;
358
- to.destroyed = destroyed;
359
- to.finished = finished;
360
- to.length = length;
361
- to.pos = pos;
362
- if (length % blockLen)
363
- to.buffer.set(buffer);
364
- return to;
365
- }
366
- clone() {
367
- return this._cloneInto();
368
- }
369
- };
370
- var SHA256_IV = /* @__PURE__ */ Uint32Array.from([
371
- 1779033703,
372
- 3144134277,
373
- 1013904242,
374
- 2773480762,
375
- 1359893119,
376
- 2600822924,
377
- 528734635,
378
- 1541459225
379
- ]);
380
- var SHA512_IV = /* @__PURE__ */ Uint32Array.from([
381
- 1779033703,
382
- 4089235720,
383
- 3144134277,
384
- 2227873595,
385
- 1013904242,
386
- 4271175723,
387
- 2773480762,
388
- 1595750129,
389
- 1359893119,
390
- 2917565137,
391
- 2600822924,
392
- 725511199,
393
- 528734635,
394
- 4215389547,
395
- 1541459225,
396
- 327033209
397
- ]);
398
-
399
- export {
400
- isBytes,
401
- anumber,
402
- abytes,
403
- ahash,
404
- aexists,
405
- aoutput,
406
- u32,
407
- clean,
408
- createView,
409
- rotr,
410
- rotl,
411
- swap8IfBE,
412
- swap32IfBE,
413
- bytesToHex,
414
- hexToBytes,
415
- utf8ToBytes,
416
- toBytes,
417
- kdfInputToBytes,
418
- concatBytes,
419
- checkOpts,
420
- Hash,
421
- createHasher,
422
- createOptHasher,
423
- randomBytes,
424
- fromBig,
425
- split,
426
- shrSH,
427
- shrSL,
428
- rotrSH,
429
- rotrSL,
430
- rotrBH,
431
- rotrBL,
432
- rotr32H,
433
- rotr32L,
434
- rotlSH,
435
- rotlSL,
436
- rotlBH,
437
- rotlBL,
438
- add,
439
- add3L,
440
- add3H,
441
- add4L,
442
- add4H,
443
- add5L,
444
- add5H,
445
- Chi,
446
- Maj,
447
- HashMD,
448
- SHA256_IV,
449
- SHA512_IV
450
- };
451
- /*! Bundled license information:
452
-
453
- @noble/hashes/esm/utils.js:
454
- (*! noble-hashes - MIT License (c) 2022 Paul Miller (paulmillr.com) *)
455
- */
456
- //# sourceMappingURL=chunk-OZTZ5YWM.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../../node_modules/.pnpm/@noble+hashes@1.8.0/node_modules/@noble/hashes/src/cryptoNode.ts","../../../node_modules/.pnpm/@noble+hashes@1.8.0/node_modules/@noble/hashes/src/utils.ts","../../../node_modules/.pnpm/@noble+hashes@1.8.0/node_modules/@noble/hashes/src/_u64.ts","../../../node_modules/.pnpm/@noble+hashes@1.8.0/node_modules/@noble/hashes/src/_md.ts"],"sourcesContent":["/**\n * Internal webcrypto alias.\n * We prefer WebCrypto aka globalThis.crypto, which exists in node.js 16+.\n * Falls back to Node.js built-in crypto for Node.js <=v14.\n * See utils.ts for details.\n * @module\n */\n// @ts-ignore\nimport * as nc from 'node:crypto';\nexport const crypto: any =\n nc && typeof nc === 'object' && 'webcrypto' in nc\n ? (nc.webcrypto as any)\n : nc && typeof nc === 'object' && 'randomBytes' in nc\n ? nc\n : undefined;\n","/**\n * Utilities for hex, bytes, CSPRNG.\n * @module\n */\n/*! noble-hashes - MIT License (c) 2022 Paul Miller (paulmillr.com) */\n\n// We use WebCrypto aka globalThis.crypto, which exists in browsers and node.js 16+.\n// node.js versions earlier than v19 don't declare it in global scope.\n// For node.js, package.json#exports field mapping rewrites import\n// from `crypto` to `cryptoNode`, which imports native module.\n// Makes the utils un-importable in browsers without a bundler.\n// Once node.js 18 is deprecated (2025-04-30), we can just drop the import.\nimport { crypto } from '@noble/hashes/crypto';\n\n/** Checks if something is Uint8Array. Be careful: nodejs Buffer will return true. */\nexport function isBytes(a: unknown): a is Uint8Array {\n return a instanceof Uint8Array || (ArrayBuffer.isView(a) && a.constructor.name === 'Uint8Array');\n}\n\n/** Asserts something is positive integer. */\nexport function anumber(n: number): void {\n if (!Number.isSafeInteger(n) || n < 0) throw new Error('positive integer expected, got ' + n);\n}\n\n/** Asserts something is Uint8Array. */\nexport function abytes(b: Uint8Array | undefined, ...lengths: number[]): void {\n if (!isBytes(b)) throw new Error('Uint8Array expected');\n if (lengths.length > 0 && !lengths.includes(b.length))\n throw new Error('Uint8Array expected of length ' + lengths + ', got length=' + b.length);\n}\n\n/** Asserts something is hash */\nexport function ahash(h: IHash): void {\n if (typeof h !== 'function' || typeof h.create !== 'function')\n throw new Error('Hash should be wrapped by utils.createHasher');\n anumber(h.outputLen);\n anumber(h.blockLen);\n}\n\n/** Asserts a hash instance has not been destroyed / finished */\nexport function aexists(instance: any, checkFinished = true): void {\n if (instance.destroyed) throw new Error('Hash instance has been destroyed');\n if (checkFinished && instance.finished) throw new Error('Hash#digest() has already been called');\n}\n\n/** Asserts output is properly-sized byte array */\nexport function aoutput(out: any, instance: any): void {\n abytes(out);\n const min = instance.outputLen;\n if (out.length < min) {\n throw new Error('digestInto() expects output buffer of length at least ' + min);\n }\n}\n\n/** Generic type encompassing 8/16/32-byte arrays - but not 64-byte. */\n// prettier-ignore\nexport type TypedArray = Int8Array | Uint8ClampedArray | Uint8Array |\n Uint16Array | Int16Array | Uint32Array | Int32Array;\n\n/** Cast u8 / u16 / u32 to u8. */\nexport function u8(arr: TypedArray): Uint8Array {\n return new Uint8Array(arr.buffer, arr.byteOffset, arr.byteLength);\n}\n\n/** Cast u8 / u16 / u32 to u32. */\nexport function u32(arr: TypedArray): Uint32Array {\n return new Uint32Array(arr.buffer, arr.byteOffset, Math.floor(arr.byteLength / 4));\n}\n\n/** Zeroize a byte array. Warning: JS provides no guarantees. */\nexport function clean(...arrays: TypedArray[]): void {\n for (let i = 0; i < arrays.length; i++) {\n arrays[i].fill(0);\n }\n}\n\n/** Create DataView of an array for easy byte-level manipulation. */\nexport function createView(arr: TypedArray): DataView {\n return new DataView(arr.buffer, arr.byteOffset, arr.byteLength);\n}\n\n/** The rotate right (circular right shift) operation for uint32 */\nexport function rotr(word: number, shift: number): number {\n return (word << (32 - shift)) | (word >>> shift);\n}\n\n/** The rotate left (circular left shift) operation for uint32 */\nexport function rotl(word: number, shift: number): number {\n return (word << shift) | ((word >>> (32 - shift)) >>> 0);\n}\n\n/** Is current platform little-endian? Most are. Big-Endian platform: IBM */\nexport const isLE: boolean = /* @__PURE__ */ (() =>\n new Uint8Array(new Uint32Array([0x11223344]).buffer)[0] === 0x44)();\n\n/** The byte swap operation for uint32 */\nexport function byteSwap(word: number): number {\n return (\n ((word << 24) & 0xff000000) |\n ((word << 8) & 0xff0000) |\n ((word >>> 8) & 0xff00) |\n ((word >>> 24) & 0xff)\n );\n}\n/** Conditionally byte swap if on a big-endian platform */\nexport const swap8IfBE: (n: number) => number = isLE\n ? (n: number) => n\n : (n: number) => byteSwap(n);\n\n/** @deprecated */\nexport const byteSwapIfBE: typeof swap8IfBE = swap8IfBE;\n/** In place byte swap for Uint32Array */\nexport function byteSwap32(arr: Uint32Array): Uint32Array {\n for (let i = 0; i < arr.length; i++) {\n arr[i] = byteSwap(arr[i]);\n }\n return arr;\n}\n\nexport const swap32IfBE: (u: Uint32Array) => Uint32Array = isLE\n ? (u: Uint32Array) => u\n : byteSwap32;\n\n// Built-in hex conversion https://caniuse.com/mdn-javascript_builtins_uint8array_fromhex\nconst hasHexBuiltin: boolean = /* @__PURE__ */ (() =>\n // @ts-ignore\n typeof Uint8Array.from([]).toHex === 'function' && typeof Uint8Array.fromHex === 'function')();\n\n// Array where index 0xf0 (240) is mapped to string 'f0'\nconst hexes = /* @__PURE__ */ Array.from({ length: 256 }, (_, i) =>\n i.toString(16).padStart(2, '0')\n);\n\n/**\n * Convert byte array to hex string. Uses built-in function, when available.\n * @example bytesToHex(Uint8Array.from([0xca, 0xfe, 0x01, 0x23])) // 'cafe0123'\n */\nexport function bytesToHex(bytes: Uint8Array): string {\n abytes(bytes);\n // @ts-ignore\n if (hasHexBuiltin) return bytes.toHex();\n // pre-caching improves the speed 6x\n let hex = '';\n for (let i = 0; i < bytes.length; i++) {\n hex += hexes[bytes[i]];\n }\n return hex;\n}\n\n// We use optimized technique to convert hex string to byte array\nconst asciis = { _0: 48, _9: 57, A: 65, F: 70, a: 97, f: 102 } as const;\nfunction asciiToBase16(ch: number): number | undefined {\n if (ch >= asciis._0 && ch <= asciis._9) return ch - asciis._0; // '2' => 50-48\n if (ch >= asciis.A && ch <= asciis.F) return ch - (asciis.A - 10); // 'B' => 66-(65-10)\n if (ch >= asciis.a && ch <= asciis.f) return ch - (asciis.a - 10); // 'b' => 98-(97-10)\n return;\n}\n\n/**\n * Convert hex string to byte array. Uses built-in function, when available.\n * @example hexToBytes('cafe0123') // Uint8Array.from([0xca, 0xfe, 0x01, 0x23])\n */\nexport function hexToBytes(hex: string): Uint8Array {\n if (typeof hex !== 'string') throw new Error('hex string expected, got ' + typeof hex);\n // @ts-ignore\n if (hasHexBuiltin) return Uint8Array.fromHex(hex);\n const hl = hex.length;\n const al = hl / 2;\n if (hl % 2) throw new Error('hex string expected, got unpadded hex of length ' + hl);\n const array = new Uint8Array(al);\n for (let ai = 0, hi = 0; ai < al; ai++, hi += 2) {\n const n1 = asciiToBase16(hex.charCodeAt(hi));\n const n2 = asciiToBase16(hex.charCodeAt(hi + 1));\n if (n1 === undefined || n2 === undefined) {\n const char = hex[hi] + hex[hi + 1];\n throw new Error('hex string expected, got non-hex character \"' + char + '\" at index ' + hi);\n }\n array[ai] = n1 * 16 + n2; // multiply first octet, e.g. 'a3' => 10*16+3 => 160 + 3 => 163\n }\n return array;\n}\n\n/**\n * There is no setImmediate in browser and setTimeout is slow.\n * Call of async fn will return Promise, which will be fullfiled only on\n * next scheduler queue processing step and this is exactly what we need.\n */\nexport const nextTick = async (): Promise<void> => {};\n\n/** Returns control to thread each 'tick' ms to avoid blocking. */\nexport async function asyncLoop(\n iters: number,\n tick: number,\n cb: (i: number) => void\n): Promise<void> {\n let ts = Date.now();\n for (let i = 0; i < iters; i++) {\n cb(i);\n // Date.now() is not monotonic, so in case if clock goes backwards we return return control too\n const diff = Date.now() - ts;\n if (diff >= 0 && diff < tick) continue;\n await nextTick();\n ts += diff;\n }\n}\n\n// Global symbols, but ts doesn't see them: https://github.com/microsoft/TypeScript/issues/31535\ndeclare const TextEncoder: any;\ndeclare const TextDecoder: any;\n\n/**\n * Converts string to bytes using UTF8 encoding.\n * @example utf8ToBytes('abc') // Uint8Array.from([97, 98, 99])\n */\nexport function utf8ToBytes(str: string): Uint8Array {\n if (typeof str !== 'string') throw new Error('string expected');\n return new Uint8Array(new TextEncoder().encode(str)); // https://bugzil.la/1681809\n}\n\n/**\n * Converts bytes to string using UTF8 encoding.\n * @example bytesToUtf8(Uint8Array.from([97, 98, 99])) // 'abc'\n */\nexport function bytesToUtf8(bytes: Uint8Array): string {\n return new TextDecoder().decode(bytes);\n}\n\n/** Accepted input of hash functions. Strings are converted to byte arrays. */\nexport type Input = string | Uint8Array;\n/**\n * Normalizes (non-hex) string or Uint8Array to Uint8Array.\n * Warning: when Uint8Array is passed, it would NOT get copied.\n * Keep in mind for future mutable operations.\n */\nexport function toBytes(data: Input): Uint8Array {\n if (typeof data === 'string') data = utf8ToBytes(data);\n abytes(data);\n return data;\n}\n\n/** KDFs can accept string or Uint8Array for user convenience. */\nexport type KDFInput = string | Uint8Array;\n/**\n * Helper for KDFs: consumes uint8array or string.\n * When string is passed, does utf8 decoding, using TextDecoder.\n */\nexport function kdfInputToBytes(data: KDFInput): Uint8Array {\n if (typeof data === 'string') data = utf8ToBytes(data);\n abytes(data);\n return data;\n}\n\n/** Copies several Uint8Arrays into one. */\nexport function concatBytes(...arrays: Uint8Array[]): Uint8Array {\n let sum = 0;\n for (let i = 0; i < arrays.length; i++) {\n const a = arrays[i];\n abytes(a);\n sum += a.length;\n }\n const res = new Uint8Array(sum);\n for (let i = 0, pad = 0; i < arrays.length; i++) {\n const a = arrays[i];\n res.set(a, pad);\n pad += a.length;\n }\n return res;\n}\n\ntype EmptyObj = {};\nexport function checkOpts<T1 extends EmptyObj, T2 extends EmptyObj>(\n defaults: T1,\n opts?: T2\n): T1 & T2 {\n if (opts !== undefined && {}.toString.call(opts) !== '[object Object]')\n throw new Error('options should be object or undefined');\n const merged = Object.assign(defaults, opts);\n return merged as T1 & T2;\n}\n\n/** Hash interface. */\nexport type IHash = {\n (data: Uint8Array): Uint8Array;\n blockLen: number;\n outputLen: number;\n create: any;\n};\n\n/** For runtime check if class implements interface */\nexport abstract class Hash<T extends Hash<T>> {\n abstract blockLen: number; // Bytes per block\n abstract outputLen: number; // Bytes in output\n abstract update(buf: Input): this;\n // Writes digest into buf\n abstract digestInto(buf: Uint8Array): void;\n abstract digest(): Uint8Array;\n /**\n * Resets internal state. Makes Hash instance unusable.\n * Reset is impossible for keyed hashes if key is consumed into state. If digest is not consumed\n * by user, they will need to manually call `destroy()` when zeroing is necessary.\n */\n abstract destroy(): void;\n /**\n * Clones hash instance. Unsafe: doesn't check whether `to` is valid. Can be used as `clone()`\n * when no options are passed.\n * Reasons to use `_cloneInto` instead of clone: 1) performance 2) reuse instance => all internal\n * buffers are overwritten => causes buffer overwrite which is used for digest in some cases.\n * There are no guarantees for clean-up because it's impossible in JS.\n */\n abstract _cloneInto(to?: T): T;\n // Safe version that clones internal state\n abstract clone(): T;\n}\n\n/**\n * XOF: streaming API to read digest in chunks.\n * Same as 'squeeze' in keccak/k12 and 'seek' in blake3, but more generic name.\n * When hash used in XOF mode it is up to user to call '.destroy' afterwards, since we cannot\n * destroy state, next call can require more bytes.\n */\nexport type HashXOF<T extends Hash<T>> = Hash<T> & {\n xof(bytes: number): Uint8Array; // Read 'bytes' bytes from digest stream\n xofInto(buf: Uint8Array): Uint8Array; // read buf.length bytes from digest stream into buf\n};\n\n/** Hash function */\nexport type CHash = ReturnType<typeof createHasher>;\n/** Hash function with output */\nexport type CHashO = ReturnType<typeof createOptHasher>;\n/** XOF with output */\nexport type CHashXO = ReturnType<typeof createXOFer>;\n\n/** Wraps hash function, creating an interface on top of it */\nexport function createHasher<T extends Hash<T>>(\n hashCons: () => Hash<T>\n): {\n (msg: Input): Uint8Array;\n outputLen: number;\n blockLen: number;\n create(): Hash<T>;\n} {\n const hashC = (msg: Input): Uint8Array => hashCons().update(toBytes(msg)).digest();\n const tmp = hashCons();\n hashC.outputLen = tmp.outputLen;\n hashC.blockLen = tmp.blockLen;\n hashC.create = () => hashCons();\n return hashC;\n}\n\nexport function createOptHasher<H extends Hash<H>, T extends Object>(\n hashCons: (opts?: T) => Hash<H>\n): {\n (msg: Input, opts?: T): Uint8Array;\n outputLen: number;\n blockLen: number;\n create(opts?: T): Hash<H>;\n} {\n const hashC = (msg: Input, opts?: T): Uint8Array => hashCons(opts).update(toBytes(msg)).digest();\n const tmp = hashCons({} as T);\n hashC.outputLen = tmp.outputLen;\n hashC.blockLen = tmp.blockLen;\n hashC.create = (opts?: T) => hashCons(opts);\n return hashC;\n}\n\nexport function createXOFer<H extends HashXOF<H>, T extends Object>(\n hashCons: (opts?: T) => HashXOF<H>\n): {\n (msg: Input, opts?: T): Uint8Array;\n outputLen: number;\n blockLen: number;\n create(opts?: T): HashXOF<H>;\n} {\n const hashC = (msg: Input, opts?: T): Uint8Array => hashCons(opts).update(toBytes(msg)).digest();\n const tmp = hashCons({} as T);\n hashC.outputLen = tmp.outputLen;\n hashC.blockLen = tmp.blockLen;\n hashC.create = (opts?: T) => hashCons(opts);\n return hashC;\n}\nexport const wrapConstructor: typeof createHasher = createHasher;\nexport const wrapConstructorWithOpts: typeof createOptHasher = createOptHasher;\nexport const wrapXOFConstructorWithOpts: typeof createXOFer = createXOFer;\n\n/** Cryptographically secure PRNG. Uses internal OS-level `crypto.getRandomValues`. */\nexport function randomBytes(bytesLength = 32): Uint8Array {\n if (crypto && typeof crypto.getRandomValues === 'function') {\n return crypto.getRandomValues(new Uint8Array(bytesLength));\n }\n // Legacy Node.js compatibility\n if (crypto && typeof crypto.randomBytes === 'function') {\n return Uint8Array.from(crypto.randomBytes(bytesLength));\n }\n throw new Error('crypto.getRandomValues must be defined');\n}\n","/**\n * Internal helpers for u64. BigUint64Array is too slow as per 2025, so we implement it using Uint32Array.\n * @todo re-check https://issues.chromium.org/issues/42212588\n * @module\n */\nconst U32_MASK64 = /* @__PURE__ */ BigInt(2 ** 32 - 1);\nconst _32n = /* @__PURE__ */ BigInt(32);\n\nfunction fromBig(\n n: bigint,\n le = false\n): {\n h: number;\n l: number;\n} {\n if (le) return { h: Number(n & U32_MASK64), l: Number((n >> _32n) & U32_MASK64) };\n return { h: Number((n >> _32n) & U32_MASK64) | 0, l: Number(n & U32_MASK64) | 0 };\n}\n\nfunction split(lst: bigint[], le = false): Uint32Array[] {\n const len = lst.length;\n let Ah = new Uint32Array(len);\n let Al = new Uint32Array(len);\n for (let i = 0; i < len; i++) {\n const { h, l } = fromBig(lst[i], le);\n [Ah[i], Al[i]] = [h, l];\n }\n return [Ah, Al];\n}\n\nconst toBig = (h: number, l: number): bigint => (BigInt(h >>> 0) << _32n) | BigInt(l >>> 0);\n// for Shift in [0, 32)\nconst shrSH = (h: number, _l: number, s: number): number => h >>> s;\nconst shrSL = (h: number, l: number, s: number): number => (h << (32 - s)) | (l >>> s);\n// Right rotate for Shift in [1, 32)\nconst rotrSH = (h: number, l: number, s: number): number => (h >>> s) | (l << (32 - s));\nconst rotrSL = (h: number, l: number, s: number): number => (h << (32 - s)) | (l >>> s);\n// Right rotate for Shift in (32, 64), NOTE: 32 is special case.\nconst rotrBH = (h: number, l: number, s: number): number => (h << (64 - s)) | (l >>> (s - 32));\nconst rotrBL = (h: number, l: number, s: number): number => (h >>> (s - 32)) | (l << (64 - s));\n// Right rotate for shift===32 (just swaps l&h)\nconst rotr32H = (_h: number, l: number): number => l;\nconst rotr32L = (h: number, _l: number): number => h;\n// Left rotate for Shift in [1, 32)\nconst rotlSH = (h: number, l: number, s: number): number => (h << s) | (l >>> (32 - s));\nconst rotlSL = (h: number, l: number, s: number): number => (l << s) | (h >>> (32 - s));\n// Left rotate for Shift in (32, 64), NOTE: 32 is special case.\nconst rotlBH = (h: number, l: number, s: number): number => (l << (s - 32)) | (h >>> (64 - s));\nconst rotlBL = (h: number, l: number, s: number): number => (h << (s - 32)) | (l >>> (64 - s));\n\n// JS uses 32-bit signed integers for bitwise operations which means we cannot\n// simple take carry out of low bit sum by shift, we need to use division.\nfunction add(\n Ah: number,\n Al: number,\n Bh: number,\n Bl: number\n): {\n h: number;\n l: number;\n} {\n const l = (Al >>> 0) + (Bl >>> 0);\n return { h: (Ah + Bh + ((l / 2 ** 32) | 0)) | 0, l: l | 0 };\n}\n// Addition with more than 2 elements\nconst add3L = (Al: number, Bl: number, Cl: number): number => (Al >>> 0) + (Bl >>> 0) + (Cl >>> 0);\nconst add3H = (low: number, Ah: number, Bh: number, Ch: number): number =>\n (Ah + Bh + Ch + ((low / 2 ** 32) | 0)) | 0;\nconst add4L = (Al: number, Bl: number, Cl: number, Dl: number): number =>\n (Al >>> 0) + (Bl >>> 0) + (Cl >>> 0) + (Dl >>> 0);\nconst add4H = (low: number, Ah: number, Bh: number, Ch: number, Dh: number): number =>\n (Ah + Bh + Ch + Dh + ((low / 2 ** 32) | 0)) | 0;\nconst add5L = (Al: number, Bl: number, Cl: number, Dl: number, El: number): number =>\n (Al >>> 0) + (Bl >>> 0) + (Cl >>> 0) + (Dl >>> 0) + (El >>> 0);\nconst add5H = (low: number, Ah: number, Bh: number, Ch: number, Dh: number, Eh: number): number =>\n (Ah + Bh + Ch + Dh + Eh + ((low / 2 ** 32) | 0)) | 0;\n\n// prettier-ignore\nexport {\n add, add3H, add3L, add4H, add4L, add5H, add5L, fromBig, rotlBH, rotlBL, rotlSH, rotlSL, rotr32H, rotr32L, rotrBH, rotrBL, rotrSH, rotrSL, shrSH, shrSL, split, toBig\n};\n// prettier-ignore\nconst u64: { fromBig: typeof fromBig; split: typeof split; toBig: (h: number, l: number) => bigint; shrSH: (h: number, _l: number, s: number) => number; shrSL: (h: number, l: number, s: number) => number; rotrSH: (h: number, l: number, s: number) => number; rotrSL: (h: number, l: number, s: number) => number; rotrBH: (h: number, l: number, s: number) => number; rotrBL: (h: number, l: number, s: number) => number; rotr32H: (_h: number, l: number) => number; rotr32L: (h: number, _l: number) => number; rotlSH: (h: number, l: number, s: number) => number; rotlSL: (h: number, l: number, s: number) => number; rotlBH: (h: number, l: number, s: number) => number; rotlBL: (h: number, l: number, s: number) => number; add: typeof add; add3L: (Al: number, Bl: number, Cl: number) => number; add3H: (low: number, Ah: number, Bh: number, Ch: number) => number; add4L: (Al: number, Bl: number, Cl: number, Dl: number) => number; add4H: (low: number, Ah: number, Bh: number, Ch: number, Dh: number) => number; add5H: (low: number, Ah: number, Bh: number, Ch: number, Dh: number, Eh: number) => number; add5L: (Al: number, Bl: number, Cl: number, Dl: number, El: number) => number; } = {\n fromBig, split, toBig,\n shrSH, shrSL,\n rotrSH, rotrSL, rotrBH, rotrBL,\n rotr32H, rotr32L,\n rotlSH, rotlSL, rotlBH, rotlBL,\n add, add3L, add3H, add4L, add4H, add5H, add5L,\n};\nexport default u64;\n","/**\n * Internal Merkle-Damgard hash utils.\n * @module\n */\nimport { type Input, Hash, abytes, aexists, aoutput, clean, createView, toBytes } from './utils.ts';\n\n/** Polyfill for Safari 14. https://caniuse.com/mdn-javascript_builtins_dataview_setbiguint64 */\nexport function setBigUint64(\n view: DataView,\n byteOffset: number,\n value: bigint,\n isLE: boolean\n): void {\n if (typeof view.setBigUint64 === 'function') return view.setBigUint64(byteOffset, value, isLE);\n const _32n = BigInt(32);\n const _u32_max = BigInt(0xffffffff);\n const wh = Number((value >> _32n) & _u32_max);\n const wl = Number(value & _u32_max);\n const h = isLE ? 4 : 0;\n const l = isLE ? 0 : 4;\n view.setUint32(byteOffset + h, wh, isLE);\n view.setUint32(byteOffset + l, wl, isLE);\n}\n\n/** Choice: a ? b : c */\nexport function Chi(a: number, b: number, c: number): number {\n return (a & b) ^ (~a & c);\n}\n\n/** Majority function, true if any two inputs is true. */\nexport function Maj(a: number, b: number, c: number): number {\n return (a & b) ^ (a & c) ^ (b & c);\n}\n\n/**\n * Merkle-Damgard hash construction base class.\n * Could be used to create MD5, RIPEMD, SHA1, SHA2.\n */\nexport abstract class HashMD<T extends HashMD<T>> extends Hash<T> {\n protected abstract process(buf: DataView, offset: number): void;\n protected abstract get(): number[];\n protected abstract set(...args: number[]): void;\n abstract destroy(): void;\n protected abstract roundClean(): void;\n\n readonly blockLen: number;\n readonly outputLen: number;\n readonly padOffset: number;\n readonly isLE: boolean;\n\n // For partial updates less than block size\n protected buffer: Uint8Array;\n protected view: DataView;\n protected finished = false;\n protected length = 0;\n protected pos = 0;\n protected destroyed = false;\n\n constructor(blockLen: number, outputLen: number, padOffset: number, isLE: boolean) {\n super();\n this.blockLen = blockLen;\n this.outputLen = outputLen;\n this.padOffset = padOffset;\n this.isLE = isLE;\n this.buffer = new Uint8Array(blockLen);\n this.view = createView(this.buffer);\n }\n update(data: Input): this {\n aexists(this);\n data = toBytes(data);\n abytes(data);\n const { view, buffer, blockLen } = this;\n const len = data.length;\n for (let pos = 0; pos < len; ) {\n const take = Math.min(blockLen - this.pos, len - pos);\n // Fast path: we have at least one block in input, cast it to view and process\n if (take === blockLen) {\n const dataView = createView(data);\n for (; blockLen <= len - pos; pos += blockLen) this.process(dataView, pos);\n continue;\n }\n buffer.set(data.subarray(pos, pos + take), this.pos);\n this.pos += take;\n pos += take;\n if (this.pos === blockLen) {\n this.process(view, 0);\n this.pos = 0;\n }\n }\n this.length += data.length;\n this.roundClean();\n return this;\n }\n digestInto(out: Uint8Array): void {\n aexists(this);\n aoutput(out, this);\n this.finished = true;\n // Padding\n // We can avoid allocation of buffer for padding completely if it\n // was previously not allocated here. But it won't change performance.\n const { buffer, view, blockLen, isLE } = this;\n let { pos } = this;\n // append the bit '1' to the message\n buffer[pos++] = 0b10000000;\n clean(this.buffer.subarray(pos));\n // we have less than padOffset left in buffer, so we cannot put length in\n // current block, need process it and pad again\n if (this.padOffset > blockLen - pos) {\n this.process(view, 0);\n pos = 0;\n }\n // Pad until full block byte with zeros\n for (let i = pos; i < blockLen; i++) buffer[i] = 0;\n // Note: sha512 requires length to be 128bit integer, but length in JS will overflow before that\n // You need to write around 2 exabytes (u64_max / 8 / (1024**6)) for this to happen.\n // So we just write lowest 64 bits of that value.\n setBigUint64(view, blockLen - 8, BigInt(this.length * 8), isLE);\n this.process(view, 0);\n const oview = createView(out);\n const len = this.outputLen;\n // NOTE: we do division by 4 later, which should be fused in single op with modulo by JIT\n if (len % 4) throw new Error('_sha2: outputLen should be aligned to 32bit');\n const outLen = len / 4;\n const state = this.get();\n if (outLen > state.length) throw new Error('_sha2: outputLen bigger than state');\n for (let i = 0; i < outLen; i++) oview.setUint32(4 * i, state[i], isLE);\n }\n digest(): Uint8Array {\n const { buffer, outputLen } = this;\n this.digestInto(buffer);\n const res = buffer.slice(0, outputLen);\n this.destroy();\n return res;\n }\n _cloneInto(to?: T): T {\n to ||= new (this.constructor as any)() as T;\n to.set(...this.get());\n const { blockLen, buffer, length, finished, destroyed, pos } = this;\n to.destroyed = destroyed;\n to.finished = finished;\n to.length = length;\n to.pos = pos;\n if (length % blockLen) to.buffer.set(buffer);\n return to;\n }\n clone(): T {\n return this._cloneInto();\n }\n}\n\n/**\n * Initial SHA-2 state: fractional parts of square roots of first 16 primes 2..53.\n * Check out `test/misc/sha2-gen-iv.js` for recomputation guide.\n */\n\n/** Initial SHA256 state. Bits 0..32 of frac part of sqrt of primes 2..19 */\nexport const SHA256_IV: Uint32Array = /* @__PURE__ */ Uint32Array.from([\n 0x6a09e667, 0xbb67ae85, 0x3c6ef372, 0xa54ff53a, 0x510e527f, 0x9b05688c, 0x1f83d9ab, 0x5be0cd19,\n]);\n\n/** Initial SHA224 state. Bits 32..64 of frac part of sqrt of primes 23..53 */\nexport const SHA224_IV: Uint32Array = /* @__PURE__ */ Uint32Array.from([\n 0xc1059ed8, 0x367cd507, 0x3070dd17, 0xf70e5939, 0xffc00b31, 0x68581511, 0x64f98fa7, 0xbefa4fa4,\n]);\n\n/** Initial SHA384 state. Bits 0..64 of frac part of sqrt of primes 23..53 */\nexport const SHA384_IV: Uint32Array = /* @__PURE__ */ Uint32Array.from([\n 0xcbbb9d5d, 0xc1059ed8, 0x629a292a, 0x367cd507, 0x9159015a, 0x3070dd17, 0x152fecd8, 0xf70e5939,\n 0x67332667, 0xffc00b31, 0x8eb44a87, 0x68581511, 0xdb0c2e0d, 0x64f98fa7, 0x47b5481d, 0xbefa4fa4,\n]);\n\n/** Initial SHA512 state. Bits 0..64 of frac part of sqrt of primes 2..19 */\nexport const SHA512_IV: Uint32Array = /* @__PURE__ */ Uint32Array.from([\n 0x6a09e667, 0xf3bcc908, 0xbb67ae85, 0x84caa73b, 0x3c6ef372, 0xfe94f82b, 0xa54ff53a, 0x5f1d36f1,\n 0x510e527f, 0xade682d1, 0x9b05688c, 0x2b3e6c1f, 0x1f83d9ab, 0xfb41bd6b, 0x5be0cd19, 0x137e2179,\n]);\n"],"mappings":";;;;;;AAQA,YAAY,QAAQ;AACb,IAAM,SACX,MAAM,OAAO,OAAO,YAAY,eAAe,KACvC,eACJ,MAAM,OAAO,OAAO,YAAY,iBAAiB,KAC/C,KACA;;;ACCF,SAAU,QAAQ,GAAU;AAChC,SAAO,aAAa,cAAe,YAAY,OAAO,CAAC,KAAK,EAAE,YAAY,SAAS;AACrF;AAFgB;AAKV,SAAU,QAAQ,GAAS;AAC/B,MAAI,CAAC,OAAO,cAAc,CAAC,KAAK,IAAI;AAAG,UAAM,IAAI,MAAM,oCAAoC,CAAC;AAC9F;AAFgB;AAKV,SAAU,OAAO,MAA8B,SAAiB;AACpE,MAAI,CAAC,QAAQ,CAAC;AAAG,UAAM,IAAI,MAAM,qBAAqB;AACtD,MAAI,QAAQ,SAAS,KAAK,CAAC,QAAQ,SAAS,EAAE,MAAM;AAClD,UAAM,IAAI,MAAM,mCAAmC,UAAU,kBAAkB,EAAE,MAAM;AAC3F;AAJgB;AAOV,SAAU,MAAM,GAAQ;AAC5B,MAAI,OAAO,MAAM,cAAc,OAAO,EAAE,WAAW;AACjD,UAAM,IAAI,MAAM,8CAA8C;AACh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