@aws-sdk/client-sts 3.502.0 → 3.507.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 +31 -179
- package/dist-es/protocols/Aws_query.js +30 -178
- package/package.json +2 -2
package/dist-cjs/index.js
CHANGED
|
@@ -340,7 +340,7 @@ var se_GetSessionTokenCommand = /* @__PURE__ */ __name(async (input, context) =>
|
|
|
340
340
|
}, "se_GetSessionTokenCommand");
|
|
341
341
|
var de_AssumeRoleCommand = /* @__PURE__ */ __name(async (output, context) => {
|
|
342
342
|
if (output.statusCode >= 300) {
|
|
343
|
-
return
|
|
343
|
+
return de_CommandError(output, context);
|
|
344
344
|
}
|
|
345
345
|
const data = await parseBody(output.body, context);
|
|
346
346
|
let contents = {};
|
|
@@ -351,37 +351,9 @@ var de_AssumeRoleCommand = /* @__PURE__ */ __name(async (output, context) => {
|
|
|
351
351
|
};
|
|
352
352
|
return response;
|
|
353
353
|
}, "de_AssumeRoleCommand");
|
|
354
|
-
var de_AssumeRoleCommandError = /* @__PURE__ */ __name(async (output, context) => {
|
|
355
|
-
const parsedOutput = {
|
|
356
|
-
...output,
|
|
357
|
-
body: await parseErrorBody(output.body, context)
|
|
358
|
-
};
|
|
359
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
|
360
|
-
switch (errorCode) {
|
|
361
|
-
case "ExpiredTokenException":
|
|
362
|
-
case "com.amazonaws.sts#ExpiredTokenException":
|
|
363
|
-
throw await de_ExpiredTokenExceptionRes(parsedOutput, context);
|
|
364
|
-
case "MalformedPolicyDocument":
|
|
365
|
-
case "com.amazonaws.sts#MalformedPolicyDocumentException":
|
|
366
|
-
throw await de_MalformedPolicyDocumentExceptionRes(parsedOutput, context);
|
|
367
|
-
case "PackedPolicyTooLarge":
|
|
368
|
-
case "com.amazonaws.sts#PackedPolicyTooLargeException":
|
|
369
|
-
throw await de_PackedPolicyTooLargeExceptionRes(parsedOutput, context);
|
|
370
|
-
case "RegionDisabledException":
|
|
371
|
-
case "com.amazonaws.sts#RegionDisabledException":
|
|
372
|
-
throw await de_RegionDisabledExceptionRes(parsedOutput, context);
|
|
373
|
-
default:
|
|
374
|
-
const parsedBody = parsedOutput.body;
|
|
375
|
-
return throwDefaultError({
|
|
376
|
-
output,
|
|
377
|
-
parsedBody: parsedBody.Error,
|
|
378
|
-
errorCode
|
|
379
|
-
});
|
|
380
|
-
}
|
|
381
|
-
}, "de_AssumeRoleCommandError");
|
|
382
354
|
var de_AssumeRoleWithSAMLCommand = /* @__PURE__ */ __name(async (output, context) => {
|
|
383
355
|
if (output.statusCode >= 300) {
|
|
384
|
-
return
|
|
356
|
+
return de_CommandError(output, context);
|
|
385
357
|
}
|
|
386
358
|
const data = await parseBody(output.body, context);
|
|
387
359
|
let contents = {};
|
|
@@ -392,43 +364,9 @@ var de_AssumeRoleWithSAMLCommand = /* @__PURE__ */ __name(async (output, context
|
|
|
392
364
|
};
|
|
393
365
|
return response;
|
|
394
366
|
}, "de_AssumeRoleWithSAMLCommand");
|
|
395
|
-
var de_AssumeRoleWithSAMLCommandError = /* @__PURE__ */ __name(async (output, context) => {
|
|
396
|
-
const parsedOutput = {
|
|
397
|
-
...output,
|
|
398
|
-
body: await parseErrorBody(output.body, context)
|
|
399
|
-
};
|
|
400
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
|
401
|
-
switch (errorCode) {
|
|
402
|
-
case "ExpiredTokenException":
|
|
403
|
-
case "com.amazonaws.sts#ExpiredTokenException":
|
|
404
|
-
throw await de_ExpiredTokenExceptionRes(parsedOutput, context);
|
|
405
|
-
case "IDPRejectedClaim":
|
|
406
|
-
case "com.amazonaws.sts#IDPRejectedClaimException":
|
|
407
|
-
throw await de_IDPRejectedClaimExceptionRes(parsedOutput, context);
|
|
408
|
-
case "InvalidIdentityToken":
|
|
409
|
-
case "com.amazonaws.sts#InvalidIdentityTokenException":
|
|
410
|
-
throw await de_InvalidIdentityTokenExceptionRes(parsedOutput, context);
|
|
411
|
-
case "MalformedPolicyDocument":
|
|
412
|
-
case "com.amazonaws.sts#MalformedPolicyDocumentException":
|
|
413
|
-
throw await de_MalformedPolicyDocumentExceptionRes(parsedOutput, context);
|
|
414
|
-
case "PackedPolicyTooLarge":
|
|
415
|
-
case "com.amazonaws.sts#PackedPolicyTooLargeException":
|
|
416
|
-
throw await de_PackedPolicyTooLargeExceptionRes(parsedOutput, context);
|
|
417
|
-
case "RegionDisabledException":
|
|
418
|
-
case "com.amazonaws.sts#RegionDisabledException":
|
|
419
|
-
throw await de_RegionDisabledExceptionRes(parsedOutput, context);
|
|
420
|
-
default:
|
|
421
|
-
const parsedBody = parsedOutput.body;
|
|
422
|
-
return throwDefaultError({
|
|
423
|
-
output,
|
|
424
|
-
parsedBody: parsedBody.Error,
|
|
425
|
-
errorCode
|
|
426
|
-
});
|
|
427
|
-
}
|
|
428
|
-
}, "de_AssumeRoleWithSAMLCommandError");
|
|
429
367
|
var de_AssumeRoleWithWebIdentityCommand = /* @__PURE__ */ __name(async (output, context) => {
|
|
430
368
|
if (output.statusCode >= 300) {
|
|
431
|
-
return
|
|
369
|
+
return de_CommandError(output, context);
|
|
432
370
|
}
|
|
433
371
|
const data = await parseBody(output.body, context);
|
|
434
372
|
let contents = {};
|
|
@@ -439,46 +377,9 @@ var de_AssumeRoleWithWebIdentityCommand = /* @__PURE__ */ __name(async (output,
|
|
|
439
377
|
};
|
|
440
378
|
return response;
|
|
441
379
|
}, "de_AssumeRoleWithWebIdentityCommand");
|
|
442
|
-
var de_AssumeRoleWithWebIdentityCommandError = /* @__PURE__ */ __name(async (output, context) => {
|
|
443
|
-
const parsedOutput = {
|
|
444
|
-
...output,
|
|
445
|
-
body: await parseErrorBody(output.body, context)
|
|
446
|
-
};
|
|
447
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
|
448
|
-
switch (errorCode) {
|
|
449
|
-
case "ExpiredTokenException":
|
|
450
|
-
case "com.amazonaws.sts#ExpiredTokenException":
|
|
451
|
-
throw await de_ExpiredTokenExceptionRes(parsedOutput, context);
|
|
452
|
-
case "IDPCommunicationError":
|
|
453
|
-
case "com.amazonaws.sts#IDPCommunicationErrorException":
|
|
454
|
-
throw await de_IDPCommunicationErrorExceptionRes(parsedOutput, context);
|
|
455
|
-
case "IDPRejectedClaim":
|
|
456
|
-
case "com.amazonaws.sts#IDPRejectedClaimException":
|
|
457
|
-
throw await de_IDPRejectedClaimExceptionRes(parsedOutput, context);
|
|
458
|
-
case "InvalidIdentityToken":
|
|
459
|
-
case "com.amazonaws.sts#InvalidIdentityTokenException":
|
|
460
|
-
throw await de_InvalidIdentityTokenExceptionRes(parsedOutput, context);
|
|
461
|
-
case "MalformedPolicyDocument":
|
|
462
|
-
case "com.amazonaws.sts#MalformedPolicyDocumentException":
|
|
463
|
-
throw await de_MalformedPolicyDocumentExceptionRes(parsedOutput, context);
|
|
464
|
-
case "PackedPolicyTooLarge":
|
|
465
|
-
case "com.amazonaws.sts#PackedPolicyTooLargeException":
|
|
466
|
-
throw await de_PackedPolicyTooLargeExceptionRes(parsedOutput, context);
|
|
467
|
-
case "RegionDisabledException":
|
|
468
|
-
case "com.amazonaws.sts#RegionDisabledException":
|
|
469
|
-
throw await de_RegionDisabledExceptionRes(parsedOutput, context);
|
|
470
|
-
default:
|
|
471
|
-
const parsedBody = parsedOutput.body;
|
|
472
|
-
return throwDefaultError({
|
|
473
|
-
output,
|
|
474
|
-
parsedBody: parsedBody.Error,
|
|
475
|
-
errorCode
|
|
476
|
-
});
|
|
477
|
-
}
|
|
478
|
-
}, "de_AssumeRoleWithWebIdentityCommandError");
|
|
479
380
|
var de_DecodeAuthorizationMessageCommand = /* @__PURE__ */ __name(async (output, context) => {
|
|
480
381
|
if (output.statusCode >= 300) {
|
|
481
|
-
return
|
|
382
|
+
return de_CommandError(output, context);
|
|
482
383
|
}
|
|
483
384
|
const data = await parseBody(output.body, context);
|
|
484
385
|
let contents = {};
|
|
@@ -489,28 +390,9 @@ var de_DecodeAuthorizationMessageCommand = /* @__PURE__ */ __name(async (output,
|
|
|
489
390
|
};
|
|
490
391
|
return response;
|
|
491
392
|
}, "de_DecodeAuthorizationMessageCommand");
|
|
492
|
-
var de_DecodeAuthorizationMessageCommandError = /* @__PURE__ */ __name(async (output, context) => {
|
|
493
|
-
const parsedOutput = {
|
|
494
|
-
...output,
|
|
495
|
-
body: await parseErrorBody(output.body, context)
|
|
496
|
-
};
|
|
497
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
|
498
|
-
switch (errorCode) {
|
|
499
|
-
case "InvalidAuthorizationMessageException":
|
|
500
|
-
case "com.amazonaws.sts#InvalidAuthorizationMessageException":
|
|
501
|
-
throw await de_InvalidAuthorizationMessageExceptionRes(parsedOutput, context);
|
|
502
|
-
default:
|
|
503
|
-
const parsedBody = parsedOutput.body;
|
|
504
|
-
return throwDefaultError({
|
|
505
|
-
output,
|
|
506
|
-
parsedBody: parsedBody.Error,
|
|
507
|
-
errorCode
|
|
508
|
-
});
|
|
509
|
-
}
|
|
510
|
-
}, "de_DecodeAuthorizationMessageCommandError");
|
|
511
393
|
var de_GetAccessKeyInfoCommand = /* @__PURE__ */ __name(async (output, context) => {
|
|
512
394
|
if (output.statusCode >= 300) {
|
|
513
|
-
return
|
|
395
|
+
return de_CommandError(output, context);
|
|
514
396
|
}
|
|
515
397
|
const data = await parseBody(output.body, context);
|
|
516
398
|
let contents = {};
|
|
@@ -521,22 +403,9 @@ var de_GetAccessKeyInfoCommand = /* @__PURE__ */ __name(async (output, context)
|
|
|
521
403
|
};
|
|
522
404
|
return response;
|
|
523
405
|
}, "de_GetAccessKeyInfoCommand");
|
|
524
|
-
var de_GetAccessKeyInfoCommandError = /* @__PURE__ */ __name(async (output, context) => {
|
|
525
|
-
const parsedOutput = {
|
|
526
|
-
...output,
|
|
527
|
-
body: await parseErrorBody(output.body, context)
|
|
528
|
-
};
|
|
529
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
|
530
|
-
const parsedBody = parsedOutput.body;
|
|
531
|
-
return throwDefaultError({
|
|
532
|
-
output,
|
|
533
|
-
parsedBody: parsedBody.Error,
|
|
534
|
-
errorCode
|
|
535
|
-
});
|
|
536
|
-
}, "de_GetAccessKeyInfoCommandError");
|
|
537
406
|
var de_GetCallerIdentityCommand = /* @__PURE__ */ __name(async (output, context) => {
|
|
538
407
|
if (output.statusCode >= 300) {
|
|
539
|
-
return
|
|
408
|
+
return de_CommandError(output, context);
|
|
540
409
|
}
|
|
541
410
|
const data = await parseBody(output.body, context);
|
|
542
411
|
let contents = {};
|
|
@@ -547,22 +416,9 @@ var de_GetCallerIdentityCommand = /* @__PURE__ */ __name(async (output, context)
|
|
|
547
416
|
};
|
|
548
417
|
return response;
|
|
549
418
|
}, "de_GetCallerIdentityCommand");
|
|
550
|
-
var de_GetCallerIdentityCommandError = /* @__PURE__ */ __name(async (output, context) => {
|
|
551
|
-
const parsedOutput = {
|
|
552
|
-
...output,
|
|
553
|
-
body: await parseErrorBody(output.body, context)
|
|
554
|
-
};
|
|
555
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
|
556
|
-
const parsedBody = parsedOutput.body;
|
|
557
|
-
return throwDefaultError({
|
|
558
|
-
output,
|
|
559
|
-
parsedBody: parsedBody.Error,
|
|
560
|
-
errorCode
|
|
561
|
-
});
|
|
562
|
-
}, "de_GetCallerIdentityCommandError");
|
|
563
419
|
var de_GetFederationTokenCommand = /* @__PURE__ */ __name(async (output, context) => {
|
|
564
420
|
if (output.statusCode >= 300) {
|
|
565
|
-
return
|
|
421
|
+
return de_CommandError(output, context);
|
|
566
422
|
}
|
|
567
423
|
const data = await parseBody(output.body, context);
|
|
568
424
|
let contents = {};
|
|
@@ -573,34 +429,9 @@ var de_GetFederationTokenCommand = /* @__PURE__ */ __name(async (output, context
|
|
|
573
429
|
};
|
|
574
430
|
return response;
|
|
575
431
|
}, "de_GetFederationTokenCommand");
|
|
576
|
-
var de_GetFederationTokenCommandError = /* @__PURE__ */ __name(async (output, context) => {
|
|
577
|
-
const parsedOutput = {
|
|
578
|
-
...output,
|
|
579
|
-
body: await parseErrorBody(output.body, context)
|
|
580
|
-
};
|
|
581
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
|
582
|
-
switch (errorCode) {
|
|
583
|
-
case "MalformedPolicyDocument":
|
|
584
|
-
case "com.amazonaws.sts#MalformedPolicyDocumentException":
|
|
585
|
-
throw await de_MalformedPolicyDocumentExceptionRes(parsedOutput, context);
|
|
586
|
-
case "PackedPolicyTooLarge":
|
|
587
|
-
case "com.amazonaws.sts#PackedPolicyTooLargeException":
|
|
588
|
-
throw await de_PackedPolicyTooLargeExceptionRes(parsedOutput, context);
|
|
589
|
-
case "RegionDisabledException":
|
|
590
|
-
case "com.amazonaws.sts#RegionDisabledException":
|
|
591
|
-
throw await de_RegionDisabledExceptionRes(parsedOutput, context);
|
|
592
|
-
default:
|
|
593
|
-
const parsedBody = parsedOutput.body;
|
|
594
|
-
return throwDefaultError({
|
|
595
|
-
output,
|
|
596
|
-
parsedBody: parsedBody.Error,
|
|
597
|
-
errorCode
|
|
598
|
-
});
|
|
599
|
-
}
|
|
600
|
-
}, "de_GetFederationTokenCommandError");
|
|
601
432
|
var de_GetSessionTokenCommand = /* @__PURE__ */ __name(async (output, context) => {
|
|
602
433
|
if (output.statusCode >= 300) {
|
|
603
|
-
return
|
|
434
|
+
return de_CommandError(output, context);
|
|
604
435
|
}
|
|
605
436
|
const data = await parseBody(output.body, context);
|
|
606
437
|
let contents = {};
|
|
@@ -611,16 +442,37 @@ var de_GetSessionTokenCommand = /* @__PURE__ */ __name(async (output, context) =
|
|
|
611
442
|
};
|
|
612
443
|
return response;
|
|
613
444
|
}, "de_GetSessionTokenCommand");
|
|
614
|
-
var
|
|
445
|
+
var de_CommandError = /* @__PURE__ */ __name(async (output, context) => {
|
|
615
446
|
const parsedOutput = {
|
|
616
447
|
...output,
|
|
617
448
|
body: await parseErrorBody(output.body, context)
|
|
618
449
|
};
|
|
619
450
|
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
|
620
451
|
switch (errorCode) {
|
|
452
|
+
case "ExpiredTokenException":
|
|
453
|
+
case "com.amazonaws.sts#ExpiredTokenException":
|
|
454
|
+
throw await de_ExpiredTokenExceptionRes(parsedOutput, context);
|
|
455
|
+
case "MalformedPolicyDocument":
|
|
456
|
+
case "com.amazonaws.sts#MalformedPolicyDocumentException":
|
|
457
|
+
throw await de_MalformedPolicyDocumentExceptionRes(parsedOutput, context);
|
|
458
|
+
case "PackedPolicyTooLarge":
|
|
459
|
+
case "com.amazonaws.sts#PackedPolicyTooLargeException":
|
|
460
|
+
throw await de_PackedPolicyTooLargeExceptionRes(parsedOutput, context);
|
|
621
461
|
case "RegionDisabledException":
|
|
622
462
|
case "com.amazonaws.sts#RegionDisabledException":
|
|
623
463
|
throw await de_RegionDisabledExceptionRes(parsedOutput, context);
|
|
464
|
+
case "IDPRejectedClaim":
|
|
465
|
+
case "com.amazonaws.sts#IDPRejectedClaimException":
|
|
466
|
+
throw await de_IDPRejectedClaimExceptionRes(parsedOutput, context);
|
|
467
|
+
case "InvalidIdentityToken":
|
|
468
|
+
case "com.amazonaws.sts#InvalidIdentityTokenException":
|
|
469
|
+
throw await de_InvalidIdentityTokenExceptionRes(parsedOutput, context);
|
|
470
|
+
case "IDPCommunicationError":
|
|
471
|
+
case "com.amazonaws.sts#IDPCommunicationErrorException":
|
|
472
|
+
throw await de_IDPCommunicationErrorExceptionRes(parsedOutput, context);
|
|
473
|
+
case "InvalidAuthorizationMessageException":
|
|
474
|
+
case "com.amazonaws.sts#InvalidAuthorizationMessageException":
|
|
475
|
+
throw await de_InvalidAuthorizationMessageExceptionRes(parsedOutput, context);
|
|
624
476
|
default:
|
|
625
477
|
const parsedBody = parsedOutput.body;
|
|
626
478
|
return throwDefaultError({
|
|
@@ -629,7 +481,7 @@ var de_GetSessionTokenCommandError = /* @__PURE__ */ __name(async (output, conte
|
|
|
629
481
|
errorCode
|
|
630
482
|
});
|
|
631
483
|
}
|
|
632
|
-
}, "
|
|
484
|
+
}, "de_CommandError");
|
|
633
485
|
var de_ExpiredTokenExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {
|
|
634
486
|
const body = parsedOutput.body;
|
|
635
487
|
const deserialized = de_ExpiredTokenException(body.Error, context);
|
|
@@ -85,7 +85,7 @@ export const se_GetSessionTokenCommand = async (input, context) => {
|
|
|
85
85
|
};
|
|
86
86
|
export const de_AssumeRoleCommand = async (output, context) => {
|
|
87
87
|
if (output.statusCode >= 300) {
|
|
88
|
-
return
|
|
88
|
+
return de_CommandError(output, context);
|
|
89
89
|
}
|
|
90
90
|
const data = await parseBody(output.body, context);
|
|
91
91
|
let contents = {};
|
|
@@ -96,37 +96,9 @@ export const de_AssumeRoleCommand = async (output, context) => {
|
|
|
96
96
|
};
|
|
97
97
|
return response;
|
|
98
98
|
};
|
|
99
|
-
const de_AssumeRoleCommandError = async (output, context) => {
|
|
100
|
-
const parsedOutput = {
|
|
101
|
-
...output,
|
|
102
|
-
body: await parseErrorBody(output.body, context),
|
|
103
|
-
};
|
|
104
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
|
105
|
-
switch (errorCode) {
|
|
106
|
-
case "ExpiredTokenException":
|
|
107
|
-
case "com.amazonaws.sts#ExpiredTokenException":
|
|
108
|
-
throw await de_ExpiredTokenExceptionRes(parsedOutput, context);
|
|
109
|
-
case "MalformedPolicyDocument":
|
|
110
|
-
case "com.amazonaws.sts#MalformedPolicyDocumentException":
|
|
111
|
-
throw await de_MalformedPolicyDocumentExceptionRes(parsedOutput, context);
|
|
112
|
-
case "PackedPolicyTooLarge":
|
|
113
|
-
case "com.amazonaws.sts#PackedPolicyTooLargeException":
|
|
114
|
-
throw await de_PackedPolicyTooLargeExceptionRes(parsedOutput, context);
|
|
115
|
-
case "RegionDisabledException":
|
|
116
|
-
case "com.amazonaws.sts#RegionDisabledException":
|
|
117
|
-
throw await de_RegionDisabledExceptionRes(parsedOutput, context);
|
|
118
|
-
default:
|
|
119
|
-
const parsedBody = parsedOutput.body;
|
|
120
|
-
return throwDefaultError({
|
|
121
|
-
output,
|
|
122
|
-
parsedBody: parsedBody.Error,
|
|
123
|
-
errorCode,
|
|
124
|
-
});
|
|
125
|
-
}
|
|
126
|
-
};
|
|
127
99
|
export const de_AssumeRoleWithSAMLCommand = async (output, context) => {
|
|
128
100
|
if (output.statusCode >= 300) {
|
|
129
|
-
return
|
|
101
|
+
return de_CommandError(output, context);
|
|
130
102
|
}
|
|
131
103
|
const data = await parseBody(output.body, context);
|
|
132
104
|
let contents = {};
|
|
@@ -137,43 +109,9 @@ export const de_AssumeRoleWithSAMLCommand = async (output, context) => {
|
|
|
137
109
|
};
|
|
138
110
|
return response;
|
|
139
111
|
};
|
|
140
|
-
const de_AssumeRoleWithSAMLCommandError = async (output, context) => {
|
|
141
|
-
const parsedOutput = {
|
|
142
|
-
...output,
|
|
143
|
-
body: await parseErrorBody(output.body, context),
|
|
144
|
-
};
|
|
145
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
|
146
|
-
switch (errorCode) {
|
|
147
|
-
case "ExpiredTokenException":
|
|
148
|
-
case "com.amazonaws.sts#ExpiredTokenException":
|
|
149
|
-
throw await de_ExpiredTokenExceptionRes(parsedOutput, context);
|
|
150
|
-
case "IDPRejectedClaim":
|
|
151
|
-
case "com.amazonaws.sts#IDPRejectedClaimException":
|
|
152
|
-
throw await de_IDPRejectedClaimExceptionRes(parsedOutput, context);
|
|
153
|
-
case "InvalidIdentityToken":
|
|
154
|
-
case "com.amazonaws.sts#InvalidIdentityTokenException":
|
|
155
|
-
throw await de_InvalidIdentityTokenExceptionRes(parsedOutput, context);
|
|
156
|
-
case "MalformedPolicyDocument":
|
|
157
|
-
case "com.amazonaws.sts#MalformedPolicyDocumentException":
|
|
158
|
-
throw await de_MalformedPolicyDocumentExceptionRes(parsedOutput, context);
|
|
159
|
-
case "PackedPolicyTooLarge":
|
|
160
|
-
case "com.amazonaws.sts#PackedPolicyTooLargeException":
|
|
161
|
-
throw await de_PackedPolicyTooLargeExceptionRes(parsedOutput, context);
|
|
162
|
-
case "RegionDisabledException":
|
|
163
|
-
case "com.amazonaws.sts#RegionDisabledException":
|
|
164
|
-
throw await de_RegionDisabledExceptionRes(parsedOutput, context);
|
|
165
|
-
default:
|
|
166
|
-
const parsedBody = parsedOutput.body;
|
|
167
|
-
return throwDefaultError({
|
|
168
|
-
output,
|
|
169
|
-
parsedBody: parsedBody.Error,
|
|
170
|
-
errorCode,
|
|
171
|
-
});
|
|
172
|
-
}
|
|
173
|
-
};
|
|
174
112
|
export const de_AssumeRoleWithWebIdentityCommand = async (output, context) => {
|
|
175
113
|
if (output.statusCode >= 300) {
|
|
176
|
-
return
|
|
114
|
+
return de_CommandError(output, context);
|
|
177
115
|
}
|
|
178
116
|
const data = await parseBody(output.body, context);
|
|
179
117
|
let contents = {};
|
|
@@ -184,46 +122,9 @@ export const de_AssumeRoleWithWebIdentityCommand = async (output, context) => {
|
|
|
184
122
|
};
|
|
185
123
|
return response;
|
|
186
124
|
};
|
|
187
|
-
const de_AssumeRoleWithWebIdentityCommandError = async (output, context) => {
|
|
188
|
-
const parsedOutput = {
|
|
189
|
-
...output,
|
|
190
|
-
body: await parseErrorBody(output.body, context),
|
|
191
|
-
};
|
|
192
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
|
193
|
-
switch (errorCode) {
|
|
194
|
-
case "ExpiredTokenException":
|
|
195
|
-
case "com.amazonaws.sts#ExpiredTokenException":
|
|
196
|
-
throw await de_ExpiredTokenExceptionRes(parsedOutput, context);
|
|
197
|
-
case "IDPCommunicationError":
|
|
198
|
-
case "com.amazonaws.sts#IDPCommunicationErrorException":
|
|
199
|
-
throw await de_IDPCommunicationErrorExceptionRes(parsedOutput, context);
|
|
200
|
-
case "IDPRejectedClaim":
|
|
201
|
-
case "com.amazonaws.sts#IDPRejectedClaimException":
|
|
202
|
-
throw await de_IDPRejectedClaimExceptionRes(parsedOutput, context);
|
|
203
|
-
case "InvalidIdentityToken":
|
|
204
|
-
case "com.amazonaws.sts#InvalidIdentityTokenException":
|
|
205
|
-
throw await de_InvalidIdentityTokenExceptionRes(parsedOutput, context);
|
|
206
|
-
case "MalformedPolicyDocument":
|
|
207
|
-
case "com.amazonaws.sts#MalformedPolicyDocumentException":
|
|
208
|
-
throw await de_MalformedPolicyDocumentExceptionRes(parsedOutput, context);
|
|
209
|
-
case "PackedPolicyTooLarge":
|
|
210
|
-
case "com.amazonaws.sts#PackedPolicyTooLargeException":
|
|
211
|
-
throw await de_PackedPolicyTooLargeExceptionRes(parsedOutput, context);
|
|
212
|
-
case "RegionDisabledException":
|
|
213
|
-
case "com.amazonaws.sts#RegionDisabledException":
|
|
214
|
-
throw await de_RegionDisabledExceptionRes(parsedOutput, context);
|
|
215
|
-
default:
|
|
216
|
-
const parsedBody = parsedOutput.body;
|
|
217
|
-
return throwDefaultError({
|
|
218
|
-
output,
|
|
219
|
-
parsedBody: parsedBody.Error,
|
|
220
|
-
errorCode,
|
|
221
|
-
});
|
|
222
|
-
}
|
|
223
|
-
};
|
|
224
125
|
export const de_DecodeAuthorizationMessageCommand = async (output, context) => {
|
|
225
126
|
if (output.statusCode >= 300) {
|
|
226
|
-
return
|
|
127
|
+
return de_CommandError(output, context);
|
|
227
128
|
}
|
|
228
129
|
const data = await parseBody(output.body, context);
|
|
229
130
|
let contents = {};
|
|
@@ -234,28 +135,9 @@ export const de_DecodeAuthorizationMessageCommand = async (output, context) => {
|
|
|
234
135
|
};
|
|
235
136
|
return response;
|
|
236
137
|
};
|
|
237
|
-
const de_DecodeAuthorizationMessageCommandError = async (output, context) => {
|
|
238
|
-
const parsedOutput = {
|
|
239
|
-
...output,
|
|
240
|
-
body: await parseErrorBody(output.body, context),
|
|
241
|
-
};
|
|
242
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
|
243
|
-
switch (errorCode) {
|
|
244
|
-
case "InvalidAuthorizationMessageException":
|
|
245
|
-
case "com.amazonaws.sts#InvalidAuthorizationMessageException":
|
|
246
|
-
throw await de_InvalidAuthorizationMessageExceptionRes(parsedOutput, context);
|
|
247
|
-
default:
|
|
248
|
-
const parsedBody = parsedOutput.body;
|
|
249
|
-
return throwDefaultError({
|
|
250
|
-
output,
|
|
251
|
-
parsedBody: parsedBody.Error,
|
|
252
|
-
errorCode,
|
|
253
|
-
});
|
|
254
|
-
}
|
|
255
|
-
};
|
|
256
138
|
export const de_GetAccessKeyInfoCommand = async (output, context) => {
|
|
257
139
|
if (output.statusCode >= 300) {
|
|
258
|
-
return
|
|
140
|
+
return de_CommandError(output, context);
|
|
259
141
|
}
|
|
260
142
|
const data = await parseBody(output.body, context);
|
|
261
143
|
let contents = {};
|
|
@@ -266,22 +148,9 @@ export const de_GetAccessKeyInfoCommand = async (output, context) => {
|
|
|
266
148
|
};
|
|
267
149
|
return response;
|
|
268
150
|
};
|
|
269
|
-
const de_GetAccessKeyInfoCommandError = async (output, context) => {
|
|
270
|
-
const parsedOutput = {
|
|
271
|
-
...output,
|
|
272
|
-
body: await parseErrorBody(output.body, context),
|
|
273
|
-
};
|
|
274
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
|
275
|
-
const parsedBody = parsedOutput.body;
|
|
276
|
-
return throwDefaultError({
|
|
277
|
-
output,
|
|
278
|
-
parsedBody: parsedBody.Error,
|
|
279
|
-
errorCode,
|
|
280
|
-
});
|
|
281
|
-
};
|
|
282
151
|
export const de_GetCallerIdentityCommand = async (output, context) => {
|
|
283
152
|
if (output.statusCode >= 300) {
|
|
284
|
-
return
|
|
153
|
+
return de_CommandError(output, context);
|
|
285
154
|
}
|
|
286
155
|
const data = await parseBody(output.body, context);
|
|
287
156
|
let contents = {};
|
|
@@ -292,22 +161,9 @@ export const de_GetCallerIdentityCommand = async (output, context) => {
|
|
|
292
161
|
};
|
|
293
162
|
return response;
|
|
294
163
|
};
|
|
295
|
-
const de_GetCallerIdentityCommandError = async (output, context) => {
|
|
296
|
-
const parsedOutput = {
|
|
297
|
-
...output,
|
|
298
|
-
body: await parseErrorBody(output.body, context),
|
|
299
|
-
};
|
|
300
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
|
301
|
-
const parsedBody = parsedOutput.body;
|
|
302
|
-
return throwDefaultError({
|
|
303
|
-
output,
|
|
304
|
-
parsedBody: parsedBody.Error,
|
|
305
|
-
errorCode,
|
|
306
|
-
});
|
|
307
|
-
};
|
|
308
164
|
export const de_GetFederationTokenCommand = async (output, context) => {
|
|
309
165
|
if (output.statusCode >= 300) {
|
|
310
|
-
return
|
|
166
|
+
return de_CommandError(output, context);
|
|
311
167
|
}
|
|
312
168
|
const data = await parseBody(output.body, context);
|
|
313
169
|
let contents = {};
|
|
@@ -318,34 +174,9 @@ export const de_GetFederationTokenCommand = async (output, context) => {
|
|
|
318
174
|
};
|
|
319
175
|
return response;
|
|
320
176
|
};
|
|
321
|
-
const de_GetFederationTokenCommandError = async (output, context) => {
|
|
322
|
-
const parsedOutput = {
|
|
323
|
-
...output,
|
|
324
|
-
body: await parseErrorBody(output.body, context),
|
|
325
|
-
};
|
|
326
|
-
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
|
327
|
-
switch (errorCode) {
|
|
328
|
-
case "MalformedPolicyDocument":
|
|
329
|
-
case "com.amazonaws.sts#MalformedPolicyDocumentException":
|
|
330
|
-
throw await de_MalformedPolicyDocumentExceptionRes(parsedOutput, context);
|
|
331
|
-
case "PackedPolicyTooLarge":
|
|
332
|
-
case "com.amazonaws.sts#PackedPolicyTooLargeException":
|
|
333
|
-
throw await de_PackedPolicyTooLargeExceptionRes(parsedOutput, context);
|
|
334
|
-
case "RegionDisabledException":
|
|
335
|
-
case "com.amazonaws.sts#RegionDisabledException":
|
|
336
|
-
throw await de_RegionDisabledExceptionRes(parsedOutput, context);
|
|
337
|
-
default:
|
|
338
|
-
const parsedBody = parsedOutput.body;
|
|
339
|
-
return throwDefaultError({
|
|
340
|
-
output,
|
|
341
|
-
parsedBody: parsedBody.Error,
|
|
342
|
-
errorCode,
|
|
343
|
-
});
|
|
344
|
-
}
|
|
345
|
-
};
|
|
346
177
|
export const de_GetSessionTokenCommand = async (output, context) => {
|
|
347
178
|
if (output.statusCode >= 300) {
|
|
348
|
-
return
|
|
179
|
+
return de_CommandError(output, context);
|
|
349
180
|
}
|
|
350
181
|
const data = await parseBody(output.body, context);
|
|
351
182
|
let contents = {};
|
|
@@ -356,16 +187,37 @@ export const de_GetSessionTokenCommand = async (output, context) => {
|
|
|
356
187
|
};
|
|
357
188
|
return response;
|
|
358
189
|
};
|
|
359
|
-
const
|
|
190
|
+
const de_CommandError = async (output, context) => {
|
|
360
191
|
const parsedOutput = {
|
|
361
192
|
...output,
|
|
362
193
|
body: await parseErrorBody(output.body, context),
|
|
363
194
|
};
|
|
364
195
|
const errorCode = loadQueryErrorCode(output, parsedOutput.body);
|
|
365
196
|
switch (errorCode) {
|
|
197
|
+
case "ExpiredTokenException":
|
|
198
|
+
case "com.amazonaws.sts#ExpiredTokenException":
|
|
199
|
+
throw await de_ExpiredTokenExceptionRes(parsedOutput, context);
|
|
200
|
+
case "MalformedPolicyDocument":
|
|
201
|
+
case "com.amazonaws.sts#MalformedPolicyDocumentException":
|
|
202
|
+
throw await de_MalformedPolicyDocumentExceptionRes(parsedOutput, context);
|
|
203
|
+
case "PackedPolicyTooLarge":
|
|
204
|
+
case "com.amazonaws.sts#PackedPolicyTooLargeException":
|
|
205
|
+
throw await de_PackedPolicyTooLargeExceptionRes(parsedOutput, context);
|
|
366
206
|
case "RegionDisabledException":
|
|
367
207
|
case "com.amazonaws.sts#RegionDisabledException":
|
|
368
208
|
throw await de_RegionDisabledExceptionRes(parsedOutput, context);
|
|
209
|
+
case "IDPRejectedClaim":
|
|
210
|
+
case "com.amazonaws.sts#IDPRejectedClaimException":
|
|
211
|
+
throw await de_IDPRejectedClaimExceptionRes(parsedOutput, context);
|
|
212
|
+
case "InvalidIdentityToken":
|
|
213
|
+
case "com.amazonaws.sts#InvalidIdentityTokenException":
|
|
214
|
+
throw await de_InvalidIdentityTokenExceptionRes(parsedOutput, context);
|
|
215
|
+
case "IDPCommunicationError":
|
|
216
|
+
case "com.amazonaws.sts#IDPCommunicationErrorException":
|
|
217
|
+
throw await de_IDPCommunicationErrorExceptionRes(parsedOutput, context);
|
|
218
|
+
case "InvalidAuthorizationMessageException":
|
|
219
|
+
case "com.amazonaws.sts#InvalidAuthorizationMessageException":
|
|
220
|
+
throw await de_InvalidAuthorizationMessageExceptionRes(parsedOutput, context);
|
|
369
221
|
default:
|
|
370
222
|
const parsedBody = parsedOutput.body;
|
|
371
223
|
return throwDefaultError({
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aws-sdk/client-sts",
|
|
3
3
|
"description": "AWS SDK for JavaScript Sts Client for Node.js, Browser and React Native",
|
|
4
|
-
"version": "3.
|
|
4
|
+
"version": "3.507.0",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
|
|
7
7
|
"build:cjs": "node ../../scripts/compilation/inline client-sts",
|
|
@@ -88,7 +88,7 @@
|
|
|
88
88
|
},
|
|
89
89
|
"license": "Apache-2.0",
|
|
90
90
|
"peerDependencies": {
|
|
91
|
-
"@aws-sdk/credential-provider-node": "
|
|
91
|
+
"@aws-sdk/credential-provider-node": "^3.507.0"
|
|
92
92
|
},
|
|
93
93
|
"browser": {
|
|
94
94
|
"./dist-es/runtimeConfig": "./dist-es/runtimeConfig.browser"
|