@aws-sdk/client-sts 3.1074.0 → 3.1076.0
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-cjs/index.js +944 -16
- package/dist-types/runtimeConfig.browser.d.ts +1 -1
- package/dist-types/runtimeConfig.d.ts +1 -1
- package/dist-types/runtimeConfig.native.d.ts +1 -1
- package/dist-types/ts3.4/runtimeConfig.browser.d.ts +7 -1
- package/dist-types/ts3.4/runtimeConfig.d.ts +7 -1
- package/dist-types/ts3.4/runtimeConfig.native.d.ts +7 -1
- package/package.json +10 -10
- package/dist-cjs/auth/httpAuthSchemeProvider.js +0 -138
- package/dist-cjs/endpoint/bdd.js +0 -85
- package/dist-cjs/endpoint/endpointResolver.js +0 -14
- package/dist-cjs/models/STSServiceException.js +0 -8
- package/dist-cjs/models/errors.js +0 -146
- package/dist-cjs/runtimeConfig.browser.js +0 -32
- package/dist-cjs/runtimeConfig.js +0 -64
- package/dist-cjs/runtimeConfig.native.js +0 -12
- package/dist-cjs/runtimeConfig.shared.js +0 -52
- package/dist-cjs/schemas/schemas_0.js +0 -425
package/dist-cjs/index.js
CHANGED
|
@@ -1,21 +1,250 @@
|
|
|
1
|
-
|
|
2
|
-
const {
|
|
3
|
-
const {
|
|
4
|
-
const { getDefaultExtensionConfiguration, resolveDefaultRuntimeConfig, Client, Command, createAggregatedClient } = require("@smithy/core/client");
|
|
1
|
+
const { awsEndpointFunctions, emitWarningIfUnsupportedVersion: emitWarningIfUnsupportedVersion$1, createDefaultUserAgentProvider, NODE_APP_ID_CONFIG_OPTIONS, getAwsRegionExtensionConfiguration, resolveAwsRegionExtensionConfiguration, resolveUserAgentConfig, resolveHostHeaderConfig, getUserAgentPlugin, getHostHeaderPlugin, getLoggerPlugin, getRecursionDetectionPlugin, setCredentialFeature, stsRegionDefaultResolver } = require("@aws-sdk/core/client");
|
|
2
|
+
const { NoAuthSigner, getHttpAuthSchemeEndpointRuleSetPlugin, DefaultIdentityProviderConfig, getHttpSigningPlugin } = require("@smithy/core");
|
|
3
|
+
const { normalizeProvider, getSmithyContext, ServiceException, NoOpLogger, emitWarningIfUnsupportedVersion, loadConfigsForDefaultMode, getDefaultExtensionConfiguration, resolveDefaultRuntimeConfig, Client, Command, createAggregatedClient } = require("@smithy/core/client");
|
|
5
4
|
exports.$Command = Command;
|
|
6
5
|
exports.__Client = Client;
|
|
7
|
-
const { resolveRegionConfig } = require("@smithy/core/config");
|
|
8
|
-
const { resolveEndpointConfig, getEndpointPlugin } = require("@smithy/core/endpoints");
|
|
9
|
-
const { getHttpHandlerExtensionConfiguration, resolveHttpHandlerRuntimeConfig, getContentLengthPlugin } = require("@smithy/core/protocols");
|
|
10
|
-
const { resolveRetryConfig, getRetryPlugin } = require("@smithy/core/retry");
|
|
11
|
-
const { getSchemaSerdePlugin } = require("@smithy/core/schema");
|
|
12
|
-
const {
|
|
13
|
-
const {
|
|
14
|
-
const {
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
const {
|
|
18
|
-
|
|
6
|
+
const { resolveDefaultsModeConfig, loadConfig, NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS, NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS, NODE_REGION_CONFIG_OPTIONS, NODE_REGION_CONFIG_FILE_OPTIONS, resolveRegionConfig } = require("@smithy/core/config");
|
|
7
|
+
const { BinaryDecisionDiagram, EndpointCache, decideEndpoint, customEndpointFunctions, resolveParams, resolveEndpointConfig, getEndpointPlugin } = require("@smithy/core/endpoints");
|
|
8
|
+
const { parseUrl, getHttpHandlerExtensionConfiguration, resolveHttpHandlerRuntimeConfig, getContentLengthPlugin } = require("@smithy/core/protocols");
|
|
9
|
+
const { DEFAULT_RETRY_MODE, NODE_RETRY_MODE_CONFIG_OPTIONS, NODE_MAX_ATTEMPT_CONFIG_OPTIONS, resolveRetryConfig, getRetryPlugin } = require("@smithy/core/retry");
|
|
10
|
+
const { TypeRegistry, getSchemaSerdePlugin } = require("@smithy/core/schema");
|
|
11
|
+
const { resolveAwsSdkSigV4Config, resolveAwsSdkSigV4AConfig, AwsSdkSigV4Signer, AwsSdkSigV4ASigner, NODE_SIGV4A_CONFIG_OPTIONS, NODE_AUTH_SCHEME_PREFERENCE_OPTIONS } = require("@aws-sdk/core/httpAuthSchemes");
|
|
12
|
+
const { SignatureV4MultiRegion } = require("@aws-sdk/signature-v4-multi-region");
|
|
13
|
+
const { defaultProvider } = require("@aws-sdk/credential-provider-node");
|
|
14
|
+
const { toUtf8, fromUtf8, toBase64, fromBase64, Hash, calculateBodyLength } = require("@smithy/core/serde");
|
|
15
|
+
const { streamCollector, NodeHttpHandler } = require("@smithy/node-http-handler");
|
|
16
|
+
const { AwsQueryProtocol } = require("@aws-sdk/core/protocols");
|
|
17
|
+
|
|
18
|
+
const q = "ref";
|
|
19
|
+
const a = -1, b = true, c = "isSet", d = "PartitionResult", e = "booleanEquals", f = "stringEquals", g = "getAttr", h = "us-east-1", i = "sigv4", j = "sts", k = "https://sts.{Region}.{PartitionResult#dnsSuffix}", l = { [q]: "Endpoint" }, m = { [q]: "Region" }, n = { [q]: d }, o = {}, p = [m];
|
|
20
|
+
const _data = {
|
|
21
|
+
conditions: [
|
|
22
|
+
[c, [l]],
|
|
23
|
+
[c, p],
|
|
24
|
+
["aws.partition", p, d],
|
|
25
|
+
[e, [{ [q]: "UseFIPS" }, b]],
|
|
26
|
+
[e, [{ [q]: "UseDualStack" }, b]],
|
|
27
|
+
[f, [m, "aws-global"]],
|
|
28
|
+
[e, [{ [q]: "UseGlobalEndpoint" }, b]],
|
|
29
|
+
[f, [m, "eu-central-1"]],
|
|
30
|
+
[e, [{ fn: g, argv: [n, "supportsDualStack"] }, b]],
|
|
31
|
+
[e, [{ fn: g, argv: [n, "supportsFIPS"] }, b]],
|
|
32
|
+
[f, [m, "ap-south-1"]],
|
|
33
|
+
[f, [m, "eu-north-1"]],
|
|
34
|
+
[f, [m, "eu-west-1"]],
|
|
35
|
+
[f, [m, "eu-west-2"]],
|
|
36
|
+
[f, [m, "eu-west-3"]],
|
|
37
|
+
[f, [m, "sa-east-1"]],
|
|
38
|
+
[f, [m, h]],
|
|
39
|
+
[f, [m, "us-east-2"]],
|
|
40
|
+
[f, [m, "us-west-2"]],
|
|
41
|
+
[f, [m, "us-west-1"]],
|
|
42
|
+
[f, [m, "ca-central-1"]],
|
|
43
|
+
[f, [m, "ap-southeast-1"]],
|
|
44
|
+
[f, [m, "ap-northeast-1"]],
|
|
45
|
+
[f, [m, "ap-southeast-2"]],
|
|
46
|
+
[f, [{ fn: g, argv: [n, "name"] }, "aws-us-gov"]]
|
|
47
|
+
],
|
|
48
|
+
results: [
|
|
49
|
+
[a],
|
|
50
|
+
["https://sts.amazonaws.com", { authSchemes: [{ name: i, signingName: j, signingRegion: h }] }],
|
|
51
|
+
[k, { authSchemes: [{ name: i, signingName: j, signingRegion: "{Region}" }] }],
|
|
52
|
+
[a, "Invalid Configuration: FIPS and custom endpoint are not supported"],
|
|
53
|
+
[a, "Invalid Configuration: Dualstack and custom endpoint are not supported"],
|
|
54
|
+
[l, o],
|
|
55
|
+
["https://sts-fips.{Region}.{PartitionResult#dualStackDnsSuffix}", o],
|
|
56
|
+
[a, "FIPS and DualStack are enabled, but this partition does not support one or both"],
|
|
57
|
+
["https://sts.{Region}.amazonaws.com", o],
|
|
58
|
+
["https://sts-fips.{Region}.{PartitionResult#dnsSuffix}", o],
|
|
59
|
+
[a, "FIPS is enabled but this partition does not support FIPS"],
|
|
60
|
+
["https://sts.{Region}.{PartitionResult#dualStackDnsSuffix}", o],
|
|
61
|
+
[a, "DualStack is enabled but this partition does not support DualStack"],
|
|
62
|
+
[k, o],
|
|
63
|
+
[a, "Invalid Configuration: Missing Region"]
|
|
64
|
+
]
|
|
65
|
+
};
|
|
66
|
+
const root = 2;
|
|
67
|
+
const r = 100_000_000;
|
|
68
|
+
const nodes = new Int32Array([
|
|
69
|
+
-1, 1, -1,
|
|
70
|
+
0, 30, 3,
|
|
71
|
+
1, 4, r + 14,
|
|
72
|
+
2, 5, r + 14,
|
|
73
|
+
3, 25, 6,
|
|
74
|
+
4, 24, 7,
|
|
75
|
+
5, r + 1, 8,
|
|
76
|
+
6, 9, r + 13,
|
|
77
|
+
7, r + 1, 10,
|
|
78
|
+
10, r + 1, 11,
|
|
79
|
+
11, r + 1, 12,
|
|
80
|
+
12, r + 1, 13,
|
|
81
|
+
13, r + 1, 14,
|
|
82
|
+
14, r + 1, 15,
|
|
83
|
+
15, r + 1, 16,
|
|
84
|
+
16, r + 1, 17,
|
|
85
|
+
17, r + 1, 18,
|
|
86
|
+
18, r + 1, 19,
|
|
87
|
+
19, r + 1, 20,
|
|
88
|
+
20, r + 1, 21,
|
|
89
|
+
21, r + 1, 22,
|
|
90
|
+
22, r + 1, 23,
|
|
91
|
+
23, r + 1, r + 2,
|
|
92
|
+
8, r + 11, r + 12,
|
|
93
|
+
4, 28, 26,
|
|
94
|
+
9, 27, r + 10,
|
|
95
|
+
24, r + 8, r + 9,
|
|
96
|
+
8, 29, r + 7,
|
|
97
|
+
9, r + 6, r + 7,
|
|
98
|
+
3, r + 3, 31,
|
|
99
|
+
4, r + 4, r + 5,
|
|
100
|
+
]);
|
|
101
|
+
const bdd = BinaryDecisionDiagram.from(nodes, root, _data.conditions, _data.results);
|
|
102
|
+
|
|
103
|
+
const cache = new EndpointCache({
|
|
104
|
+
size: 50,
|
|
105
|
+
params: ["Endpoint", "Region", "UseDualStack", "UseFIPS", "UseGlobalEndpoint"],
|
|
106
|
+
});
|
|
107
|
+
const defaultEndpointResolver = (endpointParams, context = {}) => {
|
|
108
|
+
return cache.get(endpointParams, () => decideEndpoint(bdd, {
|
|
109
|
+
endpointParams: endpointParams,
|
|
110
|
+
logger: context.logger,
|
|
111
|
+
}));
|
|
112
|
+
};
|
|
113
|
+
customEndpointFunctions.aws = awsEndpointFunctions;
|
|
114
|
+
|
|
115
|
+
const createEndpointRuleSetHttpAuthSchemeParametersProvider = (defaultHttpAuthSchemeParametersProvider) => async (config, context, input) => {
|
|
116
|
+
if (!input) {
|
|
117
|
+
throw new Error("Could not find `input` for `defaultEndpointRuleSetHttpAuthSchemeParametersProvider`");
|
|
118
|
+
}
|
|
119
|
+
const defaultParameters = await defaultHttpAuthSchemeParametersProvider(config, context, input);
|
|
120
|
+
const instructionsFn = getSmithyContext(context)?.commandInstance?.constructor
|
|
121
|
+
?.getEndpointParameterInstructions;
|
|
122
|
+
if (!instructionsFn) {
|
|
123
|
+
throw new Error(`getEndpointParameterInstructions() is not defined on '${context.commandName}'`);
|
|
124
|
+
}
|
|
125
|
+
const endpointParameters = await resolveParams(input, { getEndpointParameterInstructions: instructionsFn }, config);
|
|
126
|
+
return Object.assign(defaultParameters, endpointParameters);
|
|
127
|
+
};
|
|
128
|
+
const _defaultSTSHttpAuthSchemeParametersProvider = async (config, context, input) => {
|
|
129
|
+
return {
|
|
130
|
+
operation: getSmithyContext(context).operation,
|
|
131
|
+
region: await normalizeProvider(config.region)() || (() => {
|
|
132
|
+
throw new Error("expected `region` to be configured for `aws.auth#sigv4`");
|
|
133
|
+
})(),
|
|
134
|
+
};
|
|
135
|
+
};
|
|
136
|
+
const defaultSTSHttpAuthSchemeParametersProvider = createEndpointRuleSetHttpAuthSchemeParametersProvider(_defaultSTSHttpAuthSchemeParametersProvider);
|
|
137
|
+
function createAwsAuthSigv4HttpAuthOption(authParameters) {
|
|
138
|
+
return {
|
|
139
|
+
schemeId: "aws.auth#sigv4",
|
|
140
|
+
signingProperties: {
|
|
141
|
+
name: "sts",
|
|
142
|
+
region: authParameters.region,
|
|
143
|
+
},
|
|
144
|
+
propertiesExtractor: (config, context) => ({
|
|
145
|
+
signingProperties: {
|
|
146
|
+
config,
|
|
147
|
+
context,
|
|
148
|
+
},
|
|
149
|
+
}),
|
|
150
|
+
};
|
|
151
|
+
}
|
|
152
|
+
function createAwsAuthSigv4aHttpAuthOption(authParameters) {
|
|
153
|
+
return {
|
|
154
|
+
schemeId: "aws.auth#sigv4a",
|
|
155
|
+
signingProperties: {
|
|
156
|
+
name: "sts",
|
|
157
|
+
region: authParameters.region,
|
|
158
|
+
},
|
|
159
|
+
propertiesExtractor: (config, context) => ({
|
|
160
|
+
signingProperties: {
|
|
161
|
+
config,
|
|
162
|
+
context,
|
|
163
|
+
},
|
|
164
|
+
}),
|
|
165
|
+
};
|
|
166
|
+
}
|
|
167
|
+
function createSmithyApiNoAuthHttpAuthOption(authParameters) {
|
|
168
|
+
return {
|
|
169
|
+
schemeId: "smithy.api#noAuth",
|
|
170
|
+
};
|
|
171
|
+
}
|
|
172
|
+
const createEndpointRuleSetHttpAuthSchemeProvider = (defaultEndpointResolver, defaultHttpAuthSchemeResolver, createHttpAuthOptionFunctions) => {
|
|
173
|
+
const endpointRuleSetHttpAuthSchemeProvider = (authParameters) => {
|
|
174
|
+
const endpoint = defaultEndpointResolver(authParameters);
|
|
175
|
+
const authSchemes = endpoint.properties?.authSchemes;
|
|
176
|
+
if (!authSchemes) {
|
|
177
|
+
return defaultHttpAuthSchemeResolver(authParameters);
|
|
178
|
+
}
|
|
179
|
+
const options = [];
|
|
180
|
+
for (const scheme of authSchemes) {
|
|
181
|
+
const { name: resolvedName, properties = {}, ...rest } = scheme;
|
|
182
|
+
const name = resolvedName.toLowerCase();
|
|
183
|
+
if (resolvedName !== name) {
|
|
184
|
+
console.warn(`HttpAuthScheme has been normalized with lowercasing: '${resolvedName}' to '${name}'`);
|
|
185
|
+
}
|
|
186
|
+
let schemeId;
|
|
187
|
+
if (name === "sigv4a") {
|
|
188
|
+
schemeId = "aws.auth#sigv4a";
|
|
189
|
+
const sigv4Present = authSchemes.find((s) => {
|
|
190
|
+
const name = s.name.toLowerCase();
|
|
191
|
+
return name !== "sigv4a" && name.startsWith("sigv4");
|
|
192
|
+
});
|
|
193
|
+
if (SignatureV4MultiRegion.sigv4aDependency() === "none" && sigv4Present) {
|
|
194
|
+
continue;
|
|
195
|
+
}
|
|
196
|
+
}
|
|
197
|
+
else if (name.startsWith("sigv4")) {
|
|
198
|
+
schemeId = "aws.auth#sigv4";
|
|
199
|
+
}
|
|
200
|
+
else {
|
|
201
|
+
throw new Error(`Unknown HttpAuthScheme found in '@smithy.rules#endpointRuleSet': '${name}'`);
|
|
202
|
+
}
|
|
203
|
+
const createOption = createHttpAuthOptionFunctions[schemeId];
|
|
204
|
+
if (!createOption) {
|
|
205
|
+
throw new Error(`Could not find HttpAuthOption create function for '${schemeId}'`);
|
|
206
|
+
}
|
|
207
|
+
const option = createOption(authParameters);
|
|
208
|
+
option.schemeId = schemeId;
|
|
209
|
+
option.signingProperties = { ...(option.signingProperties || {}), ...rest, ...properties };
|
|
210
|
+
options.push(option);
|
|
211
|
+
}
|
|
212
|
+
return options;
|
|
213
|
+
};
|
|
214
|
+
return endpointRuleSetHttpAuthSchemeProvider;
|
|
215
|
+
};
|
|
216
|
+
const _defaultSTSHttpAuthSchemeProvider = (authParameters) => {
|
|
217
|
+
const options = [];
|
|
218
|
+
switch (authParameters.operation) {
|
|
219
|
+
case "AssumeRoleWithSAML": {
|
|
220
|
+
options.push(createSmithyApiNoAuthHttpAuthOption());
|
|
221
|
+
options.push(createAwsAuthSigv4aHttpAuthOption(authParameters));
|
|
222
|
+
break;
|
|
223
|
+
}
|
|
224
|
+
case "AssumeRoleWithWebIdentity": {
|
|
225
|
+
options.push(createSmithyApiNoAuthHttpAuthOption());
|
|
226
|
+
options.push(createAwsAuthSigv4aHttpAuthOption(authParameters));
|
|
227
|
+
break;
|
|
228
|
+
}
|
|
229
|
+
default: {
|
|
230
|
+
options.push(createAwsAuthSigv4HttpAuthOption(authParameters));
|
|
231
|
+
options.push(createAwsAuthSigv4aHttpAuthOption(authParameters));
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
return options;
|
|
235
|
+
};
|
|
236
|
+
const defaultSTSHttpAuthSchemeProvider = createEndpointRuleSetHttpAuthSchemeProvider(defaultEndpointResolver, _defaultSTSHttpAuthSchemeProvider, {
|
|
237
|
+
"aws.auth#sigv4": createAwsAuthSigv4HttpAuthOption,
|
|
238
|
+
"aws.auth#sigv4a": createAwsAuthSigv4aHttpAuthOption,
|
|
239
|
+
"smithy.api#noAuth": createSmithyApiNoAuthHttpAuthOption,
|
|
240
|
+
});
|
|
241
|
+
const resolveHttpAuthSchemeConfig = (config) => {
|
|
242
|
+
const config_0 = resolveAwsSdkSigV4Config(config);
|
|
243
|
+
const config_1 = resolveAwsSdkSigV4AConfig(config_0);
|
|
244
|
+
return Object.assign(config_1, {
|
|
245
|
+
authSchemePreference: normalizeProvider(config.authSchemePreference ?? []),
|
|
246
|
+
});
|
|
247
|
+
};
|
|
19
248
|
|
|
20
249
|
const resolveClientEndpointParameters = (options) => {
|
|
21
250
|
return Object.assign(options, {
|
|
@@ -33,6 +262,639 @@ const commonParams = {
|
|
|
33
262
|
UseDualStack: { type: "builtInParams", name: "useDualstackEndpoint" },
|
|
34
263
|
};
|
|
35
264
|
|
|
265
|
+
var version = "3.1075.0";
|
|
266
|
+
var packageInfo = {
|
|
267
|
+
version: version};
|
|
268
|
+
|
|
269
|
+
class STSServiceException extends ServiceException {
|
|
270
|
+
constructor(options) {
|
|
271
|
+
super(options);
|
|
272
|
+
Object.setPrototypeOf(this, STSServiceException.prototype);
|
|
273
|
+
}
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
class ExpiredTokenException extends STSServiceException {
|
|
277
|
+
name = "ExpiredTokenException";
|
|
278
|
+
$fault = "client";
|
|
279
|
+
constructor(opts) {
|
|
280
|
+
super({
|
|
281
|
+
name: "ExpiredTokenException",
|
|
282
|
+
$fault: "client",
|
|
283
|
+
...opts,
|
|
284
|
+
});
|
|
285
|
+
Object.setPrototypeOf(this, ExpiredTokenException.prototype);
|
|
286
|
+
}
|
|
287
|
+
}
|
|
288
|
+
class MalformedPolicyDocumentException extends STSServiceException {
|
|
289
|
+
name = "MalformedPolicyDocumentException";
|
|
290
|
+
$fault = "client";
|
|
291
|
+
constructor(opts) {
|
|
292
|
+
super({
|
|
293
|
+
name: "MalformedPolicyDocumentException",
|
|
294
|
+
$fault: "client",
|
|
295
|
+
...opts,
|
|
296
|
+
});
|
|
297
|
+
Object.setPrototypeOf(this, MalformedPolicyDocumentException.prototype);
|
|
298
|
+
}
|
|
299
|
+
}
|
|
300
|
+
class PackedPolicyTooLargeException extends STSServiceException {
|
|
301
|
+
name = "PackedPolicyTooLargeException";
|
|
302
|
+
$fault = "client";
|
|
303
|
+
constructor(opts) {
|
|
304
|
+
super({
|
|
305
|
+
name: "PackedPolicyTooLargeException",
|
|
306
|
+
$fault: "client",
|
|
307
|
+
...opts,
|
|
308
|
+
});
|
|
309
|
+
Object.setPrototypeOf(this, PackedPolicyTooLargeException.prototype);
|
|
310
|
+
}
|
|
311
|
+
}
|
|
312
|
+
class RegionDisabledException extends STSServiceException {
|
|
313
|
+
name = "RegionDisabledException";
|
|
314
|
+
$fault = "client";
|
|
315
|
+
constructor(opts) {
|
|
316
|
+
super({
|
|
317
|
+
name: "RegionDisabledException",
|
|
318
|
+
$fault: "client",
|
|
319
|
+
...opts,
|
|
320
|
+
});
|
|
321
|
+
Object.setPrototypeOf(this, RegionDisabledException.prototype);
|
|
322
|
+
}
|
|
323
|
+
}
|
|
324
|
+
class IDPRejectedClaimException extends STSServiceException {
|
|
325
|
+
name = "IDPRejectedClaimException";
|
|
326
|
+
$fault = "client";
|
|
327
|
+
constructor(opts) {
|
|
328
|
+
super({
|
|
329
|
+
name: "IDPRejectedClaimException",
|
|
330
|
+
$fault: "client",
|
|
331
|
+
...opts,
|
|
332
|
+
});
|
|
333
|
+
Object.setPrototypeOf(this, IDPRejectedClaimException.prototype);
|
|
334
|
+
}
|
|
335
|
+
}
|
|
336
|
+
class InvalidIdentityTokenException extends STSServiceException {
|
|
337
|
+
name = "InvalidIdentityTokenException";
|
|
338
|
+
$fault = "client";
|
|
339
|
+
constructor(opts) {
|
|
340
|
+
super({
|
|
341
|
+
name: "InvalidIdentityTokenException",
|
|
342
|
+
$fault: "client",
|
|
343
|
+
...opts,
|
|
344
|
+
});
|
|
345
|
+
Object.setPrototypeOf(this, InvalidIdentityTokenException.prototype);
|
|
346
|
+
}
|
|
347
|
+
}
|
|
348
|
+
class IDPCommunicationErrorException extends STSServiceException {
|
|
349
|
+
name = "IDPCommunicationErrorException";
|
|
350
|
+
$fault = "client";
|
|
351
|
+
$retryable = {};
|
|
352
|
+
constructor(opts) {
|
|
353
|
+
super({
|
|
354
|
+
name: "IDPCommunicationErrorException",
|
|
355
|
+
$fault: "client",
|
|
356
|
+
...opts,
|
|
357
|
+
});
|
|
358
|
+
Object.setPrototypeOf(this, IDPCommunicationErrorException.prototype);
|
|
359
|
+
}
|
|
360
|
+
}
|
|
361
|
+
class InvalidAuthorizationMessageException extends STSServiceException {
|
|
362
|
+
name = "InvalidAuthorizationMessageException";
|
|
363
|
+
$fault = "client";
|
|
364
|
+
constructor(opts) {
|
|
365
|
+
super({
|
|
366
|
+
name: "InvalidAuthorizationMessageException",
|
|
367
|
+
$fault: "client",
|
|
368
|
+
...opts,
|
|
369
|
+
});
|
|
370
|
+
Object.setPrototypeOf(this, InvalidAuthorizationMessageException.prototype);
|
|
371
|
+
}
|
|
372
|
+
}
|
|
373
|
+
class ExpiredTradeInTokenException extends STSServiceException {
|
|
374
|
+
name = "ExpiredTradeInTokenException";
|
|
375
|
+
$fault = "client";
|
|
376
|
+
constructor(opts) {
|
|
377
|
+
super({
|
|
378
|
+
name: "ExpiredTradeInTokenException",
|
|
379
|
+
$fault: "client",
|
|
380
|
+
...opts,
|
|
381
|
+
});
|
|
382
|
+
Object.setPrototypeOf(this, ExpiredTradeInTokenException.prototype);
|
|
383
|
+
}
|
|
384
|
+
}
|
|
385
|
+
class JWTPayloadSizeExceededException extends STSServiceException {
|
|
386
|
+
name = "JWTPayloadSizeExceededException";
|
|
387
|
+
$fault = "client";
|
|
388
|
+
constructor(opts) {
|
|
389
|
+
super({
|
|
390
|
+
name: "JWTPayloadSizeExceededException",
|
|
391
|
+
$fault: "client",
|
|
392
|
+
...opts,
|
|
393
|
+
});
|
|
394
|
+
Object.setPrototypeOf(this, JWTPayloadSizeExceededException.prototype);
|
|
395
|
+
}
|
|
396
|
+
}
|
|
397
|
+
class OutboundWebIdentityFederationDisabledException extends STSServiceException {
|
|
398
|
+
name = "OutboundWebIdentityFederationDisabledException";
|
|
399
|
+
$fault = "client";
|
|
400
|
+
constructor(opts) {
|
|
401
|
+
super({
|
|
402
|
+
name: "OutboundWebIdentityFederationDisabledException",
|
|
403
|
+
$fault: "client",
|
|
404
|
+
...opts,
|
|
405
|
+
});
|
|
406
|
+
Object.setPrototypeOf(this, OutboundWebIdentityFederationDisabledException.prototype);
|
|
407
|
+
}
|
|
408
|
+
}
|
|
409
|
+
class SessionDurationEscalationException extends STSServiceException {
|
|
410
|
+
name = "SessionDurationEscalationException";
|
|
411
|
+
$fault = "client";
|
|
412
|
+
constructor(opts) {
|
|
413
|
+
super({
|
|
414
|
+
name: "SessionDurationEscalationException",
|
|
415
|
+
$fault: "client",
|
|
416
|
+
...opts,
|
|
417
|
+
});
|
|
418
|
+
Object.setPrototypeOf(this, SessionDurationEscalationException.prototype);
|
|
419
|
+
}
|
|
420
|
+
}
|
|
421
|
+
|
|
422
|
+
const _A = "Arn";
|
|
423
|
+
const _AKI = "AccessKeyId";
|
|
424
|
+
const _AP = "AssumedPrincipal";
|
|
425
|
+
const _AR = "AssumeRole";
|
|
426
|
+
const _ARI = "AssumedRoleId";
|
|
427
|
+
const _ARR = "AssumeRoleRequest";
|
|
428
|
+
const _ARRs = "AssumeRoleResponse";
|
|
429
|
+
const _ARRss = "AssumeRootRequest";
|
|
430
|
+
const _ARRssu = "AssumeRootResponse";
|
|
431
|
+
const _ARU = "AssumedRoleUser";
|
|
432
|
+
const _ARWSAML = "AssumeRoleWithSAML";
|
|
433
|
+
const _ARWSAMLR = "AssumeRoleWithSAMLRequest";
|
|
434
|
+
const _ARWSAMLRs = "AssumeRoleWithSAMLResponse";
|
|
435
|
+
const _ARWWI = "AssumeRoleWithWebIdentity";
|
|
436
|
+
const _ARWWIR = "AssumeRoleWithWebIdentityRequest";
|
|
437
|
+
const _ARWWIRs = "AssumeRoleWithWebIdentityResponse";
|
|
438
|
+
const _ARs = "AssumeRoot";
|
|
439
|
+
const _Ac = "Account";
|
|
440
|
+
const _Au = "Audience";
|
|
441
|
+
const _C = "Credentials";
|
|
442
|
+
const _CA = "ContextAssertion";
|
|
443
|
+
const _DAM = "DecodeAuthorizationMessage";
|
|
444
|
+
const _DAMR = "DecodeAuthorizationMessageRequest";
|
|
445
|
+
const _DAMRe = "DecodeAuthorizationMessageResponse";
|
|
446
|
+
const _DM = "DecodedMessage";
|
|
447
|
+
const _DS = "DurationSeconds";
|
|
448
|
+
const _E = "Expiration";
|
|
449
|
+
const _EI = "ExternalId";
|
|
450
|
+
const _EM = "EncodedMessage";
|
|
451
|
+
const _ETE = "ExpiredTokenException";
|
|
452
|
+
const _ETITE = "ExpiredTradeInTokenException";
|
|
453
|
+
const _FU = "FederatedUser";
|
|
454
|
+
const _FUI = "FederatedUserId";
|
|
455
|
+
const _GAKI = "GetAccessKeyInfo";
|
|
456
|
+
const _GAKIR = "GetAccessKeyInfoRequest";
|
|
457
|
+
const _GAKIRe = "GetAccessKeyInfoResponse";
|
|
458
|
+
const _GCI = "GetCallerIdentity";
|
|
459
|
+
const _GCIR = "GetCallerIdentityRequest";
|
|
460
|
+
const _GCIRe = "GetCallerIdentityResponse";
|
|
461
|
+
const _GDAT = "GetDelegatedAccessToken";
|
|
462
|
+
const _GDATR = "GetDelegatedAccessTokenRequest";
|
|
463
|
+
const _GDATRe = "GetDelegatedAccessTokenResponse";
|
|
464
|
+
const _GFT = "GetFederationToken";
|
|
465
|
+
const _GFTR = "GetFederationTokenRequest";
|
|
466
|
+
const _GFTRe = "GetFederationTokenResponse";
|
|
467
|
+
const _GST = "GetSessionToken";
|
|
468
|
+
const _GSTR = "GetSessionTokenRequest";
|
|
469
|
+
const _GSTRe = "GetSessionTokenResponse";
|
|
470
|
+
const _GWIT = "GetWebIdentityToken";
|
|
471
|
+
const _GWITR = "GetWebIdentityTokenRequest";
|
|
472
|
+
const _GWITRe = "GetWebIdentityTokenResponse";
|
|
473
|
+
const _I = "Issuer";
|
|
474
|
+
const _IAME = "InvalidAuthorizationMessageException";
|
|
475
|
+
const _IDPCEE = "IDPCommunicationErrorException";
|
|
476
|
+
const _IDPRCE = "IDPRejectedClaimException";
|
|
477
|
+
const _IITE = "InvalidIdentityTokenException";
|
|
478
|
+
const _JWTPSEE = "JWTPayloadSizeExceededException";
|
|
479
|
+
const _K = "Key";
|
|
480
|
+
const _MPDE = "MalformedPolicyDocumentException";
|
|
481
|
+
const _N = "Name";
|
|
482
|
+
const _NQ = "NameQualifier";
|
|
483
|
+
const _OWIFDE = "OutboundWebIdentityFederationDisabledException";
|
|
484
|
+
const _P = "Policy";
|
|
485
|
+
const _PA = "PolicyArns";
|
|
486
|
+
const _PAr = "PrincipalArn";
|
|
487
|
+
const _PAro = "ProviderArn";
|
|
488
|
+
const _PC = "ProvidedContexts";
|
|
489
|
+
const _PCLT = "ProvidedContextsListType";
|
|
490
|
+
const _PCr = "ProvidedContext";
|
|
491
|
+
const _PDT = "PolicyDescriptorType";
|
|
492
|
+
const _PI = "ProviderId";
|
|
493
|
+
const _PPS = "PackedPolicySize";
|
|
494
|
+
const _PPTLE = "PackedPolicyTooLargeException";
|
|
495
|
+
const _Pr = "Provider";
|
|
496
|
+
const _RA = "RoleArn";
|
|
497
|
+
const _RDE = "RegionDisabledException";
|
|
498
|
+
const _RSN = "RoleSessionName";
|
|
499
|
+
const _S = "Subject";
|
|
500
|
+
const _SA = "SigningAlgorithm";
|
|
501
|
+
const _SAK = "SecretAccessKey";
|
|
502
|
+
const _SAMLA = "SAMLAssertion";
|
|
503
|
+
const _SAMLAT = "SAMLAssertionType";
|
|
504
|
+
const _SDEE = "SessionDurationEscalationException";
|
|
505
|
+
const _SFWIT = "SubjectFromWebIdentityToken";
|
|
506
|
+
const _SI = "SourceIdentity";
|
|
507
|
+
const _SN = "SerialNumber";
|
|
508
|
+
const _ST = "SubjectType";
|
|
509
|
+
const _STe = "SessionToken";
|
|
510
|
+
const _T = "Tags";
|
|
511
|
+
const _TC = "TokenCode";
|
|
512
|
+
const _TIT = "TradeInToken";
|
|
513
|
+
const _TP = "TargetPrincipal";
|
|
514
|
+
const _TPA = "TaskPolicyArn";
|
|
515
|
+
const _TTK = "TransitiveTagKeys";
|
|
516
|
+
const _Ta = "Tag";
|
|
517
|
+
const _UI = "UserId";
|
|
518
|
+
const _V = "Value";
|
|
519
|
+
const _WIT = "WebIdentityToken";
|
|
520
|
+
const _a = "arn";
|
|
521
|
+
const _aKST = "accessKeySecretType";
|
|
522
|
+
const _aQE = "awsQueryError";
|
|
523
|
+
const _c = "client";
|
|
524
|
+
const _cTT = "clientTokenType";
|
|
525
|
+
const _e = "error";
|
|
526
|
+
const _hE = "httpError";
|
|
527
|
+
const _m = "message";
|
|
528
|
+
const _pDLT = "policyDescriptorListType";
|
|
529
|
+
const _s = "smithy.ts.sdk.synthetic.com.amazonaws.sts";
|
|
530
|
+
const _tITT = "tradeInTokenType";
|
|
531
|
+
const _tLT = "tagListType";
|
|
532
|
+
const _wITT = "webIdentityTokenType";
|
|
533
|
+
const n0 = "com.amazonaws.sts";
|
|
534
|
+
const _s_registry = TypeRegistry.for(_s);
|
|
535
|
+
var STSServiceException$ = [-3, _s, "STSServiceException", 0, [], []];
|
|
536
|
+
_s_registry.registerError(STSServiceException$, STSServiceException);
|
|
537
|
+
const n0_registry = TypeRegistry.for(n0);
|
|
538
|
+
var ExpiredTokenException$ = [-3, n0, _ETE,
|
|
539
|
+
{ [_aQE]: [`ExpiredTokenException`, 400], [_e]: _c, [_hE]: 400 },
|
|
540
|
+
[_m],
|
|
541
|
+
[0]
|
|
542
|
+
];
|
|
543
|
+
n0_registry.registerError(ExpiredTokenException$, ExpiredTokenException);
|
|
544
|
+
var ExpiredTradeInTokenException$ = [-3, n0, _ETITE,
|
|
545
|
+
{ [_aQE]: [`ExpiredTradeInTokenException`, 400], [_e]: _c, [_hE]: 400 },
|
|
546
|
+
[_m],
|
|
547
|
+
[0]
|
|
548
|
+
];
|
|
549
|
+
n0_registry.registerError(ExpiredTradeInTokenException$, ExpiredTradeInTokenException);
|
|
550
|
+
var IDPCommunicationErrorException$ = [-3, n0, _IDPCEE,
|
|
551
|
+
{ [_aQE]: [`IDPCommunicationError`, 400], [_e]: _c, [_hE]: 400 },
|
|
552
|
+
[_m],
|
|
553
|
+
[0]
|
|
554
|
+
];
|
|
555
|
+
n0_registry.registerError(IDPCommunicationErrorException$, IDPCommunicationErrorException);
|
|
556
|
+
var IDPRejectedClaimException$ = [-3, n0, _IDPRCE,
|
|
557
|
+
{ [_aQE]: [`IDPRejectedClaim`, 403], [_e]: _c, [_hE]: 403 },
|
|
558
|
+
[_m],
|
|
559
|
+
[0]
|
|
560
|
+
];
|
|
561
|
+
n0_registry.registerError(IDPRejectedClaimException$, IDPRejectedClaimException);
|
|
562
|
+
var InvalidAuthorizationMessageException$ = [-3, n0, _IAME,
|
|
563
|
+
{ [_aQE]: [`InvalidAuthorizationMessageException`, 400], [_e]: _c, [_hE]: 400 },
|
|
564
|
+
[_m],
|
|
565
|
+
[0]
|
|
566
|
+
];
|
|
567
|
+
n0_registry.registerError(InvalidAuthorizationMessageException$, InvalidAuthorizationMessageException);
|
|
568
|
+
var InvalidIdentityTokenException$ = [-3, n0, _IITE,
|
|
569
|
+
{ [_aQE]: [`InvalidIdentityToken`, 400], [_e]: _c, [_hE]: 400 },
|
|
570
|
+
[_m],
|
|
571
|
+
[0]
|
|
572
|
+
];
|
|
573
|
+
n0_registry.registerError(InvalidIdentityTokenException$, InvalidIdentityTokenException);
|
|
574
|
+
var JWTPayloadSizeExceededException$ = [-3, n0, _JWTPSEE,
|
|
575
|
+
{ [_aQE]: [`JWTPayloadSizeExceededException`, 400], [_e]: _c, [_hE]: 400 },
|
|
576
|
+
[_m],
|
|
577
|
+
[0]
|
|
578
|
+
];
|
|
579
|
+
n0_registry.registerError(JWTPayloadSizeExceededException$, JWTPayloadSizeExceededException);
|
|
580
|
+
var MalformedPolicyDocumentException$ = [-3, n0, _MPDE,
|
|
581
|
+
{ [_aQE]: [`MalformedPolicyDocument`, 400], [_e]: _c, [_hE]: 400 },
|
|
582
|
+
[_m],
|
|
583
|
+
[0]
|
|
584
|
+
];
|
|
585
|
+
n0_registry.registerError(MalformedPolicyDocumentException$, MalformedPolicyDocumentException);
|
|
586
|
+
var OutboundWebIdentityFederationDisabledException$ = [-3, n0, _OWIFDE,
|
|
587
|
+
{ [_aQE]: [`OutboundWebIdentityFederationDisabledException`, 403], [_e]: _c, [_hE]: 403 },
|
|
588
|
+
[_m],
|
|
589
|
+
[0]
|
|
590
|
+
];
|
|
591
|
+
n0_registry.registerError(OutboundWebIdentityFederationDisabledException$, OutboundWebIdentityFederationDisabledException);
|
|
592
|
+
var PackedPolicyTooLargeException$ = [-3, n0, _PPTLE,
|
|
593
|
+
{ [_aQE]: [`PackedPolicyTooLarge`, 400], [_e]: _c, [_hE]: 400 },
|
|
594
|
+
[_m],
|
|
595
|
+
[0]
|
|
596
|
+
];
|
|
597
|
+
n0_registry.registerError(PackedPolicyTooLargeException$, PackedPolicyTooLargeException);
|
|
598
|
+
var RegionDisabledException$ = [-3, n0, _RDE,
|
|
599
|
+
{ [_aQE]: [`RegionDisabledException`, 403], [_e]: _c, [_hE]: 403 },
|
|
600
|
+
[_m],
|
|
601
|
+
[0]
|
|
602
|
+
];
|
|
603
|
+
n0_registry.registerError(RegionDisabledException$, RegionDisabledException);
|
|
604
|
+
var SessionDurationEscalationException$ = [-3, n0, _SDEE,
|
|
605
|
+
{ [_aQE]: [`SessionDurationEscalationException`, 403], [_e]: _c, [_hE]: 403 },
|
|
606
|
+
[_m],
|
|
607
|
+
[0]
|
|
608
|
+
];
|
|
609
|
+
n0_registry.registerError(SessionDurationEscalationException$, SessionDurationEscalationException);
|
|
610
|
+
const errorTypeRegistries = [
|
|
611
|
+
_s_registry,
|
|
612
|
+
n0_registry,
|
|
613
|
+
];
|
|
614
|
+
var accessKeySecretType = [0, n0, _aKST, 8, 0];
|
|
615
|
+
var clientTokenType = [0, n0, _cTT, 8, 0];
|
|
616
|
+
var SAMLAssertionType = [0, n0, _SAMLAT, 8, 0];
|
|
617
|
+
var tradeInTokenType = [0, n0, _tITT, 8, 0];
|
|
618
|
+
var webIdentityTokenType = [0, n0, _wITT, 8, 0];
|
|
619
|
+
var AssumedRoleUser$ = [3, n0, _ARU,
|
|
620
|
+
0,
|
|
621
|
+
[_ARI, _A],
|
|
622
|
+
[0, 0], 2
|
|
623
|
+
];
|
|
624
|
+
var AssumeRoleRequest$ = [3, n0, _ARR,
|
|
625
|
+
0,
|
|
626
|
+
[_RA, _RSN, _PA, _P, _DS, _T, _TTK, _EI, _SN, _TC, _SI, _PC],
|
|
627
|
+
[0, 0, () => policyDescriptorListType, 0, 1, () => tagListType, 64 | 0, 0, 0, 0, 0, () => ProvidedContextsListType], 2
|
|
628
|
+
];
|
|
629
|
+
var AssumeRoleResponse$ = [3, n0, _ARRs,
|
|
630
|
+
0,
|
|
631
|
+
[_C, _ARU, _PPS, _SI],
|
|
632
|
+
[[() => Credentials$, 0], () => AssumedRoleUser$, 1, 0]
|
|
633
|
+
];
|
|
634
|
+
var AssumeRoleWithSAMLRequest$ = [3, n0, _ARWSAMLR,
|
|
635
|
+
0,
|
|
636
|
+
[_RA, _PAr, _SAMLA, _PA, _P, _DS],
|
|
637
|
+
[0, 0, [() => SAMLAssertionType, 0], () => policyDescriptorListType, 0, 1], 3
|
|
638
|
+
];
|
|
639
|
+
var AssumeRoleWithSAMLResponse$ = [3, n0, _ARWSAMLRs,
|
|
640
|
+
0,
|
|
641
|
+
[_C, _ARU, _PPS, _S, _ST, _I, _Au, _NQ, _SI],
|
|
642
|
+
[[() => Credentials$, 0], () => AssumedRoleUser$, 1, 0, 0, 0, 0, 0, 0]
|
|
643
|
+
];
|
|
644
|
+
var AssumeRoleWithWebIdentityRequest$ = [3, n0, _ARWWIR,
|
|
645
|
+
0,
|
|
646
|
+
[_RA, _RSN, _WIT, _PI, _PA, _P, _DS],
|
|
647
|
+
[0, 0, [() => clientTokenType, 0], 0, () => policyDescriptorListType, 0, 1], 3
|
|
648
|
+
];
|
|
649
|
+
var AssumeRoleWithWebIdentityResponse$ = [3, n0, _ARWWIRs,
|
|
650
|
+
0,
|
|
651
|
+
[_C, _SFWIT, _ARU, _PPS, _Pr, _Au, _SI],
|
|
652
|
+
[[() => Credentials$, 0], 0, () => AssumedRoleUser$, 1, 0, 0, 0]
|
|
653
|
+
];
|
|
654
|
+
var AssumeRootRequest$ = [3, n0, _ARRss,
|
|
655
|
+
0,
|
|
656
|
+
[_TP, _TPA, _DS],
|
|
657
|
+
[0, () => PolicyDescriptorType$, 1], 2
|
|
658
|
+
];
|
|
659
|
+
var AssumeRootResponse$ = [3, n0, _ARRssu,
|
|
660
|
+
0,
|
|
661
|
+
[_C, _SI],
|
|
662
|
+
[[() => Credentials$, 0], 0]
|
|
663
|
+
];
|
|
664
|
+
var Credentials$ = [3, n0, _C,
|
|
665
|
+
0,
|
|
666
|
+
[_AKI, _SAK, _STe, _E],
|
|
667
|
+
[0, [() => accessKeySecretType, 0], 0, 4], 4
|
|
668
|
+
];
|
|
669
|
+
var DecodeAuthorizationMessageRequest$ = [3, n0, _DAMR,
|
|
670
|
+
0,
|
|
671
|
+
[_EM],
|
|
672
|
+
[0], 1
|
|
673
|
+
];
|
|
674
|
+
var DecodeAuthorizationMessageResponse$ = [3, n0, _DAMRe,
|
|
675
|
+
0,
|
|
676
|
+
[_DM],
|
|
677
|
+
[0]
|
|
678
|
+
];
|
|
679
|
+
var FederatedUser$ = [3, n0, _FU,
|
|
680
|
+
0,
|
|
681
|
+
[_FUI, _A],
|
|
682
|
+
[0, 0], 2
|
|
683
|
+
];
|
|
684
|
+
var GetAccessKeyInfoRequest$ = [3, n0, _GAKIR,
|
|
685
|
+
0,
|
|
686
|
+
[_AKI],
|
|
687
|
+
[0], 1
|
|
688
|
+
];
|
|
689
|
+
var GetAccessKeyInfoResponse$ = [3, n0, _GAKIRe,
|
|
690
|
+
0,
|
|
691
|
+
[_Ac],
|
|
692
|
+
[0]
|
|
693
|
+
];
|
|
694
|
+
var GetCallerIdentityRequest$ = [3, n0, _GCIR,
|
|
695
|
+
0,
|
|
696
|
+
[],
|
|
697
|
+
[]
|
|
698
|
+
];
|
|
699
|
+
var GetCallerIdentityResponse$ = [3, n0, _GCIRe,
|
|
700
|
+
0,
|
|
701
|
+
[_UI, _Ac, _A],
|
|
702
|
+
[0, 0, 0]
|
|
703
|
+
];
|
|
704
|
+
var GetDelegatedAccessTokenRequest$ = [3, n0, _GDATR,
|
|
705
|
+
0,
|
|
706
|
+
[_TIT],
|
|
707
|
+
[[() => tradeInTokenType, 0]], 1
|
|
708
|
+
];
|
|
709
|
+
var GetDelegatedAccessTokenResponse$ = [3, n0, _GDATRe,
|
|
710
|
+
0,
|
|
711
|
+
[_C, _PPS, _AP],
|
|
712
|
+
[[() => Credentials$, 0], 1, 0]
|
|
713
|
+
];
|
|
714
|
+
var GetFederationTokenRequest$ = [3, n0, _GFTR,
|
|
715
|
+
0,
|
|
716
|
+
[_N, _P, _PA, _DS, _T],
|
|
717
|
+
[0, 0, () => policyDescriptorListType, 1, () => tagListType], 1
|
|
718
|
+
];
|
|
719
|
+
var GetFederationTokenResponse$ = [3, n0, _GFTRe,
|
|
720
|
+
0,
|
|
721
|
+
[_C, _FU, _PPS],
|
|
722
|
+
[[() => Credentials$, 0], () => FederatedUser$, 1]
|
|
723
|
+
];
|
|
724
|
+
var GetSessionTokenRequest$ = [3, n0, _GSTR,
|
|
725
|
+
0,
|
|
726
|
+
[_DS, _SN, _TC],
|
|
727
|
+
[1, 0, 0]
|
|
728
|
+
];
|
|
729
|
+
var GetSessionTokenResponse$ = [3, n0, _GSTRe,
|
|
730
|
+
0,
|
|
731
|
+
[_C],
|
|
732
|
+
[[() => Credentials$, 0]]
|
|
733
|
+
];
|
|
734
|
+
var GetWebIdentityTokenRequest$ = [3, n0, _GWITR,
|
|
735
|
+
0,
|
|
736
|
+
[_Au, _SA, _DS, _T],
|
|
737
|
+
[64 | 0, 0, 1, () => tagListType], 2
|
|
738
|
+
];
|
|
739
|
+
var GetWebIdentityTokenResponse$ = [3, n0, _GWITRe,
|
|
740
|
+
0,
|
|
741
|
+
[_WIT, _E],
|
|
742
|
+
[[() => webIdentityTokenType, 0], 4]
|
|
743
|
+
];
|
|
744
|
+
var PolicyDescriptorType$ = [3, n0, _PDT,
|
|
745
|
+
0,
|
|
746
|
+
[_a],
|
|
747
|
+
[0]
|
|
748
|
+
];
|
|
749
|
+
var ProvidedContext$ = [3, n0, _PCr,
|
|
750
|
+
0,
|
|
751
|
+
[_PAro, _CA],
|
|
752
|
+
[0, 0]
|
|
753
|
+
];
|
|
754
|
+
var Tag$ = [3, n0, _Ta,
|
|
755
|
+
0,
|
|
756
|
+
[_K, _V],
|
|
757
|
+
[0, 0], 2
|
|
758
|
+
];
|
|
759
|
+
var policyDescriptorListType = [1, n0, _pDLT,
|
|
760
|
+
0, () => PolicyDescriptorType$
|
|
761
|
+
];
|
|
762
|
+
var ProvidedContextsListType = [1, n0, _PCLT,
|
|
763
|
+
0, () => ProvidedContext$
|
|
764
|
+
];
|
|
765
|
+
var tagListType = [1, n0, _tLT,
|
|
766
|
+
0, () => Tag$
|
|
767
|
+
];
|
|
768
|
+
var AssumeRole$ = [9, n0, _AR,
|
|
769
|
+
0, () => AssumeRoleRequest$, () => AssumeRoleResponse$
|
|
770
|
+
];
|
|
771
|
+
var AssumeRoleWithSAML$ = [9, n0, _ARWSAML,
|
|
772
|
+
0, () => AssumeRoleWithSAMLRequest$, () => AssumeRoleWithSAMLResponse$
|
|
773
|
+
];
|
|
774
|
+
var AssumeRoleWithWebIdentity$ = [9, n0, _ARWWI,
|
|
775
|
+
0, () => AssumeRoleWithWebIdentityRequest$, () => AssumeRoleWithWebIdentityResponse$
|
|
776
|
+
];
|
|
777
|
+
var AssumeRoot$ = [9, n0, _ARs,
|
|
778
|
+
0, () => AssumeRootRequest$, () => AssumeRootResponse$
|
|
779
|
+
];
|
|
780
|
+
var DecodeAuthorizationMessage$ = [9, n0, _DAM,
|
|
781
|
+
0, () => DecodeAuthorizationMessageRequest$, () => DecodeAuthorizationMessageResponse$
|
|
782
|
+
];
|
|
783
|
+
var GetAccessKeyInfo$ = [9, n0, _GAKI,
|
|
784
|
+
0, () => GetAccessKeyInfoRequest$, () => GetAccessKeyInfoResponse$
|
|
785
|
+
];
|
|
786
|
+
var GetCallerIdentity$ = [9, n0, _GCI,
|
|
787
|
+
0, () => GetCallerIdentityRequest$, () => GetCallerIdentityResponse$
|
|
788
|
+
];
|
|
789
|
+
var GetDelegatedAccessToken$ = [9, n0, _GDAT,
|
|
790
|
+
0, () => GetDelegatedAccessTokenRequest$, () => GetDelegatedAccessTokenResponse$
|
|
791
|
+
];
|
|
792
|
+
var GetFederationToken$ = [9, n0, _GFT,
|
|
793
|
+
0, () => GetFederationTokenRequest$, () => GetFederationTokenResponse$
|
|
794
|
+
];
|
|
795
|
+
var GetSessionToken$ = [9, n0, _GST,
|
|
796
|
+
0, () => GetSessionTokenRequest$, () => GetSessionTokenResponse$
|
|
797
|
+
];
|
|
798
|
+
var GetWebIdentityToken$ = [9, n0, _GWIT,
|
|
799
|
+
0, () => GetWebIdentityTokenRequest$, () => GetWebIdentityTokenResponse$
|
|
800
|
+
];
|
|
801
|
+
|
|
802
|
+
const getRuntimeConfig$1 = (config) => {
|
|
803
|
+
return {
|
|
804
|
+
apiVersion: "2011-06-15",
|
|
805
|
+
base64Decoder: config?.base64Decoder ?? fromBase64,
|
|
806
|
+
base64Encoder: config?.base64Encoder ?? toBase64,
|
|
807
|
+
disableHostPrefix: config?.disableHostPrefix ?? false,
|
|
808
|
+
endpointProvider: config?.endpointProvider ?? defaultEndpointResolver,
|
|
809
|
+
extensions: config?.extensions ?? [],
|
|
810
|
+
httpAuthSchemeProvider: config?.httpAuthSchemeProvider ?? defaultSTSHttpAuthSchemeProvider,
|
|
811
|
+
httpAuthSchemes: config?.httpAuthSchemes ?? [
|
|
812
|
+
{
|
|
813
|
+
schemeId: "aws.auth#sigv4",
|
|
814
|
+
identityProvider: (ipc) => ipc.getIdentityProvider("aws.auth#sigv4"),
|
|
815
|
+
signer: new AwsSdkSigV4Signer(),
|
|
816
|
+
},
|
|
817
|
+
{
|
|
818
|
+
schemeId: "aws.auth#sigv4a",
|
|
819
|
+
identityProvider: (ipc) => ipc.getIdentityProvider("aws.auth#sigv4a"),
|
|
820
|
+
signer: new AwsSdkSigV4ASigner(),
|
|
821
|
+
},
|
|
822
|
+
{
|
|
823
|
+
schemeId: "smithy.api#noAuth",
|
|
824
|
+
identityProvider: (ipc) => ipc.getIdentityProvider("smithy.api#noAuth") || (async () => ({})),
|
|
825
|
+
signer: new NoAuthSigner(),
|
|
826
|
+
},
|
|
827
|
+
],
|
|
828
|
+
logger: config?.logger ?? new NoOpLogger(),
|
|
829
|
+
protocol: config?.protocol ?? AwsQueryProtocol,
|
|
830
|
+
protocolSettings: config?.protocolSettings ?? {
|
|
831
|
+
defaultNamespace: "com.amazonaws.sts",
|
|
832
|
+
errorTypeRegistries,
|
|
833
|
+
xmlNamespace: "https://sts.amazonaws.com/doc/2011-06-15/",
|
|
834
|
+
version: "2011-06-15",
|
|
835
|
+
serviceTarget: "AWSSecurityTokenServiceV20110615",
|
|
836
|
+
},
|
|
837
|
+
serviceId: config?.serviceId ?? "STS",
|
|
838
|
+
signerConstructor: config?.signerConstructor ?? SignatureV4MultiRegion,
|
|
839
|
+
urlParser: config?.urlParser ?? parseUrl,
|
|
840
|
+
utf8Decoder: config?.utf8Decoder ?? fromUtf8,
|
|
841
|
+
utf8Encoder: config?.utf8Encoder ?? toUtf8,
|
|
842
|
+
};
|
|
843
|
+
};
|
|
844
|
+
|
|
845
|
+
const getRuntimeConfig = (config) => {
|
|
846
|
+
emitWarningIfUnsupportedVersion(process.version);
|
|
847
|
+
const defaultsMode = resolveDefaultsModeConfig(config);
|
|
848
|
+
const defaultConfigProvider = () => defaultsMode().then(loadConfigsForDefaultMode);
|
|
849
|
+
const clientSharedValues = getRuntimeConfig$1(config);
|
|
850
|
+
emitWarningIfUnsupportedVersion$1(process.version);
|
|
851
|
+
const loaderConfig = {
|
|
852
|
+
profile: config?.profile,
|
|
853
|
+
logger: clientSharedValues.logger,
|
|
854
|
+
};
|
|
855
|
+
return {
|
|
856
|
+
...clientSharedValues,
|
|
857
|
+
...config,
|
|
858
|
+
runtime: "node",
|
|
859
|
+
defaultsMode,
|
|
860
|
+
authSchemePreference: config?.authSchemePreference ?? loadConfig(NODE_AUTH_SCHEME_PREFERENCE_OPTIONS, loaderConfig),
|
|
861
|
+
bodyLengthChecker: config?.bodyLengthChecker ?? calculateBodyLength,
|
|
862
|
+
credentialDefaultProvider: config?.credentialDefaultProvider ?? defaultProvider,
|
|
863
|
+
defaultUserAgentProvider: config?.defaultUserAgentProvider ?? createDefaultUserAgentProvider({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }),
|
|
864
|
+
httpAuthSchemes: config?.httpAuthSchemes ?? [
|
|
865
|
+
{
|
|
866
|
+
schemeId: "aws.auth#sigv4",
|
|
867
|
+
identityProvider: (ipc) => ipc.getIdentityProvider("aws.auth#sigv4") || (async (idProps) => await defaultProvider(idProps?.__config || {})()),
|
|
868
|
+
signer: new AwsSdkSigV4Signer(),
|
|
869
|
+
},
|
|
870
|
+
{
|
|
871
|
+
schemeId: "aws.auth#sigv4a",
|
|
872
|
+
identityProvider: (ipc) => ipc.getIdentityProvider("aws.auth#sigv4a"),
|
|
873
|
+
signer: new AwsSdkSigV4ASigner(),
|
|
874
|
+
},
|
|
875
|
+
{
|
|
876
|
+
schemeId: "smithy.api#noAuth",
|
|
877
|
+
identityProvider: (ipc) => ipc.getIdentityProvider("smithy.api#noAuth") || (async () => ({})),
|
|
878
|
+
signer: new NoAuthSigner(),
|
|
879
|
+
},
|
|
880
|
+
],
|
|
881
|
+
maxAttempts: config?.maxAttempts ?? loadConfig(NODE_MAX_ATTEMPT_CONFIG_OPTIONS, config),
|
|
882
|
+
region: config?.region ?? loadConfig(NODE_REGION_CONFIG_OPTIONS, { ...NODE_REGION_CONFIG_FILE_OPTIONS, ...loaderConfig }),
|
|
883
|
+
requestHandler: NodeHttpHandler.create(config?.requestHandler ?? defaultConfigProvider),
|
|
884
|
+
retryMode: config?.retryMode ??
|
|
885
|
+
loadConfig({
|
|
886
|
+
...NODE_RETRY_MODE_CONFIG_OPTIONS,
|
|
887
|
+
default: async () => (await defaultConfigProvider()).retryMode || DEFAULT_RETRY_MODE,
|
|
888
|
+
}, config),
|
|
889
|
+
sha256: config?.sha256 ?? Hash.bind(null, "sha256"),
|
|
890
|
+
sigv4aSigningRegionSet: config?.sigv4aSigningRegionSet ?? loadConfig(NODE_SIGV4A_CONFIG_OPTIONS, loaderConfig),
|
|
891
|
+
streamCollector: config?.streamCollector ?? streamCollector,
|
|
892
|
+
useDualstackEndpoint: config?.useDualstackEndpoint ?? loadConfig(NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS, loaderConfig),
|
|
893
|
+
useFipsEndpoint: config?.useFipsEndpoint ?? loadConfig(NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS, loaderConfig),
|
|
894
|
+
userAgentAppId: config?.userAgentAppId ?? loadConfig(NODE_APP_ID_CONFIG_OPTIONS, loaderConfig),
|
|
895
|
+
};
|
|
896
|
+
};
|
|
897
|
+
|
|
36
898
|
const getHttpAuthExtensionConfiguration = (runtimeConfig) => {
|
|
37
899
|
const _httpAuthSchemes = runtimeConfig.httpAuthSchemes;
|
|
38
900
|
let _httpAuthSchemeProvider = runtimeConfig.httpAuthSchemeProvider;
|
|
@@ -383,19 +1245,85 @@ const decorateDefaultCredentialProvider = (provider) => (input) => provider({
|
|
|
383
1245
|
...input,
|
|
384
1246
|
});
|
|
385
1247
|
|
|
1248
|
+
exports.AssumeRole$ = AssumeRole$;
|
|
386
1249
|
exports.AssumeRoleCommand = AssumeRoleCommand;
|
|
1250
|
+
exports.AssumeRoleRequest$ = AssumeRoleRequest$;
|
|
1251
|
+
exports.AssumeRoleResponse$ = AssumeRoleResponse$;
|
|
1252
|
+
exports.AssumeRoleWithSAML$ = AssumeRoleWithSAML$;
|
|
387
1253
|
exports.AssumeRoleWithSAMLCommand = AssumeRoleWithSAMLCommand;
|
|
1254
|
+
exports.AssumeRoleWithSAMLRequest$ = AssumeRoleWithSAMLRequest$;
|
|
1255
|
+
exports.AssumeRoleWithSAMLResponse$ = AssumeRoleWithSAMLResponse$;
|
|
1256
|
+
exports.AssumeRoleWithWebIdentity$ = AssumeRoleWithWebIdentity$;
|
|
388
1257
|
exports.AssumeRoleWithWebIdentityCommand = AssumeRoleWithWebIdentityCommand;
|
|
1258
|
+
exports.AssumeRoleWithWebIdentityRequest$ = AssumeRoleWithWebIdentityRequest$;
|
|
1259
|
+
exports.AssumeRoleWithWebIdentityResponse$ = AssumeRoleWithWebIdentityResponse$;
|
|
1260
|
+
exports.AssumeRoot$ = AssumeRoot$;
|
|
389
1261
|
exports.AssumeRootCommand = AssumeRootCommand;
|
|
1262
|
+
exports.AssumeRootRequest$ = AssumeRootRequest$;
|
|
1263
|
+
exports.AssumeRootResponse$ = AssumeRootResponse$;
|
|
1264
|
+
exports.AssumedRoleUser$ = AssumedRoleUser$;
|
|
1265
|
+
exports.Credentials$ = Credentials$;
|
|
1266
|
+
exports.DecodeAuthorizationMessage$ = DecodeAuthorizationMessage$;
|
|
390
1267
|
exports.DecodeAuthorizationMessageCommand = DecodeAuthorizationMessageCommand;
|
|
1268
|
+
exports.DecodeAuthorizationMessageRequest$ = DecodeAuthorizationMessageRequest$;
|
|
1269
|
+
exports.DecodeAuthorizationMessageResponse$ = DecodeAuthorizationMessageResponse$;
|
|
1270
|
+
exports.ExpiredTokenException = ExpiredTokenException;
|
|
1271
|
+
exports.ExpiredTokenException$ = ExpiredTokenException$;
|
|
1272
|
+
exports.ExpiredTradeInTokenException = ExpiredTradeInTokenException;
|
|
1273
|
+
exports.ExpiredTradeInTokenException$ = ExpiredTradeInTokenException$;
|
|
1274
|
+
exports.FederatedUser$ = FederatedUser$;
|
|
1275
|
+
exports.GetAccessKeyInfo$ = GetAccessKeyInfo$;
|
|
391
1276
|
exports.GetAccessKeyInfoCommand = GetAccessKeyInfoCommand;
|
|
1277
|
+
exports.GetAccessKeyInfoRequest$ = GetAccessKeyInfoRequest$;
|
|
1278
|
+
exports.GetAccessKeyInfoResponse$ = GetAccessKeyInfoResponse$;
|
|
1279
|
+
exports.GetCallerIdentity$ = GetCallerIdentity$;
|
|
392
1280
|
exports.GetCallerIdentityCommand = GetCallerIdentityCommand;
|
|
1281
|
+
exports.GetCallerIdentityRequest$ = GetCallerIdentityRequest$;
|
|
1282
|
+
exports.GetCallerIdentityResponse$ = GetCallerIdentityResponse$;
|
|
1283
|
+
exports.GetDelegatedAccessToken$ = GetDelegatedAccessToken$;
|
|
393
1284
|
exports.GetDelegatedAccessTokenCommand = GetDelegatedAccessTokenCommand;
|
|
1285
|
+
exports.GetDelegatedAccessTokenRequest$ = GetDelegatedAccessTokenRequest$;
|
|
1286
|
+
exports.GetDelegatedAccessTokenResponse$ = GetDelegatedAccessTokenResponse$;
|
|
1287
|
+
exports.GetFederationToken$ = GetFederationToken$;
|
|
394
1288
|
exports.GetFederationTokenCommand = GetFederationTokenCommand;
|
|
1289
|
+
exports.GetFederationTokenRequest$ = GetFederationTokenRequest$;
|
|
1290
|
+
exports.GetFederationTokenResponse$ = GetFederationTokenResponse$;
|
|
1291
|
+
exports.GetSessionToken$ = GetSessionToken$;
|
|
395
1292
|
exports.GetSessionTokenCommand = GetSessionTokenCommand;
|
|
1293
|
+
exports.GetSessionTokenRequest$ = GetSessionTokenRequest$;
|
|
1294
|
+
exports.GetSessionTokenResponse$ = GetSessionTokenResponse$;
|
|
1295
|
+
exports.GetWebIdentityToken$ = GetWebIdentityToken$;
|
|
396
1296
|
exports.GetWebIdentityTokenCommand = GetWebIdentityTokenCommand;
|
|
1297
|
+
exports.GetWebIdentityTokenRequest$ = GetWebIdentityTokenRequest$;
|
|
1298
|
+
exports.GetWebIdentityTokenResponse$ = GetWebIdentityTokenResponse$;
|
|
1299
|
+
exports.IDPCommunicationErrorException = IDPCommunicationErrorException;
|
|
1300
|
+
exports.IDPCommunicationErrorException$ = IDPCommunicationErrorException$;
|
|
1301
|
+
exports.IDPRejectedClaimException = IDPRejectedClaimException;
|
|
1302
|
+
exports.IDPRejectedClaimException$ = IDPRejectedClaimException$;
|
|
1303
|
+
exports.InvalidAuthorizationMessageException = InvalidAuthorizationMessageException;
|
|
1304
|
+
exports.InvalidAuthorizationMessageException$ = InvalidAuthorizationMessageException$;
|
|
1305
|
+
exports.InvalidIdentityTokenException = InvalidIdentityTokenException;
|
|
1306
|
+
exports.InvalidIdentityTokenException$ = InvalidIdentityTokenException$;
|
|
1307
|
+
exports.JWTPayloadSizeExceededException = JWTPayloadSizeExceededException;
|
|
1308
|
+
exports.JWTPayloadSizeExceededException$ = JWTPayloadSizeExceededException$;
|
|
1309
|
+
exports.MalformedPolicyDocumentException = MalformedPolicyDocumentException;
|
|
1310
|
+
exports.MalformedPolicyDocumentException$ = MalformedPolicyDocumentException$;
|
|
1311
|
+
exports.OutboundWebIdentityFederationDisabledException = OutboundWebIdentityFederationDisabledException;
|
|
1312
|
+
exports.OutboundWebIdentityFederationDisabledException$ = OutboundWebIdentityFederationDisabledException$;
|
|
1313
|
+
exports.PackedPolicyTooLargeException = PackedPolicyTooLargeException;
|
|
1314
|
+
exports.PackedPolicyTooLargeException$ = PackedPolicyTooLargeException$;
|
|
1315
|
+
exports.PolicyDescriptorType$ = PolicyDescriptorType$;
|
|
1316
|
+
exports.ProvidedContext$ = ProvidedContext$;
|
|
1317
|
+
exports.RegionDisabledException = RegionDisabledException;
|
|
1318
|
+
exports.RegionDisabledException$ = RegionDisabledException$;
|
|
397
1319
|
exports.STS = STS;
|
|
398
1320
|
exports.STSClient = STSClient;
|
|
1321
|
+
exports.STSServiceException = STSServiceException;
|
|
1322
|
+
exports.STSServiceException$ = STSServiceException$;
|
|
1323
|
+
exports.SessionDurationEscalationException = SessionDurationEscalationException;
|
|
1324
|
+
exports.SessionDurationEscalationException$ = SessionDurationEscalationException$;
|
|
1325
|
+
exports.Tag$ = Tag$;
|
|
399
1326
|
exports.decorateDefaultCredentialProvider = decorateDefaultCredentialProvider;
|
|
1327
|
+
exports.errorTypeRegistries = errorTypeRegistries;
|
|
400
1328
|
exports.getDefaultRoleAssumer = getDefaultRoleAssumer;
|
|
401
1329
|
exports.getDefaultRoleAssumerWithWebIdentity = getDefaultRoleAssumerWithWebIdentity;
|