@cdk8s/awscdk-resolver 0.0.57 → 0.0.59
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/.jsii +3 -3
- package/lib/resolve.js +1 -1
- package/node_modules/@aws-sdk/client-cloudformation/dist-cjs/auth/httpAuthSchemeProvider.js +47 -0
- package/node_modules/@aws-sdk/client-cloudformation/dist-cjs/index.js +267 -1714
- package/node_modules/@aws-sdk/client-cloudformation/dist-cjs/runtimeConfig.shared.js +10 -0
- package/node_modules/@aws-sdk/client-cloudformation/dist-es/CloudFormationClient.js +17 -4
- package/node_modules/@aws-sdk/client-cloudformation/dist-es/auth/httpAuthExtensionConfiguration.js +38 -0
- package/node_modules/@aws-sdk/client-cloudformation/dist-es/auth/httpAuthSchemeProvider.js +41 -0
- package/node_modules/@aws-sdk/client-cloudformation/dist-es/protocols/Aws_query.js +180 -1685
- package/node_modules/@aws-sdk/client-cloudformation/dist-es/runtimeConfig.shared.js +10 -0
- package/node_modules/@aws-sdk/client-cloudformation/dist-es/runtimeExtensions.js +3 -0
- package/node_modules/@aws-sdk/client-cloudformation/dist-types/CloudFormationClient.d.ts +13 -11
- package/node_modules/@aws-sdk/client-cloudformation/dist-types/auth/httpAuthExtensionConfiguration.d.ts +29 -0
- package/node_modules/@aws-sdk/client-cloudformation/dist-types/auth/httpAuthSchemeProvider.d.ts +61 -0
- package/node_modules/@aws-sdk/client-cloudformation/dist-types/extensionConfiguration.d.ts +2 -1
- package/node_modules/@aws-sdk/client-cloudformation/dist-types/runtimeConfig.browser.d.ts +5 -3
- package/node_modules/@aws-sdk/client-cloudformation/dist-types/runtimeConfig.d.ts +4 -2
- package/node_modules/@aws-sdk/client-cloudformation/dist-types/runtimeConfig.native.d.ts +6 -4
- package/node_modules/@aws-sdk/client-cloudformation/dist-types/runtimeConfig.shared.d.ts +2 -0
- package/node_modules/@aws-sdk/client-cloudformation/dist-types/ts3.4/CloudFormationClient.d.ts +11 -9
- package/node_modules/@aws-sdk/client-cloudformation/dist-types/ts3.4/auth/httpAuthExtensionConfiguration.d.ts +32 -0
- package/node_modules/@aws-sdk/client-cloudformation/dist-types/ts3.4/auth/httpAuthSchemeProvider.d.ts +44 -0
- package/node_modules/@aws-sdk/client-cloudformation/dist-types/ts3.4/extensionConfiguration.d.ts +3 -1
- package/node_modules/@aws-sdk/client-cloudformation/dist-types/ts3.4/runtimeConfig.browser.d.ts +5 -5
- package/node_modules/@aws-sdk/client-cloudformation/dist-types/ts3.4/runtimeConfig.d.ts +4 -4
- package/node_modules/@aws-sdk/client-cloudformation/dist-types/ts3.4/runtimeConfig.native.d.ts +8 -8
- package/node_modules/@aws-sdk/client-cloudformation/dist-types/ts3.4/runtimeConfig.shared.d.ts +2 -0
- package/node_modules/@aws-sdk/client-cloudformation/package.json +16 -16
- package/node_modules/@aws-sdk/client-sso/dist-cjs/auth/httpAuthSchemeProvider.js +68 -0
- package/node_modules/@aws-sdk/client-sso/dist-cjs/index.js +76 -96
- package/node_modules/@aws-sdk/client-sso/dist-cjs/runtimeConfig.shared.js +16 -0
- package/node_modules/@aws-sdk/client-sso/dist-es/SSOClient.js +19 -3
- package/node_modules/@aws-sdk/client-sso/dist-es/auth/httpAuthExtensionConfiguration.js +38 -0
- package/node_modules/@aws-sdk/client-sso/dist-es/auth/httpAuthSchemeProvider.js +62 -0
- package/node_modules/@aws-sdk/client-sso/dist-es/protocols/Aws_restJson1.js +8 -89
- package/node_modules/@aws-sdk/client-sso/dist-es/runtimeConfig.shared.js +16 -0
- package/node_modules/@aws-sdk/client-sso/dist-es/runtimeExtensions.js +3 -0
- package/node_modules/@aws-sdk/client-sso/dist-types/SSOClient.d.ts +9 -6
- package/node_modules/@aws-sdk/client-sso/dist-types/auth/httpAuthExtensionConfiguration.d.ts +29 -0
- package/node_modules/@aws-sdk/client-sso/dist-types/auth/httpAuthSchemeProvider.d.ts +61 -0
- package/node_modules/@aws-sdk/client-sso/dist-types/extensionConfiguration.d.ts +2 -1
- package/node_modules/@aws-sdk/client-sso/dist-types/runtimeConfig.browser.d.ts +16 -0
- package/node_modules/@aws-sdk/client-sso/dist-types/runtimeConfig.d.ts +16 -0
- package/node_modules/@aws-sdk/client-sso/dist-types/runtimeConfig.native.d.ts +17 -1
- package/node_modules/@aws-sdk/client-sso/dist-types/runtimeConfig.shared.d.ts +13 -0
- package/node_modules/@aws-sdk/client-sso/dist-types/ts3.4/SSOClient.d.ts +9 -1
- package/node_modules/@aws-sdk/client-sso/dist-types/ts3.4/auth/httpAuthExtensionConfiguration.d.ts +32 -0
- package/node_modules/@aws-sdk/client-sso/dist-types/ts3.4/auth/httpAuthSchemeProvider.d.ts +43 -0
- package/node_modules/@aws-sdk/client-sso/dist-types/ts3.4/extensionConfiguration.d.ts +3 -1
- package/node_modules/@aws-sdk/client-sso/dist-types/ts3.4/runtimeConfig.browser.d.ts +46 -0
- package/node_modules/@aws-sdk/client-sso/dist-types/ts3.4/runtimeConfig.d.ts +46 -0
- package/node_modules/@aws-sdk/client-sso/dist-types/ts3.4/runtimeConfig.native.d.ts +47 -1
- package/node_modules/@aws-sdk/client-sso/dist-types/ts3.4/runtimeConfig.shared.d.ts +30 -0
- package/node_modules/@aws-sdk/client-sso/package.json +14 -13
- package/node_modules/@aws-sdk/client-sso-oidc/dist-cjs/auth/httpAuthSchemeProvider.js +64 -0
- package/node_modules/@aws-sdk/client-sso-oidc/dist-cjs/index.js +96 -144
- package/node_modules/@aws-sdk/client-sso-oidc/dist-cjs/runtimeConfig.shared.js +16 -0
- package/node_modules/@aws-sdk/client-sso-oidc/dist-es/SSOOIDCClient.js +17 -3
- package/node_modules/@aws-sdk/client-sso-oidc/dist-es/auth/httpAuthExtensionConfiguration.js +38 -0
- package/node_modules/@aws-sdk/client-sso-oidc/dist-es/auth/httpAuthSchemeProvider.js +58 -0
- package/node_modules/@aws-sdk/client-sso-oidc/dist-es/commands/CreateTokenWithIAMCommand.js +0 -2
- package/node_modules/@aws-sdk/client-sso-oidc/dist-es/protocols/Aws_restJson1.js +29 -134
- package/node_modules/@aws-sdk/client-sso-oidc/dist-es/runtimeConfig.shared.js +16 -0
- package/node_modules/@aws-sdk/client-sso-oidc/dist-es/runtimeExtensions.js +3 -0
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/SSOOIDCClient.d.ts +13 -11
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/auth/httpAuthExtensionConfiguration.d.ts +29 -0
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/auth/httpAuthSchemeProvider.d.ts +61 -0
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/extensionConfiguration.d.ts +2 -1
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/runtimeConfig.browser.d.ts +13 -3
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/runtimeConfig.d.ts +12 -2
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/runtimeConfig.native.d.ts +14 -4
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/runtimeConfig.shared.d.ts +13 -0
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/ts3.4/SSOOIDCClient.d.ts +11 -9
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/ts3.4/auth/httpAuthExtensionConfiguration.d.ts +32 -0
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/ts3.4/auth/httpAuthSchemeProvider.d.ts +44 -0
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/ts3.4/extensionConfiguration.d.ts +3 -1
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/ts3.4/runtimeConfig.browser.d.ts +30 -5
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/ts3.4/runtimeConfig.d.ts +29 -4
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/ts3.4/runtimeConfig.native.d.ts +33 -8
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/ts3.4/runtimeConfig.shared.d.ts +30 -0
- package/node_modules/@aws-sdk/client-sso-oidc/package.json +16 -16
- package/node_modules/@aws-sdk/client-sts/dist-cjs/index.js +74 -196
- package/node_modules/@aws-sdk/client-sts/dist-es/defaultStsRoleAssumers.js +17 -15
- package/node_modules/@aws-sdk/client-sts/dist-es/protocols/Aws_query.js +30 -178
- package/node_modules/@aws-sdk/client-sts/dist-types/defaultRoleAssumers.d.ts +4 -4
- package/node_modules/@aws-sdk/client-sts/dist-types/defaultStsRoleAssumers.d.ts +11 -3
- package/node_modules/@aws-sdk/client-sts/dist-types/ts3.4/defaultRoleAssumers.d.ts +4 -7
- package/node_modules/@aws-sdk/client-sts/dist-types/ts3.4/defaultStsRoleAssumers.d.ts +11 -3
- package/node_modules/@aws-sdk/client-sts/package.json +14 -14
- package/node_modules/@aws-sdk/core/CHANGELOG.md +22 -0
- package/node_modules/@aws-sdk/core/dist-cjs/index.js +13 -7
- package/node_modules/@aws-sdk/core/dist-es/httpAuthSchemes/aws_sdk/resolveAwsSdkSigV4Config.js +6 -2
- package/node_modules/@aws-sdk/core/package.json +2 -2
- package/node_modules/@aws-sdk/core/src/httpAuthSchemes/aws_sdk/resolveAwsSdkSigV4Config.ts +10 -2
- package/node_modules/@aws-sdk/core/tsconfig.cjs.tsbuildinfo +1 -1
- package/node_modules/@aws-sdk/core/tsconfig.es.tsbuildinfo +1 -1
- package/node_modules/@aws-sdk/core/tsconfig.types.tsbuildinfo +1 -1
- package/node_modules/@aws-sdk/credential-provider-env/package.json +2 -2
- package/node_modules/@aws-sdk/credential-provider-http/package.json +2 -2
- package/node_modules/@aws-sdk/credential-provider-ini/dist-cjs/index.js +10 -2
- package/node_modules/@aws-sdk/credential-provider-ini/dist-es/resolveAssumeRoleCredentials.js +5 -1
- package/node_modules/@aws-sdk/credential-provider-ini/dist-es/resolveWebIdentityCredentials.js +1 -0
- package/node_modules/@aws-sdk/credential-provider-ini/package.json +7 -7
- package/node_modules/@aws-sdk/credential-provider-node/package.json +10 -9
- package/node_modules/@aws-sdk/credential-provider-process/package.json +2 -2
- package/node_modules/@aws-sdk/credential-provider-sso/package.json +4 -4
- package/node_modules/@aws-sdk/credential-provider-web-identity/dist-cjs/fromWebToken.js +28 -1
- package/node_modules/@aws-sdk/credential-provider-web-identity/dist-es/fromWebToken.js +5 -1
- package/node_modules/@aws-sdk/credential-provider-web-identity/package.json +3 -3
- package/node_modules/@aws-sdk/middleware-host-header/package.json +2 -2
- package/node_modules/@aws-sdk/middleware-logger/package.json +2 -2
- package/node_modules/@aws-sdk/middleware-recursion-detection/package.json +2 -2
- package/node_modules/@aws-sdk/middleware-user-agent/package.json +3 -3
- package/node_modules/@aws-sdk/region-config-resolver/package.json +2 -2
- package/node_modules/@aws-sdk/token-providers/package.json +3 -3
- package/node_modules/@aws-sdk/types/dist-types/credentials.d.ts +16 -0
- package/node_modules/@aws-sdk/types/dist-types/ts3.4/credentials.d.ts +3 -0
- package/node_modules/@aws-sdk/types/package.json +1 -1
- package/node_modules/@aws-sdk/util-endpoints/package.json +2 -2
- package/node_modules/@aws-sdk/util-user-agent-browser/package.json +2 -2
- package/node_modules/@aws-sdk/util-user-agent-node/package.json +2 -2
- package/node_modules/@smithy/core/dist-cjs/index.js +26 -15
- package/node_modules/@smithy/core/dist-es/pagination/createPaginator.js +12 -1
- package/node_modules/@smithy/core/package.json +1 -1
- package/node_modules/@smithy/util-defaults-mode-node/dist-cjs/index.js +13 -3
- package/node_modules/@smithy/util-defaults-mode-node/dist-es/resolveDefaultsModeConfig.js +1 -1
- package/node_modules/@smithy/util-defaults-mode-node/package.json +1 -1
- package/package.json +5 -5
- package/node_modules/@aws-sdk/middleware-signing/LICENSE +0 -201
- package/node_modules/@aws-sdk/middleware-signing/README.md +0 -4
- package/node_modules/@aws-sdk/middleware-signing/dist-cjs/awsAuthConfiguration.js +0 -1
- package/node_modules/@aws-sdk/middleware-signing/dist-cjs/awsAuthMiddleware.js +0 -1
- package/node_modules/@aws-sdk/middleware-signing/dist-cjs/index.js +0 -227
- package/node_modules/@aws-sdk/middleware-signing/dist-es/awsAuthConfiguration.js +0 -103
- package/node_modules/@aws-sdk/middleware-signing/dist-es/awsAuthMiddleware.js +0 -55
- package/node_modules/@aws-sdk/middleware-signing/dist-es/index.js +0 -2
- package/node_modules/@aws-sdk/middleware-signing/dist-es/utils/getSkewCorrectedDate.js +0 -1
- package/node_modules/@aws-sdk/middleware-signing/dist-es/utils/getUpdatedSystemClockOffset.js +0 -8
- package/node_modules/@aws-sdk/middleware-signing/dist-es/utils/isClockSkewed.js +0 -2
- package/node_modules/@aws-sdk/middleware-signing/dist-types/awsAuthConfiguration.d.ts +0 -99
- package/node_modules/@aws-sdk/middleware-signing/dist-types/awsAuthMiddleware.d.ts +0 -6
- package/node_modules/@aws-sdk/middleware-signing/dist-types/index.d.ts +0 -2
- package/node_modules/@aws-sdk/middleware-signing/dist-types/ts3.4/awsAuthConfiguration.d.ts +0 -68
- package/node_modules/@aws-sdk/middleware-signing/dist-types/ts3.4/awsAuthMiddleware.d.ts +0 -19
- package/node_modules/@aws-sdk/middleware-signing/dist-types/ts3.4/index.d.ts +0 -2
- package/node_modules/@aws-sdk/middleware-signing/dist-types/ts3.4/utils/getSkewCorrectedDate.d.ts +0 -1
- package/node_modules/@aws-sdk/middleware-signing/dist-types/ts3.4/utils/getUpdatedSystemClockOffset.d.ts +0 -4
- package/node_modules/@aws-sdk/middleware-signing/dist-types/ts3.4/utils/isClockSkewed.d.ts +0 -4
- package/node_modules/@aws-sdk/middleware-signing/dist-types/utils/getSkewCorrectedDate.d.ts +0 -6
- package/node_modules/@aws-sdk/middleware-signing/dist-types/utils/getUpdatedSystemClockOffset.d.ts +0 -8
- package/node_modules/@aws-sdk/middleware-signing/dist-types/utils/isClockSkewed.d.ts +0 -7
- package/node_modules/@aws-sdk/middleware-signing/package.json +0 -59
- /package/node_modules/@aws-sdk/{middleware-signing/dist-cjs/utils/getSkewCorrectedDate.js → client-cloudformation/dist-cjs/auth/httpAuthExtensionConfiguration.js} +0 -0
- /package/node_modules/@aws-sdk/{middleware-signing/dist-cjs/utils/isClockSkewed.js → client-sso/dist-cjs/auth/httpAuthExtensionConfiguration.js} +0 -0
- /package/node_modules/@aws-sdk/{middleware-signing/dist-cjs/utils/getUpdatedSystemClockOffset.js → client-sso-oidc/dist-cjs/auth/httpAuthExtensionConfiguration.js} +0 -0
@@ -340,7 +340,7 @@ var se_GetSessionTokenCommand = /* @__PURE__ */ __name(async (input, context) =>
|
|
340
340
|
}, "se_GetSessionTokenCommand");
|
341
341
|
var de_AssumeRoleCommand = /* @__PURE__ */ __name(async (output, context) => {
|
342
342
|
if (output.statusCode >= 300) {
|
343
|
-
return
|
343
|
+
return de_CommandError(output, context);
|
344
344
|
}
|
345
345
|
const data = await parseBody(output.body, context);
|
346
346
|
let contents = {};
|
@@ -351,37 +351,9 @@ var de_AssumeRoleCommand = /* @__PURE__ */ __name(async (output, context) => {
|
|
351
351
|
};
|
352
352
|
return response;
|
353
353
|
}, "de_AssumeRoleCommand");
|
354
|
-
var de_AssumeRoleCommandError = /* @__PURE__ */ __name(async (output, context) => {
|
355
|
-
const parsedOutput = {
|
356
|
-
...output,
|
357
|
-
body: await parseErrorBody(output.body, context)
|
358
|
-
};
|
359
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
360
|
-
switch (errorCode) {
|
361
|
-
case "ExpiredTokenException":
|
362
|
-
case "com.amazonaws.sts#ExpiredTokenException":
|
363
|
-
throw await de_ExpiredTokenExceptionRes(parsedOutput, context);
|
364
|
-
case "MalformedPolicyDocument":
|
365
|
-
case "com.amazonaws.sts#MalformedPolicyDocumentException":
|
366
|
-
throw await de_MalformedPolicyDocumentExceptionRes(parsedOutput, context);
|
367
|
-
case "PackedPolicyTooLarge":
|
368
|
-
case "com.amazonaws.sts#PackedPolicyTooLargeException":
|
369
|
-
throw await de_PackedPolicyTooLargeExceptionRes(parsedOutput, context);
|
370
|
-
case "RegionDisabledException":
|
371
|
-
case "com.amazonaws.sts#RegionDisabledException":
|
372
|
-
throw await de_RegionDisabledExceptionRes(parsedOutput, context);
|
373
|
-
default:
|
374
|
-
const parsedBody = parsedOutput.body;
|
375
|
-
return throwDefaultError({
|
376
|
-
output,
|
377
|
-
parsedBody: parsedBody.Error,
|
378
|
-
errorCode
|
379
|
-
});
|
380
|
-
}
|
381
|
-
}, "de_AssumeRoleCommandError");
|
382
354
|
var de_AssumeRoleWithSAMLCommand = /* @__PURE__ */ __name(async (output, context) => {
|
383
355
|
if (output.statusCode >= 300) {
|
384
|
-
return
|
356
|
+
return de_CommandError(output, context);
|
385
357
|
}
|
386
358
|
const data = await parseBody(output.body, context);
|
387
359
|
let contents = {};
|
@@ -392,43 +364,9 @@ var de_AssumeRoleWithSAMLCommand = /* @__PURE__ */ __name(async (output, context
|
|
392
364
|
};
|
393
365
|
return response;
|
394
366
|
}, "de_AssumeRoleWithSAMLCommand");
|
395
|
-
var de_AssumeRoleWithSAMLCommandError = /* @__PURE__ */ __name(async (output, context) => {
|
396
|
-
const parsedOutput = {
|
397
|
-
...output,
|
398
|
-
body: await parseErrorBody(output.body, context)
|
399
|
-
};
|
400
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
401
|
-
switch (errorCode) {
|
402
|
-
case "ExpiredTokenException":
|
403
|
-
case "com.amazonaws.sts#ExpiredTokenException":
|
404
|
-
throw await de_ExpiredTokenExceptionRes(parsedOutput, context);
|
405
|
-
case "IDPRejectedClaim":
|
406
|
-
case "com.amazonaws.sts#IDPRejectedClaimException":
|
407
|
-
throw await de_IDPRejectedClaimExceptionRes(parsedOutput, context);
|
408
|
-
case "InvalidIdentityToken":
|
409
|
-
case "com.amazonaws.sts#InvalidIdentityTokenException":
|
410
|
-
throw await de_InvalidIdentityTokenExceptionRes(parsedOutput, context);
|
411
|
-
case "MalformedPolicyDocument":
|
412
|
-
case "com.amazonaws.sts#MalformedPolicyDocumentException":
|
413
|
-
throw await de_MalformedPolicyDocumentExceptionRes(parsedOutput, context);
|
414
|
-
case "PackedPolicyTooLarge":
|
415
|
-
case "com.amazonaws.sts#PackedPolicyTooLargeException":
|
416
|
-
throw await de_PackedPolicyTooLargeExceptionRes(parsedOutput, context);
|
417
|
-
case "RegionDisabledException":
|
418
|
-
case "com.amazonaws.sts#RegionDisabledException":
|
419
|
-
throw await de_RegionDisabledExceptionRes(parsedOutput, context);
|
420
|
-
default:
|
421
|
-
const parsedBody = parsedOutput.body;
|
422
|
-
return throwDefaultError({
|
423
|
-
output,
|
424
|
-
parsedBody: parsedBody.Error,
|
425
|
-
errorCode
|
426
|
-
});
|
427
|
-
}
|
428
|
-
}, "de_AssumeRoleWithSAMLCommandError");
|
429
367
|
var de_AssumeRoleWithWebIdentityCommand = /* @__PURE__ */ __name(async (output, context) => {
|
430
368
|
if (output.statusCode >= 300) {
|
431
|
-
return
|
369
|
+
return de_CommandError(output, context);
|
432
370
|
}
|
433
371
|
const data = await parseBody(output.body, context);
|
434
372
|
let contents = {};
|
@@ -439,46 +377,9 @@ var de_AssumeRoleWithWebIdentityCommand = /* @__PURE__ */ __name(async (output,
|
|
439
377
|
};
|
440
378
|
return response;
|
441
379
|
}, "de_AssumeRoleWithWebIdentityCommand");
|
442
|
-
var de_AssumeRoleWithWebIdentityCommandError = /* @__PURE__ */ __name(async (output, context) => {
|
443
|
-
const parsedOutput = {
|
444
|
-
...output,
|
445
|
-
body: await parseErrorBody(output.body, context)
|
446
|
-
};
|
447
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
448
|
-
switch (errorCode) {
|
449
|
-
case "ExpiredTokenException":
|
450
|
-
case "com.amazonaws.sts#ExpiredTokenException":
|
451
|
-
throw await de_ExpiredTokenExceptionRes(parsedOutput, context);
|
452
|
-
case "IDPCommunicationError":
|
453
|
-
case "com.amazonaws.sts#IDPCommunicationErrorException":
|
454
|
-
throw await de_IDPCommunicationErrorExceptionRes(parsedOutput, context);
|
455
|
-
case "IDPRejectedClaim":
|
456
|
-
case "com.amazonaws.sts#IDPRejectedClaimException":
|
457
|
-
throw await de_IDPRejectedClaimExceptionRes(parsedOutput, context);
|
458
|
-
case "InvalidIdentityToken":
|
459
|
-
case "com.amazonaws.sts#InvalidIdentityTokenException":
|
460
|
-
throw await de_InvalidIdentityTokenExceptionRes(parsedOutput, context);
|
461
|
-
case "MalformedPolicyDocument":
|
462
|
-
case "com.amazonaws.sts#MalformedPolicyDocumentException":
|
463
|
-
throw await de_MalformedPolicyDocumentExceptionRes(parsedOutput, context);
|
464
|
-
case "PackedPolicyTooLarge":
|
465
|
-
case "com.amazonaws.sts#PackedPolicyTooLargeException":
|
466
|
-
throw await de_PackedPolicyTooLargeExceptionRes(parsedOutput, context);
|
467
|
-
case "RegionDisabledException":
|
468
|
-
case "com.amazonaws.sts#RegionDisabledException":
|
469
|
-
throw await de_RegionDisabledExceptionRes(parsedOutput, context);
|
470
|
-
default:
|
471
|
-
const parsedBody = parsedOutput.body;
|
472
|
-
return throwDefaultError({
|
473
|
-
output,
|
474
|
-
parsedBody: parsedBody.Error,
|
475
|
-
errorCode
|
476
|
-
});
|
477
|
-
}
|
478
|
-
}, "de_AssumeRoleWithWebIdentityCommandError");
|
479
380
|
var de_DecodeAuthorizationMessageCommand = /* @__PURE__ */ __name(async (output, context) => {
|
480
381
|
if (output.statusCode >= 300) {
|
481
|
-
return
|
382
|
+
return de_CommandError(output, context);
|
482
383
|
}
|
483
384
|
const data = await parseBody(output.body, context);
|
484
385
|
let contents = {};
|
@@ -489,28 +390,9 @@ var de_DecodeAuthorizationMessageCommand = /* @__PURE__ */ __name(async (output,
|
|
489
390
|
};
|
490
391
|
return response;
|
491
392
|
}, "de_DecodeAuthorizationMessageCommand");
|
492
|
-
var de_DecodeAuthorizationMessageCommandError = /* @__PURE__ */ __name(async (output, context) => {
|
493
|
-
const parsedOutput = {
|
494
|
-
...output,
|
495
|
-
body: await parseErrorBody(output.body, context)
|
496
|
-
};
|
497
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
498
|
-
switch (errorCode) {
|
499
|
-
case "InvalidAuthorizationMessageException":
|
500
|
-
case "com.amazonaws.sts#InvalidAuthorizationMessageException":
|
501
|
-
throw await de_InvalidAuthorizationMessageExceptionRes(parsedOutput, context);
|
502
|
-
default:
|
503
|
-
const parsedBody = parsedOutput.body;
|
504
|
-
return throwDefaultError({
|
505
|
-
output,
|
506
|
-
parsedBody: parsedBody.Error,
|
507
|
-
errorCode
|
508
|
-
});
|
509
|
-
}
|
510
|
-
}, "de_DecodeAuthorizationMessageCommandError");
|
511
393
|
var de_GetAccessKeyInfoCommand = /* @__PURE__ */ __name(async (output, context) => {
|
512
394
|
if (output.statusCode >= 300) {
|
513
|
-
return
|
395
|
+
return de_CommandError(output, context);
|
514
396
|
}
|
515
397
|
const data = await parseBody(output.body, context);
|
516
398
|
let contents = {};
|
@@ -521,22 +403,9 @@ var de_GetAccessKeyInfoCommand = /* @__PURE__ */ __name(async (output, context)
|
|
521
403
|
};
|
522
404
|
return response;
|
523
405
|
}, "de_GetAccessKeyInfoCommand");
|
524
|
-
var de_GetAccessKeyInfoCommandError = /* @__PURE__ */ __name(async (output, context) => {
|
525
|
-
const parsedOutput = {
|
526
|
-
...output,
|
527
|
-
body: await parseErrorBody(output.body, context)
|
528
|
-
};
|
529
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
530
|
-
const parsedBody = parsedOutput.body;
|
531
|
-
return throwDefaultError({
|
532
|
-
output,
|
533
|
-
parsedBody: parsedBody.Error,
|
534
|
-
errorCode
|
535
|
-
});
|
536
|
-
}, "de_GetAccessKeyInfoCommandError");
|
537
406
|
var de_GetCallerIdentityCommand = /* @__PURE__ */ __name(async (output, context) => {
|
538
407
|
if (output.statusCode >= 300) {
|
539
|
-
return
|
408
|
+
return de_CommandError(output, context);
|
540
409
|
}
|
541
410
|
const data = await parseBody(output.body, context);
|
542
411
|
let contents = {};
|
@@ -547,22 +416,9 @@ var de_GetCallerIdentityCommand = /* @__PURE__ */ __name(async (output, context)
|
|
547
416
|
};
|
548
417
|
return response;
|
549
418
|
}, "de_GetCallerIdentityCommand");
|
550
|
-
var de_GetCallerIdentityCommandError = /* @__PURE__ */ __name(async (output, context) => {
|
551
|
-
const parsedOutput = {
|
552
|
-
...output,
|
553
|
-
body: await parseErrorBody(output.body, context)
|
554
|
-
};
|
555
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
556
|
-
const parsedBody = parsedOutput.body;
|
557
|
-
return throwDefaultError({
|
558
|
-
output,
|
559
|
-
parsedBody: parsedBody.Error,
|
560
|
-
errorCode
|
561
|
-
});
|
562
|
-
}, "de_GetCallerIdentityCommandError");
|
563
419
|
var de_GetFederationTokenCommand = /* @__PURE__ */ __name(async (output, context) => {
|
564
420
|
if (output.statusCode >= 300) {
|
565
|
-
return
|
421
|
+
return de_CommandError(output, context);
|
566
422
|
}
|
567
423
|
const data = await parseBody(output.body, context);
|
568
424
|
let contents = {};
|
@@ -573,34 +429,9 @@ var de_GetFederationTokenCommand = /* @__PURE__ */ __name(async (output, context
|
|
573
429
|
};
|
574
430
|
return response;
|
575
431
|
}, "de_GetFederationTokenCommand");
|
576
|
-
var de_GetFederationTokenCommandError = /* @__PURE__ */ __name(async (output, context) => {
|
577
|
-
const parsedOutput = {
|
578
|
-
...output,
|
579
|
-
body: await parseErrorBody(output.body, context)
|
580
|
-
};
|
581
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
582
|
-
switch (errorCode) {
|
583
|
-
case "MalformedPolicyDocument":
|
584
|
-
case "com.amazonaws.sts#MalformedPolicyDocumentException":
|
585
|
-
throw await de_MalformedPolicyDocumentExceptionRes(parsedOutput, context);
|
586
|
-
case "PackedPolicyTooLarge":
|
587
|
-
case "com.amazonaws.sts#PackedPolicyTooLargeException":
|
588
|
-
throw await de_PackedPolicyTooLargeExceptionRes(parsedOutput, context);
|
589
|
-
case "RegionDisabledException":
|
590
|
-
case "com.amazonaws.sts#RegionDisabledException":
|
591
|
-
throw await de_RegionDisabledExceptionRes(parsedOutput, context);
|
592
|
-
default:
|
593
|
-
const parsedBody = parsedOutput.body;
|
594
|
-
return throwDefaultError({
|
595
|
-
output,
|
596
|
-
parsedBody: parsedBody.Error,
|
597
|
-
errorCode
|
598
|
-
});
|
599
|
-
}
|
600
|
-
}, "de_GetFederationTokenCommandError");
|
601
432
|
var de_GetSessionTokenCommand = /* @__PURE__ */ __name(async (output, context) => {
|
602
433
|
if (output.statusCode >= 300) {
|
603
|
-
return
|
434
|
+
return de_CommandError(output, context);
|
604
435
|
}
|
605
436
|
const data = await parseBody(output.body, context);
|
606
437
|
let contents = {};
|
@@ -611,16 +442,37 @@ var de_GetSessionTokenCommand = /* @__PURE__ */ __name(async (output, context) =
|
|
611
442
|
};
|
612
443
|
return response;
|
613
444
|
}, "de_GetSessionTokenCommand");
|
614
|
-
var
|
445
|
+
var de_CommandError = /* @__PURE__ */ __name(async (output, context) => {
|
615
446
|
const parsedOutput = {
|
616
447
|
...output,
|
617
448
|
body: await parseErrorBody(output.body, context)
|
618
449
|
};
|
619
450
|
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
620
451
|
switch (errorCode) {
|
452
|
+
case "ExpiredTokenException":
|
453
|
+
case "com.amazonaws.sts#ExpiredTokenException":
|
454
|
+
throw await de_ExpiredTokenExceptionRes(parsedOutput, context);
|
455
|
+
case "MalformedPolicyDocument":
|
456
|
+
case "com.amazonaws.sts#MalformedPolicyDocumentException":
|
457
|
+
throw await de_MalformedPolicyDocumentExceptionRes(parsedOutput, context);
|
458
|
+
case "PackedPolicyTooLarge":
|
459
|
+
case "com.amazonaws.sts#PackedPolicyTooLargeException":
|
460
|
+
throw await de_PackedPolicyTooLargeExceptionRes(parsedOutput, context);
|
621
461
|
case "RegionDisabledException":
|
622
462
|
case "com.amazonaws.sts#RegionDisabledException":
|
623
463
|
throw await de_RegionDisabledExceptionRes(parsedOutput, context);
|
464
|
+
case "IDPRejectedClaim":
|
465
|
+
case "com.amazonaws.sts#IDPRejectedClaimException":
|
466
|
+
throw await de_IDPRejectedClaimExceptionRes(parsedOutput, context);
|
467
|
+
case "InvalidIdentityToken":
|
468
|
+
case "com.amazonaws.sts#InvalidIdentityTokenException":
|
469
|
+
throw await de_InvalidIdentityTokenExceptionRes(parsedOutput, context);
|
470
|
+
case "IDPCommunicationError":
|
471
|
+
case "com.amazonaws.sts#IDPCommunicationErrorException":
|
472
|
+
throw await de_IDPCommunicationErrorExceptionRes(parsedOutput, context);
|
473
|
+
case "InvalidAuthorizationMessageException":
|
474
|
+
case "com.amazonaws.sts#InvalidAuthorizationMessageException":
|
475
|
+
throw await de_InvalidAuthorizationMessageExceptionRes(parsedOutput, context);
|
624
476
|
default:
|
625
477
|
const parsedBody = parsedOutput.body;
|
626
478
|
return throwDefaultError({
|
@@ -629,7 +481,7 @@ var de_GetSessionTokenCommandError = /* @__PURE__ */ __name(async (output, conte
|
|
629
481
|
errorCode
|
630
482
|
});
|
631
483
|
}
|
632
|
-
}, "
|
484
|
+
}, "de_CommandError");
|
633
485
|
var de_ExpiredTokenExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {
|
634
486
|
const body = parsedOutput.body;
|
635
487
|
const deserialized = de_ExpiredTokenException(body.Error, context);
|
@@ -1482,34 +1334,54 @@ var STS = _STS;
|
|
1482
1334
|
// src/index.ts
|
1483
1335
|
var import_EndpointParameters9 = require("./endpoint/EndpointParameters");
|
1484
1336
|
var import_runtimeExtensions = require("././runtimeExtensions");
|
1485
|
-
|
1337
|
+
|
1486
1338
|
|
1487
1339
|
// src/defaultStsRoleAssumers.ts
|
1340
|
+
var import_util_endpoints = require("@aws-sdk/util-endpoints");
|
1488
1341
|
var ASSUME_ROLE_DEFAULT_REGION = "us-east-1";
|
1489
|
-
var
|
1490
|
-
|
1491
|
-
|
1492
|
-
|
1493
|
-
|
1494
|
-
|
1495
|
-
|
1496
|
-
|
1497
|
-
|
1498
|
-
|
1499
|
-
|
1500
|
-
|
1342
|
+
var resolveRegion = /* @__PURE__ */ __name(async (_region, _parentRegion, credentialProviderLogger) => {
|
1343
|
+
var _a2, _b;
|
1344
|
+
const region = typeof _region === "function" ? await _region() : _region;
|
1345
|
+
const parentRegion = typeof _parentRegion === "function" ? await _parentRegion() : _parentRegion;
|
1346
|
+
if (!parentRegion || (0, import_util_endpoints.partition)(parentRegion).name === "aws") {
|
1347
|
+
(_a2 = credentialProviderLogger == null ? void 0 : credentialProviderLogger.debug) == null ? void 0 : _a2.call(
|
1348
|
+
credentialProviderLogger,
|
1349
|
+
"@aws-sdk/client-sts::resolveRegion",
|
1350
|
+
"accepting first of:",
|
1351
|
+
`${region} (provider)`,
|
1352
|
+
`${ASSUME_ROLE_DEFAULT_REGION} (STS default)`
|
1353
|
+
);
|
1354
|
+
return region ?? ASSUME_ROLE_DEFAULT_REGION;
|
1355
|
+
} else {
|
1356
|
+
(_b = credentialProviderLogger == null ? void 0 : credentialProviderLogger.debug) == null ? void 0 : _b.call(
|
1357
|
+
credentialProviderLogger,
|
1358
|
+
"@aws-sdk/client-sts::resolveRegion",
|
1359
|
+
"accepting first of:",
|
1360
|
+
`${region} (provider)`,
|
1361
|
+
`${parentRegion} (parent client)`,
|
1362
|
+
`${ASSUME_ROLE_DEFAULT_REGION} (STS default)`
|
1363
|
+
);
|
1364
|
+
return region ?? parentRegion ?? ASSUME_ROLE_DEFAULT_REGION;
|
1365
|
+
}
|
1366
|
+
}, "resolveRegion");
|
1501
1367
|
var getDefaultRoleAssumer = /* @__PURE__ */ __name((stsOptions, stsClientCtor) => {
|
1502
1368
|
let stsClient;
|
1503
1369
|
let closureSourceCreds;
|
1504
1370
|
return async (sourceCreds, params) => {
|
1371
|
+
var _a2;
|
1505
1372
|
closureSourceCreds = sourceCreds;
|
1506
1373
|
if (!stsClient) {
|
1507
|
-
const { logger, region, requestHandler } = stsOptions;
|
1374
|
+
const { logger, region, requestHandler, credentialProviderLogger } = stsOptions;
|
1375
|
+
const resolvedRegion = await resolveRegion(
|
1376
|
+
region,
|
1377
|
+
(_a2 = stsOptions == null ? void 0 : stsOptions.parentClientConfig) == null ? void 0 : _a2.region,
|
1378
|
+
credentialProviderLogger
|
1379
|
+
);
|
1508
1380
|
stsClient = new stsClientCtor({
|
1509
1381
|
logger,
|
1510
1382
|
// A hack to make sts client uses the credential in current closure.
|
1511
1383
|
credentialDefaultProvider: () => async () => closureSourceCreds,
|
1512
|
-
region:
|
1384
|
+
region: resolvedRegion,
|
1513
1385
|
...requestHandler ? { requestHandler } : {}
|
1514
1386
|
});
|
1515
1387
|
}
|
@@ -1530,11 +1402,17 @@ var getDefaultRoleAssumer = /* @__PURE__ */ __name((stsOptions, stsClientCtor) =
|
|
1530
1402
|
var getDefaultRoleAssumerWithWebIdentity = /* @__PURE__ */ __name((stsOptions, stsClientCtor) => {
|
1531
1403
|
let stsClient;
|
1532
1404
|
return async (params) => {
|
1405
|
+
var _a2;
|
1533
1406
|
if (!stsClient) {
|
1534
|
-
const { logger, region, requestHandler } = stsOptions;
|
1407
|
+
const { logger, region, requestHandler, credentialProviderLogger } = stsOptions;
|
1408
|
+
const resolvedRegion = await resolveRegion(
|
1409
|
+
region,
|
1410
|
+
(_a2 = stsOptions == null ? void 0 : stsOptions.parentClientConfig) == null ? void 0 : _a2.region,
|
1411
|
+
credentialProviderLogger
|
1412
|
+
);
|
1535
1413
|
stsClient = new stsClientCtor({
|
1536
1414
|
logger,
|
1537
|
-
region:
|
1415
|
+
region: resolvedRegion,
|
1538
1416
|
...requestHandler ? { requestHandler } : {}
|
1539
1417
|
});
|
1540
1418
|
}
|
@@ -1,18 +1,18 @@
|
|
1
|
+
import { partition } from "@aws-sdk/util-endpoints";
|
1
2
|
import { AssumeRoleCommand } from "./commands/AssumeRoleCommand";
|
2
3
|
import { AssumeRoleWithWebIdentityCommand, } from "./commands/AssumeRoleWithWebIdentityCommand";
|
3
4
|
const ASSUME_ROLE_DEFAULT_REGION = "us-east-1";
|
4
|
-
const
|
5
|
-
|
6
|
-
|
5
|
+
const resolveRegion = async (_region, _parentRegion, credentialProviderLogger) => {
|
6
|
+
const region = typeof _region === "function" ? await _region() : _region;
|
7
|
+
const parentRegion = typeof _parentRegion === "function" ? await _parentRegion() : _parentRegion;
|
8
|
+
if (!parentRegion || partition(parentRegion).name === "aws") {
|
9
|
+
credentialProviderLogger?.debug?.("@aws-sdk/client-sts::resolveRegion", "accepting first of:", `${region} (provider)`, `${ASSUME_ROLE_DEFAULT_REGION} (STS default)`);
|
10
|
+
return region ?? ASSUME_ROLE_DEFAULT_REGION;
|
11
|
+
}
|
12
|
+
else {
|
13
|
+
credentialProviderLogger?.debug?.("@aws-sdk/client-sts::resolveRegion", "accepting first of:", `${region} (provider)`, `${parentRegion} (parent client)`, `${ASSUME_ROLE_DEFAULT_REGION} (STS default)`);
|
14
|
+
return region ?? parentRegion ?? ASSUME_ROLE_DEFAULT_REGION;
|
7
15
|
}
|
8
|
-
return async () => {
|
9
|
-
try {
|
10
|
-
return await region();
|
11
|
-
}
|
12
|
-
catch (e) {
|
13
|
-
return ASSUME_ROLE_DEFAULT_REGION;
|
14
|
-
}
|
15
|
-
};
|
16
16
|
};
|
17
17
|
export const getDefaultRoleAssumer = (stsOptions, stsClientCtor) => {
|
18
18
|
let stsClient;
|
@@ -20,11 +20,12 @@ export const getDefaultRoleAssumer = (stsOptions, stsClientCtor) => {
|
|
20
20
|
return async (sourceCreds, params) => {
|
21
21
|
closureSourceCreds = sourceCreds;
|
22
22
|
if (!stsClient) {
|
23
|
-
const { logger, region, requestHandler } = stsOptions;
|
23
|
+
const { logger, region, requestHandler, credentialProviderLogger } = stsOptions;
|
24
|
+
const resolvedRegion = await resolveRegion(region, stsOptions?.parentClientConfig?.region, credentialProviderLogger);
|
24
25
|
stsClient = new stsClientCtor({
|
25
26
|
logger,
|
26
27
|
credentialDefaultProvider: () => async () => closureSourceCreds,
|
27
|
-
region:
|
28
|
+
region: resolvedRegion,
|
28
29
|
...(requestHandler ? { requestHandler } : {}),
|
29
30
|
});
|
30
31
|
}
|
@@ -45,10 +46,11 @@ export const getDefaultRoleAssumerWithWebIdentity = (stsOptions, stsClientCtor)
|
|
45
46
|
let stsClient;
|
46
47
|
return async (params) => {
|
47
48
|
if (!stsClient) {
|
48
|
-
const { logger, region, requestHandler } = stsOptions;
|
49
|
+
const { logger, region, requestHandler, credentialProviderLogger } = stsOptions;
|
50
|
+
const resolvedRegion = await resolveRegion(region, stsOptions?.parentClientConfig?.region, credentialProviderLogger);
|
49
51
|
stsClient = new stsClientCtor({
|
50
52
|
logger,
|
51
|
-
region:
|
53
|
+
region: resolvedRegion,
|
52
54
|
...(requestHandler ? { requestHandler } : {}),
|
53
55
|
});
|
54
56
|
}
|