@aws-sdk/middleware-signing
Advanced tools
Comparing version 3.714.0 to 3.723.0
@@ -80,3 +80,3 @@ "use strict"; | ||
); | ||
const isSigv4a = (authScheme == null ? void 0 : authScheme.name) === "sigv4a"; | ||
const isSigv4a = authScheme?.name === "sigv4a"; | ||
const signingRegion = authScheme.signingRegion; | ||
@@ -182,3 +182,2 @@ const signingService = authScheme.signingName; | ||
var awsAuthMiddleware = /* @__PURE__ */ __name((options) => (next, context) => async function(args) { | ||
var _a, _b, _c, _d, _e, _f, _g; | ||
if (!import_protocol_http.HttpRequest.isInstance(args.request)) | ||
@@ -188,5 +187,5 @@ return next(args); | ||
let signer; | ||
const firstAuthScheme = (_c = (_b = (_a = context.endpointV2) == null ? void 0 : _a.properties) == null ? void 0 : _b.authSchemes) == null ? void 0 : _c[0]; | ||
const secondAuthScheme = (_f = (_e = (_d = context.endpointV2) == null ? void 0 : _d.properties) == null ? void 0 : _e.authSchemes) == null ? void 0 : _f[1]; | ||
const firstAuthSchemeIsSigv4a = (firstAuthScheme == null ? void 0 : firstAuthScheme.name) === "sigv4a"; | ||
const firstAuthScheme = context.endpointV2?.properties?.authSchemes?.[0]; | ||
const secondAuthScheme = context.endpointV2?.properties?.authSchemes?.[1]; | ||
const firstAuthSchemeIsSigv4a = firstAuthScheme?.name === "sigv4a"; | ||
if (firstAuthSchemeIsSigv4a && secondAuthScheme) { | ||
@@ -196,5 +195,4 @@ signer = await options.signer(authScheme = firstAuthScheme); | ||
const sigv4aAvailable = (() => { | ||
var _a2; | ||
if (typeof (uncheckedSigner == null ? void 0 : uncheckedSigner.getSigv4aSigner) === "function") { | ||
if (((_a2 = uncheckedSigner == null ? void 0 : uncheckedSigner.signerOptions) == null ? void 0 : _a2.runtime) !== "node") { | ||
if (typeof uncheckedSigner?.getSigv4aSigner === "function") { | ||
if (uncheckedSigner?.signerOptions?.runtime !== "node") { | ||
return false; | ||
@@ -217,3 +215,3 @@ } | ||
let signedRequest; | ||
const multiRegionOverride = (authScheme == null ? void 0 : authScheme.name) === "sigv4a" ? (_g = authScheme == null ? void 0 : authScheme.signingRegionSet) == null ? void 0 : _g.join(",") : void 0; | ||
const multiRegionOverride = authScheme?.name === "sigv4a" ? authScheme?.signingRegionSet?.join(",") : void 0; | ||
const signingOptions = { | ||
@@ -253,6 +251,3 @@ signingDate: getSkewCorrectedDate(options.systemClockOffset), | ||
}, "awsAuthMiddleware"); | ||
var getDateHeader = /* @__PURE__ */ __name((response) => { | ||
var _a, _b; | ||
return import_protocol_http.HttpResponse.isInstance(response) ? ((_a = response.headers) == null ? void 0 : _a.date) ?? ((_b = response.headers) == null ? void 0 : _b.Date) : void 0; | ||
}, "getDateHeader"); | ||
var getDateHeader = /* @__PURE__ */ __name((response) => import_protocol_http.HttpResponse.isInstance(response) ? response.headers?.date ?? response.headers?.Date : void 0, "getDateHeader"); | ||
var awsAuthMiddlewareOptions = { | ||
@@ -259,0 +254,0 @@ name: "awsAuthMiddleware", |
{ | ||
"name": "@aws-sdk/middleware-signing", | ||
"version": "3.714.0", | ||
"version": "3.723.0", | ||
"scripts": { | ||
@@ -27,12 +27,12 @@ "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'", | ||
"dependencies": { | ||
"@aws-sdk/types": "3.714.0", | ||
"@smithy/property-provider": "^3.1.11", | ||
"@smithy/protocol-http": "^4.1.8", | ||
"@smithy/signature-v4": "^4.2.4", | ||
"@smithy/types": "^3.7.2", | ||
"@smithy/util-middleware": "^3.0.11", | ||
"@aws-sdk/types": "3.723.0", | ||
"@smithy/property-provider": "^4.0.0", | ||
"@smithy/protocol-http": "^5.0.0", | ||
"@smithy/signature-v4": "^5.0.0", | ||
"@smithy/types": "^4.0.0", | ||
"@smithy/util-middleware": "^4.0.0", | ||
"tslib": "^2.6.2" | ||
}, | ||
"engines": { | ||
"node": ">=16.0.0" | ||
"node": ">=18.0.0" | ||
}, | ||
@@ -60,4 +60,4 @@ "typesVersions": { | ||
"rimraf": "3.0.2", | ||
"typescript": "~4.9.5" | ||
"typescript": "~5.2.2" | ||
} | ||
} |
42292
740
+ Added@aws-sdk/types@3.723.0(transitive)
+ Added@smithy/is-array-buffer@4.0.0(transitive)
+ Added@smithy/property-provider@4.0.1(transitive)
+ Added@smithy/protocol-http@5.0.1(transitive)
+ Added@smithy/signature-v4@5.0.1(transitive)
+ Added@smithy/types@4.1.0(transitive)
+ Added@smithy/util-buffer-from@4.0.0(transitive)
+ Added@smithy/util-hex-encoding@4.0.0(transitive)
+ Added@smithy/util-middleware@4.0.1(transitive)
+ Added@smithy/util-uri-escape@4.0.0(transitive)
+ Added@smithy/util-utf8@4.0.0(transitive)
- Removed@aws-sdk/types@3.714.0(transitive)
- Removed@smithy/is-array-buffer@3.0.0(transitive)
- Removed@smithy/property-provider@3.1.11(transitive)
- Removed@smithy/protocol-http@4.1.8(transitive)
- Removed@smithy/signature-v4@4.2.4(transitive)
- Removed@smithy/types@3.7.2(transitive)
- Removed@smithy/util-buffer-from@3.0.0(transitive)
- Removed@smithy/util-hex-encoding@3.0.0(transitive)
- Removed@smithy/util-middleware@3.0.11(transitive)
- Removed@smithy/util-uri-escape@3.0.0(transitive)
- Removed@smithy/util-utf8@3.0.0(transitive)
Updated@aws-sdk/types@3.723.0
Updated@smithy/protocol-http@^5.0.0
Updated@smithy/signature-v4@^5.0.0
Updated@smithy/types@^4.0.0