@granite-js/pulumi-aws 0.1.34 → 1.0.1
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/CHANGELOG.md +4 -116
- package/dist/chunk-23MVQUOJ.js +1630 -0
- package/dist/chunk-24XYHOWM.js +171 -0
- package/dist/chunk-3AVBP57V.js +1598 -0
- package/dist/chunk-3JKQPIJ2.js +460 -0
- package/dist/{chunk-ITI6QA2Q.js → chunk-3OYGHA4S.js} +1 -1
- package/dist/{chunk-IEZY5C3G.js → chunk-46DIC54Q.js} +49 -37
- package/dist/chunk-57WYIP4I.js +808 -0
- package/dist/{chunk-WCHHWTND.js → chunk-63Q3RLAK.js} +93 -59
- package/dist/chunk-6KRYZP6R.js +28 -0
- package/dist/{chunk-QAE2S7MG.js → chunk-7NN7DVGK.js} +2050 -552
- package/dist/{chunk-5W7B34BN.js → chunk-ASGFIK4A.js} +2231 -464
- package/dist/chunk-BTBQTDRJ.js +174 -0
- package/dist/chunk-DDZTWBHZ.js +154 -0
- package/dist/chunk-G3FWLTNJ.js +10 -0
- package/dist/{chunk-TJ744C2T.js → chunk-GJFKL6XM.js} +43 -38
- package/dist/chunk-H4QJ5O4E.js +36 -0
- package/dist/{chunk-X6XO7USX.js → chunk-LCO5F3JB.js} +109 -56
- package/dist/chunk-NDDYFDCU.js +60 -0
- package/dist/chunk-OCHPLE5N.js +28 -0
- package/dist/chunk-OSJA4YYQ.js +846 -0
- package/dist/chunk-PIT3K3NC.js +464 -0
- package/dist/chunk-QCKAO4UT.js +476 -0
- package/dist/{chunk-64IS37V6.js → chunk-RYIGWCGK.js} +1 -6
- package/dist/chunk-S4LJWEXU.js +37 -0
- package/dist/chunk-SJ26Y3GW.js +472 -0
- package/dist/chunk-TDZTH7TL.js +60 -0
- package/dist/chunk-THUA35UY.js +35 -0
- package/dist/{chunk-IUKLHJNE.js → chunk-V7TRGEV6.js} +4 -7
- package/dist/{chunk-KGNTV362.js → chunk-WDFKVCPC.js} +66 -34
- package/dist/{chunk-B7OAPHPY.js → chunk-YWWEFWFD.js} +3 -3
- package/dist/chunk-Z4UYYQ4J.js +42 -0
- package/dist/chunk-ZBT5SDIQ.js +16528 -0
- package/dist/chunk-ZIHRRTTA.js +24 -0
- package/dist/{dist-es-CDFIYJVE.js → dist-es-3VZ2IGGJ.js} +18 -15
- package/dist/{dist-es-SUPEA6VE-3B5JSW5C.js → dist-es-BQW4ETQH-C7ZSD5EG.js} +8 -25
- package/dist/{dist-es-GHYMLBON.js → dist-es-HSWXMGNC.js} +21 -21
- package/dist/{dist-es-OCQVKISC-TNAJ62WG.js → dist-es-IDBNBAO5-H3TO63FG.js} +15 -18
- package/dist/{dist-es-S75EKWRJ.js → dist-es-KPJNIAPT.js} +9 -10
- package/dist/{dist-es-PRWCVZGQ-HTTVI42T.js → dist-es-LZDRG6RP-SP2FWWEO.js} +3 -4
- package/dist/{dist-es-OZGLUDWT.js → dist-es-PIWY5TOR.js} +49 -26
- package/dist/{dist-es-ADTONJUN-RVFWNZHO.js → dist-es-R4LD2OHZ-B5MB6BR2.js} +11 -13
- package/dist/dist-es-S2KJK4L2-5GDBXJIO.js +470 -0
- package/dist/{dist-es-XQME5F6W.js → dist-es-THYWPEKB.js} +12 -10
- package/dist/{dist-es-HJVOMDYC-PIAMWMAL.js → dist-es-TIYLKN6W-BAHZRZH5.js} +7 -13
- package/dist/{dist-es-IDBDK36G-Y6TQMRO5.js → dist-es-VORPMM2F-WOMP2FYQ.js} +37 -30
- package/dist/{dist-es-WQHDOVD7.js → dist-es-WESJCADT.js} +3 -4
- package/dist/dist-es-XMOG24OT.js +490 -0
- package/dist/event-streams-L7RH32OW-AFMBEYJJ.js +237 -0
- package/dist/event-streams-NGUY2RWE.js +237 -0
- package/dist/index.cjs +2 -2
- package/dist/index.js +2 -2
- package/dist/lambda/auto-cache-removal.cjs +28894 -16488
- package/dist/lambda/auto-cache-removal.js +11574 -2713
- package/dist/lambda/origin-request.cjs +22351 -17619
- package/dist/lambda/origin-request.js +21 -17
- package/dist/lambda/origin-response.cjs +22219 -17387
- package/dist/lambda/origin-response.js +17 -13
- package/dist/{loadSso-CZSSLFH6-SA5HOQAX.js → loadSso-F4PTCHDN-YR3RRUYW.js} +330 -227
- package/dist/{loadSso-T7GJVVO2.js → loadSso-LG7MFP7N.js} +344 -223
- package/dist/signin-P7DNG43W.js +658 -0
- package/dist/signin-XWTOVLF3-4ENWNEF7.js +630 -0
- package/dist/{sso-oidc-PKO5GYK5-LC65L46O.js → sso-oidc-FQQGUOJL.js} +293 -332
- package/dist/{sso-oidc-55SJ27II.js → sso-oidc-RRDYLOJY-FK3AUTOI.js} +263 -337
- package/dist/{sts-OPF4H3GL.js → sts-7FBOVTCN.js} +674 -601
- package/dist/{sts-P7Q3MYTS-BKGWHQE4.js → sts-TBWJ374A-DHXXCVJJ.js} +651 -608
- package/package.json +5 -5
- package/dist/chunk-AEOST5WF.js +0 -63
- package/dist/chunk-FO7L563E.js +0 -13695
- package/dist/chunk-FRWSD3YQ.js +0 -1722
- package/dist/chunk-JBVMOFGH.js +0 -152
- package/dist/chunk-JSBRDJBE.js +0 -30
- package/dist/chunk-KRJS4RAS.js +0 -1732
- package/dist/chunk-M5GUUX64.js +0 -63
- package/dist/chunk-SX6SVQKS.js +0 -67
- package/dist/chunk-UNXXS5FM.js +0 -120
- package/dist/chunk-UT2RMOJS.js +0 -2447
- package/dist/chunk-VOTRVWIB.js +0 -1965
- package/dist/chunk-W3VXP3A3.js +0 -119
- package/dist/chunk-XLUI7RQ4.js +0 -115
- package/dist/dist-es-2M7RLZ5O.js +0 -200
- package/dist/dist-es-Y7VN37H5-WQ3GYROF.js +0 -196
|
@@ -1,16 +1,22 @@
|
|
|
1
1
|
import {
|
|
2
|
+
createAggregatedClient,
|
|
2
3
|
package_default
|
|
3
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-DDZTWBHZ.js";
|
|
5
|
+
import {
|
|
6
|
+
NoAuthSigner
|
|
7
|
+
} from "./chunk-G3FWLTNJ.js";
|
|
4
8
|
import {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
} from "./chunk-KRJS4RAS.js";
|
|
9
|
+
XmlShapeDeserializer
|
|
10
|
+
} from "./chunk-23MVQUOJ.js";
|
|
8
11
|
import {
|
|
9
12
|
AwsSdkSigV4Signer,
|
|
13
|
+
Client,
|
|
14
|
+
Command,
|
|
10
15
|
DEFAULT_RETRY_MODE,
|
|
11
16
|
DefaultIdentityProviderConfig,
|
|
12
17
|
EndpointCache,
|
|
13
18
|
Hash,
|
|
19
|
+
HttpProtocol,
|
|
14
20
|
NODE_APP_ID_CONFIG_OPTIONS,
|
|
15
21
|
NODE_AUTH_SCHEME_PREFERENCE_OPTIONS,
|
|
16
22
|
NODE_MAX_ATTEMPT_CONFIG_OPTIONS,
|
|
@@ -19,76 +25,446 @@ import {
|
|
|
19
25
|
NODE_RETRY_MODE_CONFIG_OPTIONS,
|
|
20
26
|
NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS,
|
|
21
27
|
NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS,
|
|
22
|
-
|
|
28
|
+
NoOpLogger,
|
|
29
|
+
NormalizedSchema,
|
|
30
|
+
NumericValue,
|
|
31
|
+
ProtocolLib,
|
|
32
|
+
SerdeContextConfig,
|
|
33
|
+
ServiceException,
|
|
34
|
+
TypeRegistry,
|
|
23
35
|
awsEndpointFunctions,
|
|
24
36
|
calculateBodyLength,
|
|
37
|
+
collectBody,
|
|
25
38
|
createDefaultUserAgentProvider,
|
|
26
39
|
customEndpointFunctions,
|
|
40
|
+
deref,
|
|
41
|
+
determineTimestampFormat,
|
|
27
42
|
emitWarningIfUnsupportedVersion,
|
|
43
|
+
emitWarningIfUnsupportedVersion2,
|
|
44
|
+
extendedEncodeURIComponent,
|
|
28
45
|
getAwsRegionExtensionConfiguration,
|
|
29
46
|
getContentLengthPlugin,
|
|
47
|
+
getDefaultExtensionConfiguration,
|
|
30
48
|
getEndpointPlugin,
|
|
31
49
|
getHostHeaderPlugin,
|
|
32
50
|
getHttpAuthSchemeEndpointRuleSetPlugin,
|
|
51
|
+
getHttpHandlerExtensionConfiguration,
|
|
33
52
|
getHttpSigningPlugin,
|
|
34
53
|
getLoggerPlugin,
|
|
35
54
|
getRecursionDetectionPlugin,
|
|
36
55
|
getRetryPlugin,
|
|
37
|
-
|
|
56
|
+
getSchemaSerdePlugin,
|
|
38
57
|
getSmithyContext,
|
|
39
58
|
getUserAgentPlugin,
|
|
59
|
+
loadConfigsForDefaultMode,
|
|
40
60
|
normalizeProvider,
|
|
41
61
|
resolveAwsRegionExtensionConfiguration,
|
|
42
62
|
resolveAwsSdkSigV4Config,
|
|
63
|
+
resolveDefaultRuntimeConfig,
|
|
43
64
|
resolveDefaultsModeConfig,
|
|
44
65
|
resolveEndpoint,
|
|
45
66
|
resolveEndpointConfig,
|
|
46
67
|
resolveHostHeaderConfig,
|
|
68
|
+
resolveHttpHandlerRuntimeConfig,
|
|
47
69
|
resolveRegionConfig,
|
|
48
70
|
resolveRetryConfig,
|
|
49
|
-
resolveUserAgentConfig
|
|
50
|
-
|
|
71
|
+
resolveUserAgentConfig,
|
|
72
|
+
serializingStructIterator,
|
|
73
|
+
v4
|
|
74
|
+
} from "./chunk-ASGFIK4A.js";
|
|
51
75
|
import {
|
|
52
76
|
loadConfig,
|
|
53
77
|
parseUrl
|
|
54
|
-
} from "./chunk-
|
|
55
|
-
import "./chunk-
|
|
78
|
+
} from "./chunk-LCO5F3JB.js";
|
|
79
|
+
import "./chunk-6KRYZP6R.js";
|
|
56
80
|
import {
|
|
57
|
-
Client,
|
|
58
|
-
Command,
|
|
59
|
-
HttpRequest,
|
|
60
|
-
NoOpLogger,
|
|
61
81
|
NodeHttpHandler,
|
|
62
|
-
|
|
63
|
-
ServiceException,
|
|
64
|
-
createAggregatedClient,
|
|
65
|
-
decorateServiceException,
|
|
66
|
-
emitWarningIfUnsupportedVersion as emitWarningIfUnsupportedVersion2,
|
|
67
|
-
expectNonNull,
|
|
68
|
-
expectString,
|
|
69
|
-
extendedEncodeURIComponent,
|
|
82
|
+
dateToUtcString,
|
|
70
83
|
fromBase64,
|
|
71
|
-
fromUtf8,
|
|
72
|
-
getDefaultExtensionConfiguration,
|
|
73
|
-
getHttpHandlerExtensionConfiguration,
|
|
74
|
-
loadConfigsForDefaultMode,
|
|
75
|
-
parseRfc3339DateTimeWithOffset,
|
|
76
|
-
resolveDefaultRuntimeConfig,
|
|
77
|
-
resolveHttpHandlerRuntimeConfig,
|
|
78
84
|
streamCollector,
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
} from "./chunk-
|
|
85
|
+
toBase64
|
|
86
|
+
} from "./chunk-OSJA4YYQ.js";
|
|
87
|
+
import {
|
|
88
|
+
HttpRequest
|
|
89
|
+
} from "./chunk-NDDYFDCU.js";
|
|
90
|
+
import "./chunk-WDFKVCPC.js";
|
|
84
91
|
import {
|
|
85
92
|
setCredentialFeature
|
|
86
|
-
} from "./chunk-
|
|
87
|
-
import "./chunk-
|
|
88
|
-
import
|
|
89
|
-
|
|
93
|
+
} from "./chunk-3OYGHA4S.js";
|
|
94
|
+
import "./chunk-S4LJWEXU.js";
|
|
95
|
+
import {
|
|
96
|
+
fromUtf8,
|
|
97
|
+
toUtf8
|
|
98
|
+
} from "./chunk-Z4UYYQ4J.js";
|
|
99
|
+
|
|
100
|
+
// ../../.yarn/cache/@smithy-core-npm-3.18.5-16e80a170e-c6ccaf4a06.zip/node_modules/@smithy/core/dist-es/submodules/protocols/RpcProtocol.js
|
|
101
|
+
var RpcProtocol = class extends HttpProtocol {
|
|
102
|
+
async serializeRequest(operationSchema, input, context) {
|
|
103
|
+
const serializer = this.serializer;
|
|
104
|
+
const query = {};
|
|
105
|
+
const headers = {};
|
|
106
|
+
const endpoint = await context.endpoint();
|
|
107
|
+
const ns = NormalizedSchema.of(operationSchema?.input);
|
|
108
|
+
const schema = ns.getSchema();
|
|
109
|
+
let payload;
|
|
110
|
+
const request = new HttpRequest({
|
|
111
|
+
protocol: "",
|
|
112
|
+
hostname: "",
|
|
113
|
+
port: void 0,
|
|
114
|
+
path: "/",
|
|
115
|
+
fragment: void 0,
|
|
116
|
+
query,
|
|
117
|
+
headers,
|
|
118
|
+
body: void 0
|
|
119
|
+
});
|
|
120
|
+
if (endpoint) {
|
|
121
|
+
this.updateServiceEndpoint(request, endpoint);
|
|
122
|
+
this.setHostPrefix(request, operationSchema, input);
|
|
123
|
+
}
|
|
124
|
+
const _input = {
|
|
125
|
+
...input
|
|
126
|
+
};
|
|
127
|
+
if (input) {
|
|
128
|
+
const eventStreamMember = ns.getEventStreamMember();
|
|
129
|
+
if (eventStreamMember) {
|
|
130
|
+
if (_input[eventStreamMember]) {
|
|
131
|
+
const initialRequest = {};
|
|
132
|
+
for (const [memberName, memberSchema] of ns.structIterator()) {
|
|
133
|
+
if (memberName !== eventStreamMember && _input[memberName]) {
|
|
134
|
+
serializer.write(memberSchema, _input[memberName]);
|
|
135
|
+
initialRequest[memberName] = serializer.flush();
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
payload = await this.serializeEventStream({
|
|
139
|
+
eventStream: _input[eventStreamMember],
|
|
140
|
+
requestSchema: ns,
|
|
141
|
+
initialRequest
|
|
142
|
+
});
|
|
143
|
+
}
|
|
144
|
+
} else {
|
|
145
|
+
serializer.write(schema, _input);
|
|
146
|
+
payload = serializer.flush();
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
request.headers = headers;
|
|
150
|
+
request.query = query;
|
|
151
|
+
request.body = payload;
|
|
152
|
+
request.method = "POST";
|
|
153
|
+
return request;
|
|
154
|
+
}
|
|
155
|
+
async deserializeResponse(operationSchema, context, response) {
|
|
156
|
+
const deserializer = this.deserializer;
|
|
157
|
+
const ns = NormalizedSchema.of(operationSchema.output);
|
|
158
|
+
const dataObject = {};
|
|
159
|
+
if (response.statusCode >= 300) {
|
|
160
|
+
const bytes = await collectBody(response.body, context);
|
|
161
|
+
if (bytes.byteLength > 0) {
|
|
162
|
+
Object.assign(dataObject, await deserializer.read(15, bytes));
|
|
163
|
+
}
|
|
164
|
+
await this.handleError(operationSchema, context, response, dataObject, this.deserializeMetadata(response));
|
|
165
|
+
throw new Error("@smithy/core/protocols - RPC Protocol error handler failed to throw.");
|
|
166
|
+
}
|
|
167
|
+
for (const header in response.headers) {
|
|
168
|
+
const value = response.headers[header];
|
|
169
|
+
delete response.headers[header];
|
|
170
|
+
response.headers[header.toLowerCase()] = value;
|
|
171
|
+
}
|
|
172
|
+
const eventStreamMember = ns.getEventStreamMember();
|
|
173
|
+
if (eventStreamMember) {
|
|
174
|
+
dataObject[eventStreamMember] = await this.deserializeEventStream({
|
|
175
|
+
response,
|
|
176
|
+
responseSchema: ns,
|
|
177
|
+
initialResponseContainer: dataObject
|
|
178
|
+
});
|
|
179
|
+
} else {
|
|
180
|
+
const bytes = await collectBody(response.body, context);
|
|
181
|
+
if (bytes.byteLength > 0) {
|
|
182
|
+
Object.assign(dataObject, await deserializer.read(ns, bytes));
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
dataObject.$metadata = this.deserializeMetadata(response);
|
|
186
|
+
return dataObject;
|
|
187
|
+
}
|
|
188
|
+
};
|
|
189
|
+
|
|
190
|
+
// ../../.yarn/cache/@aws-sdk-core-npm-3.940.0-0d32a8e8d2-090b960007.zip/node_modules/@aws-sdk/core/dist-es/submodules/protocols/query/QueryShapeSerializer.js
|
|
191
|
+
var QueryShapeSerializer = class extends SerdeContextConfig {
|
|
192
|
+
settings;
|
|
193
|
+
buffer;
|
|
194
|
+
constructor(settings) {
|
|
195
|
+
super();
|
|
196
|
+
this.settings = settings;
|
|
197
|
+
}
|
|
198
|
+
write(schema, value, prefix = "") {
|
|
199
|
+
if (this.buffer === void 0) {
|
|
200
|
+
this.buffer = "";
|
|
201
|
+
}
|
|
202
|
+
const ns = NormalizedSchema.of(schema);
|
|
203
|
+
if (prefix && !prefix.endsWith(".")) {
|
|
204
|
+
prefix += ".";
|
|
205
|
+
}
|
|
206
|
+
if (ns.isBlobSchema()) {
|
|
207
|
+
if (typeof value === "string" || value instanceof Uint8Array) {
|
|
208
|
+
this.writeKey(prefix);
|
|
209
|
+
this.writeValue((this.serdeContext?.base64Encoder ?? toBase64)(value));
|
|
210
|
+
}
|
|
211
|
+
} else if (ns.isBooleanSchema() || ns.isNumericSchema() || ns.isStringSchema()) {
|
|
212
|
+
if (value != null) {
|
|
213
|
+
this.writeKey(prefix);
|
|
214
|
+
this.writeValue(String(value));
|
|
215
|
+
} else if (ns.isIdempotencyToken()) {
|
|
216
|
+
this.writeKey(prefix);
|
|
217
|
+
this.writeValue(v4());
|
|
218
|
+
}
|
|
219
|
+
} else if (ns.isBigIntegerSchema()) {
|
|
220
|
+
if (value != null) {
|
|
221
|
+
this.writeKey(prefix);
|
|
222
|
+
this.writeValue(String(value));
|
|
223
|
+
}
|
|
224
|
+
} else if (ns.isBigDecimalSchema()) {
|
|
225
|
+
if (value != null) {
|
|
226
|
+
this.writeKey(prefix);
|
|
227
|
+
this.writeValue(value instanceof NumericValue ? value.string : String(value));
|
|
228
|
+
}
|
|
229
|
+
} else if (ns.isTimestampSchema()) {
|
|
230
|
+
if (value instanceof Date) {
|
|
231
|
+
this.writeKey(prefix);
|
|
232
|
+
const format = determineTimestampFormat(ns, this.settings);
|
|
233
|
+
switch (format) {
|
|
234
|
+
case 5:
|
|
235
|
+
this.writeValue(value.toISOString().replace(".000Z", "Z"));
|
|
236
|
+
break;
|
|
237
|
+
case 6:
|
|
238
|
+
this.writeValue(dateToUtcString(value));
|
|
239
|
+
break;
|
|
240
|
+
case 7:
|
|
241
|
+
this.writeValue(String(value.getTime() / 1e3));
|
|
242
|
+
break;
|
|
243
|
+
}
|
|
244
|
+
}
|
|
245
|
+
} else if (ns.isDocumentSchema()) {
|
|
246
|
+
throw new Error(`@aws-sdk/core/protocols - QuerySerializer unsupported document type ${ns.getName(true)}`);
|
|
247
|
+
} else if (ns.isListSchema()) {
|
|
248
|
+
if (Array.isArray(value)) {
|
|
249
|
+
if (value.length === 0) {
|
|
250
|
+
if (this.settings.serializeEmptyLists) {
|
|
251
|
+
this.writeKey(prefix);
|
|
252
|
+
this.writeValue("");
|
|
253
|
+
}
|
|
254
|
+
} else {
|
|
255
|
+
const member = ns.getValueSchema();
|
|
256
|
+
const flat = this.settings.flattenLists || ns.getMergedTraits().xmlFlattened;
|
|
257
|
+
let i2 = 1;
|
|
258
|
+
for (const item of value) {
|
|
259
|
+
if (item == null) {
|
|
260
|
+
continue;
|
|
261
|
+
}
|
|
262
|
+
const suffix = this.getKey("member", member.getMergedTraits().xmlName);
|
|
263
|
+
const key = flat ? `${prefix}${i2}` : `${prefix}${suffix}.${i2}`;
|
|
264
|
+
this.write(member, item, key);
|
|
265
|
+
++i2;
|
|
266
|
+
}
|
|
267
|
+
}
|
|
268
|
+
}
|
|
269
|
+
} else if (ns.isMapSchema()) {
|
|
270
|
+
if (value && typeof value === "object") {
|
|
271
|
+
const keySchema = ns.getKeySchema();
|
|
272
|
+
const memberSchema = ns.getValueSchema();
|
|
273
|
+
const flat = ns.getMergedTraits().xmlFlattened;
|
|
274
|
+
let i2 = 1;
|
|
275
|
+
for (const [k2, v2] of Object.entries(value)) {
|
|
276
|
+
if (v2 == null) {
|
|
277
|
+
continue;
|
|
278
|
+
}
|
|
279
|
+
const keySuffix = this.getKey("key", keySchema.getMergedTraits().xmlName);
|
|
280
|
+
const key = flat ? `${prefix}${i2}.${keySuffix}` : `${prefix}entry.${i2}.${keySuffix}`;
|
|
281
|
+
const valueSuffix = this.getKey("value", memberSchema.getMergedTraits().xmlName);
|
|
282
|
+
const valueKey = flat ? `${prefix}${i2}.${valueSuffix}` : `${prefix}entry.${i2}.${valueSuffix}`;
|
|
283
|
+
this.write(keySchema, k2, key);
|
|
284
|
+
this.write(memberSchema, v2, valueKey);
|
|
285
|
+
++i2;
|
|
286
|
+
}
|
|
287
|
+
}
|
|
288
|
+
} else if (ns.isStructSchema()) {
|
|
289
|
+
if (value && typeof value === "object") {
|
|
290
|
+
for (const [memberName, member] of serializingStructIterator(ns, value)) {
|
|
291
|
+
if (value[memberName] == null && !member.isIdempotencyToken()) {
|
|
292
|
+
continue;
|
|
293
|
+
}
|
|
294
|
+
const suffix = this.getKey(memberName, member.getMergedTraits().xmlName);
|
|
295
|
+
const key = `${prefix}${suffix}`;
|
|
296
|
+
this.write(member, value[memberName], key);
|
|
297
|
+
}
|
|
298
|
+
}
|
|
299
|
+
} else if (ns.isUnitSchema()) {
|
|
300
|
+
} else {
|
|
301
|
+
throw new Error(`@aws-sdk/core/protocols - QuerySerializer unrecognized schema type ${ns.getName(true)}`);
|
|
302
|
+
}
|
|
303
|
+
}
|
|
304
|
+
flush() {
|
|
305
|
+
if (this.buffer === void 0) {
|
|
306
|
+
throw new Error("@aws-sdk/core/protocols - QuerySerializer cannot flush with nothing written to buffer.");
|
|
307
|
+
}
|
|
308
|
+
const str = this.buffer;
|
|
309
|
+
delete this.buffer;
|
|
310
|
+
return str;
|
|
311
|
+
}
|
|
312
|
+
getKey(memberName, xmlName) {
|
|
313
|
+
const key = xmlName ?? memberName;
|
|
314
|
+
if (this.settings.capitalizeKeys) {
|
|
315
|
+
return key[0].toUpperCase() + key.slice(1);
|
|
316
|
+
}
|
|
317
|
+
return key;
|
|
318
|
+
}
|
|
319
|
+
writeKey(key) {
|
|
320
|
+
if (key.endsWith(".")) {
|
|
321
|
+
key = key.slice(0, key.length - 1);
|
|
322
|
+
}
|
|
323
|
+
this.buffer += `&${extendedEncodeURIComponent(key)}=`;
|
|
324
|
+
}
|
|
325
|
+
writeValue(value) {
|
|
326
|
+
this.buffer += extendedEncodeURIComponent(value);
|
|
327
|
+
}
|
|
328
|
+
};
|
|
90
329
|
|
|
91
|
-
// ../../.yarn/cache/@aws-sdk-
|
|
330
|
+
// ../../.yarn/cache/@aws-sdk-core-npm-3.940.0-0d32a8e8d2-090b960007.zip/node_modules/@aws-sdk/core/dist-es/submodules/protocols/query/AwsQueryProtocol.js
|
|
331
|
+
var AwsQueryProtocol = class extends RpcProtocol {
|
|
332
|
+
options;
|
|
333
|
+
serializer;
|
|
334
|
+
deserializer;
|
|
335
|
+
mixin = new ProtocolLib();
|
|
336
|
+
constructor(options) {
|
|
337
|
+
super({
|
|
338
|
+
defaultNamespace: options.defaultNamespace
|
|
339
|
+
});
|
|
340
|
+
this.options = options;
|
|
341
|
+
const settings = {
|
|
342
|
+
timestampFormat: {
|
|
343
|
+
useTrait: true,
|
|
344
|
+
default: 5
|
|
345
|
+
},
|
|
346
|
+
httpBindings: false,
|
|
347
|
+
xmlNamespace: options.xmlNamespace,
|
|
348
|
+
serviceNamespace: options.defaultNamespace,
|
|
349
|
+
serializeEmptyLists: true
|
|
350
|
+
};
|
|
351
|
+
this.serializer = new QueryShapeSerializer(settings);
|
|
352
|
+
this.deserializer = new XmlShapeDeserializer(settings);
|
|
353
|
+
}
|
|
354
|
+
getShapeId() {
|
|
355
|
+
return "aws.protocols#awsQuery";
|
|
356
|
+
}
|
|
357
|
+
setSerdeContext(serdeContext) {
|
|
358
|
+
this.serializer.setSerdeContext(serdeContext);
|
|
359
|
+
this.deserializer.setSerdeContext(serdeContext);
|
|
360
|
+
}
|
|
361
|
+
getPayloadCodec() {
|
|
362
|
+
throw new Error("AWSQuery protocol has no payload codec.");
|
|
363
|
+
}
|
|
364
|
+
async serializeRequest(operationSchema, input, context) {
|
|
365
|
+
const request = await super.serializeRequest(operationSchema, input, context);
|
|
366
|
+
if (!request.path.endsWith("/")) {
|
|
367
|
+
request.path += "/";
|
|
368
|
+
}
|
|
369
|
+
Object.assign(request.headers, {
|
|
370
|
+
"content-type": `application/x-www-form-urlencoded`
|
|
371
|
+
});
|
|
372
|
+
if (deref(operationSchema.input) === "unit" || !request.body) {
|
|
373
|
+
request.body = "";
|
|
374
|
+
}
|
|
375
|
+
const action = operationSchema.name.split("#")[1] ?? operationSchema.name;
|
|
376
|
+
request.body = `Action=${action}&Version=${this.options.version}` + request.body;
|
|
377
|
+
if (request.body.endsWith("&")) {
|
|
378
|
+
request.body = request.body.slice(-1);
|
|
379
|
+
}
|
|
380
|
+
return request;
|
|
381
|
+
}
|
|
382
|
+
async deserializeResponse(operationSchema, context, response) {
|
|
383
|
+
const deserializer = this.deserializer;
|
|
384
|
+
const ns = NormalizedSchema.of(operationSchema.output);
|
|
385
|
+
const dataObject = {};
|
|
386
|
+
if (response.statusCode >= 300) {
|
|
387
|
+
const bytes2 = await collectBody(response.body, context);
|
|
388
|
+
if (bytes2.byteLength > 0) {
|
|
389
|
+
Object.assign(dataObject, await deserializer.read(15, bytes2));
|
|
390
|
+
}
|
|
391
|
+
await this.handleError(operationSchema, context, response, dataObject, this.deserializeMetadata(response));
|
|
392
|
+
}
|
|
393
|
+
for (const header in response.headers) {
|
|
394
|
+
const value = response.headers[header];
|
|
395
|
+
delete response.headers[header];
|
|
396
|
+
response.headers[header.toLowerCase()] = value;
|
|
397
|
+
}
|
|
398
|
+
const shortName = operationSchema.name.split("#")[1] ?? operationSchema.name;
|
|
399
|
+
const awsQueryResultKey = ns.isStructSchema() && this.useNestedResult() ? shortName + "Result" : void 0;
|
|
400
|
+
const bytes = await collectBody(response.body, context);
|
|
401
|
+
if (bytes.byteLength > 0) {
|
|
402
|
+
Object.assign(dataObject, await deserializer.read(ns, bytes, awsQueryResultKey));
|
|
403
|
+
}
|
|
404
|
+
const output = {
|
|
405
|
+
$metadata: this.deserializeMetadata(response),
|
|
406
|
+
...dataObject
|
|
407
|
+
};
|
|
408
|
+
return output;
|
|
409
|
+
}
|
|
410
|
+
useNestedResult() {
|
|
411
|
+
return true;
|
|
412
|
+
}
|
|
413
|
+
async handleError(operationSchema, context, response, dataObject, metadata) {
|
|
414
|
+
const errorIdentifier = this.loadQueryErrorCode(response, dataObject) ?? "Unknown";
|
|
415
|
+
const errorData = this.loadQueryError(dataObject);
|
|
416
|
+
const message = this.loadQueryErrorMessage(dataObject);
|
|
417
|
+
errorData.message = message;
|
|
418
|
+
errorData.Error = {
|
|
419
|
+
Type: errorData.Type,
|
|
420
|
+
Code: errorData.Code,
|
|
421
|
+
Message: message
|
|
422
|
+
};
|
|
423
|
+
const { errorSchema, errorMetadata } = await this.mixin.getErrorSchemaOrThrowBaseException(errorIdentifier, this.options.defaultNamespace, response, errorData, metadata, (registry, errorName) => {
|
|
424
|
+
try {
|
|
425
|
+
return registry.getSchema(errorName);
|
|
426
|
+
} catch (e2) {
|
|
427
|
+
return registry.find((schema) => NormalizedSchema.of(schema).getMergedTraits().awsQueryError?.[0] === errorName);
|
|
428
|
+
}
|
|
429
|
+
});
|
|
430
|
+
const ns = NormalizedSchema.of(errorSchema);
|
|
431
|
+
const ErrorCtor = TypeRegistry.for(errorSchema[1]).getErrorCtor(errorSchema) ?? Error;
|
|
432
|
+
const exception = new ErrorCtor(message);
|
|
433
|
+
const output = {
|
|
434
|
+
Error: errorData.Error
|
|
435
|
+
};
|
|
436
|
+
for (const [name, member] of ns.structIterator()) {
|
|
437
|
+
const target = member.getMergedTraits().xmlName ?? name;
|
|
438
|
+
const value = errorData[target] ?? dataObject[target];
|
|
439
|
+
output[name] = this.deserializer.readSchema(member, value);
|
|
440
|
+
}
|
|
441
|
+
throw this.mixin.decorateServiceException(Object.assign(exception, errorMetadata, {
|
|
442
|
+
$fault: ns.getMergedTraits().error,
|
|
443
|
+
message
|
|
444
|
+
}, output), dataObject);
|
|
445
|
+
}
|
|
446
|
+
loadQueryErrorCode(output, data) {
|
|
447
|
+
const code = (data.Errors?.[0]?.Error ?? data.Errors?.Error ?? data.Error)?.Code;
|
|
448
|
+
if (code !== void 0) {
|
|
449
|
+
return code;
|
|
450
|
+
}
|
|
451
|
+
if (output.statusCode == 404) {
|
|
452
|
+
return "NotFound";
|
|
453
|
+
}
|
|
454
|
+
}
|
|
455
|
+
loadQueryError(data) {
|
|
456
|
+
return data.Errors?.[0]?.Error ?? data.Errors?.Error ?? data.Error;
|
|
457
|
+
}
|
|
458
|
+
loadQueryErrorMessage(data) {
|
|
459
|
+
const errorData = this.loadQueryError(data);
|
|
460
|
+
return errorData?.message ?? errorData?.Message ?? data.message ?? data.Message ?? "Unknown";
|
|
461
|
+
}
|
|
462
|
+
getDefaultContentType() {
|
|
463
|
+
return "application/x-www-form-urlencoded";
|
|
464
|
+
}
|
|
465
|
+
};
|
|
466
|
+
|
|
467
|
+
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.940.0-415b36f0bc-6695cd044d.zip/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/auth/httpAuthSchemeProvider.js
|
|
92
468
|
var defaultSTSHttpAuthSchemeParametersProvider = async (config, context, input) => {
|
|
93
469
|
return {
|
|
94
470
|
operation: getSmithyContext(context).operation,
|
|
@@ -141,7 +517,7 @@ var resolveHttpAuthSchemeConfig = (config) => {
|
|
|
141
517
|
});
|
|
142
518
|
};
|
|
143
519
|
|
|
144
|
-
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.
|
|
520
|
+
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.940.0-415b36f0bc-6695cd044d.zip/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/endpoint/EndpointParameters.js
|
|
145
521
|
var resolveClientEndpointParameters = (options) => {
|
|
146
522
|
return Object.assign(options, {
|
|
147
523
|
useDualstackEndpoint: options.useDualstackEndpoint ?? false,
|
|
@@ -158,7 +534,7 @@ var commonParams = {
|
|
|
158
534
|
UseDualStack: { type: "builtInParams", name: "useDualstackEndpoint" }
|
|
159
535
|
};
|
|
160
536
|
|
|
161
|
-
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.
|
|
537
|
+
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.940.0-415b36f0bc-6695cd044d.zip/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/endpoint/ruleset.js
|
|
162
538
|
var F = "required";
|
|
163
539
|
var G = "type";
|
|
164
540
|
var H = "fn";
|
|
@@ -176,8 +552,8 @@ var i = "https://sts.{Region}.{PartitionResult#dnsSuffix}";
|
|
|
176
552
|
var j = "tree";
|
|
177
553
|
var k = "error";
|
|
178
554
|
var l = "getAttr";
|
|
179
|
-
var m = { [F]: false, [G]: "
|
|
180
|
-
var n = { [F]: true, "default": false, [G]: "
|
|
555
|
+
var m = { [F]: false, [G]: "string" };
|
|
556
|
+
var n = { [F]: true, "default": false, [G]: "boolean" };
|
|
181
557
|
var o = { [J]: "Endpoint" };
|
|
182
558
|
var p = { [H]: "isSet", [I]: [{ [J]: "Region" }] };
|
|
183
559
|
var q = { [J]: "Region" };
|
|
@@ -198,7 +574,7 @@ var E = [y];
|
|
|
198
574
|
var _data = { version: "1.0", parameters: { Region: m, UseDualStack: n, UseFIPS: n, Endpoint: m, UseGlobalEndpoint: n }, rules: [{ conditions: [{ [H]: c, [I]: [{ [J]: "UseGlobalEndpoint" }, b] }, { [H]: "not", [I]: C }, p, r, { [H]: c, [I]: [s, a] }, { [H]: c, [I]: [t, a] }], rules: [{ conditions: [{ [H]: d, [I]: [q, "ap-northeast-1"] }], endpoint: u, [G]: h }, { conditions: [{ [H]: d, [I]: [q, "ap-south-1"] }], endpoint: u, [G]: h }, { conditions: [{ [H]: d, [I]: [q, "ap-southeast-1"] }], endpoint: u, [G]: h }, { conditions: [{ [H]: d, [I]: [q, "ap-southeast-2"] }], endpoint: u, [G]: h }, w, { conditions: [{ [H]: d, [I]: [q, "ca-central-1"] }], endpoint: u, [G]: h }, { conditions: [{ [H]: d, [I]: [q, "eu-central-1"] }], endpoint: u, [G]: h }, { conditions: [{ [H]: d, [I]: [q, "eu-north-1"] }], endpoint: u, [G]: h }, { conditions: [{ [H]: d, [I]: [q, "eu-west-1"] }], endpoint: u, [G]: h }, { conditions: [{ [H]: d, [I]: [q, "eu-west-2"] }], endpoint: u, [G]: h }, { conditions: [{ [H]: d, [I]: [q, "eu-west-3"] }], endpoint: u, [G]: h }, { conditions: [{ [H]: d, [I]: [q, "sa-east-1"] }], endpoint: u, [G]: h }, { conditions: [{ [H]: d, [I]: [q, g] }], endpoint: u, [G]: h }, { conditions: [{ [H]: d, [I]: [q, "us-east-2"] }], endpoint: u, [G]: h }, { conditions: [{ [H]: d, [I]: [q, "us-west-1"] }], endpoint: u, [G]: h }, { conditions: [{ [H]: d, [I]: [q, "us-west-2"] }], endpoint: u, [G]: h }, { endpoint: { url: i, properties: { authSchemes: [{ name: e, signingName: f, signingRegion: "{Region}" }] }, headers: v }, [G]: h }], [G]: j }, { conditions: C, rules: [{ conditions: D, error: "Invalid Configuration: FIPS and custom endpoint are not supported", [G]: k }, { conditions: E, error: "Invalid Configuration: Dualstack and custom endpoint are not supported", [G]: k }, { endpoint: { url: o, properties: v, headers: v }, [G]: h }], [G]: j }, { conditions: [p], rules: [{ conditions: [r], rules: [{ conditions: [x, y], rules: [{ conditions: [{ [H]: c, [I]: [b, z] }, B], rules: [{ endpoint: { url: "https://sts-fips.{Region}.{PartitionResult#dualStackDnsSuffix}", properties: v, headers: v }, [G]: h }], [G]: j }, { error: "FIPS and DualStack are enabled, but this partition does not support one or both", [G]: k }], [G]: j }, { conditions: D, rules: [{ conditions: [{ [H]: c, [I]: [z, b] }], rules: [{ conditions: [{ [H]: d, [I]: [{ [H]: l, [I]: [A, "name"] }, "aws-us-gov"] }], endpoint: { url: "https://sts.{Region}.amazonaws.com", properties: v, headers: v }, [G]: h }, { endpoint: { url: "https://sts-fips.{Region}.{PartitionResult#dnsSuffix}", properties: v, headers: v }, [G]: h }], [G]: j }, { error: "FIPS is enabled but this partition does not support FIPS", [G]: k }], [G]: j }, { conditions: E, rules: [{ conditions: [B], rules: [{ endpoint: { url: "https://sts.{Region}.{PartitionResult#dualStackDnsSuffix}", properties: v, headers: v }, [G]: h }], [G]: j }, { error: "DualStack is enabled but this partition does not support DualStack", [G]: k }], [G]: j }, w, { endpoint: { url: i, properties: v, headers: v }, [G]: h }], [G]: j }], [G]: j }, { error: "Invalid Configuration: Missing Region", [G]: k }] };
|
|
199
575
|
var ruleSet = _data;
|
|
200
576
|
|
|
201
|
-
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.
|
|
577
|
+
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.940.0-415b36f0bc-6695cd044d.zip/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/endpoint/endpointResolver.js
|
|
202
578
|
var cache = new EndpointCache({
|
|
203
579
|
size: 50,
|
|
204
580
|
params: ["Endpoint", "Region", "UseDualStack", "UseFIPS", "UseGlobalEndpoint"]
|
|
@@ -211,7 +587,7 @@ var defaultEndpointResolver = (endpointParams, context = {}) => {
|
|
|
211
587
|
};
|
|
212
588
|
customEndpointFunctions.aws = awsEndpointFunctions;
|
|
213
589
|
|
|
214
|
-
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.
|
|
590
|
+
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.940.0-415b36f0bc-6695cd044d.zip/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/runtimeConfig.shared.js
|
|
215
591
|
var getRuntimeConfig = (config) => {
|
|
216
592
|
return {
|
|
217
593
|
apiVersion: "2011-06-15",
|
|
@@ -234,6 +610,11 @@ var getRuntimeConfig = (config) => {
|
|
|
234
610
|
}
|
|
235
611
|
],
|
|
236
612
|
logger: config?.logger ?? new NoOpLogger(),
|
|
613
|
+
protocol: config?.protocol ?? new AwsQueryProtocol({
|
|
614
|
+
defaultNamespace: "com.amazonaws.sts",
|
|
615
|
+
xmlNamespace: "https://sts.amazonaws.com/doc/2011-06-15/",
|
|
616
|
+
version: "2011-06-15"
|
|
617
|
+
}),
|
|
237
618
|
serviceId: config?.serviceId ?? "STS",
|
|
238
619
|
urlParser: config?.urlParser ?? parseUrl,
|
|
239
620
|
utf8Decoder: config?.utf8Decoder ?? fromUtf8,
|
|
@@ -241,7 +622,7 @@ var getRuntimeConfig = (config) => {
|
|
|
241
622
|
};
|
|
242
623
|
};
|
|
243
624
|
|
|
244
|
-
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.
|
|
625
|
+
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.940.0-415b36f0bc-6695cd044d.zip/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/runtimeConfig.js
|
|
245
626
|
var getRuntimeConfig2 = (config) => {
|
|
246
627
|
emitWarningIfUnsupportedVersion2(process.version);
|
|
247
628
|
const defaultsMode = resolveDefaultsModeConfig(config);
|
|
@@ -287,7 +668,23 @@ var getRuntimeConfig2 = (config) => {
|
|
|
287
668
|
};
|
|
288
669
|
};
|
|
289
670
|
|
|
290
|
-
// ../../.yarn/cache/@aws-sdk-
|
|
671
|
+
// ../../.yarn/cache/@aws-sdk-region-config-resolver-npm-3.936.0-ac429a151d-67ecf8f357.zip/node_modules/@aws-sdk/region-config-resolver/dist-es/regionConfig/stsRegionDefaultResolver.js
|
|
672
|
+
function stsRegionDefaultResolver(loaderConfig = {}) {
|
|
673
|
+
return loadConfig({
|
|
674
|
+
...NODE_REGION_CONFIG_OPTIONS,
|
|
675
|
+
async default() {
|
|
676
|
+
if (!warning.silence) {
|
|
677
|
+
console.warn("@aws-sdk - WARN - default STS region of us-east-1 used. See @aws-sdk/credential-providers README and set a region explicitly.");
|
|
678
|
+
}
|
|
679
|
+
return "us-east-1";
|
|
680
|
+
}
|
|
681
|
+
}, { ...NODE_REGION_CONFIG_FILE_OPTIONS, ...loaderConfig });
|
|
682
|
+
}
|
|
683
|
+
var warning = {
|
|
684
|
+
silence: false
|
|
685
|
+
};
|
|
686
|
+
|
|
687
|
+
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.940.0-415b36f0bc-6695cd044d.zip/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/auth/httpAuthExtensionConfiguration.js
|
|
291
688
|
var getHttpAuthExtensionConfiguration = (runtimeConfig) => {
|
|
292
689
|
const _httpAuthSchemes = runtimeConfig.httpAuthSchemes;
|
|
293
690
|
let _httpAuthSchemeProvider = runtimeConfig.httpAuthSchemeProvider;
|
|
@@ -326,14 +723,14 @@ var resolveHttpAuthRuntimeConfig = (config) => {
|
|
|
326
723
|
};
|
|
327
724
|
};
|
|
328
725
|
|
|
329
|
-
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.
|
|
726
|
+
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.940.0-415b36f0bc-6695cd044d.zip/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/runtimeExtensions.js
|
|
330
727
|
var resolveRuntimeExtensions = (runtimeConfig, extensions) => {
|
|
331
728
|
const extensionConfiguration = Object.assign(getAwsRegionExtensionConfiguration(runtimeConfig), getDefaultExtensionConfiguration(runtimeConfig), getHttpHandlerExtensionConfiguration(runtimeConfig), getHttpAuthExtensionConfiguration(runtimeConfig));
|
|
332
729
|
extensions.forEach((extension) => extension.configure(extensionConfiguration));
|
|
333
730
|
return Object.assign(runtimeConfig, resolveAwsRegionExtensionConfiguration(extensionConfiguration), resolveDefaultRuntimeConfig(extensionConfiguration), resolveHttpHandlerRuntimeConfig(extensionConfiguration), resolveHttpAuthRuntimeConfig(extensionConfiguration));
|
|
334
731
|
};
|
|
335
732
|
|
|
336
|
-
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.
|
|
733
|
+
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.940.0-415b36f0bc-6695cd044d.zip/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/STSClient.js
|
|
337
734
|
var STSClient = class extends Client {
|
|
338
735
|
config;
|
|
339
736
|
constructor(...[configuration]) {
|
|
@@ -349,6 +746,7 @@ var STSClient = class extends Client {
|
|
|
349
746
|
const _config_7 = resolveHttpAuthSchemeConfig(_config_6);
|
|
350
747
|
const _config_8 = resolveRuntimeExtensions(_config_7, configuration?.extensions || []);
|
|
351
748
|
this.config = _config_8;
|
|
749
|
+
this.middlewareStack.use(getSchemaSerdePlugin(this.config));
|
|
352
750
|
this.middlewareStack.use(getUserAgentPlugin(this.config));
|
|
353
751
|
this.middlewareStack.use(getRetryPlugin(this.config));
|
|
354
752
|
this.middlewareStack.use(getContentLengthPlugin(this.config));
|
|
@@ -368,7 +766,7 @@ var STSClient = class extends Client {
|
|
|
368
766
|
}
|
|
369
767
|
};
|
|
370
768
|
|
|
371
|
-
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.
|
|
769
|
+
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.940.0-415b36f0bc-6695cd044d.zip/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/models/STSServiceException.js
|
|
372
770
|
var STSServiceException = class _STSServiceException extends ServiceException {
|
|
373
771
|
constructor(options) {
|
|
374
772
|
super(options);
|
|
@@ -376,15 +774,7 @@ var STSServiceException = class _STSServiceException extends ServiceException {
|
|
|
376
774
|
}
|
|
377
775
|
};
|
|
378
776
|
|
|
379
|
-
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.
|
|
380
|
-
var CredentialsFilterSensitiveLog = (obj) => ({
|
|
381
|
-
...obj,
|
|
382
|
-
...obj.SecretAccessKey && { SecretAccessKey: SENSITIVE_STRING }
|
|
383
|
-
});
|
|
384
|
-
var AssumeRoleResponseFilterSensitiveLog = (obj) => ({
|
|
385
|
-
...obj,
|
|
386
|
-
...obj.Credentials && { Credentials: CredentialsFilterSensitiveLog(obj.Credentials) }
|
|
387
|
-
});
|
|
777
|
+
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.940.0-415b36f0bc-6695cd044d.zip/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/models/errors.js
|
|
388
778
|
var ExpiredTokenException = class _ExpiredTokenException extends STSServiceException {
|
|
389
779
|
name = "ExpiredTokenException";
|
|
390
780
|
$fault = "client";
|
|
@@ -457,14 +847,6 @@ var InvalidIdentityTokenException = class _InvalidIdentityTokenException extends
|
|
|
457
847
|
Object.setPrototypeOf(this, _InvalidIdentityTokenException.prototype);
|
|
458
848
|
}
|
|
459
849
|
};
|
|
460
|
-
var AssumeRoleWithWebIdentityRequestFilterSensitiveLog = (obj) => ({
|
|
461
|
-
...obj,
|
|
462
|
-
...obj.WebIdentityToken && { WebIdentityToken: SENSITIVE_STRING }
|
|
463
|
-
});
|
|
464
|
-
var AssumeRoleWithWebIdentityResponseFilterSensitiveLog = (obj) => ({
|
|
465
|
-
...obj,
|
|
466
|
-
...obj.Credentials && { Credentials: CredentialsFilterSensitiveLog(obj.Credentials) }
|
|
467
|
-
});
|
|
468
850
|
var IDPCommunicationErrorException = class _IDPCommunicationErrorException extends STSServiceException {
|
|
469
851
|
name = "IDPCommunicationErrorException";
|
|
470
852
|
$fault = "client";
|
|
@@ -478,504 +860,42 @@ var IDPCommunicationErrorException = class _IDPCommunicationErrorException exten
|
|
|
478
860
|
}
|
|
479
861
|
};
|
|
480
862
|
|
|
481
|
-
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.
|
|
482
|
-
var
|
|
483
|
-
const headers = SHARED_HEADERS;
|
|
484
|
-
let body;
|
|
485
|
-
body = buildFormUrlencodedString({
|
|
486
|
-
...se_AssumeRoleRequest(input, context),
|
|
487
|
-
[_A]: _AR,
|
|
488
|
-
[_V]: _
|
|
489
|
-
});
|
|
490
|
-
return buildHttpRpcRequest(context, headers, "/", void 0, body);
|
|
491
|
-
};
|
|
492
|
-
var se_AssumeRoleWithWebIdentityCommand = async (input, context) => {
|
|
493
|
-
const headers = SHARED_HEADERS;
|
|
494
|
-
let body;
|
|
495
|
-
body = buildFormUrlencodedString({
|
|
496
|
-
...se_AssumeRoleWithWebIdentityRequest(input, context),
|
|
497
|
-
[_A]: _ARWWI,
|
|
498
|
-
[_V]: _
|
|
499
|
-
});
|
|
500
|
-
return buildHttpRpcRequest(context, headers, "/", void 0, body);
|
|
501
|
-
};
|
|
502
|
-
var de_AssumeRoleCommand = async (output, context) => {
|
|
503
|
-
if (output.statusCode >= 300) {
|
|
504
|
-
return de_CommandError(output, context);
|
|
505
|
-
}
|
|
506
|
-
const data = await parseXmlBody(output.body, context);
|
|
507
|
-
let contents = {};
|
|
508
|
-
contents = de_AssumeRoleResponse(data.AssumeRoleResult, context);
|
|
509
|
-
const response = {
|
|
510
|
-
$metadata: deserializeMetadata(output),
|
|
511
|
-
...contents
|
|
512
|
-
};
|
|
513
|
-
return response;
|
|
514
|
-
};
|
|
515
|
-
var de_AssumeRoleWithWebIdentityCommand = async (output, context) => {
|
|
516
|
-
if (output.statusCode >= 300) {
|
|
517
|
-
return de_CommandError(output, context);
|
|
518
|
-
}
|
|
519
|
-
const data = await parseXmlBody(output.body, context);
|
|
520
|
-
let contents = {};
|
|
521
|
-
contents = de_AssumeRoleWithWebIdentityResponse(data.AssumeRoleWithWebIdentityResult, context);
|
|
522
|
-
const response = {
|
|
523
|
-
$metadata: deserializeMetadata(output),
|
|
524
|
-
...contents
|
|
525
|
-
};
|
|
526
|
-
return response;
|
|
527
|
-
};
|
|
528
|
-
var de_CommandError = async (output, context) => {
|
|
529
|
-
const parsedOutput = {
|
|
530
|
-
...output,
|
|
531
|
-
body: await parseXmlErrorBody(output.body, context)
|
|
532
|
-
};
|
|
533
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
|
534
|
-
switch (errorCode) {
|
|
535
|
-
case "ExpiredTokenException":
|
|
536
|
-
case "com.amazonaws.sts#ExpiredTokenException":
|
|
537
|
-
throw await de_ExpiredTokenExceptionRes(parsedOutput, context);
|
|
538
|
-
case "MalformedPolicyDocument":
|
|
539
|
-
case "com.amazonaws.sts#MalformedPolicyDocumentException":
|
|
540
|
-
throw await de_MalformedPolicyDocumentExceptionRes(parsedOutput, context);
|
|
541
|
-
case "PackedPolicyTooLarge":
|
|
542
|
-
case "com.amazonaws.sts#PackedPolicyTooLargeException":
|
|
543
|
-
throw await de_PackedPolicyTooLargeExceptionRes(parsedOutput, context);
|
|
544
|
-
case "RegionDisabledException":
|
|
545
|
-
case "com.amazonaws.sts#RegionDisabledException":
|
|
546
|
-
throw await de_RegionDisabledExceptionRes(parsedOutput, context);
|
|
547
|
-
case "IDPCommunicationError":
|
|
548
|
-
case "com.amazonaws.sts#IDPCommunicationErrorException":
|
|
549
|
-
throw await de_IDPCommunicationErrorExceptionRes(parsedOutput, context);
|
|
550
|
-
case "IDPRejectedClaim":
|
|
551
|
-
case "com.amazonaws.sts#IDPRejectedClaimException":
|
|
552
|
-
throw await de_IDPRejectedClaimExceptionRes(parsedOutput, context);
|
|
553
|
-
case "InvalidIdentityToken":
|
|
554
|
-
case "com.amazonaws.sts#InvalidIdentityTokenException":
|
|
555
|
-
throw await de_InvalidIdentityTokenExceptionRes(parsedOutput, context);
|
|
556
|
-
default:
|
|
557
|
-
const parsedBody = parsedOutput.body;
|
|
558
|
-
return throwDefaultError({
|
|
559
|
-
output,
|
|
560
|
-
parsedBody: parsedBody.Error,
|
|
561
|
-
errorCode
|
|
562
|
-
});
|
|
563
|
-
}
|
|
564
|
-
};
|
|
565
|
-
var de_ExpiredTokenExceptionRes = async (parsedOutput, context) => {
|
|
566
|
-
const body = parsedOutput.body;
|
|
567
|
-
const deserialized = de_ExpiredTokenException(body.Error, context);
|
|
568
|
-
const exception = new ExpiredTokenException({
|
|
569
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
570
|
-
...deserialized
|
|
571
|
-
});
|
|
572
|
-
return decorateServiceException(exception, body);
|
|
573
|
-
};
|
|
574
|
-
var de_IDPCommunicationErrorExceptionRes = async (parsedOutput, context) => {
|
|
575
|
-
const body = parsedOutput.body;
|
|
576
|
-
const deserialized = de_IDPCommunicationErrorException(body.Error, context);
|
|
577
|
-
const exception = new IDPCommunicationErrorException({
|
|
578
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
579
|
-
...deserialized
|
|
580
|
-
});
|
|
581
|
-
return decorateServiceException(exception, body);
|
|
582
|
-
};
|
|
583
|
-
var de_IDPRejectedClaimExceptionRes = async (parsedOutput, context) => {
|
|
584
|
-
const body = parsedOutput.body;
|
|
585
|
-
const deserialized = de_IDPRejectedClaimException(body.Error, context);
|
|
586
|
-
const exception = new IDPRejectedClaimException({
|
|
587
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
588
|
-
...deserialized
|
|
589
|
-
});
|
|
590
|
-
return decorateServiceException(exception, body);
|
|
591
|
-
};
|
|
592
|
-
var de_InvalidIdentityTokenExceptionRes = async (parsedOutput, context) => {
|
|
593
|
-
const body = parsedOutput.body;
|
|
594
|
-
const deserialized = de_InvalidIdentityTokenException(body.Error, context);
|
|
595
|
-
const exception = new InvalidIdentityTokenException({
|
|
596
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
597
|
-
...deserialized
|
|
598
|
-
});
|
|
599
|
-
return decorateServiceException(exception, body);
|
|
600
|
-
};
|
|
601
|
-
var de_MalformedPolicyDocumentExceptionRes = async (parsedOutput, context) => {
|
|
602
|
-
const body = parsedOutput.body;
|
|
603
|
-
const deserialized = de_MalformedPolicyDocumentException(body.Error, context);
|
|
604
|
-
const exception = new MalformedPolicyDocumentException({
|
|
605
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
606
|
-
...deserialized
|
|
607
|
-
});
|
|
608
|
-
return decorateServiceException(exception, body);
|
|
609
|
-
};
|
|
610
|
-
var de_PackedPolicyTooLargeExceptionRes = async (parsedOutput, context) => {
|
|
611
|
-
const body = parsedOutput.body;
|
|
612
|
-
const deserialized = de_PackedPolicyTooLargeException(body.Error, context);
|
|
613
|
-
const exception = new PackedPolicyTooLargeException({
|
|
614
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
615
|
-
...deserialized
|
|
616
|
-
});
|
|
617
|
-
return decorateServiceException(exception, body);
|
|
618
|
-
};
|
|
619
|
-
var de_RegionDisabledExceptionRes = async (parsedOutput, context) => {
|
|
620
|
-
const body = parsedOutput.body;
|
|
621
|
-
const deserialized = de_RegionDisabledException(body.Error, context);
|
|
622
|
-
const exception = new RegionDisabledException({
|
|
623
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
624
|
-
...deserialized
|
|
625
|
-
});
|
|
626
|
-
return decorateServiceException(exception, body);
|
|
627
|
-
};
|
|
628
|
-
var se_AssumeRoleRequest = (input, context) => {
|
|
629
|
-
const entries = {};
|
|
630
|
-
if (input[_RA] != null) {
|
|
631
|
-
entries[_RA] = input[_RA];
|
|
632
|
-
}
|
|
633
|
-
if (input[_RSN] != null) {
|
|
634
|
-
entries[_RSN] = input[_RSN];
|
|
635
|
-
}
|
|
636
|
-
if (input[_PA] != null) {
|
|
637
|
-
const memberEntries = se_policyDescriptorListType(input[_PA], context);
|
|
638
|
-
if (input[_PA]?.length === 0) {
|
|
639
|
-
entries.PolicyArns = [];
|
|
640
|
-
}
|
|
641
|
-
Object.entries(memberEntries).forEach(([key, value]) => {
|
|
642
|
-
const loc = `PolicyArns.${key}`;
|
|
643
|
-
entries[loc] = value;
|
|
644
|
-
});
|
|
645
|
-
}
|
|
646
|
-
if (input[_P] != null) {
|
|
647
|
-
entries[_P] = input[_P];
|
|
648
|
-
}
|
|
649
|
-
if (input[_DS] != null) {
|
|
650
|
-
entries[_DS] = input[_DS];
|
|
651
|
-
}
|
|
652
|
-
if (input[_T] != null) {
|
|
653
|
-
const memberEntries = se_tagListType(input[_T], context);
|
|
654
|
-
if (input[_T]?.length === 0) {
|
|
655
|
-
entries.Tags = [];
|
|
656
|
-
}
|
|
657
|
-
Object.entries(memberEntries).forEach(([key, value]) => {
|
|
658
|
-
const loc = `Tags.${key}`;
|
|
659
|
-
entries[loc] = value;
|
|
660
|
-
});
|
|
661
|
-
}
|
|
662
|
-
if (input[_TTK] != null) {
|
|
663
|
-
const memberEntries = se_tagKeyListType(input[_TTK], context);
|
|
664
|
-
if (input[_TTK]?.length === 0) {
|
|
665
|
-
entries.TransitiveTagKeys = [];
|
|
666
|
-
}
|
|
667
|
-
Object.entries(memberEntries).forEach(([key, value]) => {
|
|
668
|
-
const loc = `TransitiveTagKeys.${key}`;
|
|
669
|
-
entries[loc] = value;
|
|
670
|
-
});
|
|
671
|
-
}
|
|
672
|
-
if (input[_EI] != null) {
|
|
673
|
-
entries[_EI] = input[_EI];
|
|
674
|
-
}
|
|
675
|
-
if (input[_SN] != null) {
|
|
676
|
-
entries[_SN] = input[_SN];
|
|
677
|
-
}
|
|
678
|
-
if (input[_TC] != null) {
|
|
679
|
-
entries[_TC] = input[_TC];
|
|
680
|
-
}
|
|
681
|
-
if (input[_SI] != null) {
|
|
682
|
-
entries[_SI] = input[_SI];
|
|
683
|
-
}
|
|
684
|
-
if (input[_PC] != null) {
|
|
685
|
-
const memberEntries = se_ProvidedContextsListType(input[_PC], context);
|
|
686
|
-
if (input[_PC]?.length === 0) {
|
|
687
|
-
entries.ProvidedContexts = [];
|
|
688
|
-
}
|
|
689
|
-
Object.entries(memberEntries).forEach(([key, value]) => {
|
|
690
|
-
const loc = `ProvidedContexts.${key}`;
|
|
691
|
-
entries[loc] = value;
|
|
692
|
-
});
|
|
693
|
-
}
|
|
694
|
-
return entries;
|
|
695
|
-
};
|
|
696
|
-
var se_AssumeRoleWithWebIdentityRequest = (input, context) => {
|
|
697
|
-
const entries = {};
|
|
698
|
-
if (input[_RA] != null) {
|
|
699
|
-
entries[_RA] = input[_RA];
|
|
700
|
-
}
|
|
701
|
-
if (input[_RSN] != null) {
|
|
702
|
-
entries[_RSN] = input[_RSN];
|
|
703
|
-
}
|
|
704
|
-
if (input[_WIT] != null) {
|
|
705
|
-
entries[_WIT] = input[_WIT];
|
|
706
|
-
}
|
|
707
|
-
if (input[_PI] != null) {
|
|
708
|
-
entries[_PI] = input[_PI];
|
|
709
|
-
}
|
|
710
|
-
if (input[_PA] != null) {
|
|
711
|
-
const memberEntries = se_policyDescriptorListType(input[_PA], context);
|
|
712
|
-
if (input[_PA]?.length === 0) {
|
|
713
|
-
entries.PolicyArns = [];
|
|
714
|
-
}
|
|
715
|
-
Object.entries(memberEntries).forEach(([key, value]) => {
|
|
716
|
-
const loc = `PolicyArns.${key}`;
|
|
717
|
-
entries[loc] = value;
|
|
718
|
-
});
|
|
719
|
-
}
|
|
720
|
-
if (input[_P] != null) {
|
|
721
|
-
entries[_P] = input[_P];
|
|
722
|
-
}
|
|
723
|
-
if (input[_DS] != null) {
|
|
724
|
-
entries[_DS] = input[_DS];
|
|
725
|
-
}
|
|
726
|
-
return entries;
|
|
727
|
-
};
|
|
728
|
-
var se_policyDescriptorListType = (input, context) => {
|
|
729
|
-
const entries = {};
|
|
730
|
-
let counter = 1;
|
|
731
|
-
for (const entry of input) {
|
|
732
|
-
if (entry === null) {
|
|
733
|
-
continue;
|
|
734
|
-
}
|
|
735
|
-
const memberEntries = se_PolicyDescriptorType(entry, context);
|
|
736
|
-
Object.entries(memberEntries).forEach(([key, value]) => {
|
|
737
|
-
entries[`member.${counter}.${key}`] = value;
|
|
738
|
-
});
|
|
739
|
-
counter++;
|
|
740
|
-
}
|
|
741
|
-
return entries;
|
|
742
|
-
};
|
|
743
|
-
var se_PolicyDescriptorType = (input, context) => {
|
|
744
|
-
const entries = {};
|
|
745
|
-
if (input[_a] != null) {
|
|
746
|
-
entries[_a] = input[_a];
|
|
747
|
-
}
|
|
748
|
-
return entries;
|
|
749
|
-
};
|
|
750
|
-
var se_ProvidedContext = (input, context) => {
|
|
751
|
-
const entries = {};
|
|
752
|
-
if (input[_PAr] != null) {
|
|
753
|
-
entries[_PAr] = input[_PAr];
|
|
754
|
-
}
|
|
755
|
-
if (input[_CA] != null) {
|
|
756
|
-
entries[_CA] = input[_CA];
|
|
757
|
-
}
|
|
758
|
-
return entries;
|
|
759
|
-
};
|
|
760
|
-
var se_ProvidedContextsListType = (input, context) => {
|
|
761
|
-
const entries = {};
|
|
762
|
-
let counter = 1;
|
|
763
|
-
for (const entry of input) {
|
|
764
|
-
if (entry === null) {
|
|
765
|
-
continue;
|
|
766
|
-
}
|
|
767
|
-
const memberEntries = se_ProvidedContext(entry, context);
|
|
768
|
-
Object.entries(memberEntries).forEach(([key, value]) => {
|
|
769
|
-
entries[`member.${counter}.${key}`] = value;
|
|
770
|
-
});
|
|
771
|
-
counter++;
|
|
772
|
-
}
|
|
773
|
-
return entries;
|
|
774
|
-
};
|
|
775
|
-
var se_Tag = (input, context) => {
|
|
776
|
-
const entries = {};
|
|
777
|
-
if (input[_K] != null) {
|
|
778
|
-
entries[_K] = input[_K];
|
|
779
|
-
}
|
|
780
|
-
if (input[_Va] != null) {
|
|
781
|
-
entries[_Va] = input[_Va];
|
|
782
|
-
}
|
|
783
|
-
return entries;
|
|
784
|
-
};
|
|
785
|
-
var se_tagKeyListType = (input, context) => {
|
|
786
|
-
const entries = {};
|
|
787
|
-
let counter = 1;
|
|
788
|
-
for (const entry of input) {
|
|
789
|
-
if (entry === null) {
|
|
790
|
-
continue;
|
|
791
|
-
}
|
|
792
|
-
entries[`member.${counter}`] = entry;
|
|
793
|
-
counter++;
|
|
794
|
-
}
|
|
795
|
-
return entries;
|
|
796
|
-
};
|
|
797
|
-
var se_tagListType = (input, context) => {
|
|
798
|
-
const entries = {};
|
|
799
|
-
let counter = 1;
|
|
800
|
-
for (const entry of input) {
|
|
801
|
-
if (entry === null) {
|
|
802
|
-
continue;
|
|
803
|
-
}
|
|
804
|
-
const memberEntries = se_Tag(entry, context);
|
|
805
|
-
Object.entries(memberEntries).forEach(([key, value]) => {
|
|
806
|
-
entries[`member.${counter}.${key}`] = value;
|
|
807
|
-
});
|
|
808
|
-
counter++;
|
|
809
|
-
}
|
|
810
|
-
return entries;
|
|
811
|
-
};
|
|
812
|
-
var de_AssumedRoleUser = (output, context) => {
|
|
813
|
-
const contents = {};
|
|
814
|
-
if (output[_ARI] != null) {
|
|
815
|
-
contents[_ARI] = expectString(output[_ARI]);
|
|
816
|
-
}
|
|
817
|
-
if (output[_Ar] != null) {
|
|
818
|
-
contents[_Ar] = expectString(output[_Ar]);
|
|
819
|
-
}
|
|
820
|
-
return contents;
|
|
821
|
-
};
|
|
822
|
-
var de_AssumeRoleResponse = (output, context) => {
|
|
823
|
-
const contents = {};
|
|
824
|
-
if (output[_C] != null) {
|
|
825
|
-
contents[_C] = de_Credentials(output[_C], context);
|
|
826
|
-
}
|
|
827
|
-
if (output[_ARU] != null) {
|
|
828
|
-
contents[_ARU] = de_AssumedRoleUser(output[_ARU], context);
|
|
829
|
-
}
|
|
830
|
-
if (output[_PPS] != null) {
|
|
831
|
-
contents[_PPS] = strictParseInt32(output[_PPS]);
|
|
832
|
-
}
|
|
833
|
-
if (output[_SI] != null) {
|
|
834
|
-
contents[_SI] = expectString(output[_SI]);
|
|
835
|
-
}
|
|
836
|
-
return contents;
|
|
837
|
-
};
|
|
838
|
-
var de_AssumeRoleWithWebIdentityResponse = (output, context) => {
|
|
839
|
-
const contents = {};
|
|
840
|
-
if (output[_C] != null) {
|
|
841
|
-
contents[_C] = de_Credentials(output[_C], context);
|
|
842
|
-
}
|
|
843
|
-
if (output[_SFWIT] != null) {
|
|
844
|
-
contents[_SFWIT] = expectString(output[_SFWIT]);
|
|
845
|
-
}
|
|
846
|
-
if (output[_ARU] != null) {
|
|
847
|
-
contents[_ARU] = de_AssumedRoleUser(output[_ARU], context);
|
|
848
|
-
}
|
|
849
|
-
if (output[_PPS] != null) {
|
|
850
|
-
contents[_PPS] = strictParseInt32(output[_PPS]);
|
|
851
|
-
}
|
|
852
|
-
if (output[_Pr] != null) {
|
|
853
|
-
contents[_Pr] = expectString(output[_Pr]);
|
|
854
|
-
}
|
|
855
|
-
if (output[_Au] != null) {
|
|
856
|
-
contents[_Au] = expectString(output[_Au]);
|
|
857
|
-
}
|
|
858
|
-
if (output[_SI] != null) {
|
|
859
|
-
contents[_SI] = expectString(output[_SI]);
|
|
860
|
-
}
|
|
861
|
-
return contents;
|
|
862
|
-
};
|
|
863
|
-
var de_Credentials = (output, context) => {
|
|
864
|
-
const contents = {};
|
|
865
|
-
if (output[_AKI] != null) {
|
|
866
|
-
contents[_AKI] = expectString(output[_AKI]);
|
|
867
|
-
}
|
|
868
|
-
if (output[_SAK] != null) {
|
|
869
|
-
contents[_SAK] = expectString(output[_SAK]);
|
|
870
|
-
}
|
|
871
|
-
if (output[_ST] != null) {
|
|
872
|
-
contents[_ST] = expectString(output[_ST]);
|
|
873
|
-
}
|
|
874
|
-
if (output[_E] != null) {
|
|
875
|
-
contents[_E] = expectNonNull(parseRfc3339DateTimeWithOffset(output[_E]));
|
|
876
|
-
}
|
|
877
|
-
return contents;
|
|
878
|
-
};
|
|
879
|
-
var de_ExpiredTokenException = (output, context) => {
|
|
880
|
-
const contents = {};
|
|
881
|
-
if (output[_m] != null) {
|
|
882
|
-
contents[_m] = expectString(output[_m]);
|
|
883
|
-
}
|
|
884
|
-
return contents;
|
|
885
|
-
};
|
|
886
|
-
var de_IDPCommunicationErrorException = (output, context) => {
|
|
887
|
-
const contents = {};
|
|
888
|
-
if (output[_m] != null) {
|
|
889
|
-
contents[_m] = expectString(output[_m]);
|
|
890
|
-
}
|
|
891
|
-
return contents;
|
|
892
|
-
};
|
|
893
|
-
var de_IDPRejectedClaimException = (output, context) => {
|
|
894
|
-
const contents = {};
|
|
895
|
-
if (output[_m] != null) {
|
|
896
|
-
contents[_m] = expectString(output[_m]);
|
|
897
|
-
}
|
|
898
|
-
return contents;
|
|
899
|
-
};
|
|
900
|
-
var de_InvalidIdentityTokenException = (output, context) => {
|
|
901
|
-
const contents = {};
|
|
902
|
-
if (output[_m] != null) {
|
|
903
|
-
contents[_m] = expectString(output[_m]);
|
|
904
|
-
}
|
|
905
|
-
return contents;
|
|
906
|
-
};
|
|
907
|
-
var de_MalformedPolicyDocumentException = (output, context) => {
|
|
908
|
-
const contents = {};
|
|
909
|
-
if (output[_m] != null) {
|
|
910
|
-
contents[_m] = expectString(output[_m]);
|
|
911
|
-
}
|
|
912
|
-
return contents;
|
|
913
|
-
};
|
|
914
|
-
var de_PackedPolicyTooLargeException = (output, context) => {
|
|
915
|
-
const contents = {};
|
|
916
|
-
if (output[_m] != null) {
|
|
917
|
-
contents[_m] = expectString(output[_m]);
|
|
918
|
-
}
|
|
919
|
-
return contents;
|
|
920
|
-
};
|
|
921
|
-
var de_RegionDisabledException = (output, context) => {
|
|
922
|
-
const contents = {};
|
|
923
|
-
if (output[_m] != null) {
|
|
924
|
-
contents[_m] = expectString(output[_m]);
|
|
925
|
-
}
|
|
926
|
-
return contents;
|
|
927
|
-
};
|
|
928
|
-
var deserializeMetadata = (output) => ({
|
|
929
|
-
httpStatusCode: output.statusCode,
|
|
930
|
-
requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
|
|
931
|
-
extendedRequestId: output.headers["x-amz-id-2"],
|
|
932
|
-
cfId: output.headers["x-amz-cf-id"]
|
|
933
|
-
});
|
|
934
|
-
var throwDefaultError = withBaseException(STSServiceException);
|
|
935
|
-
var buildHttpRpcRequest = async (context, headers, path, resolvedHostname, body) => {
|
|
936
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
937
|
-
const contents = {
|
|
938
|
-
protocol,
|
|
939
|
-
hostname,
|
|
940
|
-
port,
|
|
941
|
-
method: "POST",
|
|
942
|
-
path: basePath.endsWith("/") ? basePath.slice(0, -1) + path : basePath + path,
|
|
943
|
-
headers
|
|
944
|
-
};
|
|
945
|
-
if (resolvedHostname !== void 0) {
|
|
946
|
-
contents.hostname = resolvedHostname;
|
|
947
|
-
}
|
|
948
|
-
if (body !== void 0) {
|
|
949
|
-
contents.body = body;
|
|
950
|
-
}
|
|
951
|
-
return new HttpRequest(contents);
|
|
952
|
-
};
|
|
953
|
-
var SHARED_HEADERS = {
|
|
954
|
-
"content-type": "application/x-www-form-urlencoded"
|
|
955
|
-
};
|
|
956
|
-
var _ = "2011-06-15";
|
|
957
|
-
var _A = "Action";
|
|
863
|
+
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.940.0-415b36f0bc-6695cd044d.zip/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/schemas/schemas_0.js
|
|
864
|
+
var _A = "Arn";
|
|
958
865
|
var _AKI = "AccessKeyId";
|
|
959
866
|
var _AR = "AssumeRole";
|
|
960
867
|
var _ARI = "AssumedRoleId";
|
|
868
|
+
var _ARR = "AssumeRoleRequest";
|
|
869
|
+
var _ARRs = "AssumeRoleResponse";
|
|
961
870
|
var _ARU = "AssumedRoleUser";
|
|
962
871
|
var _ARWWI = "AssumeRoleWithWebIdentity";
|
|
963
|
-
var
|
|
872
|
+
var _ARWWIR = "AssumeRoleWithWebIdentityRequest";
|
|
873
|
+
var _ARWWIRs = "AssumeRoleWithWebIdentityResponse";
|
|
964
874
|
var _Au = "Audience";
|
|
965
875
|
var _C = "Credentials";
|
|
966
876
|
var _CA = "ContextAssertion";
|
|
967
877
|
var _DS = "DurationSeconds";
|
|
968
878
|
var _E = "Expiration";
|
|
969
879
|
var _EI = "ExternalId";
|
|
880
|
+
var _ETE = "ExpiredTokenException";
|
|
881
|
+
var _IDPCEE = "IDPCommunicationErrorException";
|
|
882
|
+
var _IDPRCE = "IDPRejectedClaimException";
|
|
883
|
+
var _IITE = "InvalidIdentityTokenException";
|
|
970
884
|
var _K = "Key";
|
|
885
|
+
var _MPDE = "MalformedPolicyDocumentException";
|
|
971
886
|
var _P = "Policy";
|
|
972
887
|
var _PA = "PolicyArns";
|
|
973
888
|
var _PAr = "ProviderArn";
|
|
974
889
|
var _PC = "ProvidedContexts";
|
|
890
|
+
var _PCLT = "ProvidedContextsListType";
|
|
891
|
+
var _PCr = "ProvidedContext";
|
|
892
|
+
var _PDT = "PolicyDescriptorType";
|
|
975
893
|
var _PI = "ProviderId";
|
|
976
894
|
var _PPS = "PackedPolicySize";
|
|
895
|
+
var _PPTLE = "PackedPolicyTooLargeException";
|
|
977
896
|
var _Pr = "Provider";
|
|
978
897
|
var _RA = "RoleArn";
|
|
898
|
+
var _RDE = "RegionDisabledException";
|
|
979
899
|
var _RSN = "RoleSessionName";
|
|
980
900
|
var _SAK = "SecretAccessKey";
|
|
981
901
|
var _SFWIT = "SubjectFromWebIdentityToken";
|
|
@@ -985,40 +905,187 @@ var _ST = "SessionToken";
|
|
|
985
905
|
var _T = "Tags";
|
|
986
906
|
var _TC = "TokenCode";
|
|
987
907
|
var _TTK = "TransitiveTagKeys";
|
|
988
|
-
var
|
|
989
|
-
var
|
|
908
|
+
var _Ta = "Tag";
|
|
909
|
+
var _V = "Value";
|
|
990
910
|
var _WIT = "WebIdentityToken";
|
|
991
911
|
var _a = "arn";
|
|
912
|
+
var _aKST = "accessKeySecretType";
|
|
913
|
+
var _aQE = "awsQueryError";
|
|
914
|
+
var _c = "client";
|
|
915
|
+
var _cTT = "clientTokenType";
|
|
916
|
+
var _e = "error";
|
|
917
|
+
var _hE = "httpError";
|
|
992
918
|
var _m = "message";
|
|
993
|
-
var
|
|
994
|
-
var
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
919
|
+
var _pDLT = "policyDescriptorListType";
|
|
920
|
+
var _s = "smithy.ts.sdk.synthetic.com.amazonaws.sts";
|
|
921
|
+
var _tLT = "tagListType";
|
|
922
|
+
var n0 = "com.amazonaws.sts";
|
|
923
|
+
var accessKeySecretType = [0, n0, _aKST, 8, 0];
|
|
924
|
+
var clientTokenType = [0, n0, _cTT, 8, 0];
|
|
925
|
+
var AssumedRoleUser = [3, n0, _ARU, 0, [_ARI, _A], [0, 0]];
|
|
926
|
+
var AssumeRoleRequest = [
|
|
927
|
+
3,
|
|
928
|
+
n0,
|
|
929
|
+
_ARR,
|
|
930
|
+
0,
|
|
931
|
+
[_RA, _RSN, _PA, _P, _DS, _T, _TTK, _EI, _SN, _TC, _SI, _PC],
|
|
932
|
+
[0, 0, () => policyDescriptorListType, 0, 1, () => tagListType, 64 | 0, 0, 0, 0, 0, () => ProvidedContextsListType]
|
|
933
|
+
];
|
|
934
|
+
var AssumeRoleResponse = [
|
|
935
|
+
3,
|
|
936
|
+
n0,
|
|
937
|
+
_ARRs,
|
|
938
|
+
0,
|
|
939
|
+
[_C, _ARU, _PPS, _SI],
|
|
940
|
+
[[() => Credentials, 0], () => AssumedRoleUser, 1, 0]
|
|
941
|
+
];
|
|
942
|
+
var AssumeRoleWithWebIdentityRequest = [
|
|
943
|
+
3,
|
|
944
|
+
n0,
|
|
945
|
+
_ARWWIR,
|
|
946
|
+
0,
|
|
947
|
+
[_RA, _RSN, _WIT, _PI, _PA, _P, _DS],
|
|
948
|
+
[0, 0, [() => clientTokenType, 0], 0, () => policyDescriptorListType, 0, 1]
|
|
949
|
+
];
|
|
950
|
+
var AssumeRoleWithWebIdentityResponse = [
|
|
951
|
+
3,
|
|
952
|
+
n0,
|
|
953
|
+
_ARWWIRs,
|
|
954
|
+
0,
|
|
955
|
+
[_C, _SFWIT, _ARU, _PPS, _Pr, _Au, _SI],
|
|
956
|
+
[[() => Credentials, 0], 0, () => AssumedRoleUser, 1, 0, 0, 0]
|
|
957
|
+
];
|
|
958
|
+
var Credentials = [
|
|
959
|
+
3,
|
|
960
|
+
n0,
|
|
961
|
+
_C,
|
|
962
|
+
0,
|
|
963
|
+
[_AKI, _SAK, _ST, _E],
|
|
964
|
+
[0, [() => accessKeySecretType, 0], 0, 4]
|
|
965
|
+
];
|
|
966
|
+
var ExpiredTokenException2 = [
|
|
967
|
+
-3,
|
|
968
|
+
n0,
|
|
969
|
+
_ETE,
|
|
970
|
+
{
|
|
971
|
+
[_e]: _c,
|
|
972
|
+
[_hE]: 400,
|
|
973
|
+
[_aQE]: [`ExpiredTokenException`, 400]
|
|
974
|
+
},
|
|
975
|
+
[_m],
|
|
976
|
+
[0]
|
|
977
|
+
];
|
|
978
|
+
TypeRegistry.for(n0).registerError(ExpiredTokenException2, ExpiredTokenException);
|
|
979
|
+
var IDPCommunicationErrorException2 = [
|
|
980
|
+
-3,
|
|
981
|
+
n0,
|
|
982
|
+
_IDPCEE,
|
|
983
|
+
{
|
|
984
|
+
[_e]: _c,
|
|
985
|
+
[_hE]: 400,
|
|
986
|
+
[_aQE]: [`IDPCommunicationError`, 400]
|
|
987
|
+
},
|
|
988
|
+
[_m],
|
|
989
|
+
[0]
|
|
990
|
+
];
|
|
991
|
+
TypeRegistry.for(n0).registerError(IDPCommunicationErrorException2, IDPCommunicationErrorException);
|
|
992
|
+
var IDPRejectedClaimException2 = [
|
|
993
|
+
-3,
|
|
994
|
+
n0,
|
|
995
|
+
_IDPRCE,
|
|
996
|
+
{
|
|
997
|
+
[_e]: _c,
|
|
998
|
+
[_hE]: 403,
|
|
999
|
+
[_aQE]: [`IDPRejectedClaim`, 403]
|
|
1000
|
+
},
|
|
1001
|
+
[_m],
|
|
1002
|
+
[0]
|
|
1003
|
+
];
|
|
1004
|
+
TypeRegistry.for(n0).registerError(IDPRejectedClaimException2, IDPRejectedClaimException);
|
|
1005
|
+
var InvalidIdentityTokenException2 = [
|
|
1006
|
+
-3,
|
|
1007
|
+
n0,
|
|
1008
|
+
_IITE,
|
|
1009
|
+
{
|
|
1010
|
+
[_e]: _c,
|
|
1011
|
+
[_hE]: 400,
|
|
1012
|
+
[_aQE]: [`InvalidIdentityToken`, 400]
|
|
1013
|
+
},
|
|
1014
|
+
[_m],
|
|
1015
|
+
[0]
|
|
1016
|
+
];
|
|
1017
|
+
TypeRegistry.for(n0).registerError(InvalidIdentityTokenException2, InvalidIdentityTokenException);
|
|
1018
|
+
var MalformedPolicyDocumentException2 = [
|
|
1019
|
+
-3,
|
|
1020
|
+
n0,
|
|
1021
|
+
_MPDE,
|
|
1022
|
+
{
|
|
1023
|
+
[_e]: _c,
|
|
1024
|
+
[_hE]: 400,
|
|
1025
|
+
[_aQE]: [`MalformedPolicyDocument`, 400]
|
|
1026
|
+
},
|
|
1027
|
+
[_m],
|
|
1028
|
+
[0]
|
|
1029
|
+
];
|
|
1030
|
+
TypeRegistry.for(n0).registerError(MalformedPolicyDocumentException2, MalformedPolicyDocumentException);
|
|
1031
|
+
var PackedPolicyTooLargeException2 = [
|
|
1032
|
+
-3,
|
|
1033
|
+
n0,
|
|
1034
|
+
_PPTLE,
|
|
1035
|
+
{
|
|
1036
|
+
[_e]: _c,
|
|
1037
|
+
[_hE]: 400,
|
|
1038
|
+
[_aQE]: [`PackedPolicyTooLarge`, 400]
|
|
1039
|
+
},
|
|
1040
|
+
[_m],
|
|
1041
|
+
[0]
|
|
1042
|
+
];
|
|
1043
|
+
TypeRegistry.for(n0).registerError(PackedPolicyTooLargeException2, PackedPolicyTooLargeException);
|
|
1044
|
+
var PolicyDescriptorType = [3, n0, _PDT, 0, [_a], [0]];
|
|
1045
|
+
var ProvidedContext = [3, n0, _PCr, 0, [_PAr, _CA], [0, 0]];
|
|
1046
|
+
var RegionDisabledException2 = [
|
|
1047
|
+
-3,
|
|
1048
|
+
n0,
|
|
1049
|
+
_RDE,
|
|
1050
|
+
{
|
|
1051
|
+
[_e]: _c,
|
|
1052
|
+
[_hE]: 403,
|
|
1053
|
+
[_aQE]: [`RegionDisabledException`, 403]
|
|
1054
|
+
},
|
|
1055
|
+
[_m],
|
|
1056
|
+
[0]
|
|
1057
|
+
];
|
|
1058
|
+
TypeRegistry.for(n0).registerError(RegionDisabledException2, RegionDisabledException);
|
|
1059
|
+
var Tag = [3, n0, _Ta, 0, [_K, _V], [0, 0]];
|
|
1060
|
+
var STSServiceException2 = [-3, _s, "STSServiceException", 0, [], []];
|
|
1061
|
+
TypeRegistry.for(_s).registerError(STSServiceException2, STSServiceException);
|
|
1062
|
+
var policyDescriptorListType = [1, n0, _pDLT, 0, () => PolicyDescriptorType];
|
|
1063
|
+
var ProvidedContextsListType = [1, n0, _PCLT, 0, () => ProvidedContext];
|
|
1064
|
+
var tagKeyListType = 64 | 0;
|
|
1065
|
+
var tagListType = [1, n0, _tLT, 0, () => Tag];
|
|
1066
|
+
var AssumeRole = [9, n0, _AR, 0, () => AssumeRoleRequest, () => AssumeRoleResponse];
|
|
1067
|
+
var AssumeRoleWithWebIdentity = [
|
|
1068
|
+
9,
|
|
1069
|
+
n0,
|
|
1070
|
+
_ARWWI,
|
|
1071
|
+
0,
|
|
1072
|
+
() => AssumeRoleWithWebIdentityRequest,
|
|
1073
|
+
() => AssumeRoleWithWebIdentityResponse
|
|
1074
|
+
];
|
|
1002
1075
|
|
|
1003
|
-
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.
|
|
1076
|
+
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.940.0-415b36f0bc-6695cd044d.zip/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/commands/AssumeRoleCommand.js
|
|
1004
1077
|
var AssumeRoleCommand = class extends Command.classBuilder().ep(commonParams).m(function(Command2, cs, config, o2) {
|
|
1005
|
-
return [
|
|
1006
|
-
|
|
1007
|
-
getEndpointPlugin(config, Command2.getEndpointParameterInstructions())
|
|
1008
|
-
];
|
|
1009
|
-
}).s("AWSSecurityTokenServiceV20110615", "AssumeRole", {}).n("STSClient", "AssumeRoleCommand").f(void 0, AssumeRoleResponseFilterSensitiveLog).ser(se_AssumeRoleCommand).de(de_AssumeRoleCommand).build() {
|
|
1078
|
+
return [getEndpointPlugin(config, Command2.getEndpointParameterInstructions())];
|
|
1079
|
+
}).s("AWSSecurityTokenServiceV20110615", "AssumeRole", {}).n("STSClient", "AssumeRoleCommand").sc(AssumeRole).build() {
|
|
1010
1080
|
};
|
|
1011
1081
|
|
|
1012
|
-
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.
|
|
1082
|
+
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.940.0-415b36f0bc-6695cd044d.zip/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/commands/AssumeRoleWithWebIdentityCommand.js
|
|
1013
1083
|
var AssumeRoleWithWebIdentityCommand = class extends Command.classBuilder().ep(commonParams).m(function(Command2, cs, config, o2) {
|
|
1014
|
-
return [
|
|
1015
|
-
|
|
1016
|
-
getEndpointPlugin(config, Command2.getEndpointParameterInstructions())
|
|
1017
|
-
];
|
|
1018
|
-
}).s("AWSSecurityTokenServiceV20110615", "AssumeRoleWithWebIdentity", {}).n("STSClient", "AssumeRoleWithWebIdentityCommand").f(AssumeRoleWithWebIdentityRequestFilterSensitiveLog, AssumeRoleWithWebIdentityResponseFilterSensitiveLog).ser(se_AssumeRoleWithWebIdentityCommand).de(de_AssumeRoleWithWebIdentityCommand).build() {
|
|
1084
|
+
return [getEndpointPlugin(config, Command2.getEndpointParameterInstructions())];
|
|
1085
|
+
}).s("AWSSecurityTokenServiceV20110615", "AssumeRoleWithWebIdentity", {}).n("STSClient", "AssumeRoleWithWebIdentityCommand").sc(AssumeRoleWithWebIdentity).build() {
|
|
1019
1086
|
};
|
|
1020
1087
|
|
|
1021
|
-
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.
|
|
1088
|
+
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.940.0-415b36f0bc-6695cd044d.zip/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/STS.js
|
|
1022
1089
|
var commands = {
|
|
1023
1090
|
AssumeRoleCommand,
|
|
1024
1091
|
AssumeRoleWithWebIdentityCommand
|
|
@@ -1027,8 +1094,7 @@ var STS = class extends STSClient {
|
|
|
1027
1094
|
};
|
|
1028
1095
|
createAggregatedClient(commands, STS);
|
|
1029
1096
|
|
|
1030
|
-
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.
|
|
1031
|
-
var ASSUME_ROLE_DEFAULT_REGION = "us-east-1";
|
|
1097
|
+
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.940.0-415b36f0bc-6695cd044d.zip/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/defaultStsRoleAssumers.js
|
|
1032
1098
|
var getAccountIdFromAssumedRoleUser = (assumedRoleUser) => {
|
|
1033
1099
|
if (typeof assumedRoleUser?.Arn === "string") {
|
|
1034
1100
|
const arnComponents = assumedRoleUser.Arn.split(":");
|
|
@@ -1038,11 +1104,12 @@ var getAccountIdFromAssumedRoleUser = (assumedRoleUser) => {
|
|
|
1038
1104
|
}
|
|
1039
1105
|
return void 0;
|
|
1040
1106
|
};
|
|
1041
|
-
var resolveRegion = async (_region, _parentRegion, credentialProviderLogger) => {
|
|
1107
|
+
var resolveRegion = async (_region, _parentRegion, credentialProviderLogger, loaderConfig = {}) => {
|
|
1042
1108
|
const region = typeof _region === "function" ? await _region() : _region;
|
|
1043
1109
|
const parentRegion = typeof _parentRegion === "function" ? await _parentRegion() : _parentRegion;
|
|
1044
|
-
|
|
1045
|
-
|
|
1110
|
+
const stsDefaultRegion = await stsRegionDefaultResolver(loaderConfig)();
|
|
1111
|
+
credentialProviderLogger?.debug?.("@aws-sdk/client-sts::resolveRegion", "accepting first of:", `${region} (credential provider clientConfig)`, `${parentRegion} (contextual client)`, `${stsDefaultRegion} (STS default: AWS_REGION, profile region, or us-east-1)`);
|
|
1112
|
+
return region ?? parentRegion ?? stsDefaultRegion;
|
|
1046
1113
|
};
|
|
1047
1114
|
var getDefaultRoleAssumer = (stsOptions, STSClient2) => {
|
|
1048
1115
|
let stsClient;
|
|
@@ -1050,28 +1117,33 @@ var getDefaultRoleAssumer = (stsOptions, STSClient2) => {
|
|
|
1050
1117
|
return async (sourceCreds, params) => {
|
|
1051
1118
|
closureSourceCreds = sourceCreds;
|
|
1052
1119
|
if (!stsClient) {
|
|
1053
|
-
const { logger = stsOptions?.parentClientConfig?.logger, region, requestHandler = stsOptions?.parentClientConfig?.requestHandler, credentialProviderLogger } = stsOptions;
|
|
1054
|
-
const resolvedRegion = await resolveRegion(region, stsOptions?.parentClientConfig?.region, credentialProviderLogger
|
|
1120
|
+
const { logger = stsOptions?.parentClientConfig?.logger, profile = stsOptions?.parentClientConfig?.profile, region, requestHandler = stsOptions?.parentClientConfig?.requestHandler, credentialProviderLogger, userAgentAppId = stsOptions?.parentClientConfig?.userAgentAppId } = stsOptions;
|
|
1121
|
+
const resolvedRegion = await resolveRegion(region, stsOptions?.parentClientConfig?.region, credentialProviderLogger, {
|
|
1122
|
+
logger,
|
|
1123
|
+
profile
|
|
1124
|
+
});
|
|
1055
1125
|
const isCompatibleRequestHandler = !isH2(requestHandler);
|
|
1056
1126
|
stsClient = new STSClient2({
|
|
1057
|
-
|
|
1127
|
+
...stsOptions,
|
|
1128
|
+
userAgentAppId,
|
|
1129
|
+
profile,
|
|
1058
1130
|
credentialDefaultProvider: () => async () => closureSourceCreds,
|
|
1059
1131
|
region: resolvedRegion,
|
|
1060
1132
|
requestHandler: isCompatibleRequestHandler ? requestHandler : void 0,
|
|
1061
1133
|
logger
|
|
1062
1134
|
});
|
|
1063
1135
|
}
|
|
1064
|
-
const { Credentials, AssumedRoleUser } = await stsClient.send(new AssumeRoleCommand(params));
|
|
1065
|
-
if (!
|
|
1136
|
+
const { Credentials: Credentials2, AssumedRoleUser: AssumedRoleUser2 } = await stsClient.send(new AssumeRoleCommand(params));
|
|
1137
|
+
if (!Credentials2 || !Credentials2.AccessKeyId || !Credentials2.SecretAccessKey) {
|
|
1066
1138
|
throw new Error(`Invalid response from STS.assumeRole call with role ${params.RoleArn}`);
|
|
1067
1139
|
}
|
|
1068
|
-
const accountId = getAccountIdFromAssumedRoleUser(
|
|
1140
|
+
const accountId = getAccountIdFromAssumedRoleUser(AssumedRoleUser2);
|
|
1069
1141
|
const credentials = {
|
|
1070
|
-
accessKeyId:
|
|
1071
|
-
secretAccessKey:
|
|
1072
|
-
sessionToken:
|
|
1073
|
-
expiration:
|
|
1074
|
-
...
|
|
1142
|
+
accessKeyId: Credentials2.AccessKeyId,
|
|
1143
|
+
secretAccessKey: Credentials2.SecretAccessKey,
|
|
1144
|
+
sessionToken: Credentials2.SessionToken,
|
|
1145
|
+
expiration: Credentials2.Expiration,
|
|
1146
|
+
...Credentials2.CredentialScope && { credentialScope: Credentials2.CredentialScope },
|
|
1075
1147
|
...accountId && { accountId }
|
|
1076
1148
|
};
|
|
1077
1149
|
setCredentialFeature(credentials, "CREDENTIALS_STS_ASSUME_ROLE", "i");
|
|
@@ -1082,27 +1154,32 @@ var getDefaultRoleAssumerWithWebIdentity = (stsOptions, STSClient2) => {
|
|
|
1082
1154
|
let stsClient;
|
|
1083
1155
|
return async (params) => {
|
|
1084
1156
|
if (!stsClient) {
|
|
1085
|
-
const { logger = stsOptions?.parentClientConfig?.logger, region, requestHandler = stsOptions?.parentClientConfig?.requestHandler, credentialProviderLogger } = stsOptions;
|
|
1086
|
-
const resolvedRegion = await resolveRegion(region, stsOptions?.parentClientConfig?.region, credentialProviderLogger
|
|
1157
|
+
const { logger = stsOptions?.parentClientConfig?.logger, profile = stsOptions?.parentClientConfig?.profile, region, requestHandler = stsOptions?.parentClientConfig?.requestHandler, credentialProviderLogger, userAgentAppId = stsOptions?.parentClientConfig?.userAgentAppId } = stsOptions;
|
|
1158
|
+
const resolvedRegion = await resolveRegion(region, stsOptions?.parentClientConfig?.region, credentialProviderLogger, {
|
|
1159
|
+
logger,
|
|
1160
|
+
profile
|
|
1161
|
+
});
|
|
1087
1162
|
const isCompatibleRequestHandler = !isH2(requestHandler);
|
|
1088
1163
|
stsClient = new STSClient2({
|
|
1089
|
-
|
|
1164
|
+
...stsOptions,
|
|
1165
|
+
userAgentAppId,
|
|
1166
|
+
profile,
|
|
1090
1167
|
region: resolvedRegion,
|
|
1091
1168
|
requestHandler: isCompatibleRequestHandler ? requestHandler : void 0,
|
|
1092
1169
|
logger
|
|
1093
1170
|
});
|
|
1094
1171
|
}
|
|
1095
|
-
const { Credentials, AssumedRoleUser } = await stsClient.send(new AssumeRoleWithWebIdentityCommand(params));
|
|
1096
|
-
if (!
|
|
1172
|
+
const { Credentials: Credentials2, AssumedRoleUser: AssumedRoleUser2 } = await stsClient.send(new AssumeRoleWithWebIdentityCommand(params));
|
|
1173
|
+
if (!Credentials2 || !Credentials2.AccessKeyId || !Credentials2.SecretAccessKey) {
|
|
1097
1174
|
throw new Error(`Invalid response from STS.assumeRoleWithWebIdentity call with role ${params.RoleArn}`);
|
|
1098
1175
|
}
|
|
1099
|
-
const accountId = getAccountIdFromAssumedRoleUser(
|
|
1176
|
+
const accountId = getAccountIdFromAssumedRoleUser(AssumedRoleUser2);
|
|
1100
1177
|
const credentials = {
|
|
1101
|
-
accessKeyId:
|
|
1102
|
-
secretAccessKey:
|
|
1103
|
-
sessionToken:
|
|
1104
|
-
expiration:
|
|
1105
|
-
...
|
|
1178
|
+
accessKeyId: Credentials2.AccessKeyId,
|
|
1179
|
+
secretAccessKey: Credentials2.SecretAccessKey,
|
|
1180
|
+
sessionToken: Credentials2.SessionToken,
|
|
1181
|
+
expiration: Credentials2.Expiration,
|
|
1182
|
+
...Credentials2.CredentialScope && { credentialScope: Credentials2.CredentialScope },
|
|
1106
1183
|
...accountId && { accountId }
|
|
1107
1184
|
};
|
|
1108
1185
|
if (accountId) {
|
|
@@ -1116,7 +1193,7 @@ var isH2 = (requestHandler) => {
|
|
|
1116
1193
|
return requestHandler?.metadata?.handlerProtocol === "h2";
|
|
1117
1194
|
};
|
|
1118
1195
|
|
|
1119
|
-
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.
|
|
1196
|
+
// ../../.yarn/cache/@aws-sdk-nested-clients-npm-3.940.0-415b36f0bc-6695cd044d.zip/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/defaultRoleAssumers.js
|
|
1120
1197
|
var getCustomizableStsClientCtor = (baseCtor, customizations) => {
|
|
1121
1198
|
if (!customizations)
|
|
1122
1199
|
return baseCtor;
|
|
@@ -1140,11 +1217,7 @@ var decorateDefaultCredentialProvider = (provider) => (input) => provider({
|
|
|
1140
1217
|
export {
|
|
1141
1218
|
Command as $Command,
|
|
1142
1219
|
AssumeRoleCommand,
|
|
1143
|
-
AssumeRoleResponseFilterSensitiveLog,
|
|
1144
1220
|
AssumeRoleWithWebIdentityCommand,
|
|
1145
|
-
AssumeRoleWithWebIdentityRequestFilterSensitiveLog,
|
|
1146
|
-
AssumeRoleWithWebIdentityResponseFilterSensitiveLog,
|
|
1147
|
-
CredentialsFilterSensitiveLog,
|
|
1148
1221
|
ExpiredTokenException,
|
|
1149
1222
|
IDPCommunicationErrorException,
|
|
1150
1223
|
IDPRejectedClaimException,
|