@aws-sdk/client-sts 3.35.0 → 3.38.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/CHANGELOG.md +47 -0
- package/dist-cjs/STS.js +0 -8
- package/dist-cjs/STSClient.js +0 -13
- package/dist-cjs/commands/AssumeRoleCommand.js +0 -108
- package/dist-cjs/commands/AssumeRoleWithSAMLCommand.js +0 -156
- package/dist-cjs/commands/AssumeRoleWithWebIdentityCommand.js +0 -160
- package/dist-cjs/commands/DecodeAuthorizationMessageCommand.js +0 -60
- package/dist-cjs/commands/GetAccessKeyInfoCommand.js +0 -42
- package/dist-cjs/commands/GetCallerIdentityCommand.js +0 -34
- package/dist-cjs/commands/GetFederationTokenCommand.js +0 -163
- package/dist-cjs/commands/GetSessionTokenCommand.js +0 -76
- package/dist-cjs/commands/index.js +11 -0
- package/dist-cjs/defaultRoleAssumers.js +0 -17
- package/dist-cjs/defaultStsRoleAssumers.js +0 -21
- package/dist-cjs/endpoints.js +1 -2
- package/dist-cjs/index.js +3 -11
- package/dist-cjs/models/index.js +0 -1
- package/dist-cjs/models/models_0.js +0 -88
- package/dist-cjs/protocols/Aws_query.js +0 -3
- package/dist-cjs/runtimeConfig.browser.js +1 -6
- package/dist-cjs/runtimeConfig.js +3 -8
- package/dist-cjs/runtimeConfig.native.js +0 -4
- package/dist-cjs/runtimeConfig.shared.js +0 -4
- package/dist-es/STS.js +0 -1
- package/dist-es/STSClient.js +0 -1
- package/dist-es/commands/AssumeRoleCommand.js +0 -1
- package/dist-es/commands/AssumeRoleWithSAMLCommand.js +0 -1
- package/dist-es/commands/AssumeRoleWithWebIdentityCommand.js +0 -1
- package/dist-es/commands/DecodeAuthorizationMessageCommand.js +0 -1
- package/dist-es/commands/GetAccessKeyInfoCommand.js +0 -1
- package/dist-es/commands/GetCallerIdentityCommand.js +0 -1
- package/dist-es/commands/GetFederationTokenCommand.js +0 -1
- package/dist-es/commands/GetSessionTokenCommand.js +0 -1
- package/dist-es/commands/index.js +8 -0
- package/dist-es/defaultRoleAssumers.js +0 -1
- package/dist-es/defaultStsRoleAssumers.js +0 -1
- package/dist-es/endpoints.js +1 -2
- package/dist-es/index.js +3 -11
- package/dist-es/models/index.js +0 -1
- package/dist-es/models/models_0.js +0 -1
- package/dist-es/protocols/Aws_query.js +0 -1
- package/dist-es/runtimeConfig.browser.js +1 -2
- package/dist-es/runtimeConfig.js +3 -4
- package/dist-es/runtimeConfig.native.js +0 -1
- package/dist-es/runtimeConfig.shared.js +0 -1
- package/dist-types/commands/index.d.ts +8 -0
- package/dist-types/index.d.ts +3 -10
- package/dist-types/ts3.4/STS.d.ts +9 -630
- package/dist-types/ts3.4/STSClient.d.ts +24 -93
- package/dist-types/ts3.4/commands/AssumeRoleCommand.d.ts +2 -103
- package/dist-types/ts3.4/commands/AssumeRoleWithSAMLCommand.d.ts +2 -151
- package/dist-types/ts3.4/commands/AssumeRoleWithWebIdentityCommand.d.ts +2 -155
- package/dist-types/ts3.4/commands/DecodeAuthorizationMessageCommand.d.ts +2 -55
- package/dist-types/ts3.4/commands/GetAccessKeyInfoCommand.d.ts +2 -37
- package/dist-types/ts3.4/commands/GetCallerIdentityCommand.d.ts +2 -29
- package/dist-types/ts3.4/commands/GetFederationTokenCommand.d.ts +2 -158
- package/dist-types/ts3.4/commands/GetSessionTokenCommand.d.ts +2 -71
- package/dist-types/ts3.4/commands/index.d.ts +8 -0
- package/dist-types/ts3.4/defaultRoleAssumers.d.ts +3 -14
- package/dist-types/ts3.4/defaultStsRoleAssumers.d.ts +6 -25
- package/dist-types/ts3.4/index.d.ts +3 -10
- package/dist-types/ts3.4/models/models_0.d.ts +123 -948
- package/dist-types/ts3.4/runtimeConfig.browser.d.ts +1 -3
- package/dist-types/ts3.4/runtimeConfig.d.ts +1 -3
- package/dist-types/ts3.4/runtimeConfig.native.d.ts +1 -3
- package/dist-types/ts3.4/runtimeConfig.shared.d.ts +1 -3
- package/package.json +33 -30
- package/dist-cjs/STS.js.map +0 -1
- package/dist-cjs/STSClient.js.map +0 -1
- package/dist-cjs/commands/AssumeRoleCommand.js.map +0 -1
- package/dist-cjs/commands/AssumeRoleWithSAMLCommand.js.map +0 -1
- package/dist-cjs/commands/AssumeRoleWithWebIdentityCommand.js.map +0 -1
- package/dist-cjs/commands/DecodeAuthorizationMessageCommand.js.map +0 -1
- package/dist-cjs/commands/GetAccessKeyInfoCommand.js.map +0 -1
- package/dist-cjs/commands/GetCallerIdentityCommand.js.map +0 -1
- package/dist-cjs/commands/GetFederationTokenCommand.js.map +0 -1
- package/dist-cjs/commands/GetSessionTokenCommand.js.map +0 -1
- package/dist-cjs/defaultRoleAssumers.js.map +0 -1
- package/dist-cjs/defaultStsRoleAssumers.js.map +0 -1
- package/dist-cjs/endpoints.js.map +0 -1
- package/dist-cjs/index.js.map +0 -1
- package/dist-cjs/models/index.js.map +0 -1
- package/dist-cjs/models/models_0.js.map +0 -1
- package/dist-cjs/protocols/Aws_query.js.map +0 -1
- package/dist-cjs/runtimeConfig.browser.js.map +0 -1
- package/dist-cjs/runtimeConfig.js.map +0 -1
- package/dist-cjs/runtimeConfig.native.js.map +0 -1
- package/dist-cjs/runtimeConfig.shared.js.map +0 -1
- package/dist-es/STS.js.map +0 -1
- package/dist-es/STSClient.js.map +0 -1
- package/dist-es/commands/AssumeRoleCommand.js.map +0 -1
- package/dist-es/commands/AssumeRoleWithSAMLCommand.js.map +0 -1
- package/dist-es/commands/AssumeRoleWithWebIdentityCommand.js.map +0 -1
- package/dist-es/commands/DecodeAuthorizationMessageCommand.js.map +0 -1
- package/dist-es/commands/GetAccessKeyInfoCommand.js.map +0 -1
- package/dist-es/commands/GetCallerIdentityCommand.js.map +0 -1
- package/dist-es/commands/GetFederationTokenCommand.js.map +0 -1
- package/dist-es/commands/GetSessionTokenCommand.js.map +0 -1
- package/dist-es/defaultRoleAssumers.js.map +0 -1
- package/dist-es/defaultStsRoleAssumers.js.map +0 -1
- package/dist-es/endpoints.js.map +0 -1
- package/dist-es/index.js.map +0 -1
- package/dist-es/models/index.js.map +0 -1
- package/dist-es/models/models_0.js.map +0 -1
- package/dist-es/protocols/Aws_query.js.map +0 -1
- package/dist-es/runtimeConfig.browser.js.map +0 -1
- package/dist-es/runtimeConfig.js.map +0 -1
- package/dist-es/runtimeConfig.native.js.map +0 -1
- package/dist-es/runtimeConfig.shared.js.map +0 -1
- package/jest.config.js +0 -4
- package/src/STS.ts +0 -897
- package/src/STSClient.ts +0 -264
- package/src/commands/AssumeRoleCommand.ts +0 -177
- package/src/commands/AssumeRoleWithSAMLCommand.ts +0 -226
- package/src/commands/AssumeRoleWithWebIdentityCommand.ts +0 -233
- package/src/commands/DecodeAuthorizationMessageCommand.ts +0 -135
- package/src/commands/GetAccessKeyInfoCommand.ts +0 -114
- package/src/commands/GetCallerIdentityCommand.ts +0 -106
- package/src/commands/GetFederationTokenCommand.ts +0 -235
- package/src/commands/GetSessionTokenCommand.ts +0 -148
- package/src/defaultRoleAssumers.ts +0 -41
- package/src/defaultStsRoleAssumers.ts +0 -126
- package/src/endpoints.ts +0 -91
- package/src/index.ts +0 -12
- package/src/models/index.ts +0 -1
- package/src/models/models_0.ts +0 -1361
- package/src/protocols/Aws_query.ts +0 -1514
- package/src/runtimeConfig.browser.ts +0 -41
- package/src/runtimeConfig.native.ts +0 -17
- package/src/runtimeConfig.shared.ts +0 -17
- package/src/runtimeConfig.ts +0 -46
- package/test/defaultRoleAssumers.spec.ts +0 -149
- package/tsconfig.es.json +0 -10
- package/tsconfig.json +0 -33
- package/tsconfig.types.json +0 -9
|
@@ -1,233 +0,0 @@
|
|
|
1
|
-
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
2
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
|
|
3
|
-
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
4
|
-
import {
|
|
5
|
-
FinalizeHandlerArguments,
|
|
6
|
-
Handler,
|
|
7
|
-
HandlerExecutionContext,
|
|
8
|
-
HttpHandlerOptions as __HttpHandlerOptions,
|
|
9
|
-
MetadataBearer as __MetadataBearer,
|
|
10
|
-
MiddlewareStack,
|
|
11
|
-
SerdeContext as __SerdeContext,
|
|
12
|
-
} from "@aws-sdk/types";
|
|
13
|
-
|
|
14
|
-
import { AssumeRoleWithWebIdentityRequest, AssumeRoleWithWebIdentityResponse } from "../models/models_0";
|
|
15
|
-
import {
|
|
16
|
-
deserializeAws_queryAssumeRoleWithWebIdentityCommand,
|
|
17
|
-
serializeAws_queryAssumeRoleWithWebIdentityCommand,
|
|
18
|
-
} from "../protocols/Aws_query";
|
|
19
|
-
import { ServiceInputTypes, ServiceOutputTypes, STSClientResolvedConfig } from "../STSClient";
|
|
20
|
-
|
|
21
|
-
export interface AssumeRoleWithWebIdentityCommandInput extends AssumeRoleWithWebIdentityRequest {}
|
|
22
|
-
export interface AssumeRoleWithWebIdentityCommandOutput extends AssumeRoleWithWebIdentityResponse, __MetadataBearer {}
|
|
23
|
-
|
|
24
|
-
/**
|
|
25
|
-
* <p>Returns a set of temporary security credentials for users who have been authenticated in
|
|
26
|
-
* a mobile or web application with a web identity provider. Example providers include Amazon Cognito,
|
|
27
|
-
* Login with Amazon, Facebook, Google, or any OpenID Connect-compatible identity
|
|
28
|
-
* provider.</p>
|
|
29
|
-
* <note>
|
|
30
|
-
* <p>For mobile applications, we recommend that you use Amazon Cognito. You can use Amazon Cognito with the
|
|
31
|
-
* <a href="http://aws.amazon.com/sdkforios/">Amazon Web Services SDK for iOS Developer Guide</a> and the <a href="http://aws.amazon.com/sdkforandroid/">Amazon Web Services SDK for Android Developer Guide</a> to uniquely
|
|
32
|
-
* identify a user. You can also supply the user with a consistent identity throughout the
|
|
33
|
-
* lifetime of an application.</p>
|
|
34
|
-
* <p>To learn more about Amazon Cognito, see <a href="https://docs.aws.amazon.com/mobile/sdkforandroid/developerguide/cognito-auth.html#d0e840">Amazon Cognito Overview</a> in
|
|
35
|
-
* <i>Amazon Web Services SDK for Android Developer Guide</i> and <a href="https://docs.aws.amazon.com/mobile/sdkforios/developerguide/cognito-auth.html#d0e664">Amazon Cognito Overview</a> in the
|
|
36
|
-
* <i>Amazon Web Services SDK for iOS Developer Guide</i>.</p>
|
|
37
|
-
* </note>
|
|
38
|
-
* <p>Calling <code>AssumeRoleWithWebIdentity</code> does not require the use of Amazon Web Services
|
|
39
|
-
* security credentials. Therefore, you can distribute an application (for example, on mobile
|
|
40
|
-
* devices) that requests temporary security credentials without including long-term Amazon Web Services
|
|
41
|
-
* credentials in the application. You also don't need to deploy server-based proxy services
|
|
42
|
-
* that use long-term Amazon Web Services credentials. Instead, the identity of the caller is validated by
|
|
43
|
-
* using a token from the web identity provider. For a comparison of
|
|
44
|
-
* <code>AssumeRoleWithWebIdentity</code> with the other API operations that produce
|
|
45
|
-
* temporary credentials, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html">Requesting Temporary Security
|
|
46
|
-
* Credentials</a> and <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison">Comparing the
|
|
47
|
-
* STS API operations</a> in the <i>IAM User Guide</i>.</p>
|
|
48
|
-
* <p>The temporary security credentials returned by this API consist of an access key ID, a
|
|
49
|
-
* secret access key, and a security token. Applications can use these temporary security
|
|
50
|
-
* credentials to sign calls to Amazon Web Services service API operations.</p>
|
|
51
|
-
* <p>
|
|
52
|
-
* <b>Session Duration</b>
|
|
53
|
-
* </p>
|
|
54
|
-
* <p>By default, the temporary security credentials created by
|
|
55
|
-
* <code>AssumeRoleWithWebIdentity</code> last for one hour. However, you can use the
|
|
56
|
-
* optional <code>DurationSeconds</code> parameter to specify the duration of your session.
|
|
57
|
-
* You can provide a value from 900 seconds (15 minutes) up to the maximum session duration
|
|
58
|
-
* setting for the role. This setting can have a value from 1 hour to 12 hours. To learn how
|
|
59
|
-
* to view the maximum value for your role, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session">View the
|
|
60
|
-
* Maximum Session Duration Setting for a Role</a> in the
|
|
61
|
-
* <i>IAM User Guide</i>. The maximum session duration limit applies when
|
|
62
|
-
* you use the <code>AssumeRole*</code> API operations or the <code>assume-role*</code> CLI
|
|
63
|
-
* commands. However the limit does not apply when you use those operations to create a
|
|
64
|
-
* console URL. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html">Using IAM Roles</a> in the
|
|
65
|
-
* <i>IAM User Guide</i>. </p>
|
|
66
|
-
* <p>
|
|
67
|
-
* <b>Permissions</b>
|
|
68
|
-
* </p>
|
|
69
|
-
* <p>The temporary security credentials created by <code>AssumeRoleWithWebIdentity</code> can
|
|
70
|
-
* be used to make API calls to any Amazon Web Services service with the following exception: you cannot
|
|
71
|
-
* call the STS <code>GetFederationToken</code> or <code>GetSessionToken</code> API
|
|
72
|
-
* operations.</p>
|
|
73
|
-
* <p>(Optional) You can pass inline or managed <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session">session policies</a> to
|
|
74
|
-
* this operation. You can pass a single JSON policy document to use as an inline session
|
|
75
|
-
* policy. You can also specify up to 10 managed policies to use as managed session policies.
|
|
76
|
-
* The plaintext that you use for both inline and managed session policies can't exceed 2,048
|
|
77
|
-
* characters. Passing policies to this operation returns new
|
|
78
|
-
* temporary credentials. The resulting session's permissions are the intersection of the
|
|
79
|
-
* role's identity-based policy and the session policies. You can use the role's temporary
|
|
80
|
-
* credentials in subsequent Amazon Web Services API calls to access resources in the account that owns
|
|
81
|
-
* the role. You cannot use session policies to grant more permissions than those allowed
|
|
82
|
-
* by the identity-based policy of the role that is being assumed. For more information, see
|
|
83
|
-
* <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session">Session
|
|
84
|
-
* Policies</a> in the <i>IAM User Guide</i>.</p>
|
|
85
|
-
* <p>
|
|
86
|
-
* <b>Tags</b>
|
|
87
|
-
* </p>
|
|
88
|
-
* <p>(Optional) You can configure your IdP to pass attributes into your web identity token as
|
|
89
|
-
* session tags. Each session tag consists of a key name and an associated value. For more
|
|
90
|
-
* information about session tags, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html">Passing Session Tags in STS</a> in the
|
|
91
|
-
* <i>IAM User Guide</i>.</p>
|
|
92
|
-
* <p>You can pass up to 50 session tags. The plaintext session tag keys can’t exceed 128
|
|
93
|
-
* characters and the values can’t exceed 256 characters. For these and additional limits, see
|
|
94
|
-
* <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-limits.html#reference_iam-limits-entity-length">IAM
|
|
95
|
-
* and STS Character Limits</a> in the <i>IAM User Guide</i>.</p>
|
|
96
|
-
*
|
|
97
|
-
* <note>
|
|
98
|
-
* <p>An Amazon Web Services conversion compresses the passed session policies and session tags into a
|
|
99
|
-
* packed binary format that has a separate limit. Your request can fail for this limit
|
|
100
|
-
* even if your plaintext meets the other requirements. The <code>PackedPolicySize</code>
|
|
101
|
-
* response element indicates by percentage how close the policies and tags for your
|
|
102
|
-
* request are to the upper size limit.
|
|
103
|
-
* </p>
|
|
104
|
-
* </note>
|
|
105
|
-
* <p>You can pass a session tag with the same key as a tag that is
|
|
106
|
-
* attached to the role. When you do, the session tag overrides the role tag with the same
|
|
107
|
-
* key.</p>
|
|
108
|
-
* <p>An administrator must grant you the permissions necessary to pass session tags. The
|
|
109
|
-
* administrator can also create granular permissions to allow you to pass only specific
|
|
110
|
-
* session tags. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/tutorial_attribute-based-access-control.html">Tutorial: Using Tags
|
|
111
|
-
* for Attribute-Based Access Control</a> in the
|
|
112
|
-
* <i>IAM User Guide</i>.</p>
|
|
113
|
-
* <p>You can set the session tags as transitive. Transitive tags persist during role
|
|
114
|
-
* chaining. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_session-tags.html#id_session-tags_role-chaining">Chaining Roles
|
|
115
|
-
* with Session Tags</a> in the <i>IAM User Guide</i>.</p>
|
|
116
|
-
* <p>
|
|
117
|
-
* <b>Identities</b>
|
|
118
|
-
* </p>
|
|
119
|
-
* <p>Before your application can call <code>AssumeRoleWithWebIdentity</code>, you must have
|
|
120
|
-
* an identity token from a supported identity provider and create a role that the application
|
|
121
|
-
* can assume. The role that your application assumes must trust the identity provider that is
|
|
122
|
-
* associated with the identity token. In other words, the identity provider must be specified
|
|
123
|
-
* in the role's trust policy. </p>
|
|
124
|
-
* <important>
|
|
125
|
-
* <p>Calling <code>AssumeRoleWithWebIdentity</code> can result in an entry in your
|
|
126
|
-
* CloudTrail logs. The entry includes the <a href="http://openid.net/specs/openid-connect-core-1_0.html#Claims">Subject</a> of
|
|
127
|
-
* the provided web identity token. We recommend that you avoid using any personally
|
|
128
|
-
* identifiable information (PII) in this field. For example, you could instead use a GUID
|
|
129
|
-
* or a pairwise identifier, as <a href="http://openid.net/specs/openid-connect-core-1_0.html#SubjectIDTypes">suggested
|
|
130
|
-
* in the OIDC specification</a>.</p>
|
|
131
|
-
* </important>
|
|
132
|
-
* <p>For more information about how to use web identity federation and the
|
|
133
|
-
* <code>AssumeRoleWithWebIdentity</code> API, see the following resources: </p>
|
|
134
|
-
* <ul>
|
|
135
|
-
* <li>
|
|
136
|
-
* <p>
|
|
137
|
-
* <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_oidc_manual.html">Using Web Identity Federation API Operations for Mobile Apps</a> and <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_assumerolewithwebidentity">Federation Through a Web-based Identity Provider</a>. </p>
|
|
138
|
-
* </li>
|
|
139
|
-
* <li>
|
|
140
|
-
* <p>
|
|
141
|
-
* <a href="https://aws.amazon.com/blogs/aws/the-aws-web-identity-federation-playground/"> Web Identity Federation Playground</a>. Walk through the process of
|
|
142
|
-
* authenticating through Login with Amazon, Facebook, or Google, getting temporary
|
|
143
|
-
* security credentials, and then using those credentials to make a request to Amazon Web Services.
|
|
144
|
-
* </p>
|
|
145
|
-
* </li>
|
|
146
|
-
* <li>
|
|
147
|
-
* <p>
|
|
148
|
-
* <a href="http://aws.amazon.com/sdkforios/">Amazon Web Services SDK for iOS Developer Guide</a> and <a href="http://aws.amazon.com/sdkforandroid/">Amazon Web Services SDK for Android Developer Guide</a>. These toolkits
|
|
149
|
-
* contain sample apps that show how to invoke the identity providers. The toolkits then
|
|
150
|
-
* show how to use the information from these providers to get and use temporary
|
|
151
|
-
* security credentials. </p>
|
|
152
|
-
* </li>
|
|
153
|
-
* <li>
|
|
154
|
-
* <p>
|
|
155
|
-
* <a href="http://aws.amazon.com/articles/web-identity-federation-with-mobile-applications">Web Identity
|
|
156
|
-
* Federation with Mobile Applications</a>. This article discusses web identity
|
|
157
|
-
* federation and shows an example of how to use web identity federation to get access
|
|
158
|
-
* to content in Amazon S3. </p>
|
|
159
|
-
* </li>
|
|
160
|
-
* </ul>
|
|
161
|
-
* @example
|
|
162
|
-
* Use a bare-bones client and the command you need to make an API call.
|
|
163
|
-
* ```javascript
|
|
164
|
-
* import { STSClient, AssumeRoleWithWebIdentityCommand } from "@aws-sdk/client-sts"; // ES Modules import
|
|
165
|
-
* // const { STSClient, AssumeRoleWithWebIdentityCommand } = require("@aws-sdk/client-sts"); // CommonJS import
|
|
166
|
-
* const client = new STSClient(config);
|
|
167
|
-
* const command = new AssumeRoleWithWebIdentityCommand(input);
|
|
168
|
-
* const response = await client.send(command);
|
|
169
|
-
* ```
|
|
170
|
-
*
|
|
171
|
-
* @see {@link AssumeRoleWithWebIdentityCommandInput} for command's `input` shape.
|
|
172
|
-
* @see {@link AssumeRoleWithWebIdentityCommandOutput} for command's `response` shape.
|
|
173
|
-
* @see {@link STSClientResolvedConfig | config} for command's `input` shape.
|
|
174
|
-
*
|
|
175
|
-
*/
|
|
176
|
-
export class AssumeRoleWithWebIdentityCommand extends $Command<
|
|
177
|
-
AssumeRoleWithWebIdentityCommandInput,
|
|
178
|
-
AssumeRoleWithWebIdentityCommandOutput,
|
|
179
|
-
STSClientResolvedConfig
|
|
180
|
-
> {
|
|
181
|
-
// Start section: command_properties
|
|
182
|
-
// End section: command_properties
|
|
183
|
-
|
|
184
|
-
constructor(readonly input: AssumeRoleWithWebIdentityCommandInput) {
|
|
185
|
-
// Start section: command_constructor
|
|
186
|
-
super();
|
|
187
|
-
// End section: command_constructor
|
|
188
|
-
}
|
|
189
|
-
|
|
190
|
-
/**
|
|
191
|
-
* @internal
|
|
192
|
-
*/
|
|
193
|
-
resolveMiddleware(
|
|
194
|
-
clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>,
|
|
195
|
-
configuration: STSClientResolvedConfig,
|
|
196
|
-
options?: __HttpHandlerOptions
|
|
197
|
-
): Handler<AssumeRoleWithWebIdentityCommandInput, AssumeRoleWithWebIdentityCommandOutput> {
|
|
198
|
-
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
199
|
-
|
|
200
|
-
const stack = clientStack.concat(this.middlewareStack);
|
|
201
|
-
|
|
202
|
-
const { logger } = configuration;
|
|
203
|
-
const clientName = "STSClient";
|
|
204
|
-
const commandName = "AssumeRoleWithWebIdentityCommand";
|
|
205
|
-
const handlerExecutionContext: HandlerExecutionContext = {
|
|
206
|
-
logger,
|
|
207
|
-
clientName,
|
|
208
|
-
commandName,
|
|
209
|
-
inputFilterSensitiveLog: AssumeRoleWithWebIdentityRequest.filterSensitiveLog,
|
|
210
|
-
outputFilterSensitiveLog: AssumeRoleWithWebIdentityResponse.filterSensitiveLog,
|
|
211
|
-
};
|
|
212
|
-
const { requestHandler } = configuration;
|
|
213
|
-
return stack.resolve(
|
|
214
|
-
(request: FinalizeHandlerArguments<any>) =>
|
|
215
|
-
requestHandler.handle(request.request as __HttpRequest, options || {}),
|
|
216
|
-
handlerExecutionContext
|
|
217
|
-
);
|
|
218
|
-
}
|
|
219
|
-
|
|
220
|
-
private serialize(input: AssumeRoleWithWebIdentityCommandInput, context: __SerdeContext): Promise<__HttpRequest> {
|
|
221
|
-
return serializeAws_queryAssumeRoleWithWebIdentityCommand(input, context);
|
|
222
|
-
}
|
|
223
|
-
|
|
224
|
-
private deserialize(
|
|
225
|
-
output: __HttpResponse,
|
|
226
|
-
context: __SerdeContext
|
|
227
|
-
): Promise<AssumeRoleWithWebIdentityCommandOutput> {
|
|
228
|
-
return deserializeAws_queryAssumeRoleWithWebIdentityCommand(output, context);
|
|
229
|
-
}
|
|
230
|
-
|
|
231
|
-
// Start section: command_body_extra
|
|
232
|
-
// End section: command_body_extra
|
|
233
|
-
}
|
|
@@ -1,135 +0,0 @@
|
|
|
1
|
-
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
2
|
-
import { getAwsAuthPlugin } from "@aws-sdk/middleware-signing";
|
|
3
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
|
|
4
|
-
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
5
|
-
import {
|
|
6
|
-
FinalizeHandlerArguments,
|
|
7
|
-
Handler,
|
|
8
|
-
HandlerExecutionContext,
|
|
9
|
-
HttpHandlerOptions as __HttpHandlerOptions,
|
|
10
|
-
MetadataBearer as __MetadataBearer,
|
|
11
|
-
MiddlewareStack,
|
|
12
|
-
SerdeContext as __SerdeContext,
|
|
13
|
-
} from "@aws-sdk/types";
|
|
14
|
-
|
|
15
|
-
import { DecodeAuthorizationMessageRequest, DecodeAuthorizationMessageResponse } from "../models/models_0";
|
|
16
|
-
import {
|
|
17
|
-
deserializeAws_queryDecodeAuthorizationMessageCommand,
|
|
18
|
-
serializeAws_queryDecodeAuthorizationMessageCommand,
|
|
19
|
-
} from "../protocols/Aws_query";
|
|
20
|
-
import { ServiceInputTypes, ServiceOutputTypes, STSClientResolvedConfig } from "../STSClient";
|
|
21
|
-
|
|
22
|
-
export interface DecodeAuthorizationMessageCommandInput extends DecodeAuthorizationMessageRequest {}
|
|
23
|
-
export interface DecodeAuthorizationMessageCommandOutput extends DecodeAuthorizationMessageResponse, __MetadataBearer {}
|
|
24
|
-
|
|
25
|
-
/**
|
|
26
|
-
* <p>Decodes additional information about the authorization status of a request from an
|
|
27
|
-
* encoded message returned in response to an Amazon Web Services request.</p>
|
|
28
|
-
* <p>For example, if a user is not authorized to perform an operation that he or she has
|
|
29
|
-
* requested, the request returns a <code>Client.UnauthorizedOperation</code> response (an
|
|
30
|
-
* HTTP 403 response). Some Amazon Web Services operations additionally return an encoded message that can
|
|
31
|
-
* provide details about this authorization failure. </p>
|
|
32
|
-
* <note>
|
|
33
|
-
* <p>Only certain Amazon Web Services operations return an encoded authorization message. The
|
|
34
|
-
* documentation for an individual operation indicates whether that operation returns an
|
|
35
|
-
* encoded message in addition to returning an HTTP code.</p>
|
|
36
|
-
* </note>
|
|
37
|
-
* <p>The message is encoded because the details of the authorization status can constitute
|
|
38
|
-
* privileged information that the user who requested the operation should not see. To decode
|
|
39
|
-
* an authorization status message, a user must be granted permissions via an IAM policy to
|
|
40
|
-
* request the <code>DecodeAuthorizationMessage</code>
|
|
41
|
-
* (<code>sts:DecodeAuthorizationMessage</code>) action. </p>
|
|
42
|
-
* <p>The decoded message includes the following type of information:</p>
|
|
43
|
-
* <ul>
|
|
44
|
-
* <li>
|
|
45
|
-
* <p>Whether the request was denied due to an explicit deny or due to the absence of an
|
|
46
|
-
* explicit allow. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_evaluation-logic.html#policy-eval-denyallow">Determining Whether a Request is Allowed or Denied</a> in the
|
|
47
|
-
* <i>IAM User Guide</i>. </p>
|
|
48
|
-
* </li>
|
|
49
|
-
* <li>
|
|
50
|
-
* <p>The principal who made the request.</p>
|
|
51
|
-
* </li>
|
|
52
|
-
* <li>
|
|
53
|
-
* <p>The requested action.</p>
|
|
54
|
-
* </li>
|
|
55
|
-
* <li>
|
|
56
|
-
* <p>The requested resource.</p>
|
|
57
|
-
* </li>
|
|
58
|
-
* <li>
|
|
59
|
-
* <p>The values of condition keys in the context of the user's request.</p>
|
|
60
|
-
* </li>
|
|
61
|
-
* </ul>
|
|
62
|
-
* @example
|
|
63
|
-
* Use a bare-bones client and the command you need to make an API call.
|
|
64
|
-
* ```javascript
|
|
65
|
-
* import { STSClient, DecodeAuthorizationMessageCommand } from "@aws-sdk/client-sts"; // ES Modules import
|
|
66
|
-
* // const { STSClient, DecodeAuthorizationMessageCommand } = require("@aws-sdk/client-sts"); // CommonJS import
|
|
67
|
-
* const client = new STSClient(config);
|
|
68
|
-
* const command = new DecodeAuthorizationMessageCommand(input);
|
|
69
|
-
* const response = await client.send(command);
|
|
70
|
-
* ```
|
|
71
|
-
*
|
|
72
|
-
* @see {@link DecodeAuthorizationMessageCommandInput} for command's `input` shape.
|
|
73
|
-
* @see {@link DecodeAuthorizationMessageCommandOutput} for command's `response` shape.
|
|
74
|
-
* @see {@link STSClientResolvedConfig | config} for command's `input` shape.
|
|
75
|
-
*
|
|
76
|
-
*/
|
|
77
|
-
export class DecodeAuthorizationMessageCommand extends $Command<
|
|
78
|
-
DecodeAuthorizationMessageCommandInput,
|
|
79
|
-
DecodeAuthorizationMessageCommandOutput,
|
|
80
|
-
STSClientResolvedConfig
|
|
81
|
-
> {
|
|
82
|
-
// Start section: command_properties
|
|
83
|
-
// End section: command_properties
|
|
84
|
-
|
|
85
|
-
constructor(readonly input: DecodeAuthorizationMessageCommandInput) {
|
|
86
|
-
// Start section: command_constructor
|
|
87
|
-
super();
|
|
88
|
-
// End section: command_constructor
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
/**
|
|
92
|
-
* @internal
|
|
93
|
-
*/
|
|
94
|
-
resolveMiddleware(
|
|
95
|
-
clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>,
|
|
96
|
-
configuration: STSClientResolvedConfig,
|
|
97
|
-
options?: __HttpHandlerOptions
|
|
98
|
-
): Handler<DecodeAuthorizationMessageCommandInput, DecodeAuthorizationMessageCommandOutput> {
|
|
99
|
-
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
100
|
-
this.middlewareStack.use(getAwsAuthPlugin(configuration));
|
|
101
|
-
|
|
102
|
-
const stack = clientStack.concat(this.middlewareStack);
|
|
103
|
-
|
|
104
|
-
const { logger } = configuration;
|
|
105
|
-
const clientName = "STSClient";
|
|
106
|
-
const commandName = "DecodeAuthorizationMessageCommand";
|
|
107
|
-
const handlerExecutionContext: HandlerExecutionContext = {
|
|
108
|
-
logger,
|
|
109
|
-
clientName,
|
|
110
|
-
commandName,
|
|
111
|
-
inputFilterSensitiveLog: DecodeAuthorizationMessageRequest.filterSensitiveLog,
|
|
112
|
-
outputFilterSensitiveLog: DecodeAuthorizationMessageResponse.filterSensitiveLog,
|
|
113
|
-
};
|
|
114
|
-
const { requestHandler } = configuration;
|
|
115
|
-
return stack.resolve(
|
|
116
|
-
(request: FinalizeHandlerArguments<any>) =>
|
|
117
|
-
requestHandler.handle(request.request as __HttpRequest, options || {}),
|
|
118
|
-
handlerExecutionContext
|
|
119
|
-
);
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
private serialize(input: DecodeAuthorizationMessageCommandInput, context: __SerdeContext): Promise<__HttpRequest> {
|
|
123
|
-
return serializeAws_queryDecodeAuthorizationMessageCommand(input, context);
|
|
124
|
-
}
|
|
125
|
-
|
|
126
|
-
private deserialize(
|
|
127
|
-
output: __HttpResponse,
|
|
128
|
-
context: __SerdeContext
|
|
129
|
-
): Promise<DecodeAuthorizationMessageCommandOutput> {
|
|
130
|
-
return deserializeAws_queryDecodeAuthorizationMessageCommand(output, context);
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
// Start section: command_body_extra
|
|
134
|
-
// End section: command_body_extra
|
|
135
|
-
}
|
|
@@ -1,114 +0,0 @@
|
|
|
1
|
-
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
2
|
-
import { getAwsAuthPlugin } from "@aws-sdk/middleware-signing";
|
|
3
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
|
|
4
|
-
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
5
|
-
import {
|
|
6
|
-
FinalizeHandlerArguments,
|
|
7
|
-
Handler,
|
|
8
|
-
HandlerExecutionContext,
|
|
9
|
-
HttpHandlerOptions as __HttpHandlerOptions,
|
|
10
|
-
MetadataBearer as __MetadataBearer,
|
|
11
|
-
MiddlewareStack,
|
|
12
|
-
SerdeContext as __SerdeContext,
|
|
13
|
-
} from "@aws-sdk/types";
|
|
14
|
-
|
|
15
|
-
import { GetAccessKeyInfoRequest, GetAccessKeyInfoResponse } from "../models/models_0";
|
|
16
|
-
import {
|
|
17
|
-
deserializeAws_queryGetAccessKeyInfoCommand,
|
|
18
|
-
serializeAws_queryGetAccessKeyInfoCommand,
|
|
19
|
-
} from "../protocols/Aws_query";
|
|
20
|
-
import { ServiceInputTypes, ServiceOutputTypes, STSClientResolvedConfig } from "../STSClient";
|
|
21
|
-
|
|
22
|
-
export interface GetAccessKeyInfoCommandInput extends GetAccessKeyInfoRequest {}
|
|
23
|
-
export interface GetAccessKeyInfoCommandOutput extends GetAccessKeyInfoResponse, __MetadataBearer {}
|
|
24
|
-
|
|
25
|
-
/**
|
|
26
|
-
* <p>Returns the account identifier for the specified access key ID.</p>
|
|
27
|
-
* <p>Access keys consist of two parts: an access key ID (for example,
|
|
28
|
-
* <code>AKIAIOSFODNN7EXAMPLE</code>) and a secret access key (for example,
|
|
29
|
-
* <code>wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY</code>). For more information about
|
|
30
|
-
* access keys, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_access-keys.html">Managing Access Keys for IAM
|
|
31
|
-
* Users</a> in the <i>IAM User Guide</i>.</p>
|
|
32
|
-
* <p>When you pass an access key ID to this operation, it returns the ID of the Amazon Web Services
|
|
33
|
-
* account to which the keys belong. Access key IDs beginning with <code>AKIA</code> are
|
|
34
|
-
* long-term credentials for an IAM user or the Amazon Web Services account root user. Access key IDs
|
|
35
|
-
* beginning with <code>ASIA</code> are temporary credentials that are created using STS
|
|
36
|
-
* operations. If the account in the response belongs to you, you can sign in as the root
|
|
37
|
-
* user and review your root user access keys. Then, you can pull a <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_getting-report.html">credentials report</a> to learn which IAM user owns the keys. To learn who
|
|
38
|
-
* requested the temporary credentials for an <code>ASIA</code> access key, view the STS
|
|
39
|
-
* events in your <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/cloudtrail-integration.html">CloudTrail logs</a> in the
|
|
40
|
-
* <i>IAM User Guide</i>.</p>
|
|
41
|
-
* <p>This operation does not indicate the state of the access key. The key might be active,
|
|
42
|
-
* inactive, or deleted. Active keys might not have permissions to perform an operation.
|
|
43
|
-
* Providing a deleted access key might return an error that the key doesn't exist.</p>
|
|
44
|
-
* @example
|
|
45
|
-
* Use a bare-bones client and the command you need to make an API call.
|
|
46
|
-
* ```javascript
|
|
47
|
-
* import { STSClient, GetAccessKeyInfoCommand } from "@aws-sdk/client-sts"; // ES Modules import
|
|
48
|
-
* // const { STSClient, GetAccessKeyInfoCommand } = require("@aws-sdk/client-sts"); // CommonJS import
|
|
49
|
-
* const client = new STSClient(config);
|
|
50
|
-
* const command = new GetAccessKeyInfoCommand(input);
|
|
51
|
-
* const response = await client.send(command);
|
|
52
|
-
* ```
|
|
53
|
-
*
|
|
54
|
-
* @see {@link GetAccessKeyInfoCommandInput} for command's `input` shape.
|
|
55
|
-
* @see {@link GetAccessKeyInfoCommandOutput} for command's `response` shape.
|
|
56
|
-
* @see {@link STSClientResolvedConfig | config} for command's `input` shape.
|
|
57
|
-
*
|
|
58
|
-
*/
|
|
59
|
-
export class GetAccessKeyInfoCommand extends $Command<
|
|
60
|
-
GetAccessKeyInfoCommandInput,
|
|
61
|
-
GetAccessKeyInfoCommandOutput,
|
|
62
|
-
STSClientResolvedConfig
|
|
63
|
-
> {
|
|
64
|
-
// Start section: command_properties
|
|
65
|
-
// End section: command_properties
|
|
66
|
-
|
|
67
|
-
constructor(readonly input: GetAccessKeyInfoCommandInput) {
|
|
68
|
-
// Start section: command_constructor
|
|
69
|
-
super();
|
|
70
|
-
// End section: command_constructor
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
/**
|
|
74
|
-
* @internal
|
|
75
|
-
*/
|
|
76
|
-
resolveMiddleware(
|
|
77
|
-
clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>,
|
|
78
|
-
configuration: STSClientResolvedConfig,
|
|
79
|
-
options?: __HttpHandlerOptions
|
|
80
|
-
): Handler<GetAccessKeyInfoCommandInput, GetAccessKeyInfoCommandOutput> {
|
|
81
|
-
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
82
|
-
this.middlewareStack.use(getAwsAuthPlugin(configuration));
|
|
83
|
-
|
|
84
|
-
const stack = clientStack.concat(this.middlewareStack);
|
|
85
|
-
|
|
86
|
-
const { logger } = configuration;
|
|
87
|
-
const clientName = "STSClient";
|
|
88
|
-
const commandName = "GetAccessKeyInfoCommand";
|
|
89
|
-
const handlerExecutionContext: HandlerExecutionContext = {
|
|
90
|
-
logger,
|
|
91
|
-
clientName,
|
|
92
|
-
commandName,
|
|
93
|
-
inputFilterSensitiveLog: GetAccessKeyInfoRequest.filterSensitiveLog,
|
|
94
|
-
outputFilterSensitiveLog: GetAccessKeyInfoResponse.filterSensitiveLog,
|
|
95
|
-
};
|
|
96
|
-
const { requestHandler } = configuration;
|
|
97
|
-
return stack.resolve(
|
|
98
|
-
(request: FinalizeHandlerArguments<any>) =>
|
|
99
|
-
requestHandler.handle(request.request as __HttpRequest, options || {}),
|
|
100
|
-
handlerExecutionContext
|
|
101
|
-
);
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
private serialize(input: GetAccessKeyInfoCommandInput, context: __SerdeContext): Promise<__HttpRequest> {
|
|
105
|
-
return serializeAws_queryGetAccessKeyInfoCommand(input, context);
|
|
106
|
-
}
|
|
107
|
-
|
|
108
|
-
private deserialize(output: __HttpResponse, context: __SerdeContext): Promise<GetAccessKeyInfoCommandOutput> {
|
|
109
|
-
return deserializeAws_queryGetAccessKeyInfoCommand(output, context);
|
|
110
|
-
}
|
|
111
|
-
|
|
112
|
-
// Start section: command_body_extra
|
|
113
|
-
// End section: command_body_extra
|
|
114
|
-
}
|
|
@@ -1,106 +0,0 @@
|
|
|
1
|
-
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
2
|
-
import { getAwsAuthPlugin } from "@aws-sdk/middleware-signing";
|
|
3
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
|
|
4
|
-
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
5
|
-
import {
|
|
6
|
-
FinalizeHandlerArguments,
|
|
7
|
-
Handler,
|
|
8
|
-
HandlerExecutionContext,
|
|
9
|
-
HttpHandlerOptions as __HttpHandlerOptions,
|
|
10
|
-
MetadataBearer as __MetadataBearer,
|
|
11
|
-
MiddlewareStack,
|
|
12
|
-
SerdeContext as __SerdeContext,
|
|
13
|
-
} from "@aws-sdk/types";
|
|
14
|
-
|
|
15
|
-
import { GetCallerIdentityRequest, GetCallerIdentityResponse } from "../models/models_0";
|
|
16
|
-
import {
|
|
17
|
-
deserializeAws_queryGetCallerIdentityCommand,
|
|
18
|
-
serializeAws_queryGetCallerIdentityCommand,
|
|
19
|
-
} from "../protocols/Aws_query";
|
|
20
|
-
import { ServiceInputTypes, ServiceOutputTypes, STSClientResolvedConfig } from "../STSClient";
|
|
21
|
-
|
|
22
|
-
export interface GetCallerIdentityCommandInput extends GetCallerIdentityRequest {}
|
|
23
|
-
export interface GetCallerIdentityCommandOutput extends GetCallerIdentityResponse, __MetadataBearer {}
|
|
24
|
-
|
|
25
|
-
/**
|
|
26
|
-
* <p>Returns details about the IAM user or role whose credentials are used to call the
|
|
27
|
-
* operation.</p>
|
|
28
|
-
* <note>
|
|
29
|
-
* <p>No permissions are required to perform this operation. If an administrator adds a
|
|
30
|
-
* policy to your IAM user or role that explicitly denies access to the
|
|
31
|
-
* <code>sts:GetCallerIdentity</code> action, you can still perform this operation.
|
|
32
|
-
* Permissions are not required because the same information is returned when an IAM
|
|
33
|
-
* user or role is denied access. To view an example response, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/troubleshoot_general.html#troubleshoot_general_access-denied-delete-mfa">I Am Not Authorized to Perform: iam:DeleteVirtualMFADevice</a> in the
|
|
34
|
-
* <i>IAM User Guide</i>.</p>
|
|
35
|
-
* </note>
|
|
36
|
-
* @example
|
|
37
|
-
* Use a bare-bones client and the command you need to make an API call.
|
|
38
|
-
* ```javascript
|
|
39
|
-
* import { STSClient, GetCallerIdentityCommand } from "@aws-sdk/client-sts"; // ES Modules import
|
|
40
|
-
* // const { STSClient, GetCallerIdentityCommand } = require("@aws-sdk/client-sts"); // CommonJS import
|
|
41
|
-
* const client = new STSClient(config);
|
|
42
|
-
* const command = new GetCallerIdentityCommand(input);
|
|
43
|
-
* const response = await client.send(command);
|
|
44
|
-
* ```
|
|
45
|
-
*
|
|
46
|
-
* @see {@link GetCallerIdentityCommandInput} for command's `input` shape.
|
|
47
|
-
* @see {@link GetCallerIdentityCommandOutput} for command's `response` shape.
|
|
48
|
-
* @see {@link STSClientResolvedConfig | config} for command's `input` shape.
|
|
49
|
-
*
|
|
50
|
-
*/
|
|
51
|
-
export class GetCallerIdentityCommand extends $Command<
|
|
52
|
-
GetCallerIdentityCommandInput,
|
|
53
|
-
GetCallerIdentityCommandOutput,
|
|
54
|
-
STSClientResolvedConfig
|
|
55
|
-
> {
|
|
56
|
-
// Start section: command_properties
|
|
57
|
-
// End section: command_properties
|
|
58
|
-
|
|
59
|
-
constructor(readonly input: GetCallerIdentityCommandInput) {
|
|
60
|
-
// Start section: command_constructor
|
|
61
|
-
super();
|
|
62
|
-
// End section: command_constructor
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
/**
|
|
66
|
-
* @internal
|
|
67
|
-
*/
|
|
68
|
-
resolveMiddleware(
|
|
69
|
-
clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>,
|
|
70
|
-
configuration: STSClientResolvedConfig,
|
|
71
|
-
options?: __HttpHandlerOptions
|
|
72
|
-
): Handler<GetCallerIdentityCommandInput, GetCallerIdentityCommandOutput> {
|
|
73
|
-
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
74
|
-
this.middlewareStack.use(getAwsAuthPlugin(configuration));
|
|
75
|
-
|
|
76
|
-
const stack = clientStack.concat(this.middlewareStack);
|
|
77
|
-
|
|
78
|
-
const { logger } = configuration;
|
|
79
|
-
const clientName = "STSClient";
|
|
80
|
-
const commandName = "GetCallerIdentityCommand";
|
|
81
|
-
const handlerExecutionContext: HandlerExecutionContext = {
|
|
82
|
-
logger,
|
|
83
|
-
clientName,
|
|
84
|
-
commandName,
|
|
85
|
-
inputFilterSensitiveLog: GetCallerIdentityRequest.filterSensitiveLog,
|
|
86
|
-
outputFilterSensitiveLog: GetCallerIdentityResponse.filterSensitiveLog,
|
|
87
|
-
};
|
|
88
|
-
const { requestHandler } = configuration;
|
|
89
|
-
return stack.resolve(
|
|
90
|
-
(request: FinalizeHandlerArguments<any>) =>
|
|
91
|
-
requestHandler.handle(request.request as __HttpRequest, options || {}),
|
|
92
|
-
handlerExecutionContext
|
|
93
|
-
);
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
private serialize(input: GetCallerIdentityCommandInput, context: __SerdeContext): Promise<__HttpRequest> {
|
|
97
|
-
return serializeAws_queryGetCallerIdentityCommand(input, context);
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
private deserialize(output: __HttpResponse, context: __SerdeContext): Promise<GetCallerIdentityCommandOutput> {
|
|
101
|
-
return deserializeAws_queryGetCallerIdentityCommand(output, context);
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
// Start section: command_body_extra
|
|
105
|
-
// End section: command_body_extra
|
|
106
|
-
}
|