🎩 You're Invited:Meet the Socket team at Black Hat in Las Vegas, August 3-6.RSVP
Sign In

@smithy/core

Package Overview
Dependencies
Maintainers
2
Versions
150
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@smithy/core - npm Package Compare versions

Comparing version
3.29.3
to
3.29.4
+3
-3
dist-cjs/submodules/cbor/index.js

@@ -931,3 +931,3 @@ const { nv, NumericValue, calculateBodyLength, _parseEpochTimestamp, fromBase64, generateIdempotencyToken } = require("@smithy/core/serde");

}
catch (e) { }
catch (ignored) { }
}

@@ -1181,3 +1181,3 @@ return new HttpRequest(contents);

}
catch (e) { }
catch (ignored) { }
}

@@ -1214,3 +1214,3 @@ const { service, operation } = getSmithyContext(context);

}
catch (e) {
catch (ignored) {
if (dataObject.Message) {

@@ -1217,0 +1217,0 @@ dataObject.message = dataObject.Message;

@@ -248,3 +248,3 @@ const { normalizeProvider } = require("@smithy/core/client");

const partition = getResolvedPartition(region, { partitionHash });
const resolvedRegion = region in regionHash ? region : partitionHash[partition]?.endpoint ?? region;
const resolvedRegion = region in regionHash ? region : (partitionHash[partition]?.endpoint ?? region);
const hostnameOptions = { useFipsEndpoint, useDualstackEndpoint };

@@ -295,3 +295,3 @@ const regionHostname = getHostnameFromVariants(regionHash[resolvedRegion]?.variants, hostnameOptions);

if (navigator?.connection) {
const { effectiveType, rtt, downlink } = navigator?.connection;
const { effectiveType, rtt, downlink } = navigator.connection;
const slow = (typeof effectiveType === "string" && effectiveType !== "4g") || Number(rtt) > 100 || Number(downlink) < 10;

@@ -298,0 +298,0 @@ if (slow) {

@@ -210,3 +210,3 @@ const { homedir } = require("node:os");

const prefixKeyRegex = /^([\w-]+)\s(["'])?([\w-@\+\.%:/]+)\2$/;
const prefixKeyRegex = /^([\w-]+)\s(["'])?([\w-@+.%:/]+)\2$/;
const profileNameBlockList = ["__proto__", "profile __proto__"];

@@ -359,3 +359,3 @@ const parseIni = (iniData) => {

}
catch (e) {
catch (ignored) {
return functionString;

@@ -664,3 +664,3 @@ }

const partition = getResolvedPartition(region, { partitionHash });
const resolvedRegion = region in regionHash ? region : partitionHash[partition]?.endpoint ?? region;
const resolvedRegion = region in regionHash ? region : (partitionHash[partition]?.endpoint ?? region);
const hostnameOptions = { useFipsEndpoint, useDualstackEndpoint };

@@ -667,0 +667,0 @@ const regionHostname = getHostnameFromVariants(regionHash[resolvedRegion]?.variants, hostnameOptions);

@@ -248,3 +248,3 @@ const { normalizeProvider } = require("@smithy/core/client");

const partition = getResolvedPartition(region, { partitionHash });
const resolvedRegion = region in regionHash ? region : partitionHash[partition]?.endpoint ?? region;
const resolvedRegion = region in regionHash ? region : (partitionHash[partition]?.endpoint ?? region);
const hostnameOptions = { useFipsEndpoint, useDualstackEndpoint };

@@ -251,0 +251,0 @@ const regionHostname = getHostnameFromVariants(regionHash[resolvedRegion]?.variants, hostnameOptions);

@@ -31,3 +31,3 @@ const { toEndpointV1, getSmithyContext, normalizeProvider, isValidHostLabel } = require("@smithy/core/transport");

};
const DOMAIN_PATTERN = /^[a-z0-9][a-z0-9\.\-]{1,61}[a-z0-9]$/;
const DOMAIN_PATTERN = /^[a-z0-9][a-z0-9.-]{1,61}[a-z0-9]$/;
const IP_ADDRESS_PATTERN = /(\d+\.){3}\d+/;

@@ -421,3 +421,3 @@ const DOTS_PATTERN = /\.\./;

}
catch (error) {
catch (ignored) {
return null;

@@ -424,0 +424,0 @@ }

@@ -63,3 +63,3 @@ const { CONFIG_PREFIX_SEPARATOR, loadConfig } = require("@smithy/core/config");

};
const DOMAIN_PATTERN = /^[a-z0-9][a-z0-9\.\-]{1,61}[a-z0-9]$/;
const DOMAIN_PATTERN = /^[a-z0-9][a-z0-9.-]{1,61}[a-z0-9]$/;
const IP_ADDRESS_PATTERN = /(\d+\.){3}\d+/;

@@ -453,3 +453,3 @@ const DOTS_PATTERN = /\.\./;

}
catch (error) {
catch (ignored) {
return null;

@@ -456,0 +456,0 @@ }

@@ -72,8 +72,8 @@ const { Crc32 } = require("@smithy/core/checksum");

case "boolean":
return Uint8Array.from([header.value ? 0 : 1]);
return Uint8Array.from([header.value ? HEADER_VALUE_TYPE.boolTrue : HEADER_VALUE_TYPE.boolFalse]);
case "byte":
return Uint8Array.from([2, header.value]);
return Uint8Array.from([HEADER_VALUE_TYPE.byte, header.value]);
case "short":
const shortView = new DataView(new ArrayBuffer(3));
shortView.setUint8(0, 3);
shortView.setUint8(0, HEADER_VALUE_TYPE.short);
shortView.setInt16(1, header.value, false);

@@ -83,3 +83,3 @@ return new Uint8Array(shortView.buffer);

const intView = new DataView(new ArrayBuffer(5));
intView.setUint8(0, 4);
intView.setUint8(0, HEADER_VALUE_TYPE.integer);
intView.setInt32(1, header.value, false);

@@ -89,3 +89,3 @@ return new Uint8Array(intView.buffer);

const longBytes = new Uint8Array(9);
longBytes[0] = 5;
longBytes[0] = HEADER_VALUE_TYPE.long;
longBytes.set(header.value.bytes, 1);

@@ -95,3 +95,3 @@ return longBytes;

const binView = new DataView(new ArrayBuffer(3 + header.value.byteLength));
binView.setUint8(0, 6);
binView.setUint8(0, HEADER_VALUE_TYPE.byteArray);
binView.setUint16(1, header.value.byteLength, false);

@@ -104,3 +104,3 @@ const binBytes = new Uint8Array(binView.buffer);

const strView = new DataView(new ArrayBuffer(3 + utf8Bytes.byteLength));
strView.setUint8(0, 7);
strView.setUint8(0, HEADER_VALUE_TYPE.string);
strView.setUint16(1, utf8Bytes.byteLength, false);

@@ -112,3 +112,3 @@ const strBytes = new Uint8Array(strView.buffer);

const tsBytes = new Uint8Array(9);
tsBytes[0] = 8;
tsBytes[0] = HEADER_VALUE_TYPE.timestamp;
tsBytes.set(Int64.fromNumber(header.value.valueOf()).bytes, 1);

@@ -121,4 +121,4 @@ return tsBytes;

const uuidBytes = new Uint8Array(17);
uuidBytes[0] = 9;
uuidBytes.set(fromHex(header.value.replace(/\-/g, "")), 1);
uuidBytes[0] = HEADER_VALUE_TYPE.uuid;
uuidBytes.set(fromHex(header.value.replace(/-/g, "")), 1);
return uuidBytes;

@@ -135,3 +135,3 @@ }

switch (headers.getUint8(position++)) {
case 0:
case HEADER_VALUE_TYPE.boolTrue:
out[name] = {

@@ -142,3 +142,3 @@ type: BOOLEAN_TAG,

break;
case 1:
case HEADER_VALUE_TYPE.boolFalse:
out[name] = {

@@ -149,3 +149,3 @@ type: BOOLEAN_TAG,

break;
case 2:
case HEADER_VALUE_TYPE.byte:
out[name] = {

@@ -156,3 +156,3 @@ type: BYTE_TAG,

break;
case 3:
case HEADER_VALUE_TYPE.short:
out[name] = {

@@ -164,3 +164,3 @@ type: SHORT_TAG,

break;
case 4:
case HEADER_VALUE_TYPE.integer:
out[name] = {

@@ -172,3 +172,3 @@ type: INT_TAG,

break;
case 5:
case HEADER_VALUE_TYPE.long:
out[name] = {

@@ -180,3 +180,3 @@ type: LONG_TAG,

break;
case 6:
case HEADER_VALUE_TYPE.byteArray:
const binaryLength = headers.getUint16(position, false);

@@ -190,3 +190,3 @@ position += 2;

break;
case 7:
case HEADER_VALUE_TYPE.string:
const stringLength = headers.getUint16(position, false);

@@ -200,3 +200,3 @@ position += 2;

break;
case 8:
case HEADER_VALUE_TYPE.timestamp:
out[name] = {

@@ -208,3 +208,3 @@ type: TIMESTAMP_TAG,

break;
case 9:
case HEADER_VALUE_TYPE.uuid:
const uuidBytes = new Uint8Array(headers.buffer, headers.byteOffset + position, 16);

@@ -211,0 +211,0 @@ position += 16;

@@ -73,8 +73,8 @@ const { Crc32 } = require("@smithy/core/checksum");

case "boolean":
return Uint8Array.from([header.value ? 0 : 1]);
return Uint8Array.from([header.value ? HEADER_VALUE_TYPE.boolTrue : HEADER_VALUE_TYPE.boolFalse]);
case "byte":
return Uint8Array.from([2, header.value]);
return Uint8Array.from([HEADER_VALUE_TYPE.byte, header.value]);
case "short":
const shortView = new DataView(new ArrayBuffer(3));
shortView.setUint8(0, 3);
shortView.setUint8(0, HEADER_VALUE_TYPE.short);
shortView.setInt16(1, header.value, false);

@@ -84,3 +84,3 @@ return new Uint8Array(shortView.buffer);

const intView = new DataView(new ArrayBuffer(5));
intView.setUint8(0, 4);
intView.setUint8(0, HEADER_VALUE_TYPE.integer);
intView.setInt32(1, header.value, false);

@@ -90,3 +90,3 @@ return new Uint8Array(intView.buffer);

const longBytes = new Uint8Array(9);
longBytes[0] = 5;
longBytes[0] = HEADER_VALUE_TYPE.long;
longBytes.set(header.value.bytes, 1);

@@ -96,3 +96,3 @@ return longBytes;

const binView = new DataView(new ArrayBuffer(3 + header.value.byteLength));
binView.setUint8(0, 6);
binView.setUint8(0, HEADER_VALUE_TYPE.byteArray);
binView.setUint16(1, header.value.byteLength, false);

@@ -105,3 +105,3 @@ const binBytes = new Uint8Array(binView.buffer);

const strView = new DataView(new ArrayBuffer(3 + utf8Bytes.byteLength));
strView.setUint8(0, 7);
strView.setUint8(0, HEADER_VALUE_TYPE.string);
strView.setUint16(1, utf8Bytes.byteLength, false);

@@ -113,3 +113,3 @@ const strBytes = new Uint8Array(strView.buffer);

const tsBytes = new Uint8Array(9);
tsBytes[0] = 8;
tsBytes[0] = HEADER_VALUE_TYPE.timestamp;
tsBytes.set(Int64.fromNumber(header.value.valueOf()).bytes, 1);

@@ -122,4 +122,4 @@ return tsBytes;

const uuidBytes = new Uint8Array(17);
uuidBytes[0] = 9;
uuidBytes.set(fromHex(header.value.replace(/\-/g, "")), 1);
uuidBytes[0] = HEADER_VALUE_TYPE.uuid;
uuidBytes.set(fromHex(header.value.replace(/-/g, "")), 1);
return uuidBytes;

@@ -136,3 +136,3 @@ }

switch (headers.getUint8(position++)) {
case 0:
case HEADER_VALUE_TYPE.boolTrue:
out[name] = {

@@ -143,3 +143,3 @@ type: BOOLEAN_TAG,

break;
case 1:
case HEADER_VALUE_TYPE.boolFalse:
out[name] = {

@@ -150,3 +150,3 @@ type: BOOLEAN_TAG,

break;
case 2:
case HEADER_VALUE_TYPE.byte:
out[name] = {

@@ -157,3 +157,3 @@ type: BYTE_TAG,

break;
case 3:
case HEADER_VALUE_TYPE.short:
out[name] = {

@@ -165,3 +165,3 @@ type: SHORT_TAG,

break;
case 4:
case HEADER_VALUE_TYPE.integer:
out[name] = {

@@ -173,3 +173,3 @@ type: INT_TAG,

break;
case 5:
case HEADER_VALUE_TYPE.long:
out[name] = {

@@ -181,3 +181,3 @@ type: LONG_TAG,

break;
case 6:
case HEADER_VALUE_TYPE.byteArray:
const binaryLength = headers.getUint16(position, false);

@@ -191,3 +191,3 @@ position += 2;

break;
case 7:
case HEADER_VALUE_TYPE.string:
const stringLength = headers.getUint16(position, false);

@@ -201,3 +201,3 @@ position += 2;

break;
case 8:
case HEADER_VALUE_TYPE.timestamp:
out[name] = {

@@ -209,3 +209,3 @@ type: TIMESTAMP_TAG,

break;
case 9:
case HEADER_VALUE_TYPE.uuid:
const uuidBytes = new Uint8Array(headers.buffer, headers.byteOffset + position, 16);

@@ -212,0 +212,0 @@ position += 16;

@@ -968,3 +968,3 @@ const { Uint8ArrayBlobAdapter, sdkStreamMixin, splitEvery, splitHeader, fromBase64, _parseEpochTimestamp, _parseRfc7231DateTime, _parseRfc3339DateTimeWithOffset, LazyJsonString, NumericValue, toUtf8, fromUtf8, generateIdempotencyToken, toBase64, dateToUtcString, quoteHeader } = require("@smithy/core/serde");

}
catch (error) {
catch (ignored) {
}

@@ -971,0 +971,0 @@ }

@@ -184,3 +184,3 @@ const { NoOpLogger, normalizeProvider } = require("@smithy/core/client");

}
catch (refreshError) {
catch (ignoredRefreshError) {
if (!lastError.$metadata) {

@@ -503,3 +503,3 @@ lastError.$metadata = {};

}
catch (error) {
catch (ignored) {
console.warn(`Max attempts provider could not resolve. Using default of ${DEFAULT_MAX_ATTEMPTS}`);

@@ -631,3 +631,3 @@ return DEFAULT_MAX_ATTEMPTS;

}
catch (error) {
catch (ignored) {
maxAttempts = DEFAULT_MAX_ATTEMPTS;

@@ -634,0 +634,0 @@ }

@@ -186,3 +186,3 @@ const { Readable } = require("node:stream");

}
catch (refreshError) {
catch (ignoredRefreshError) {
if (!lastError.$metadata) {

@@ -505,3 +505,3 @@ lastError.$metadata = {};

}
catch (error) {
catch (ignored) {
console.warn(`Max attempts provider could not resolve. Using default of ${DEFAULT_MAX_ATTEMPTS}`);

@@ -633,3 +633,3 @@ return DEFAULT_MAX_ATTEMPTS;

}
catch (error) {
catch (ignored) {
maxAttempts = DEFAULT_MAX_ATTEMPTS;

@@ -636,0 +636,0 @@ }

@@ -44,3 +44,3 @@ const { getSmithyContext, HttpResponse, toEndpointV1 } = require("@smithy/core/transport");

}
catch (e) {
catch (ignored) {
if (!context.logger || context.logger?.constructor?.name === "NoOpLogger") {

@@ -70,3 +70,3 @@ console.warn(hint);

}
catch (e) {
catch (ignored) {
}

@@ -210,3 +210,3 @@ }

}
const error = (namespace, name, traits, memberNames, memberList, ctor) => Schema.assign(new ErrorSchema(), {
const error = (namespace, name, traits, memberNames, memberList, _ctor) => Schema.assign(new ErrorSchema(), {
name,

@@ -463,3 +463,3 @@ namespace,

? 15
: schema[4] ?? 0;
: (schema[4] ?? 0);
return member([memberSchema, 0], "key");

@@ -466,0 +466,0 @@ }

@@ -153,3 +153,3 @@ const { HttpResponse } = require("@smithy/core/transport");

const copyDocumentWithTransform = (source, schemaRef, transform = (_) => _) => source;
const copyDocumentWithTransform = (source, _schemaRef, _transform = (_) => _) => source;

@@ -424,3 +424,3 @@ const parseBoolean = (value) => {

};
const RFC3339_WITH_OFFSET$1 = new RegExp(/^(\d{4})-(\d{2})-(\d{2})[tT](\d{2}):(\d{2}):(\d{2})(?:\.(\d+))?(([-+]\d{2}\:\d{2})|[zZ])$/);
const RFC3339_WITH_OFFSET$1 = new RegExp(/^(\d{4})-(\d{2})-(\d{2})[tT](\d{2}):(\d{2}):(\d{2})(?:\.(\d+))?(([-+]\d{2}:\d{2})|[zZ])$/);
const parseRfc3339DateTimeWithOffset = (value) => {

@@ -920,3 +920,3 @@ if (value === null || value === undefined) {

}
catch (e) {
catch (ignored) {
if (!context.logger || context.logger?.constructor?.name === "NoOpLogger") {

@@ -946,3 +946,3 @@ console.warn(hint);

}
catch (e) {
catch (ignored) {
}

@@ -949,0 +949,0 @@ }

@@ -121,3 +121,3 @@ const { createHmac, createHash, getRandomValues } = require("node:crypto");

const copyDocumentWithTransform = (source, schemaRef, transform = (_) => _) => source;
const copyDocumentWithTransform = (source, _schemaRef, _transform = (_) => _) => source;

@@ -392,3 +392,3 @@ const parseBoolean = (value) => {

};
const RFC3339_WITH_OFFSET$1 = new RegExp(/^(\d{4})-(\d{2})-(\d{2})[tT](\d{2}):(\d{2}):(\d{2})(?:\.(\d+))?(([-+]\d{2}\:\d{2})|[zZ])$/);
const RFC3339_WITH_OFFSET$1 = new RegExp(/^(\d{4})-(\d{2})-(\d{2})[tT](\d{2}):(\d{2}):(\d{2})(?:\.(\d+))?(([-+]\d{2}:\d{2})|[zZ])$/);
const parseRfc3339DateTimeWithOffset = (value) => {

@@ -885,3 +885,3 @@ if (value === null || value === undefined) {

}
catch (e) {
catch (ignored) {
if (!context.logger || context.logger?.constructor?.name === "NoOpLogger") {

@@ -911,3 +911,3 @@ console.warn(hint);

}
catch (e) {
catch (ignored) {
}

@@ -1602,3 +1602,3 @@ }

}
catch (e) {
catch (ignored) {
const name = stream?.__proto__?.constructor?.name || stream;

@@ -1605,0 +1605,0 @@ throw new Error(`Unexpected stream implementation, expect Stream.Readable instance, got ${name}`);

@@ -153,3 +153,3 @@ const { HttpResponse } = require("@smithy/core/transport");

const copyDocumentWithTransform = (source, schemaRef, transform = (_) => _) => source;
const copyDocumentWithTransform = (source, _schemaRef, _transform = (_) => _) => source;

@@ -424,3 +424,3 @@ const parseBoolean = (value) => {

};
const RFC3339_WITH_OFFSET$1 = new RegExp(/^(\d{4})-(\d{2})-(\d{2})[tT](\d{2}):(\d{2}):(\d{2})(?:\.(\d+))?(([-+]\d{2}\:\d{2})|[zZ])$/);
const RFC3339_WITH_OFFSET$1 = new RegExp(/^(\d{4})-(\d{2})-(\d{2})[tT](\d{2}):(\d{2}):(\d{2})(?:\.(\d+))?(([-+]\d{2}:\d{2})|[zZ])$/);
const parseRfc3339DateTimeWithOffset = (value) => {

@@ -920,3 +920,3 @@ if (value === null || value === undefined) {

}
catch (e) {
catch (ignored) {
if (!context.logger || context.logger?.constructor?.name === "NoOpLogger") {

@@ -946,3 +946,3 @@ console.warn(hint);

}
catch (e) {
catch (ignored) {
}

@@ -949,0 +949,0 @@ }

@@ -104,3 +104,3 @@ const { SMITHY_CONTEXT_KEY } = require("@smithy/types");

function isValidHostname(hostname) {
const hostPattern = /^[a-z0-9][a-z0-9\.\-]*[a-z0-9]$/;
const hostPattern = /^[a-z0-9][a-z0-9.-]*[a-z0-9]$/;
return hostPattern.test(hostname);

@@ -107,0 +107,0 @@ }

@@ -94,5 +94,5 @@ import { HttpRequest as __HttpRequest, collectBody } from "@smithy/core/protocols";

}
catch (e) { }
catch (ignored) { }
}
return new __HttpRequest(contents);
};

@@ -38,3 +38,3 @@ import { RpcProtocol } from "@smithy/core/protocols";

}
catch (e) { }
catch (ignored) { }
}

@@ -71,3 +71,3 @@ const { service, operation } = getSmithyContext(context);

}
catch (e) {
catch (ignored) {
if (dataObject.Message) {

@@ -74,0 +74,0 @@ dataObject.message = dataObject.Message;

@@ -7,3 +7,3 @@ import { getHostnameFromVariants } from "./getHostnameFromVariants";

const partition = getResolvedPartition(region, { partitionHash });
const resolvedRegion = region in regionHash ? region : partitionHash[partition]?.endpoint ?? region;
const resolvedRegion = region in regionHash ? region : (partitionHash[partition]?.endpoint ?? region);
const hostnameOptions = { useFipsEndpoint, useDualstackEndpoint };

@@ -10,0 +10,0 @@ const regionHostname = getHostnameFromVariants(regionHash[resolvedRegion]?.variants, hostnameOptions);

@@ -23,3 +23,3 @@ import { memoize } from "../property-provider/memoize";

if (navigator?.connection) {
const { effectiveType, rtt, downlink } = navigator?.connection;
const { effectiveType, rtt, downlink } = navigator.connection;
const slow = (typeof effectiveType === "string" && effectiveType !== "4g") || Number(rtt) > 100 || Number(downlink) < 10;

@@ -26,0 +26,0 @@ if (slow) {

@@ -9,5 +9,5 @@ export function getSelectorName(functionString) {

}
catch (e) {
catch (ignored) {
return functionString;
}
}
import { IniSectionType } from "@smithy/types";
import { CONFIG_PREFIX_SEPARATOR } from "./constants";
const prefixKeyRegex = /^([\w-]+)\s(["'])?([\w-@\+\.%:/]+)\2$/;
const prefixKeyRegex = /^([\w-]+)\s(["'])?([\w-@+.%:/]+)\2$/;
const profileNameBlockList = ["__proto__", "profile __proto__"];

@@ -5,0 +5,0 @@ export const parseIni = (iniData) => {

@@ -23,3 +23,3 @@ export const resolveParamsForS3 = async (endpointParams) => {

};
const DOMAIN_PATTERN = /^[a-z0-9][a-z0-9\.\-]{1,61}[a-z0-9]$/;
const DOMAIN_PATTERN = /^[a-z0-9][a-z0-9.-]{1,61}[a-z0-9]$/;
const IP_ADDRESS_PATTERN = /(\d+\.){3}\d+/;

@@ -26,0 +26,0 @@ const DOTS_PATTERN = /\.\./;

@@ -23,3 +23,3 @@ import { EndpointURLScheme } from "@smithy/types";

}
catch (error) {
catch (ignored) {
return null;

@@ -26,0 +26,0 @@ }

@@ -27,8 +27,8 @@ import { fromHex, toHex } from "@smithy/core/serde";

case "boolean":
return Uint8Array.from([header.value ? 0 : 1]);
return Uint8Array.from([header.value ? HEADER_VALUE_TYPE.boolTrue : HEADER_VALUE_TYPE.boolFalse]);
case "byte":
return Uint8Array.from([2, header.value]);
return Uint8Array.from([HEADER_VALUE_TYPE.byte, header.value]);
case "short":
const shortView = new DataView(new ArrayBuffer(3));
shortView.setUint8(0, 3);
shortView.setUint8(0, HEADER_VALUE_TYPE.short);
shortView.setInt16(1, header.value, false);

@@ -38,3 +38,3 @@ return new Uint8Array(shortView.buffer);

const intView = new DataView(new ArrayBuffer(5));
intView.setUint8(0, 4);
intView.setUint8(0, HEADER_VALUE_TYPE.integer);
intView.setInt32(1, header.value, false);

@@ -44,3 +44,3 @@ return new Uint8Array(intView.buffer);

const longBytes = new Uint8Array(9);
longBytes[0] = 5;
longBytes[0] = HEADER_VALUE_TYPE.long;
longBytes.set(header.value.bytes, 1);

@@ -50,3 +50,3 @@ return longBytes;

const binView = new DataView(new ArrayBuffer(3 + header.value.byteLength));
binView.setUint8(0, 6);
binView.setUint8(0, HEADER_VALUE_TYPE.byteArray);
binView.setUint16(1, header.value.byteLength, false);

@@ -59,3 +59,3 @@ const binBytes = new Uint8Array(binView.buffer);

const strView = new DataView(new ArrayBuffer(3 + utf8Bytes.byteLength));
strView.setUint8(0, 7);
strView.setUint8(0, HEADER_VALUE_TYPE.string);
strView.setUint16(1, utf8Bytes.byteLength, false);

@@ -67,3 +67,3 @@ const strBytes = new Uint8Array(strView.buffer);

const tsBytes = new Uint8Array(9);
tsBytes[0] = 8;
tsBytes[0] = HEADER_VALUE_TYPE.timestamp;
tsBytes.set(Int64.fromNumber(header.value.valueOf()).bytes, 1);

@@ -76,4 +76,4 @@ return tsBytes;

const uuidBytes = new Uint8Array(17);
uuidBytes[0] = 9;
uuidBytes.set(fromHex(header.value.replace(/\-/g, "")), 1);
uuidBytes[0] = HEADER_VALUE_TYPE.uuid;
uuidBytes.set(fromHex(header.value.replace(/-/g, "")), 1);
return uuidBytes;

@@ -90,3 +90,3 @@ }

switch (headers.getUint8(position++)) {
case 0:
case HEADER_VALUE_TYPE.boolTrue:
out[name] = {

@@ -97,3 +97,3 @@ type: BOOLEAN_TAG,

break;
case 1:
case HEADER_VALUE_TYPE.boolFalse:
out[name] = {

@@ -104,3 +104,3 @@ type: BOOLEAN_TAG,

break;
case 2:
case HEADER_VALUE_TYPE.byte:
out[name] = {

@@ -111,3 +111,3 @@ type: BYTE_TAG,

break;
case 3:
case HEADER_VALUE_TYPE.short:
out[name] = {

@@ -119,3 +119,3 @@ type: SHORT_TAG,

break;
case 4:
case HEADER_VALUE_TYPE.integer:
out[name] = {

@@ -127,3 +127,3 @@ type: INT_TAG,

break;
case 5:
case HEADER_VALUE_TYPE.long:
out[name] = {

@@ -135,3 +135,3 @@ type: LONG_TAG,

break;
case 6:
case HEADER_VALUE_TYPE.byteArray:
const binaryLength = headers.getUint16(position, false);

@@ -145,3 +145,3 @@ position += 2;

break;
case 7:
case HEADER_VALUE_TYPE.string:
const stringLength = headers.getUint16(position, false);

@@ -155,3 +155,3 @@ position += 2;

break;
case 8:
case HEADER_VALUE_TYPE.timestamp:
out[name] = {

@@ -163,3 +163,3 @@ type: TIMESTAMP_TAG,

break;
case 9:
case HEADER_VALUE_TYPE.uuid:
const uuidBytes = new Uint8Array(headers.buffer, headers.byteOffset + position, 16);

@@ -166,0 +166,0 @@ position += 16;

@@ -19,3 +19,3 @@ import { HttpRequest } from "@smithy/core/transport";

}
catch (error) {
catch (ignored) {
}

@@ -22,0 +22,0 @@ }

@@ -30,3 +30,3 @@ import { HttpRequest, HttpResponse } from "@smithy/core/protocols";

}
catch (error) {
catch (ignored) {
maxAttempts = DEFAULT_MAX_ATTEMPTS;

@@ -33,0 +33,0 @@ }

@@ -44,3 +44,3 @@ import { NoOpLogger } from "@smithy/core/client";

}
catch (refreshError) {
catch (ignoredRefreshError) {
if (!lastError.$metadata) {

@@ -47,0 +47,0 @@ lastError.$metadata = {};

@@ -79,3 +79,3 @@ import { DefaultRetryBackoffStrategy } from "./DefaultRetryBackoffStrategy";

}
catch (error) {
catch (ignored) {
console.warn(`Max attempts provider could not resolve. Using default of ${DEFAULT_MAX_ATTEMPTS}`);

@@ -82,0 +82,0 @@ return DEFAULT_MAX_ATTEMPTS;

@@ -29,3 +29,3 @@ import { HttpResponse, getSmithyContext } from "@smithy/core/transport";

}
catch (e) {
catch (ignored) {
if (!context.logger || context.logger?.constructor?.name === "NoOpLogger") {

@@ -55,3 +55,3 @@ console.warn(hint);

}
catch (e) {
catch (ignored) {
}

@@ -58,0 +58,0 @@ }

@@ -8,3 +8,3 @@ import { Schema } from "./Schema";

}
export const error = (namespace, name, traits, memberNames, memberList, ctor) => Schema.assign(new ErrorSchema(), {
export const error = (namespace, name, traits, memberNames, memberList, _ctor) => Schema.assign(new ErrorSchema(), {
name,

@@ -11,0 +11,0 @@ namespace,

@@ -219,3 +219,3 @@ import { deref } from "../deref";

? 15
: schema[4] ?? 0;
: (schema[4] ?? 0);
return member([memberSchema, 0], "key");

@@ -222,0 +222,0 @@ }

@@ -1,1 +0,1 @@

export const copyDocumentWithTransform = (source, schemaRef, transform = (_) => _) => source;
export const copyDocumentWithTransform = (source, _schemaRef, _transform = (_) => _) => source;

@@ -36,3 +36,3 @@ import { strictParseByte, strictParseDouble, strictParseFloat32, strictParseShort } from "./parse-utils";

};
const RFC3339_WITH_OFFSET = new RegExp(/^(\d{4})-(\d{2})-(\d{2})[tT](\d{2}):(\d{2}):(\d{2})(?:\.(\d+))?(([-+]\d{2}\:\d{2})|[zZ])$/);
const RFC3339_WITH_OFFSET = new RegExp(/^(\d{4})-(\d{2})-(\d{2})[tT](\d{2}):(\d{2}):(\d{2})(?:\.(\d+))?(([-+]\d{2}:\d{2})|[zZ])$/);
export const parseRfc3339DateTimeWithOffset = (value) => {

@@ -39,0 +39,0 @@ if (value === null || value === undefined) {

@@ -23,3 +23,3 @@ import { HttpResponse } from "@smithy/core/transport";

}
catch (e) {
catch (ignored) {
if (!context.logger || context.logger?.constructor?.name === "NoOpLogger") {

@@ -49,3 +49,3 @@ console.warn(hint);

}
catch (e) {
catch (ignored) {
}

@@ -52,0 +52,0 @@ }

@@ -11,3 +11,3 @@ import { Readable } from "node:stream";

}
catch (e) {
catch (ignored) {
const name = stream?.__proto__?.constructor?.name || stream;

@@ -14,0 +14,0 @@ throw new Error(`Unexpected stream implementation, expect Stream.Readable instance, got ${name}`);

export function isValidHostname(hostname) {
const hostPattern = /^[a-z0-9][a-z0-9\.\-]*[a-z0-9]$/;
const hostPattern = /^[a-z0-9][a-z0-9.-]*[a-z0-9]$/;
return hostPattern.test(hostname);
}

@@ -31,3 +31,3 @@ import type { SchemaRef, SchemaTraits } from "@smithy/types";

* @param memberList - list of schemaRef corresponding to each
* @param ctor - class reference for the existing Error extending class.
* @param _ctor - class reference for the existing Error extending class.
*/

@@ -38,2 +38,2 @@ export declare const error: (namespace: string, name: string, traits: SchemaTraits, memberNames: string[], memberList: SchemaRef[],

*/
ctor?: any) => ErrorSchema;
_ctor?: any) => ErrorSchema;

@@ -6,2 +6,2 @@ import type { SchemaRef } from "@smithy/types";

*/
export declare const copyDocumentWithTransform: (source: any, schemaRef: SchemaRef, transform?: (_: any, schemaRef: SchemaRef) => any) => any;
export declare const copyDocumentWithTransform: (source: any, _schemaRef: SchemaRef, _transform?: (_: any, schemaRef: SchemaRef) => any) => any;

@@ -31,3 +31,3 @@ import { SchemaRef, SchemaTraits } from "@smithy/types";

* @param memberList - list of schemaRef corresponding to each
* @param ctor - class reference for the existing Error extending class.
* @param _ctor - class reference for the existing Error extending class.
*/

@@ -38,2 +38,2 @@ export declare const error: (namespace: string, name: string, traits: SchemaTraits, memberNames: string[], memberList: SchemaRef[],

*/
ctor?: any) => ErrorSchema;
_ctor?: any) => ErrorSchema;

@@ -6,2 +6,2 @@ import { SchemaRef } from "@smithy/types";

*/
export declare const copyDocumentWithTransform: (source: any, schemaRef: SchemaRef, transform?: (_: any, schemaRef: SchemaRef) => any) => any;
export declare const copyDocumentWithTransform: (source: any, _schemaRef: SchemaRef, _transform?: (_: any, schemaRef: SchemaRef) => any) => any;
{
"name": "@smithy/core",
"version": "3.29.3",
"version": "3.29.4",
"scripts": {

@@ -8,3 +8,3 @@ "benchmark:cbor": "node ./scripts/cbor-perf.mjs",

"build": "concurrently 'yarn:build:types' 'yarn:build:es:cjs'",
"build:es:cjs": "premove dist-es && yarn g:tsc -p tsconfig.es.json && node ../../scripts/inline",
"build:es:cjs": "node ../../scripts/compilation/es_cjs.js",
"build:types": "premove dist-types && yarn g:tsc -p tsconfig.types.json",

@@ -14,3 +14,2 @@ "build:types:downlevel": "premove dist-types/ts3.4 && downlevel-dts dist-types dist-types/ts3.4",

"extract:docs": "api-extractor run --local",
"format": "prettier --config ../../prettier.config.js --ignore-path ../../.prettierignore --write \"**/*.{ts,md,json}\"",
"lint": "node ../../scripts/validation/submodules-linter.js",

@@ -194,2 +193,5 @@ "prebuild": "yarn lint",

"dist-types/ts3.4/*"
],
"*": [
"dist-types/ts3.4/submodules/*/index.d.ts"
]

@@ -196,0 +198,0 @@ }