replicas-engine 0.1.143 → 0.1.145
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/dist/src/{chunk-XCFRYWEV.js → chunk-2Y7PD56W.js} +12 -12
- package/dist/src/{chunk-JFXVYYQY.js → chunk-5VUQ55WW.js} +19 -19
- package/dist/src/{chunk-NPXMDMPW.js → chunk-AAVVX4U5.js} +6 -6
- package/dist/src/{chunk-J3WZZOOL.js → chunk-BUG7ZAQW.js} +72 -355
- package/dist/src/{chunk-TY2FR253.js → chunk-SGITM26Q.js} +309 -22
- package/dist/src/{chunk-YDW6RZI2.js → chunk-ST5JVROM.js} +2 -2
- package/dist/src/{chunk-WCAERHFE.js → chunk-SWX24AGM.js} +1 -1
- package/dist/src/{chunk-7RS3TOFT.js → chunk-TU2SAX7Z.js} +1072 -1228
- package/dist/src/{chunk-MCYTXPBZ.js → chunk-WPAL27HA.js} +2 -2
- package/dist/src/{chunk-N2BGF5AZ.js → chunk-ZNARSMJG.js} +1 -1
- package/dist/src/{dist-es-UV765YRF.js → dist-es-BUG4C6LP.js} +18 -18
- package/dist/src/{dist-es-3LYC7DO3.js → dist-es-F6RG3S4O.js} +12 -14
- package/dist/src/{dist-es-KHBICPEM.js → dist-es-GGHPJZ3K.js} +19 -19
- package/dist/src/{dist-es-7DTYZ3KD.js → dist-es-GZBSW2H3.js} +27 -27
- package/dist/src/{dist-es-YWO2URNL.js → dist-es-JIV2SPEM.js} +7 -7
- package/dist/src/{dist-es-BNJQGHZR.js → dist-es-Q3YZVSCP.js} +7 -7
- package/dist/src/{dist-es-EVINFDC2.js → dist-es-YKS4LXBO.js} +3 -3
- package/dist/src/index.js +4 -109
- package/dist/src/{loadSso-ZRFAKENS.js → loadSso-3WFGTQV7.js} +109 -148
- package/dist/src/{signin-PNR24U2H.js → signin-RSKKVVIS.js} +123 -177
- package/dist/src/{sso-oidc-O55BGCVQ.js → sso-oidc-LBVW2ORP.js} +111 -150
- package/dist/src/{sts-MRC7OH6Z.js → sts-DKGAU6YE.js} +2911 -718
- package/package.json +1 -1
- package/dist/src/chunk-5V5ZNFZK.js +0 -178
- package/dist/src/event-streams-IFAW3KBX.js +0 -244
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
fromUtf8
|
|
6
6
|
} from "./chunk-ERL3EC7G.js";
|
|
7
7
|
|
|
8
|
-
// ../node_modules/.bun/@smithy+protocol-http@5.3.
|
|
8
|
+
// ../node_modules/.bun/@smithy+protocol-http@5.3.14/node_modules/@smithy/protocol-http/dist-es/httpResponse.js
|
|
9
9
|
var HttpResponse = class {
|
|
10
10
|
statusCode;
|
|
11
11
|
reason;
|
|
@@ -29,7 +29,7 @@ var HttpResponse = class {
|
|
|
29
29
|
var escapeUri = (uri) => encodeURIComponent(uri).replace(/[!'()*]/g, hexEncode);
|
|
30
30
|
var hexEncode = (c) => `%${c.charCodeAt(0).toString(16).toUpperCase()}`;
|
|
31
31
|
|
|
32
|
-
// ../node_modules/.bun/@smithy+querystring-builder@4.2.
|
|
32
|
+
// ../node_modules/.bun/@smithy+querystring-builder@4.2.14/node_modules/@smithy/querystring-builder/dist-es/index.js
|
|
33
33
|
function buildQueryString(query) {
|
|
34
34
|
const parts = [];
|
|
35
35
|
for (let key of Object.keys(query).sort()) {
|
|
@@ -50,10 +50,10 @@ function buildQueryString(query) {
|
|
|
50
50
|
return parts.join("&");
|
|
51
51
|
}
|
|
52
52
|
|
|
53
|
-
// ../node_modules/.bun/@smithy+node-http-handler@4.
|
|
53
|
+
// ../node_modules/.bun/@smithy+node-http-handler@4.6.1/node_modules/@smithy/node-http-handler/dist-es/node-http-handler.js
|
|
54
54
|
import { Agent as hsAgent, request as hsRequest } from "https";
|
|
55
55
|
|
|
56
|
-
// ../node_modules/.bun/@smithy+node-http-handler@4.
|
|
56
|
+
// ../node_modules/.bun/@smithy+node-http-handler@4.6.1/node_modules/@smithy/node-http-handler/dist-es/build-abort-error.js
|
|
57
57
|
function buildAbortError(abortSignal) {
|
|
58
58
|
const reason = abortSignal && typeof abortSignal === "object" && "reason" in abortSignal ? abortSignal.reason : void 0;
|
|
59
59
|
if (reason) {
|
|
@@ -72,10 +72,10 @@ function buildAbortError(abortSignal) {
|
|
|
72
72
|
return abortError;
|
|
73
73
|
}
|
|
74
74
|
|
|
75
|
-
// ../node_modules/.bun/@smithy+node-http-handler@4.
|
|
75
|
+
// ../node_modules/.bun/@smithy+node-http-handler@4.6.1/node_modules/@smithy/node-http-handler/dist-es/constants.js
|
|
76
76
|
var NODEJS_TIMEOUT_ERROR_CODES = ["ECONNRESET", "EPIPE", "ETIMEDOUT"];
|
|
77
77
|
|
|
78
|
-
// ../node_modules/.bun/@smithy+node-http-handler@4.
|
|
78
|
+
// ../node_modules/.bun/@smithy+node-http-handler@4.6.1/node_modules/@smithy/node-http-handler/dist-es/get-transformed-headers.js
|
|
79
79
|
var getTransformedHeaders = (headers) => {
|
|
80
80
|
const transformedHeaders = {};
|
|
81
81
|
for (const name of Object.keys(headers)) {
|
|
@@ -85,13 +85,13 @@ var getTransformedHeaders = (headers) => {
|
|
|
85
85
|
return transformedHeaders;
|
|
86
86
|
};
|
|
87
87
|
|
|
88
|
-
// ../node_modules/.bun/@smithy+node-http-handler@4.
|
|
88
|
+
// ../node_modules/.bun/@smithy+node-http-handler@4.6.1/node_modules/@smithy/node-http-handler/dist-es/timing.js
|
|
89
89
|
var timing = {
|
|
90
90
|
setTimeout: (cb, ms) => setTimeout(cb, ms),
|
|
91
91
|
clearTimeout: (timeoutId) => clearTimeout(timeoutId)
|
|
92
92
|
};
|
|
93
93
|
|
|
94
|
-
// ../node_modules/.bun/@smithy+node-http-handler@4.
|
|
94
|
+
// ../node_modules/.bun/@smithy+node-http-handler@4.6.1/node_modules/@smithy/node-http-handler/dist-es/set-connection-timeout.js
|
|
95
95
|
var DEFER_EVENT_LISTENER_TIME = 1e3;
|
|
96
96
|
var setConnectionTimeout = (request, reject, timeoutInMs = 0) => {
|
|
97
97
|
if (!timeoutInMs) {
|
|
@@ -126,8 +126,8 @@ var setConnectionTimeout = (request, reject, timeoutInMs = 0) => {
|
|
|
126
126
|
return timing.setTimeout(registerTimeout.bind(null, DEFER_EVENT_LISTENER_TIME), DEFER_EVENT_LISTENER_TIME);
|
|
127
127
|
};
|
|
128
128
|
|
|
129
|
-
// ../node_modules/.bun/@smithy+node-http-handler@4.
|
|
130
|
-
var setRequestTimeout = (req, reject, timeoutInMs = 0, throwOnRequestTimeout,
|
|
129
|
+
// ../node_modules/.bun/@smithy+node-http-handler@4.6.1/node_modules/@smithy/node-http-handler/dist-es/set-request-timeout.js
|
|
130
|
+
var setRequestTimeout = (req, reject, timeoutInMs = 0, throwOnRequestTimeout, logger2) => {
|
|
131
131
|
if (timeoutInMs) {
|
|
132
132
|
return timing.setTimeout(() => {
|
|
133
133
|
let msg = `@smithy/node-http-handler - [${throwOnRequestTimeout ? "ERROR" : "WARN"}] a request has exceeded the configured ${timeoutInMs} ms requestTimeout.`;
|
|
@@ -140,14 +140,14 @@ var setRequestTimeout = (req, reject, timeoutInMs = 0, throwOnRequestTimeout, lo
|
|
|
140
140
|
reject(error);
|
|
141
141
|
} else {
|
|
142
142
|
msg += ` Init client requestHandler with throwOnRequestTimeout=true to turn this into an error.`;
|
|
143
|
-
|
|
143
|
+
logger2?.warn?.(msg);
|
|
144
144
|
}
|
|
145
145
|
}, timeoutInMs);
|
|
146
146
|
}
|
|
147
147
|
return -1;
|
|
148
148
|
};
|
|
149
149
|
|
|
150
|
-
// ../node_modules/.bun/@smithy+node-http-handler@4.
|
|
150
|
+
// ../node_modules/.bun/@smithy+node-http-handler@4.6.1/node_modules/@smithy/node-http-handler/dist-es/set-socket-keep-alive.js
|
|
151
151
|
var DEFER_EVENT_LISTENER_TIME2 = 3e3;
|
|
152
152
|
var setSocketKeepAlive = (request, { keepAlive, keepAliveMsecs }, deferTimeMs = DEFER_EVENT_LISTENER_TIME2) => {
|
|
153
153
|
if (keepAlive !== true) {
|
|
@@ -169,7 +169,7 @@ var setSocketKeepAlive = (request, { keepAlive, keepAliveMsecs }, deferTimeMs =
|
|
|
169
169
|
return timing.setTimeout(registerListener, deferTimeMs);
|
|
170
170
|
};
|
|
171
171
|
|
|
172
|
-
// ../node_modules/.bun/@smithy+node-http-handler@4.
|
|
172
|
+
// ../node_modules/.bun/@smithy+node-http-handler@4.6.1/node_modules/@smithy/node-http-handler/dist-es/set-socket-timeout.js
|
|
173
173
|
var DEFER_EVENT_LISTENER_TIME3 = 3e3;
|
|
174
174
|
var setSocketTimeout = (request, reject, timeoutInMs = 0) => {
|
|
175
175
|
const registerTimeout = (offset) => {
|
|
@@ -192,7 +192,7 @@ var setSocketTimeout = (request, reject, timeoutInMs = 0) => {
|
|
|
192
192
|
return timing.setTimeout(registerTimeout.bind(null, timeoutInMs === 0 ? 0 : DEFER_EVENT_LISTENER_TIME3), DEFER_EVENT_LISTENER_TIME3);
|
|
193
193
|
};
|
|
194
194
|
|
|
195
|
-
// ../node_modules/.bun/@smithy+node-http-handler@4.
|
|
195
|
+
// ../node_modules/.bun/@smithy+node-http-handler@4.6.1/node_modules/@smithy/node-http-handler/dist-es/write-request-body.js
|
|
196
196
|
import { Readable } from "stream";
|
|
197
197
|
var MIN_WAIT_TIME = 6e3;
|
|
198
198
|
async function writeRequestBody(httpRequest, request, maxContinueTimeoutMs = MIN_WAIT_TIME, externalAgent = false) {
|
|
@@ -252,7 +252,7 @@ function writeBody(httpRequest, body) {
|
|
|
252
252
|
httpRequest.end();
|
|
253
253
|
}
|
|
254
254
|
|
|
255
|
-
// ../node_modules/.bun/@smithy+node-http-handler@4.
|
|
255
|
+
// ../node_modules/.bun/@smithy+node-http-handler@4.6.1/node_modules/@smithy/node-http-handler/dist-es/node-http-handler.js
|
|
256
256
|
var hAgent = void 0;
|
|
257
257
|
var hRequest = void 0;
|
|
258
258
|
var NodeHttpHandler = class _NodeHttpHandler {
|
|
@@ -267,7 +267,7 @@ var NodeHttpHandler = class _NodeHttpHandler {
|
|
|
267
267
|
}
|
|
268
268
|
return new _NodeHttpHandler(instanceOrOptions);
|
|
269
269
|
}
|
|
270
|
-
static checkSocketUsage(agent, socketWarningTimestamp,
|
|
270
|
+
static checkSocketUsage(agent, socketWarningTimestamp, logger2 = console) {
|
|
271
271
|
const { sockets, requests, maxSockets } = agent;
|
|
272
272
|
if (typeof maxSockets !== "number" || maxSockets === Infinity) {
|
|
273
273
|
return socketWarningTimestamp;
|
|
@@ -281,7 +281,7 @@ var NodeHttpHandler = class _NodeHttpHandler {
|
|
|
281
281
|
const socketsInUse = sockets[origin]?.length ?? 0;
|
|
282
282
|
const requestsEnqueued = requests[origin]?.length ?? 0;
|
|
283
283
|
if (socketsInUse >= maxSockets && requestsEnqueued >= 2 * maxSockets) {
|
|
284
|
-
|
|
284
|
+
logger2?.warn?.(`@smithy/node-http-handler:WARN - socket usage at capacity=${socketsInUse} and ${requestsEnqueued} additional requests are enqueued.
|
|
285
285
|
See https://docs.aws.amazon.com/sdk-for-javascript/v3/developer-guide/node-configuring-maxsockets.html
|
|
286
286
|
or increase socketAcquisitionWarningTimeout=(millis) in the NodeHttpHandler config.`);
|
|
287
287
|
return Date.now();
|
|
@@ -434,7 +434,7 @@ or increase socketAcquisitionWarningTimeout=(millis) in the NodeHttpHandler conf
|
|
|
434
434
|
return this.config ?? {};
|
|
435
435
|
}
|
|
436
436
|
resolveDefaultConfig(options) {
|
|
437
|
-
const { requestTimeout, connectionTimeout, socketTimeout, socketAcquisitionWarningTimeout, httpAgent, httpsAgent, throwOnRequestTimeout, logger } = options || {};
|
|
437
|
+
const { requestTimeout, connectionTimeout, socketTimeout, socketAcquisitionWarningTimeout, httpAgent, httpsAgent, throwOnRequestTimeout, logger: logger2 } = options || {};
|
|
438
438
|
const keepAlive = true;
|
|
439
439
|
const maxSockets = 50;
|
|
440
440
|
return {
|
|
@@ -460,12 +460,12 @@ or increase socketAcquisitionWarningTimeout=(millis) in the NodeHttpHandler conf
|
|
|
460
460
|
}
|
|
461
461
|
return new hsAgent({ keepAlive, maxSockets, ...httpsAgent });
|
|
462
462
|
})(),
|
|
463
|
-
logger
|
|
463
|
+
logger: logger2
|
|
464
464
|
};
|
|
465
465
|
}
|
|
466
466
|
};
|
|
467
467
|
|
|
468
|
-
// ../node_modules/.bun/@smithy+node-http-handler@4.
|
|
468
|
+
// ../node_modules/.bun/@smithy+node-http-handler@4.6.1/node_modules/@smithy/node-http-handler/dist-es/stream-collector/collector.js
|
|
469
469
|
import { Writable } from "stream";
|
|
470
470
|
var Collector = class extends Writable {
|
|
471
471
|
bufferedBytes = [];
|
|
@@ -475,7 +475,7 @@ var Collector = class extends Writable {
|
|
|
475
475
|
}
|
|
476
476
|
};
|
|
477
477
|
|
|
478
|
-
// ../node_modules/.bun/@smithy+node-http-handler@4.
|
|
478
|
+
// ../node_modules/.bun/@smithy+node-http-handler@4.6.1/node_modules/@smithy/node-http-handler/dist-es/stream-collector/index.js
|
|
479
479
|
var streamCollector = (stream) => {
|
|
480
480
|
if (isReadableStreamInstance(stream)) {
|
|
481
481
|
return collectReadableStream(stream);
|
|
@@ -517,6 +517,288 @@ async function collectReadableStream(stream) {
|
|
|
517
517
|
return collected;
|
|
518
518
|
}
|
|
519
519
|
|
|
520
|
+
// ../node_modules/.bun/@smithy+core@3.23.17/node_modules/@smithy/core/dist-es/submodules/serde/parse-utils.js
|
|
521
|
+
var expectNumber = (value) => {
|
|
522
|
+
if (value === null || value === void 0) {
|
|
523
|
+
return void 0;
|
|
524
|
+
}
|
|
525
|
+
if (typeof value === "string") {
|
|
526
|
+
const parsed = parseFloat(value);
|
|
527
|
+
if (!Number.isNaN(parsed)) {
|
|
528
|
+
if (String(parsed) !== String(value)) {
|
|
529
|
+
logger.warn(stackTraceWarning(`Expected number but observed string: ${value}`));
|
|
530
|
+
}
|
|
531
|
+
return parsed;
|
|
532
|
+
}
|
|
533
|
+
}
|
|
534
|
+
if (typeof value === "number") {
|
|
535
|
+
return value;
|
|
536
|
+
}
|
|
537
|
+
throw new TypeError(`Expected number, got ${typeof value}: ${value}`);
|
|
538
|
+
};
|
|
539
|
+
var MAX_FLOAT = Math.ceil(2 ** 127 * (2 - 2 ** -23));
|
|
540
|
+
var expectFloat32 = (value) => {
|
|
541
|
+
const expected = expectNumber(value);
|
|
542
|
+
if (expected !== void 0 && !Number.isNaN(expected) && expected !== Infinity && expected !== -Infinity) {
|
|
543
|
+
if (Math.abs(expected) > MAX_FLOAT) {
|
|
544
|
+
throw new TypeError(`Expected 32-bit float, got ${value}`);
|
|
545
|
+
}
|
|
546
|
+
}
|
|
547
|
+
return expected;
|
|
548
|
+
};
|
|
549
|
+
var expectLong = (value) => {
|
|
550
|
+
if (value === null || value === void 0) {
|
|
551
|
+
return void 0;
|
|
552
|
+
}
|
|
553
|
+
if (Number.isInteger(value) && !Number.isNaN(value)) {
|
|
554
|
+
return value;
|
|
555
|
+
}
|
|
556
|
+
throw new TypeError(`Expected integer, got ${typeof value}: ${value}`);
|
|
557
|
+
};
|
|
558
|
+
var expectShort = (value) => expectSizedInt(value, 16);
|
|
559
|
+
var expectByte = (value) => expectSizedInt(value, 8);
|
|
560
|
+
var expectSizedInt = (value, size) => {
|
|
561
|
+
const expected = expectLong(value);
|
|
562
|
+
if (expected !== void 0 && castInt(expected, size) !== expected) {
|
|
563
|
+
throw new TypeError(`Expected ${size}-bit integer, got ${value}`);
|
|
564
|
+
}
|
|
565
|
+
return expected;
|
|
566
|
+
};
|
|
567
|
+
var castInt = (value, size) => {
|
|
568
|
+
switch (size) {
|
|
569
|
+
case 32:
|
|
570
|
+
return Int32Array.of(value)[0];
|
|
571
|
+
case 16:
|
|
572
|
+
return Int16Array.of(value)[0];
|
|
573
|
+
case 8:
|
|
574
|
+
return Int8Array.of(value)[0];
|
|
575
|
+
}
|
|
576
|
+
};
|
|
577
|
+
var strictParseDouble = (value) => {
|
|
578
|
+
if (typeof value == "string") {
|
|
579
|
+
return expectNumber(parseNumber(value));
|
|
580
|
+
}
|
|
581
|
+
return expectNumber(value);
|
|
582
|
+
};
|
|
583
|
+
var strictParseFloat32 = (value) => {
|
|
584
|
+
if (typeof value == "string") {
|
|
585
|
+
return expectFloat32(parseNumber(value));
|
|
586
|
+
}
|
|
587
|
+
return expectFloat32(value);
|
|
588
|
+
};
|
|
589
|
+
var NUMBER_REGEX = /(-?(?:0|[1-9]\d*)(?:\.\d+)?(?:[eE][+-]?\d+)?)|(-?Infinity)|(NaN)/g;
|
|
590
|
+
var parseNumber = (value) => {
|
|
591
|
+
const matches = value.match(NUMBER_REGEX);
|
|
592
|
+
if (matches === null || matches[0].length !== value.length) {
|
|
593
|
+
throw new TypeError(`Expected real number, got implicit NaN`);
|
|
594
|
+
}
|
|
595
|
+
return parseFloat(value);
|
|
596
|
+
};
|
|
597
|
+
var strictParseShort = (value) => {
|
|
598
|
+
if (typeof value === "string") {
|
|
599
|
+
return expectShort(parseNumber(value));
|
|
600
|
+
}
|
|
601
|
+
return expectShort(value);
|
|
602
|
+
};
|
|
603
|
+
var strictParseByte = (value) => {
|
|
604
|
+
if (typeof value === "string") {
|
|
605
|
+
return expectByte(parseNumber(value));
|
|
606
|
+
}
|
|
607
|
+
return expectByte(value);
|
|
608
|
+
};
|
|
609
|
+
var stackTraceWarning = (message) => {
|
|
610
|
+
return String(new TypeError(message).stack || message).split("\n").slice(0, 5).filter((s) => !s.includes("stackTraceWarning")).join("\n");
|
|
611
|
+
};
|
|
612
|
+
var logger = {
|
|
613
|
+
warn: console.warn
|
|
614
|
+
};
|
|
615
|
+
|
|
616
|
+
// ../node_modules/.bun/@smithy+core@3.23.17/node_modules/@smithy/core/dist-es/submodules/serde/date-utils.js
|
|
617
|
+
var DAYS = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"];
|
|
618
|
+
var MONTHS = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"];
|
|
619
|
+
function dateToUtcString(date) {
|
|
620
|
+
const year = date.getUTCFullYear();
|
|
621
|
+
const month = date.getUTCMonth();
|
|
622
|
+
const dayOfWeek = date.getUTCDay();
|
|
623
|
+
const dayOfMonthInt = date.getUTCDate();
|
|
624
|
+
const hoursInt = date.getUTCHours();
|
|
625
|
+
const minutesInt = date.getUTCMinutes();
|
|
626
|
+
const secondsInt = date.getUTCSeconds();
|
|
627
|
+
const dayOfMonthString = dayOfMonthInt < 10 ? `0${dayOfMonthInt}` : `${dayOfMonthInt}`;
|
|
628
|
+
const hoursString = hoursInt < 10 ? `0${hoursInt}` : `${hoursInt}`;
|
|
629
|
+
const minutesString = minutesInt < 10 ? `0${minutesInt}` : `${minutesInt}`;
|
|
630
|
+
const secondsString = secondsInt < 10 ? `0${secondsInt}` : `${secondsInt}`;
|
|
631
|
+
return `${DAYS[dayOfWeek]}, ${dayOfMonthString} ${MONTHS[month]} ${year} ${hoursString}:${minutesString}:${secondsString} GMT`;
|
|
632
|
+
}
|
|
633
|
+
var RFC3339 = new RegExp(/^(\d{4})-(\d{2})-(\d{2})[tT](\d{2}):(\d{2}):(\d{2})(?:\.(\d+))?[zZ]$/);
|
|
634
|
+
var parseRfc3339DateTime = (value) => {
|
|
635
|
+
if (value === null || value === void 0) {
|
|
636
|
+
return void 0;
|
|
637
|
+
}
|
|
638
|
+
if (typeof value !== "string") {
|
|
639
|
+
throw new TypeError("RFC-3339 date-times must be expressed as strings");
|
|
640
|
+
}
|
|
641
|
+
const match = RFC3339.exec(value);
|
|
642
|
+
if (!match) {
|
|
643
|
+
throw new TypeError("Invalid RFC-3339 date-time value");
|
|
644
|
+
}
|
|
645
|
+
const [_, yearStr, monthStr, dayStr, hours, minutes, seconds, fractionalMilliseconds] = match;
|
|
646
|
+
const year = strictParseShort(stripLeadingZeroes(yearStr));
|
|
647
|
+
const month = parseDateValue(monthStr, "month", 1, 12);
|
|
648
|
+
const day = parseDateValue(dayStr, "day", 1, 31);
|
|
649
|
+
return buildDate(year, month, day, { hours, minutes, seconds, fractionalMilliseconds });
|
|
650
|
+
};
|
|
651
|
+
var RFC3339_WITH_OFFSET = new RegExp(/^(\d{4})-(\d{2})-(\d{2})[tT](\d{2}):(\d{2}):(\d{2})(?:\.(\d+))?(([-+]\d{2}\:\d{2})|[zZ])$/);
|
|
652
|
+
var parseRfc3339DateTimeWithOffset = (value) => {
|
|
653
|
+
if (value === null || value === void 0) {
|
|
654
|
+
return void 0;
|
|
655
|
+
}
|
|
656
|
+
if (typeof value !== "string") {
|
|
657
|
+
throw new TypeError("RFC-3339 date-times must be expressed as strings");
|
|
658
|
+
}
|
|
659
|
+
const match = RFC3339_WITH_OFFSET.exec(value);
|
|
660
|
+
if (!match) {
|
|
661
|
+
throw new TypeError("Invalid RFC-3339 date-time value");
|
|
662
|
+
}
|
|
663
|
+
const [_, yearStr, monthStr, dayStr, hours, minutes, seconds, fractionalMilliseconds, offsetStr] = match;
|
|
664
|
+
const year = strictParseShort(stripLeadingZeroes(yearStr));
|
|
665
|
+
const month = parseDateValue(monthStr, "month", 1, 12);
|
|
666
|
+
const day = parseDateValue(dayStr, "day", 1, 31);
|
|
667
|
+
const date = buildDate(year, month, day, { hours, minutes, seconds, fractionalMilliseconds });
|
|
668
|
+
if (offsetStr.toUpperCase() != "Z") {
|
|
669
|
+
date.setTime(date.getTime() - parseOffsetToMilliseconds(offsetStr));
|
|
670
|
+
}
|
|
671
|
+
return date;
|
|
672
|
+
};
|
|
673
|
+
var IMF_FIXDATE = new RegExp(/^(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d{2}) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? GMT$/);
|
|
674
|
+
var RFC_850_DATE = new RegExp(/^(?:Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday), (\d{2})-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d{2}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? GMT$/);
|
|
675
|
+
var ASC_TIME = new RegExp(/^(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( [1-9]|\d{2}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? (\d{4})$/);
|
|
676
|
+
var parseRfc7231DateTime = (value) => {
|
|
677
|
+
if (value === null || value === void 0) {
|
|
678
|
+
return void 0;
|
|
679
|
+
}
|
|
680
|
+
if (typeof value !== "string") {
|
|
681
|
+
throw new TypeError("RFC-7231 date-times must be expressed as strings");
|
|
682
|
+
}
|
|
683
|
+
let match = IMF_FIXDATE.exec(value);
|
|
684
|
+
if (match) {
|
|
685
|
+
const [_, dayStr, monthStr, yearStr, hours, minutes, seconds, fractionalMilliseconds] = match;
|
|
686
|
+
return buildDate(strictParseShort(stripLeadingZeroes(yearStr)), parseMonthByShortName(monthStr), parseDateValue(dayStr, "day", 1, 31), { hours, minutes, seconds, fractionalMilliseconds });
|
|
687
|
+
}
|
|
688
|
+
match = RFC_850_DATE.exec(value);
|
|
689
|
+
if (match) {
|
|
690
|
+
const [_, dayStr, monthStr, yearStr, hours, minutes, seconds, fractionalMilliseconds] = match;
|
|
691
|
+
return adjustRfc850Year(buildDate(parseTwoDigitYear(yearStr), parseMonthByShortName(monthStr), parseDateValue(dayStr, "day", 1, 31), {
|
|
692
|
+
hours,
|
|
693
|
+
minutes,
|
|
694
|
+
seconds,
|
|
695
|
+
fractionalMilliseconds
|
|
696
|
+
}));
|
|
697
|
+
}
|
|
698
|
+
match = ASC_TIME.exec(value);
|
|
699
|
+
if (match) {
|
|
700
|
+
const [_, monthStr, dayStr, hours, minutes, seconds, fractionalMilliseconds, yearStr] = match;
|
|
701
|
+
return buildDate(strictParseShort(stripLeadingZeroes(yearStr)), parseMonthByShortName(monthStr), parseDateValue(dayStr.trimLeft(), "day", 1, 31), { hours, minutes, seconds, fractionalMilliseconds });
|
|
702
|
+
}
|
|
703
|
+
throw new TypeError("Invalid RFC-7231 date-time value");
|
|
704
|
+
};
|
|
705
|
+
var parseEpochTimestamp = (value) => {
|
|
706
|
+
if (value === null || value === void 0) {
|
|
707
|
+
return void 0;
|
|
708
|
+
}
|
|
709
|
+
let valueAsDouble;
|
|
710
|
+
if (typeof value === "number") {
|
|
711
|
+
valueAsDouble = value;
|
|
712
|
+
} else if (typeof value === "string") {
|
|
713
|
+
valueAsDouble = strictParseDouble(value);
|
|
714
|
+
} else if (typeof value === "object" && value.tag === 1) {
|
|
715
|
+
valueAsDouble = value.value;
|
|
716
|
+
} else {
|
|
717
|
+
throw new TypeError("Epoch timestamps must be expressed as floating point numbers or their string representation");
|
|
718
|
+
}
|
|
719
|
+
if (Number.isNaN(valueAsDouble) || valueAsDouble === Infinity || valueAsDouble === -Infinity) {
|
|
720
|
+
throw new TypeError("Epoch timestamps must be valid, non-Infinite, non-NaN numerics");
|
|
721
|
+
}
|
|
722
|
+
return new Date(Math.round(valueAsDouble * 1e3));
|
|
723
|
+
};
|
|
724
|
+
var buildDate = (year, month, day, time) => {
|
|
725
|
+
const adjustedMonth = month - 1;
|
|
726
|
+
validateDayOfMonth(year, adjustedMonth, day);
|
|
727
|
+
return new Date(Date.UTC(year, adjustedMonth, day, parseDateValue(time.hours, "hour", 0, 23), parseDateValue(time.minutes, "minute", 0, 59), parseDateValue(time.seconds, "seconds", 0, 60), parseMilliseconds(time.fractionalMilliseconds)));
|
|
728
|
+
};
|
|
729
|
+
var parseTwoDigitYear = (value) => {
|
|
730
|
+
const thisYear = (/* @__PURE__ */ new Date()).getUTCFullYear();
|
|
731
|
+
const valueInThisCentury = Math.floor(thisYear / 100) * 100 + strictParseShort(stripLeadingZeroes(value));
|
|
732
|
+
if (valueInThisCentury < thisYear) {
|
|
733
|
+
return valueInThisCentury + 100;
|
|
734
|
+
}
|
|
735
|
+
return valueInThisCentury;
|
|
736
|
+
};
|
|
737
|
+
var FIFTY_YEARS_IN_MILLIS = 50 * 365 * 24 * 60 * 60 * 1e3;
|
|
738
|
+
var adjustRfc850Year = (input) => {
|
|
739
|
+
if (input.getTime() - (/* @__PURE__ */ new Date()).getTime() > FIFTY_YEARS_IN_MILLIS) {
|
|
740
|
+
return new Date(Date.UTC(input.getUTCFullYear() - 100, input.getUTCMonth(), input.getUTCDate(), input.getUTCHours(), input.getUTCMinutes(), input.getUTCSeconds(), input.getUTCMilliseconds()));
|
|
741
|
+
}
|
|
742
|
+
return input;
|
|
743
|
+
};
|
|
744
|
+
var parseMonthByShortName = (value) => {
|
|
745
|
+
const monthIdx = MONTHS.indexOf(value);
|
|
746
|
+
if (monthIdx < 0) {
|
|
747
|
+
throw new TypeError(`Invalid month: ${value}`);
|
|
748
|
+
}
|
|
749
|
+
return monthIdx + 1;
|
|
750
|
+
};
|
|
751
|
+
var DAYS_IN_MONTH = [31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];
|
|
752
|
+
var validateDayOfMonth = (year, month, day) => {
|
|
753
|
+
let maxDays = DAYS_IN_MONTH[month];
|
|
754
|
+
if (month === 1 && isLeapYear(year)) {
|
|
755
|
+
maxDays = 29;
|
|
756
|
+
}
|
|
757
|
+
if (day > maxDays) {
|
|
758
|
+
throw new TypeError(`Invalid day for ${MONTHS[month]} in ${year}: ${day}`);
|
|
759
|
+
}
|
|
760
|
+
};
|
|
761
|
+
var isLeapYear = (year) => {
|
|
762
|
+
return year % 4 === 0 && (year % 100 !== 0 || year % 400 === 0);
|
|
763
|
+
};
|
|
764
|
+
var parseDateValue = (value, type, lower, upper) => {
|
|
765
|
+
const dateVal = strictParseByte(stripLeadingZeroes(value));
|
|
766
|
+
if (dateVal < lower || dateVal > upper) {
|
|
767
|
+
throw new TypeError(`${type} must be between ${lower} and ${upper}, inclusive`);
|
|
768
|
+
}
|
|
769
|
+
return dateVal;
|
|
770
|
+
};
|
|
771
|
+
var parseMilliseconds = (value) => {
|
|
772
|
+
if (value === null || value === void 0) {
|
|
773
|
+
return 0;
|
|
774
|
+
}
|
|
775
|
+
return strictParseFloat32("0." + value) * 1e3;
|
|
776
|
+
};
|
|
777
|
+
var parseOffsetToMilliseconds = (value) => {
|
|
778
|
+
const directionStr = value[0];
|
|
779
|
+
let direction = 1;
|
|
780
|
+
if (directionStr == "+") {
|
|
781
|
+
direction = 1;
|
|
782
|
+
} else if (directionStr == "-") {
|
|
783
|
+
direction = -1;
|
|
784
|
+
} else {
|
|
785
|
+
throw new TypeError(`Offset direction, ${directionStr}, must be "+" or "-"`);
|
|
786
|
+
}
|
|
787
|
+
const hour = Number(value.substring(1, 3));
|
|
788
|
+
const minute = Number(value.substring(4, 6));
|
|
789
|
+
return direction * (hour * 60 + minute) * 60 * 1e3;
|
|
790
|
+
};
|
|
791
|
+
var stripLeadingZeroes = (value) => {
|
|
792
|
+
let idx = 0;
|
|
793
|
+
while (idx < value.length - 1 && value.charAt(idx) === "0") {
|
|
794
|
+
idx++;
|
|
795
|
+
}
|
|
796
|
+
if (idx === 0) {
|
|
797
|
+
return value;
|
|
798
|
+
}
|
|
799
|
+
return value.slice(idx);
|
|
800
|
+
};
|
|
801
|
+
|
|
520
802
|
// ../node_modules/.bun/@smithy+util-base64@4.3.2/node_modules/@smithy/util-base64/dist-es/fromBase64.js
|
|
521
803
|
var BASE64_REGEX = /^[A-Za-z0-9+/]*={0,2}$/;
|
|
522
804
|
var fromBase64 = (input) => {
|
|
@@ -586,5 +868,10 @@ export {
|
|
|
586
868
|
NodeHttpHandler,
|
|
587
869
|
streamCollector,
|
|
588
870
|
fromHex,
|
|
589
|
-
toHex
|
|
871
|
+
toHex,
|
|
872
|
+
dateToUtcString,
|
|
873
|
+
parseRfc3339DateTime,
|
|
874
|
+
parseRfc3339DateTimeWithOffset,
|
|
875
|
+
parseRfc7231DateTime,
|
|
876
|
+
parseEpochTimestamp
|
|
590
877
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
|
-
// ../node_modules/.bun/@smithy+property-provider@4.2.
|
|
3
|
+
// ../node_modules/.bun/@smithy+property-provider@4.2.14/node_modules/@smithy/property-provider/dist-es/ProviderError.js
|
|
4
4
|
var ProviderError = class _ProviderError extends Error {
|
|
5
5
|
name = "ProviderError";
|
|
6
6
|
tryNextLink;
|
|
@@ -24,7 +24,7 @@ var ProviderError = class _ProviderError extends Error {
|
|
|
24
24
|
}
|
|
25
25
|
};
|
|
26
26
|
|
|
27
|
-
// ../node_modules/.bun/@smithy+property-provider@4.2.
|
|
27
|
+
// ../node_modules/.bun/@smithy+property-provider@4.2.14/node_modules/@smithy/property-provider/dist-es/CredentialsProviderError.js
|
|
28
28
|
var CredentialsProviderError = class _CredentialsProviderError extends ProviderError {
|
|
29
29
|
name = "CredentialsProviderError";
|
|
30
30
|
constructor(message, options = true) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
|
-
// ../node_modules/.bun/@smithy+protocol-http@5.3.
|
|
3
|
+
// ../node_modules/.bun/@smithy+protocol-http@5.3.14/node_modules/@smithy/protocol-http/dist-es/httpRequest.js
|
|
4
4
|
var HttpRequest = class _HttpRequest {
|
|
5
5
|
method;
|
|
6
6
|
protocol;
|