@larkup/cli 0.2.24 → 0.2.26
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.
- package/README.md +8 -0
- package/dist/{analytics-store-KI3NXDYV.js → analytics-store-4NYU7DMO.js} +2 -2
- package/dist/api-X4PHQJTH.js +6943 -0
- package/dist/bowser-GZLEN3PD.js +2821 -0
- package/dist/{chroma-BCASZNMJ.js → chroma-RJVBZZMP.js} +2 -11
- package/dist/chunk-3EBUYTA7.js +136 -0
- package/dist/chunk-4XN2IRCG.js +46 -0
- package/dist/{chunk-FM6HYXZ5.js → chunk-5UWKP64Q.js} +24 -72
- package/dist/chunk-65EVYGDT.js +2904 -0
- package/dist/chunk-A7HMSODH.js +126 -0
- package/dist/chunk-BDMLJQRN.js +534 -0
- package/dist/chunk-FUTLPXFR.js +921 -0
- package/dist/chunk-HAABLEPO.js +1570 -0
- package/dist/chunk-HOPZALAP.js +449 -0
- package/dist/{chunk-L34L3RDQ.js → chunk-JZ3UCEGF.js} +157 -197
- package/dist/chunk-MACWQEJS.js +2091 -0
- package/dist/chunk-MYOADNR2.js +515 -0
- package/dist/chunk-N6IF5QLH.js +1850 -0
- package/dist/chunk-ODWAFTDP.js +1711 -0
- package/dist/chunk-QGM4M3NI.js +37 -0
- package/dist/chunk-S5DCG3CZ.js +41 -0
- package/dist/{chunk-I6JJWCUQ.js → chunk-V3VNCOZ6.js} +118 -29
- package/dist/dist-es-5DTOPEBY.js +322 -0
- package/dist/dist-es-BM4STLL5.js +70 -0
- package/dist/dist-es-DS5SFRTK.js +377 -0
- package/dist/dist-es-F6WXDZQY.js +88 -0
- package/dist/dist-es-KMHWFNXI.js +295 -0
- package/dist/dist-es-LRDDK5LI.js +11761 -0
- package/dist/dist-es-LWW2DNRF.js +139 -0
- package/dist/dist-es-NEADJWQM.js +176 -0
- package/dist/dist-es-S5FAFKBD.js +23 -0
- package/dist/dist-es-YD724GH3.js +221 -0
- package/dist/event-streams-NPIZBVLJ.js +43 -0
- package/dist/index.js +2163 -1798
- package/dist/{lancedb-UB2EPDCN.js → lancedb-TCUZKSHN.js} +1 -1
- package/dist/lexer-DQCqS3nf-CGRGK47I.js +62 -0
- package/dist/loadSso-HXXA5UNF.js +584 -0
- package/dist/{pinecone-OHOY4YYM.js → pinecone-ME3YOCQJ.js} +3 -21
- package/dist/signin-7FUGJFG3.js +822 -0
- package/dist/sso-oidc-EPMF7LMF.js +838 -0
- package/dist/sts-RBEOIBEJ.js +1118 -0
- package/dist/{tool-loader-KKODIWEV.js → tool-loader-PEQZZWTB.js} +3 -3
- package/dist/{tool-registry-CXCFMOWA.js → tool-registry-VJYLRXKJ.js} +2 -2
- package/package.json +20 -16
- package/dist/chunk-3RG5ZIWI.js +0 -10
|
@@ -0,0 +1,515 @@
|
|
|
1
|
+
import {
|
|
2
|
+
toUint8Array
|
|
3
|
+
} from "./chunk-MACWQEJS.js";
|
|
4
|
+
|
|
5
|
+
// ../../node_modules/.pnpm/@smithy+core@3.33.3/node_modules/@smithy/core/dist-es/submodules/checksum/crc32/Crc32Node.js
|
|
6
|
+
import * as zlib from "zlib";
|
|
7
|
+
|
|
8
|
+
// ../../node_modules/.pnpm/@smithy+core@3.33.3/node_modules/@smithy/core/dist-es/submodules/checksum/crc32/Crc32Js.js
|
|
9
|
+
var CRC32_TABLE = new Uint32Array(256);
|
|
10
|
+
for (let i = 0; i < 256; ++i) {
|
|
11
|
+
let c = i;
|
|
12
|
+
for (let j = 0; j < 8; ++j) {
|
|
13
|
+
c = c & 1 ? 3988292384 ^ c >>> 1 : c >>> 1;
|
|
14
|
+
}
|
|
15
|
+
CRC32_TABLE[i] = c >>> 0;
|
|
16
|
+
}
|
|
17
|
+
var ONES = 4294967295;
|
|
18
|
+
var Crc32Js = class {
|
|
19
|
+
digestLength = 4;
|
|
20
|
+
checksum = ONES;
|
|
21
|
+
update(data) {
|
|
22
|
+
for (let i = 0; i < data.length; ++i) {
|
|
23
|
+
this.checksum = this.checksum >>> 8 ^ CRC32_TABLE[(this.checksum ^ data[i]) & 255];
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
digestSync() {
|
|
27
|
+
return (this.checksum ^ ONES) >>> 0;
|
|
28
|
+
}
|
|
29
|
+
async digest() {
|
|
30
|
+
const value = this.digestSync();
|
|
31
|
+
const out = new Uint8Array(4);
|
|
32
|
+
new DataView(out.buffer).setUint32(0, value, false);
|
|
33
|
+
return out;
|
|
34
|
+
}
|
|
35
|
+
reset() {
|
|
36
|
+
this.checksum = ONES;
|
|
37
|
+
}
|
|
38
|
+
};
|
|
39
|
+
|
|
40
|
+
// ../../node_modules/.pnpm/@smithy+core@3.33.3/node_modules/@smithy/core/dist-es/submodules/checksum/crc32/Crc32Node.js
|
|
41
|
+
var zlibCrc32 = typeof zlib.crc32 === "function" ? zlib.crc32 : void 0;
|
|
42
|
+
var Crc32Node = zlibCrc32 ? buildNativeClass(zlibCrc32) : Crc32Js;
|
|
43
|
+
function buildNativeClass(nativeCrc32) {
|
|
44
|
+
return class Crc32Node {
|
|
45
|
+
digestLength = 4;
|
|
46
|
+
value = 0;
|
|
47
|
+
update(data) {
|
|
48
|
+
this.value = nativeCrc32(data, this.value);
|
|
49
|
+
}
|
|
50
|
+
digestSync() {
|
|
51
|
+
return this.value >>> 0;
|
|
52
|
+
}
|
|
53
|
+
async digest() {
|
|
54
|
+
const out = new Uint8Array(4);
|
|
55
|
+
new DataView(out.buffer).setUint32(0, this.digestSync(), false);
|
|
56
|
+
return out;
|
|
57
|
+
}
|
|
58
|
+
reset() {
|
|
59
|
+
this.value = 0;
|
|
60
|
+
}
|
|
61
|
+
};
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
// ../../node_modules/.pnpm/@smithy+core@3.33.3/node_modules/@smithy/core/dist-es/submodules/checksum/hash-stream-node/HashCalculator.js
|
|
65
|
+
import { Writable } from "stream";
|
|
66
|
+
var HashCalculator = class extends Writable {
|
|
67
|
+
hash;
|
|
68
|
+
constructor(hash, options) {
|
|
69
|
+
super(options);
|
|
70
|
+
this.hash = hash;
|
|
71
|
+
}
|
|
72
|
+
_write(chunk, encoding, callback) {
|
|
73
|
+
try {
|
|
74
|
+
this.hash.update(toUint8Array(chunk));
|
|
75
|
+
} catch (err) {
|
|
76
|
+
return callback(err);
|
|
77
|
+
}
|
|
78
|
+
callback();
|
|
79
|
+
}
|
|
80
|
+
};
|
|
81
|
+
|
|
82
|
+
// ../../node_modules/.pnpm/@smithy+core@3.33.3/node_modules/@smithy/core/dist-es/submodules/checksum/hash-stream-node/readableStreamHasher.js
|
|
83
|
+
var readableStreamHasher = (hashCtor, readableStream) => {
|
|
84
|
+
if (readableStream.readableFlowing !== null) {
|
|
85
|
+
throw new Error("Unable to calculate hash for flowing readable stream");
|
|
86
|
+
}
|
|
87
|
+
const hash = new hashCtor();
|
|
88
|
+
const hashCalculator = new HashCalculator(hash);
|
|
89
|
+
readableStream.pipe(hashCalculator);
|
|
90
|
+
return new Promise((resolve, reject) => {
|
|
91
|
+
readableStream.on("error", (err) => {
|
|
92
|
+
hashCalculator.end();
|
|
93
|
+
reject(err);
|
|
94
|
+
});
|
|
95
|
+
hashCalculator.on("error", reject);
|
|
96
|
+
hashCalculator.on("finish", () => {
|
|
97
|
+
hash.digest().then(resolve).catch(reject);
|
|
98
|
+
});
|
|
99
|
+
});
|
|
100
|
+
};
|
|
101
|
+
|
|
102
|
+
// ../../node_modules/.pnpm/@smithy+core@3.33.3/node_modules/@smithy/core/dist-es/submodules/checksum/md5/Md5Js.js
|
|
103
|
+
var Md5Js = class {
|
|
104
|
+
digestLength = 16;
|
|
105
|
+
state = Uint32Array.from(INIT);
|
|
106
|
+
writeBuffer = new DataView(new ArrayBuffer(64));
|
|
107
|
+
bufferLength = 0;
|
|
108
|
+
bytesHashed = 0;
|
|
109
|
+
update(sourceData) {
|
|
110
|
+
const data = toUint8Array(sourceData);
|
|
111
|
+
let pos = 0;
|
|
112
|
+
let len = data.byteLength;
|
|
113
|
+
this.bytesHashed += len;
|
|
114
|
+
while (len > 0) {
|
|
115
|
+
this.writeBuffer.setUint8(this.bufferLength++, data[pos++]);
|
|
116
|
+
--len;
|
|
117
|
+
if (this.bufferLength === 64) {
|
|
118
|
+
compress(this.state, this.writeBuffer);
|
|
119
|
+
this.bufferLength = 0;
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
async digest() {
|
|
124
|
+
const state = Uint32Array.from(this.state);
|
|
125
|
+
const buf = new DataView(this.writeBuffer.buffer.slice(0));
|
|
126
|
+
let bufLen = this.bufferLength;
|
|
127
|
+
const bits = this.bytesHashed * 8;
|
|
128
|
+
buf.setUint8(bufLen++, 128);
|
|
129
|
+
if (this.bufferLength % 64 >= 56) {
|
|
130
|
+
for (let i = bufLen; i < 64; ++i) {
|
|
131
|
+
buf.setUint8(i, 0);
|
|
132
|
+
}
|
|
133
|
+
compress(state, buf);
|
|
134
|
+
bufLen = 0;
|
|
135
|
+
}
|
|
136
|
+
for (let i = bufLen; i < 56; ++i) {
|
|
137
|
+
buf.setUint8(i, 0);
|
|
138
|
+
}
|
|
139
|
+
buf.setUint32(56, bits >>> 0, true);
|
|
140
|
+
buf.setUint32(60, Math.floor(bits / 2 ** 32), true);
|
|
141
|
+
compress(state, buf);
|
|
142
|
+
const out = new Uint8Array(16);
|
|
143
|
+
const view = new DataView(out.buffer);
|
|
144
|
+
for (let i = 0; i < 4; ++i) {
|
|
145
|
+
view.setUint32(i * 4, state[i], true);
|
|
146
|
+
}
|
|
147
|
+
return out;
|
|
148
|
+
}
|
|
149
|
+
reset() {
|
|
150
|
+
this.state.set(INIT);
|
|
151
|
+
this.writeBuffer = new DataView(new ArrayBuffer(64));
|
|
152
|
+
this.bufferLength = 0;
|
|
153
|
+
this.bytesHashed = 0;
|
|
154
|
+
}
|
|
155
|
+
};
|
|
156
|
+
var INIT = [1732584193, 4023233417, 2562383102, 271733878];
|
|
157
|
+
var M = 4294967295;
|
|
158
|
+
var S = Uint8Array.of(7, 12, 17, 22, 5, 9, 14, 20, 4, 11, 16, 23, 6, 10, 15, 21);
|
|
159
|
+
var T = Array.from({ length: 64 }, (_, i) => Math.abs(Math.sin(i + 1)) * 2 ** 32 >>> 0);
|
|
160
|
+
function compress(state, block) {
|
|
161
|
+
let a = state[0], b = state[1], c = state[2], d = state[3];
|
|
162
|
+
for (let i = 0; i < 64; ++i) {
|
|
163
|
+
let f, g;
|
|
164
|
+
if (i < 16) {
|
|
165
|
+
f = b & c | ~b & d;
|
|
166
|
+
g = i;
|
|
167
|
+
} else if (i < 32) {
|
|
168
|
+
f = d & b | c & ~d;
|
|
169
|
+
g = (5 * i + 1) % 16;
|
|
170
|
+
} else if (i < 48) {
|
|
171
|
+
f = b ^ c ^ d;
|
|
172
|
+
g = (3 * i + 5) % 16;
|
|
173
|
+
} else {
|
|
174
|
+
f = c ^ (b | ~d);
|
|
175
|
+
g = 7 * i % 16;
|
|
176
|
+
}
|
|
177
|
+
const x = block.getUint32(g * 4, true);
|
|
178
|
+
const tmp = d;
|
|
179
|
+
d = c;
|
|
180
|
+
c = b;
|
|
181
|
+
const s = S[(i >> 4) * 4 + (i & 3)];
|
|
182
|
+
const sum = (a + f & M) + (x + T[i] & M) & M;
|
|
183
|
+
b = b + ((sum << s | sum >>> 32 - s) >>> 0) & M;
|
|
184
|
+
a = tmp;
|
|
185
|
+
}
|
|
186
|
+
state[0] = state[0] + a & M;
|
|
187
|
+
state[1] = state[1] + b & M;
|
|
188
|
+
state[2] = state[2] + c & M;
|
|
189
|
+
state[3] = state[3] + d & M;
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
// ../../node_modules/.pnpm/@smithy+core@3.33.3/node_modules/@smithy/core/dist-es/submodules/checksum/md5/Md5Node.js
|
|
193
|
+
import { createHash } from "crypto";
|
|
194
|
+
var hasNativeCrypto = (() => {
|
|
195
|
+
try {
|
|
196
|
+
createHash("md5");
|
|
197
|
+
return true;
|
|
198
|
+
} catch {
|
|
199
|
+
return false;
|
|
200
|
+
}
|
|
201
|
+
})();
|
|
202
|
+
var Md5Node = hasNativeCrypto ? buildNativeClass2() : Md5Js;
|
|
203
|
+
function buildNativeClass2() {
|
|
204
|
+
return class Md5Node {
|
|
205
|
+
digestLength = 16;
|
|
206
|
+
hash = createHash("md5");
|
|
207
|
+
update(data) {
|
|
208
|
+
this.hash.update(toUint8Array(data));
|
|
209
|
+
}
|
|
210
|
+
async digest() {
|
|
211
|
+
const buf = this.hash.copy().digest();
|
|
212
|
+
return new Uint8Array(buf.buffer, buf.byteOffset, buf.byteLength);
|
|
213
|
+
}
|
|
214
|
+
reset() {
|
|
215
|
+
this.hash = createHash("md5");
|
|
216
|
+
}
|
|
217
|
+
};
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
// ../../node_modules/.pnpm/@smithy+core@3.33.3/node_modules/@smithy/core/dist-es/submodules/checksum/sha256/Sha256Js.js
|
|
221
|
+
var BLOCK = 64;
|
|
222
|
+
var DIGEST_LENGTH = 32;
|
|
223
|
+
var MAX_HASHABLE_LENGTH = 2 ** 53 - 1;
|
|
224
|
+
var Sha256Js = class _Sha256Js {
|
|
225
|
+
digestLength = DIGEST_LENGTH;
|
|
226
|
+
state = Int32Array.from(INIT2);
|
|
227
|
+
w;
|
|
228
|
+
buffer = new Uint8Array(64);
|
|
229
|
+
bufferLength = 0;
|
|
230
|
+
bytesHashed = 0;
|
|
231
|
+
finished = false;
|
|
232
|
+
inner;
|
|
233
|
+
outer;
|
|
234
|
+
constructor(secret) {
|
|
235
|
+
if (secret) {
|
|
236
|
+
const key = _Sha256Js.normalizeKey(secret);
|
|
237
|
+
this.inner = new _Sha256Js();
|
|
238
|
+
this.outer = new _Sha256Js();
|
|
239
|
+
const { inner, outer } = this;
|
|
240
|
+
const pad = new Uint8Array(BLOCK * 2);
|
|
241
|
+
for (let i = 0; i < BLOCK; ++i) {
|
|
242
|
+
pad[i] = 54 ^ key[i];
|
|
243
|
+
pad[i + BLOCK] = 92 ^ key[i];
|
|
244
|
+
}
|
|
245
|
+
inner.update(pad.subarray(0, BLOCK));
|
|
246
|
+
outer.update(pad.subarray(BLOCK));
|
|
247
|
+
}
|
|
248
|
+
}
|
|
249
|
+
update(data) {
|
|
250
|
+
if (this.finished) {
|
|
251
|
+
throw new Error("Attempted to update an already finished HMAC.");
|
|
252
|
+
}
|
|
253
|
+
if (this.inner) {
|
|
254
|
+
this.inner.update(data);
|
|
255
|
+
return;
|
|
256
|
+
}
|
|
257
|
+
const chunk = toUint8Array(data);
|
|
258
|
+
let position = 0;
|
|
259
|
+
let { byteLength } = chunk;
|
|
260
|
+
this.bytesHashed += byteLength;
|
|
261
|
+
if (this.bytesHashed * 8 > MAX_HASHABLE_LENGTH) {
|
|
262
|
+
throw new Error("Cannot hash more than 2^53 - 1 bits");
|
|
263
|
+
}
|
|
264
|
+
while (byteLength > 0) {
|
|
265
|
+
this.buffer[this.bufferLength++] = chunk[position++];
|
|
266
|
+
byteLength--;
|
|
267
|
+
if (this.bufferLength === BLOCK) {
|
|
268
|
+
this.hashBuffer();
|
|
269
|
+
this.bufferLength = 0;
|
|
270
|
+
}
|
|
271
|
+
}
|
|
272
|
+
}
|
|
273
|
+
async digest() {
|
|
274
|
+
const { inner, outer } = this;
|
|
275
|
+
if (inner && outer) {
|
|
276
|
+
if (this.finished) {
|
|
277
|
+
throw new Error("Attempted to digest an already finished HMAC.");
|
|
278
|
+
}
|
|
279
|
+
this.finished = true;
|
|
280
|
+
const innerDigest = inner.digestSync();
|
|
281
|
+
outer.update(innerDigest);
|
|
282
|
+
return outer.digestSync();
|
|
283
|
+
}
|
|
284
|
+
return this.digestSync();
|
|
285
|
+
}
|
|
286
|
+
reset() {
|
|
287
|
+
this.state = Int32Array.from(INIT2);
|
|
288
|
+
this.buffer = new Uint8Array(64);
|
|
289
|
+
this.bufferLength = 0;
|
|
290
|
+
this.bytesHashed = 0;
|
|
291
|
+
}
|
|
292
|
+
digestSync() {
|
|
293
|
+
const state = this.state.slice();
|
|
294
|
+
const buffer = this.buffer.slice();
|
|
295
|
+
let bufferLength = this.bufferLength;
|
|
296
|
+
const bitsHashed = this.bytesHashed * 8;
|
|
297
|
+
const bufferView = new DataView(buffer.buffer, buffer.byteOffset, buffer.byteLength);
|
|
298
|
+
bufferView.setUint8(bufferLength++, 128);
|
|
299
|
+
if ((bufferLength - 1) % BLOCK >= BLOCK - 8) {
|
|
300
|
+
for (let i = bufferLength; i < BLOCK; ++i) {
|
|
301
|
+
bufferView.setUint8(i, 0);
|
|
302
|
+
}
|
|
303
|
+
this.hashBufferWith(state, buffer);
|
|
304
|
+
bufferLength = 0;
|
|
305
|
+
}
|
|
306
|
+
for (let i = bufferLength; i < BLOCK - 8; ++i) {
|
|
307
|
+
bufferView.setUint8(i, 0);
|
|
308
|
+
}
|
|
309
|
+
bufferView.setUint32(BLOCK - 8, Math.floor(bitsHashed / 4294967296), false);
|
|
310
|
+
bufferView.setUint32(BLOCK - 4, bitsHashed, false);
|
|
311
|
+
this.hashBufferWith(state, buffer);
|
|
312
|
+
const out = new Uint8Array(DIGEST_LENGTH);
|
|
313
|
+
for (let i = 0; i < 8; ++i) {
|
|
314
|
+
out[i * 4] = state[i] >>> 24 & 255;
|
|
315
|
+
out[i * 4 + 1] = state[i] >>> 16 & 255;
|
|
316
|
+
out[i * 4 + 2] = state[i] >>> 8 & 255;
|
|
317
|
+
out[i * 4 + 3] = state[i] >>> 0 & 255;
|
|
318
|
+
}
|
|
319
|
+
return out;
|
|
320
|
+
}
|
|
321
|
+
static normalizeKey(secret) {
|
|
322
|
+
const key = toUint8Array(secret);
|
|
323
|
+
if (key.byteLength > BLOCK) {
|
|
324
|
+
const h = new _Sha256Js();
|
|
325
|
+
h.update(key);
|
|
326
|
+
const out = h.digestSync();
|
|
327
|
+
const padded = new Uint8Array(BLOCK);
|
|
328
|
+
padded.set(out);
|
|
329
|
+
return padded;
|
|
330
|
+
}
|
|
331
|
+
if (key.byteLength < BLOCK) {
|
|
332
|
+
const padded = new Uint8Array(BLOCK);
|
|
333
|
+
padded.set(key);
|
|
334
|
+
return padded;
|
|
335
|
+
}
|
|
336
|
+
return key;
|
|
337
|
+
}
|
|
338
|
+
hashBuffer() {
|
|
339
|
+
this.hashBufferWith(this.state, this.buffer);
|
|
340
|
+
}
|
|
341
|
+
hashBufferWith(state, buffer) {
|
|
342
|
+
const w = this.w ??= new Int32Array(64);
|
|
343
|
+
let s0 = state[0], s1 = state[1], s2 = state[2], s3 = state[3], s4 = state[4], s5 = state[5], s6 = state[6], s7 = state[7];
|
|
344
|
+
for (let i = 0; i < BLOCK; ++i) {
|
|
345
|
+
if (i < 16) {
|
|
346
|
+
w[i] = (buffer[i * 4] & 255) << 24 | (buffer[i * 4 + 1] & 255) << 16 | (buffer[i * 4 + 2] & 255) << 8 | buffer[i * 4 + 3] & 255;
|
|
347
|
+
} else {
|
|
348
|
+
let u = w[i - 2];
|
|
349
|
+
const t12 = (u >>> 17 | u << 15) ^ (u >>> 19 | u << 13) ^ u >>> 10;
|
|
350
|
+
u = w[i - 15];
|
|
351
|
+
const t22 = (u >>> 7 | u << 25) ^ (u >>> 18 | u << 14) ^ u >>> 3;
|
|
352
|
+
w[i] = (t12 + w[i - 7] | 0) + (t22 + w[i - 16] | 0);
|
|
353
|
+
}
|
|
354
|
+
const t1 = (((s4 >>> 6 | s4 << 26) ^ (s4 >>> 11 | s4 << 21) ^ (s4 >>> 25 | s4 << 7)) + (s4 & s5 ^ ~s4 & s6) | 0) + (s7 + (K[i] + w[i] | 0) | 0) | 0;
|
|
355
|
+
const t2 = ((s0 >>> 2 | s0 << 30) ^ (s0 >>> 13 | s0 << 19) ^ (s0 >>> 22 | s0 << 10)) + (s0 & s1 ^ s0 & s2 ^ s1 & s2) | 0;
|
|
356
|
+
s7 = s6;
|
|
357
|
+
s6 = s5;
|
|
358
|
+
s5 = s4;
|
|
359
|
+
s4 = s3 + t1 | 0;
|
|
360
|
+
s3 = s2;
|
|
361
|
+
s2 = s1;
|
|
362
|
+
s1 = s0;
|
|
363
|
+
s0 = t1 + t2 | 0;
|
|
364
|
+
}
|
|
365
|
+
state[0] += s0;
|
|
366
|
+
state[1] += s1;
|
|
367
|
+
state[2] += s2;
|
|
368
|
+
state[3] += s3;
|
|
369
|
+
state[4] += s4;
|
|
370
|
+
state[5] += s5;
|
|
371
|
+
state[6] += s6;
|
|
372
|
+
state[7] += s7;
|
|
373
|
+
}
|
|
374
|
+
};
|
|
375
|
+
var INIT2 = new Int32Array([
|
|
376
|
+
1779033703,
|
|
377
|
+
3144134277,
|
|
378
|
+
1013904242,
|
|
379
|
+
2773480762,
|
|
380
|
+
1359893119,
|
|
381
|
+
2600822924,
|
|
382
|
+
528734635,
|
|
383
|
+
1541459225
|
|
384
|
+
]);
|
|
385
|
+
var K = new Int32Array([
|
|
386
|
+
1116352408,
|
|
387
|
+
1899447441,
|
|
388
|
+
3049323471,
|
|
389
|
+
3921009573,
|
|
390
|
+
961987163,
|
|
391
|
+
1508970993,
|
|
392
|
+
2453635748,
|
|
393
|
+
2870763221,
|
|
394
|
+
3624381080,
|
|
395
|
+
310598401,
|
|
396
|
+
607225278,
|
|
397
|
+
1426881987,
|
|
398
|
+
1925078388,
|
|
399
|
+
2162078206,
|
|
400
|
+
2614888103,
|
|
401
|
+
3248222580,
|
|
402
|
+
3835390401,
|
|
403
|
+
4022224774,
|
|
404
|
+
264347078,
|
|
405
|
+
604807628,
|
|
406
|
+
770255983,
|
|
407
|
+
1249150122,
|
|
408
|
+
1555081692,
|
|
409
|
+
1996064986,
|
|
410
|
+
2554220882,
|
|
411
|
+
2821834349,
|
|
412
|
+
2952996808,
|
|
413
|
+
3210313671,
|
|
414
|
+
3336571891,
|
|
415
|
+
3584528711,
|
|
416
|
+
113926993,
|
|
417
|
+
338241895,
|
|
418
|
+
666307205,
|
|
419
|
+
773529912,
|
|
420
|
+
1294757372,
|
|
421
|
+
1396182291,
|
|
422
|
+
1695183700,
|
|
423
|
+
1986661051,
|
|
424
|
+
2177026350,
|
|
425
|
+
2456956037,
|
|
426
|
+
2730485921,
|
|
427
|
+
2820302411,
|
|
428
|
+
3259730800,
|
|
429
|
+
3345764771,
|
|
430
|
+
3516065817,
|
|
431
|
+
3600352804,
|
|
432
|
+
4094571909,
|
|
433
|
+
275423344,
|
|
434
|
+
430227734,
|
|
435
|
+
506948616,
|
|
436
|
+
659060556,
|
|
437
|
+
883997877,
|
|
438
|
+
958139571,
|
|
439
|
+
1322822218,
|
|
440
|
+
1537002063,
|
|
441
|
+
1747873779,
|
|
442
|
+
1955562222,
|
|
443
|
+
2024104815,
|
|
444
|
+
2227730452,
|
|
445
|
+
2361852424,
|
|
446
|
+
2428436474,
|
|
447
|
+
2756734187,
|
|
448
|
+
3204031479,
|
|
449
|
+
3329325298
|
|
450
|
+
]);
|
|
451
|
+
|
|
452
|
+
// ../../node_modules/.pnpm/@smithy+core@3.33.3/node_modules/@smithy/core/dist-es/submodules/checksum/sha256/Sha256Node.js
|
|
453
|
+
import { createHash as createHash2, createHmac } from "crypto";
|
|
454
|
+
var hasNativeCrypto2 = (() => {
|
|
455
|
+
try {
|
|
456
|
+
createHash2("sha256");
|
|
457
|
+
return true;
|
|
458
|
+
} catch {
|
|
459
|
+
return false;
|
|
460
|
+
}
|
|
461
|
+
})();
|
|
462
|
+
var Sha256Node = hasNativeCrypto2 ? buildNativeClass3() : Sha256Js;
|
|
463
|
+
function buildNativeClass3() {
|
|
464
|
+
return class Sha256Node {
|
|
465
|
+
digestLength = 32;
|
|
466
|
+
secret;
|
|
467
|
+
hash;
|
|
468
|
+
isHmac;
|
|
469
|
+
finished = false;
|
|
470
|
+
constructor(secret) {
|
|
471
|
+
this.secret = secret;
|
|
472
|
+
this.isHmac = !!secret;
|
|
473
|
+
this.hash = this.createHash();
|
|
474
|
+
}
|
|
475
|
+
update(data) {
|
|
476
|
+
if (this.finished) {
|
|
477
|
+
throw new Error("Attempted to update an already finished hash.");
|
|
478
|
+
}
|
|
479
|
+
this.hash.update(data);
|
|
480
|
+
}
|
|
481
|
+
async digest() {
|
|
482
|
+
let buf;
|
|
483
|
+
if (this.isHmac) {
|
|
484
|
+
this.finished = true;
|
|
485
|
+
buf = this.hash.digest();
|
|
486
|
+
} else {
|
|
487
|
+
buf = this.hash.copy().digest();
|
|
488
|
+
}
|
|
489
|
+
return new Uint8Array(buf.buffer, buf.byteOffset, buf.byteLength);
|
|
490
|
+
}
|
|
491
|
+
reset() {
|
|
492
|
+
this.hash = this.createHash();
|
|
493
|
+
this.finished = false;
|
|
494
|
+
}
|
|
495
|
+
createHash() {
|
|
496
|
+
return this.secret ? createHmac("sha256", toBuffer(this.secret)) : createHash2("sha256");
|
|
497
|
+
}
|
|
498
|
+
};
|
|
499
|
+
}
|
|
500
|
+
function toBuffer(data) {
|
|
501
|
+
if (typeof data === "string") {
|
|
502
|
+
return data;
|
|
503
|
+
}
|
|
504
|
+
if (ArrayBuffer.isView(data)) {
|
|
505
|
+
return Buffer.from(data.buffer, data.byteOffset, data.byteLength);
|
|
506
|
+
}
|
|
507
|
+
return Buffer.from(data);
|
|
508
|
+
}
|
|
509
|
+
|
|
510
|
+
export {
|
|
511
|
+
readableStreamHasher,
|
|
512
|
+
Md5Node,
|
|
513
|
+
Crc32Node,
|
|
514
|
+
Sha256Node
|
|
515
|
+
};
|