@aws-sdk/client-sts 3.36.0 → 3.39.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.
Files changed (47) hide show
  1. package/CHANGELOG.md +42 -0
  2. package/dist-cjs/STS.js +0 -7
  3. package/dist-cjs/STSClient.js +0 -12
  4. package/dist-cjs/commands/AssumeRoleCommand.js +0 -107
  5. package/dist-cjs/commands/AssumeRoleWithSAMLCommand.js +0 -155
  6. package/dist-cjs/commands/AssumeRoleWithWebIdentityCommand.js +0 -159
  7. package/dist-cjs/commands/DecodeAuthorizationMessageCommand.js +0 -59
  8. package/dist-cjs/commands/GetAccessKeyInfoCommand.js +0 -41
  9. package/dist-cjs/commands/GetCallerIdentityCommand.js +0 -33
  10. package/dist-cjs/commands/GetFederationTokenCommand.js +0 -162
  11. package/dist-cjs/commands/GetSessionTokenCommand.js +0 -75
  12. package/dist-cjs/commands/index.js +11 -0
  13. package/dist-cjs/defaultRoleAssumers.js +0 -16
  14. package/dist-cjs/defaultStsRoleAssumers.js +0 -20
  15. package/dist-cjs/endpoints.js +6 -1
  16. package/dist-cjs/index.js +3 -10
  17. package/dist-cjs/models/models_0.js +0 -87
  18. package/dist-cjs/protocols/Aws_query.js +0 -2
  19. package/dist-cjs/runtimeConfig.browser.js +1 -5
  20. package/dist-cjs/runtimeConfig.js +1 -5
  21. package/dist-cjs/runtimeConfig.native.js +0 -3
  22. package/dist-cjs/runtimeConfig.shared.js +0 -3
  23. package/dist-es/commands/index.js +8 -0
  24. package/dist-es/endpoints.js +6 -1
  25. package/dist-es/index.js +3 -10
  26. package/dist-types/commands/index.d.ts +8 -0
  27. package/dist-types/index.d.ts +3 -10
  28. package/dist-types/ts3.4/STS.d.ts +9 -630
  29. package/dist-types/ts3.4/STSClient.d.ts +24 -93
  30. package/dist-types/ts3.4/commands/AssumeRoleCommand.d.ts +2 -103
  31. package/dist-types/ts3.4/commands/AssumeRoleWithSAMLCommand.d.ts +2 -151
  32. package/dist-types/ts3.4/commands/AssumeRoleWithWebIdentityCommand.d.ts +2 -155
  33. package/dist-types/ts3.4/commands/DecodeAuthorizationMessageCommand.d.ts +2 -55
  34. package/dist-types/ts3.4/commands/GetAccessKeyInfoCommand.d.ts +2 -37
  35. package/dist-types/ts3.4/commands/GetCallerIdentityCommand.d.ts +2 -29
  36. package/dist-types/ts3.4/commands/GetFederationTokenCommand.d.ts +2 -158
  37. package/dist-types/ts3.4/commands/GetSessionTokenCommand.d.ts +2 -71
  38. package/dist-types/ts3.4/commands/index.d.ts +8 -0
  39. package/dist-types/ts3.4/defaultRoleAssumers.d.ts +3 -14
  40. package/dist-types/ts3.4/defaultStsRoleAssumers.d.ts +6 -25
  41. package/dist-types/ts3.4/index.d.ts +3 -10
  42. package/dist-types/ts3.4/models/models_0.d.ts +123 -948
  43. package/dist-types/ts3.4/runtimeConfig.browser.d.ts +1 -3
  44. package/dist-types/ts3.4/runtimeConfig.d.ts +1 -3
  45. package/dist-types/ts3.4/runtimeConfig.native.d.ts +1 -3
  46. package/dist-types/ts3.4/runtimeConfig.shared.d.ts +1 -3
  47. package/package.json +32 -32
@@ -8,658 +8,37 @@ import { GetCallerIdentityCommandInput, GetCallerIdentityCommandOutput } from ".
8
8
  import { GetFederationTokenCommandInput, GetFederationTokenCommandOutput } from "./commands/GetFederationTokenCommand";
9
9
  import { GetSessionTokenCommandInput, GetSessionTokenCommandOutput } from "./commands/GetSessionTokenCommand";
10
10
  import { STSClient } from "./STSClient";
11
- /**
12
- * <fullname>Security Token Service</fullname>
13
- * <p>Security Token Service (STS) enables you to request temporary, limited-privilege
14
- * credentials for Identity and Access Management (IAM) users or for users that you
15
- * authenticate (federated users). This guide provides descriptions of the STS API. For
16
- * more information about using this service, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp.html">Temporary Security Credentials</a>.</p>
17
- */
11
+
18
12
  export declare class STS extends STSClient {
19
- /**
20
- * <p>Returns a set of temporary security credentials that you can use to access Amazon Web Services
21
- * resources that you might not normally have access to. These temporary credentials
22
- * consist of an access key ID, a secret access key, and a security token. Typically, you
23
- * use <code>AssumeRole</code> within your account or for cross-account access. For a
24
- * comparison of <code>AssumeRole</code> with other API operations that produce temporary
25
- * credentials, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html">Requesting Temporary Security
26
- * Credentials</a> and <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison">Comparing
27
- * the STS API operations</a> in the
28
- * <i>IAM User Guide</i>.</p>
29
- * <p>
30
- * <b>Permissions</b>
31
- * </p>
32
- * <p>The temporary security credentials created by <code>AssumeRole</code> can be used to
33
- * make API calls to any Amazon Web Services service with the following exception: You cannot call the
34
- * STS <code>GetFederationToken</code> or <code>GetSessionToken</code> API
35
- * operations.</p>
36
- * <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
37
- * this operation. You can pass a single JSON policy document to use as an inline session
38
- * policy. You can also specify up to 10 managed policies to use as managed session policies.
39
- * The plaintext that you use for both inline and managed session policies can't exceed 2,048
40
- * characters. Passing policies to this operation returns new
41
- * temporary credentials. The resulting session's permissions are the intersection of the
42
- * role's identity-based policy and the session policies. You can use the role's temporary
43
- * credentials in subsequent Amazon Web Services API calls to access resources in the account that owns
44
- * the role. You cannot use session policies to grant more permissions than those allowed
45
- * by the identity-based policy of the role that is being assumed. For more information, see
46
- * <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session">Session
47
- * Policies</a> in the <i>IAM User Guide</i>.</p>
48
- * <p>To assume a role from a different account, your account must be trusted by the
49
- * role. The trust relationship is defined in the role's trust policy when the role is
50
- * created. That trust policy states which accounts are allowed to delegate that access to
51
- * users in the account. </p>
52
- * <p>A user who wants to access a role in a different account must also have permissions that
53
- * are delegated from the user account administrator. The administrator must attach a policy
54
- * that allows the user to call <code>AssumeRole</code> for the ARN of the role in the other
55
- * account. If the user is in the same account as the role, then you can do either of the
56
- * following:</p>
57
- * <ul>
58
- * <li>
59
- * <p>Attach a policy to the user (identical to the previous user in a different
60
- * account).</p>
61
- * </li>
62
- * <li>
63
- * <p>Add the user as a principal directly in the role's trust policy.</p>
64
- * </li>
65
- * </ul>
66
- * <p>In this case, the trust policy acts as an IAM resource-based policy. Users in the same
67
- * account as the role do not need explicit permission to assume the role. For more
68
- * information about trust policies and resource-based policies, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html">IAM Policies</a> in
69
- * the <i>IAM User Guide</i>.</p>
70
- * <p>
71
- * <b>Tags</b>
72
- * </p>
73
- * <p>(Optional) You can pass tag key-value pairs to your session. These tags are called
74
- * session tags. For more 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
75
- * <i>IAM User Guide</i>.</p>
76
- * <p>An administrator must grant you the permissions necessary to pass session tags. The
77
- * administrator can also create granular permissions to allow you to pass only specific
78
- * 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
79
- * for Attribute-Based Access Control</a> in the
80
- * <i>IAM User Guide</i>.</p>
81
- * <p>You can set the session tags as transitive. Transitive tags persist during role
82
- * 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
83
- * with Session Tags</a> in the <i>IAM User Guide</i>.</p>
84
- * <p>
85
- * <b>Using MFA with AssumeRole</b>
86
- * </p>
87
- * <p>(Optional) You can include multi-factor authentication (MFA) information when you call
88
- * <code>AssumeRole</code>. This is useful for cross-account scenarios to ensure that the
89
- * user that assumes the role has been authenticated with an Amazon Web Services MFA device. In that
90
- * scenario, the trust policy of the role being assumed includes a condition that tests for
91
- * MFA authentication. If the caller does not include valid MFA information, the request to
92
- * assume the role is denied. The condition in a trust policy that tests for MFA
93
- * authentication might look like the following example.</p>
94
- * <p>
95
- * <code>"Condition": {"Bool": {"aws:MultiFactorAuthPresent": true}}</code>
96
- * </p>
97
- * <p>For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/MFAProtectedAPI.html">Configuring MFA-Protected API Access</a>
98
- * in the <i>IAM User Guide</i> guide.</p>
99
- * <p>To use MFA with <code>AssumeRole</code>, you pass values for the
100
- * <code>SerialNumber</code> and <code>TokenCode</code> parameters. The
101
- * <code>SerialNumber</code> value identifies the user's hardware or virtual MFA device.
102
- * The <code>TokenCode</code> is the time-based one-time password (TOTP) that the MFA device
103
- * produces. </p>
104
- */
13
+
105
14
  assumeRole(args: AssumeRoleCommandInput, options?: __HttpHandlerOptions): Promise<AssumeRoleCommandOutput>;
106
15
  assumeRole(args: AssumeRoleCommandInput, cb: (err: any, data?: AssumeRoleCommandOutput) => void): void;
107
16
  assumeRole(args: AssumeRoleCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: AssumeRoleCommandOutput) => void): void;
108
- /**
109
- * <p>Returns a set of temporary security credentials for users who have been authenticated
110
- * via a SAML authentication response. This operation provides a mechanism for tying an
111
- * enterprise identity store or directory to role-based Amazon Web Services access without user-specific
112
- * credentials or configuration. For a comparison of <code>AssumeRoleWithSAML</code> with the
113
- * other API operations that produce temporary credentials, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html">Requesting Temporary Security
114
- * Credentials</a> and <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison">Comparing the
115
- * STS API operations</a> in the <i>IAM User Guide</i>.</p>
116
- * <p>The temporary security credentials returned by this operation consist of an access key
117
- * ID, a secret access key, and a security token. Applications can use these temporary
118
- * security credentials to sign calls to Amazon Web Services services.</p>
119
- * <p>
120
- * <b>Session Duration</b>
121
- * </p>
122
- * <p>By default, the temporary security credentials created by
123
- * <code>AssumeRoleWithSAML</code> last for one hour. However, you can use the optional
124
- * <code>DurationSeconds</code> parameter to specify the duration of your session. Your
125
- * role session lasts for the duration that you specify, or until the time specified in the
126
- * SAML authentication response's <code>SessionNotOnOrAfter</code> value, whichever is
127
- * shorter. You can provide a <code>DurationSeconds</code> value from 900 seconds (15 minutes)
128
- * up to the maximum session duration setting for the role. This setting can have a value from
129
- * 1 hour to 12 hours. To learn how 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
130
- * Maximum Session Duration Setting for a Role</a> in the
131
- * <i>IAM User Guide</i>. The maximum session duration limit applies when
132
- * you use the <code>AssumeRole*</code> API operations or the <code>assume-role*</code> CLI
133
- * commands. However the limit does not apply when you use those operations to create a
134
- * 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
135
- * <i>IAM User Guide</i>.</p>
136
- * <note>
137
- * <p>
138
- * <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_terms-and-concepts.html#iam-term-role-chaining">Role chaining</a> limits your CLI or Amazon Web Services API
139
- * role session to a maximum of one hour. When you use the <code>AssumeRole</code> API
140
- * operation to assume a role, you can specify the duration of your role session with
141
- * the <code>DurationSeconds</code> parameter. You can specify a parameter value of up
142
- * to 43200 seconds (12 hours), depending on the maximum session duration setting for
143
- * your role. However, if you assume a role using role chaining and provide a
144
- * <code>DurationSeconds</code> parameter value greater than one hour, the
145
- * operation fails.</p>
146
- * </note>
147
- * <p>
148
- * <b>Permissions</b>
149
- * </p>
150
- * <p>The temporary security credentials created by <code>AssumeRoleWithSAML</code> can be
151
- * used to make API calls to any Amazon Web Services service with the following exception: you cannot call
152
- * the STS <code>GetFederationToken</code> or <code>GetSessionToken</code> API
153
- * operations.</p>
154
- * <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
155
- * this operation. You can pass a single JSON policy document to use as an inline session
156
- * policy. You can also specify up to 10 managed policies to use as managed session policies.
157
- * The plaintext that you use for both inline and managed session policies can't exceed 2,048
158
- * characters. Passing policies to this operation returns new
159
- * temporary credentials. The resulting session's permissions are the intersection of the
160
- * role's identity-based policy and the session policies. You can use the role's temporary
161
- * credentials in subsequent Amazon Web Services API calls to access resources in the account that owns
162
- * the role. You cannot use session policies to grant more permissions than those allowed
163
- * by the identity-based policy of the role that is being assumed. For more information, see
164
- * <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session">Session
165
- * Policies</a> in the <i>IAM User Guide</i>.</p>
166
- * <p>Calling <code>AssumeRoleWithSAML</code> does not require the use of Amazon Web Services security
167
- * credentials. The identity of the caller is validated by using keys in the metadata document
168
- * that is uploaded for the SAML provider entity for your identity provider. </p>
169
- * <important>
170
- * <p>Calling <code>AssumeRoleWithSAML</code> can result in an entry in your CloudTrail logs.
171
- * The entry includes the value in the <code>NameID</code> element of the SAML assertion.
172
- * We recommend that you use a <code>NameIDType</code> that is not associated with any
173
- * personally identifiable information (PII). For example, you could instead use the
174
- * persistent identifier
175
- * (<code>urn:oasis:names:tc:SAML:2.0:nameid-format:persistent</code>).</p>
176
- * </important>
177
- * <p>
178
- * <b>Tags</b>
179
- * </p>
180
- * <p>(Optional) You can configure your IdP to pass attributes into your SAML assertion as
181
- * session tags. Each session tag consists of a key name and an associated value. For more
182
- * 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
183
- * <i>IAM User Guide</i>.</p>
184
- * <p>You can pass up to 50 session tags. The plaintext session tag keys can’t exceed 128
185
- * characters and the values can’t exceed 256 characters. For these and additional limits, see
186
- * <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-limits.html#reference_iam-limits-entity-length">IAM
187
- * and STS Character Limits</a> in the <i>IAM User Guide</i>.</p>
188
- *
189
- * <note>
190
- * <p>An Amazon Web Services conversion compresses the passed session policies and session tags into a
191
- * packed binary format that has a separate limit. Your request can fail for this limit
192
- * even if your plaintext meets the other requirements. The <code>PackedPolicySize</code>
193
- * response element indicates by percentage how close the policies and tags for your
194
- * request are to the upper size limit.
195
- * </p>
196
- * </note>
197
- * <p>You can pass a session tag with the same key as a tag that is
198
- * attached to the role. When you do, session tags override the role's tags with the same
199
- * key.</p>
200
- * <p>An administrator must grant you the permissions necessary to pass session tags. The
201
- * administrator can also create granular permissions to allow you to pass only specific
202
- * 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
203
- * for Attribute-Based Access Control</a> in the
204
- * <i>IAM User Guide</i>.</p>
205
- * <p>You can set the session tags as transitive. Transitive tags persist during role
206
- * 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
207
- * with Session Tags</a> in the <i>IAM User Guide</i>.</p>
208
- * <p>
209
- * <b>SAML Configuration</b>
210
- * </p>
211
- * <p>Before your application can call <code>AssumeRoleWithSAML</code>, you must configure
212
- * your SAML identity provider (IdP) to issue the claims required by Amazon Web Services. Additionally, you
213
- * must use Identity and Access Management (IAM) to create a SAML provider entity in your Amazon Web Services account that
214
- * represents your identity provider. You must also create an IAM role that specifies this
215
- * SAML provider in its trust policy. </p>
216
- * <p>For more information, see the following resources:</p>
217
- * <ul>
218
- * <li>
219
- * <p>
220
- * <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_saml.html">About
221
- * SAML 2.0-based Federation</a> in the <i>IAM User Guide</i>.
222
- * </p>
223
- * </li>
224
- * <li>
225
- * <p>
226
- * <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_create_saml.html">Creating SAML Identity Providers</a> in the
227
- * <i>IAM User Guide</i>. </p>
228
- * </li>
229
- * <li>
230
- * <p>
231
- * <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_create_saml_relying-party.html">Configuring
232
- * a Relying Party and Claims</a> in the <i>IAM User Guide</i>.
233
- * </p>
234
- * </li>
235
- * <li>
236
- * <p>
237
- * <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_create_for-idp_saml.html">Creating a Role for SAML 2.0 Federation</a> in the
238
- * <i>IAM User Guide</i>. </p>
239
- * </li>
240
- * </ul>
241
- */
17
+
242
18
  assumeRoleWithSAML(args: AssumeRoleWithSAMLCommandInput, options?: __HttpHandlerOptions): Promise<AssumeRoleWithSAMLCommandOutput>;
243
19
  assumeRoleWithSAML(args: AssumeRoleWithSAMLCommandInput, cb: (err: any, data?: AssumeRoleWithSAMLCommandOutput) => void): void;
244
20
  assumeRoleWithSAML(args: AssumeRoleWithSAMLCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: AssumeRoleWithSAMLCommandOutput) => void): void;
245
- /**
246
- * <p>Returns a set of temporary security credentials for users who have been authenticated in
247
- * a mobile or web application with a web identity provider. Example providers include Amazon Cognito,
248
- * Login with Amazon, Facebook, Google, or any OpenID Connect-compatible identity
249
- * provider.</p>
250
- * <note>
251
- * <p>For mobile applications, we recommend that you use Amazon Cognito. You can use Amazon Cognito with the
252
- * <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
253
- * identify a user. You can also supply the user with a consistent identity throughout the
254
- * lifetime of an application.</p>
255
- * <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
256
- * <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
257
- * <i>Amazon Web Services SDK for iOS Developer Guide</i>.</p>
258
- * </note>
259
- * <p>Calling <code>AssumeRoleWithWebIdentity</code> does not require the use of Amazon Web Services
260
- * security credentials. Therefore, you can distribute an application (for example, on mobile
261
- * devices) that requests temporary security credentials without including long-term Amazon Web Services
262
- * credentials in the application. You also don't need to deploy server-based proxy services
263
- * that use long-term Amazon Web Services credentials. Instead, the identity of the caller is validated by
264
- * using a token from the web identity provider. For a comparison of
265
- * <code>AssumeRoleWithWebIdentity</code> with the other API operations that produce
266
- * temporary credentials, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html">Requesting Temporary Security
267
- * Credentials</a> and <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison">Comparing the
268
- * STS API operations</a> in the <i>IAM User Guide</i>.</p>
269
- * <p>The temporary security credentials returned by this API consist of an access key ID, a
270
- * secret access key, and a security token. Applications can use these temporary security
271
- * credentials to sign calls to Amazon Web Services service API operations.</p>
272
- * <p>
273
- * <b>Session Duration</b>
274
- * </p>
275
- * <p>By default, the temporary security credentials created by
276
- * <code>AssumeRoleWithWebIdentity</code> last for one hour. However, you can use the
277
- * optional <code>DurationSeconds</code> parameter to specify the duration of your session.
278
- * You can provide a value from 900 seconds (15 minutes) up to the maximum session duration
279
- * setting for the role. This setting can have a value from 1 hour to 12 hours. To learn how
280
- * 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
281
- * Maximum Session Duration Setting for a Role</a> in the
282
- * <i>IAM User Guide</i>. The maximum session duration limit applies when
283
- * you use the <code>AssumeRole*</code> API operations or the <code>assume-role*</code> CLI
284
- * commands. However the limit does not apply when you use those operations to create a
285
- * 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
286
- * <i>IAM User Guide</i>. </p>
287
- * <p>
288
- * <b>Permissions</b>
289
- * </p>
290
- * <p>The temporary security credentials created by <code>AssumeRoleWithWebIdentity</code> can
291
- * be used to make API calls to any Amazon Web Services service with the following exception: you cannot
292
- * call the STS <code>GetFederationToken</code> or <code>GetSessionToken</code> API
293
- * operations.</p>
294
- * <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
295
- * this operation. You can pass a single JSON policy document to use as an inline session
296
- * policy. You can also specify up to 10 managed policies to use as managed session policies.
297
- * The plaintext that you use for both inline and managed session policies can't exceed 2,048
298
- * characters. Passing policies to this operation returns new
299
- * temporary credentials. The resulting session's permissions are the intersection of the
300
- * role's identity-based policy and the session policies. You can use the role's temporary
301
- * credentials in subsequent Amazon Web Services API calls to access resources in the account that owns
302
- * the role. You cannot use session policies to grant more permissions than those allowed
303
- * by the identity-based policy of the role that is being assumed. For more information, see
304
- * <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session">Session
305
- * Policies</a> in the <i>IAM User Guide</i>.</p>
306
- * <p>
307
- * <b>Tags</b>
308
- * </p>
309
- * <p>(Optional) You can configure your IdP to pass attributes into your web identity token as
310
- * session tags. Each session tag consists of a key name and an associated value. For more
311
- * 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
312
- * <i>IAM User Guide</i>.</p>
313
- * <p>You can pass up to 50 session tags. The plaintext session tag keys can’t exceed 128
314
- * characters and the values can’t exceed 256 characters. For these and additional limits, see
315
- * <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-limits.html#reference_iam-limits-entity-length">IAM
316
- * and STS Character Limits</a> in the <i>IAM User Guide</i>.</p>
317
- *
318
- * <note>
319
- * <p>An Amazon Web Services conversion compresses the passed session policies and session tags into a
320
- * packed binary format that has a separate limit. Your request can fail for this limit
321
- * even if your plaintext meets the other requirements. The <code>PackedPolicySize</code>
322
- * response element indicates by percentage how close the policies and tags for your
323
- * request are to the upper size limit.
324
- * </p>
325
- * </note>
326
- * <p>You can pass a session tag with the same key as a tag that is
327
- * attached to the role. When you do, the session tag overrides the role tag with the same
328
- * key.</p>
329
- * <p>An administrator must grant you the permissions necessary to pass session tags. The
330
- * administrator can also create granular permissions to allow you to pass only specific
331
- * 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
332
- * for Attribute-Based Access Control</a> in the
333
- * <i>IAM User Guide</i>.</p>
334
- * <p>You can set the session tags as transitive. Transitive tags persist during role
335
- * 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
336
- * with Session Tags</a> in the <i>IAM User Guide</i>.</p>
337
- * <p>
338
- * <b>Identities</b>
339
- * </p>
340
- * <p>Before your application can call <code>AssumeRoleWithWebIdentity</code>, you must have
341
- * an identity token from a supported identity provider and create a role that the application
342
- * can assume. The role that your application assumes must trust the identity provider that is
343
- * associated with the identity token. In other words, the identity provider must be specified
344
- * in the role's trust policy. </p>
345
- * <important>
346
- * <p>Calling <code>AssumeRoleWithWebIdentity</code> can result in an entry in your
347
- * CloudTrail logs. The entry includes the <a href="http://openid.net/specs/openid-connect-core-1_0.html#Claims">Subject</a> of
348
- * the provided web identity token. We recommend that you avoid using any personally
349
- * identifiable information (PII) in this field. For example, you could instead use a GUID
350
- * or a pairwise identifier, as <a href="http://openid.net/specs/openid-connect-core-1_0.html#SubjectIDTypes">suggested
351
- * in the OIDC specification</a>.</p>
352
- * </important>
353
- * <p>For more information about how to use web identity federation and the
354
- * <code>AssumeRoleWithWebIdentity</code> API, see the following resources: </p>
355
- * <ul>
356
- * <li>
357
- * <p>
358
- * <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>
359
- * </li>
360
- * <li>
361
- * <p>
362
- * <a href="https://aws.amazon.com/blogs/aws/the-aws-web-identity-federation-playground/"> Web Identity Federation Playground</a>. Walk through the process of
363
- * authenticating through Login with Amazon, Facebook, or Google, getting temporary
364
- * security credentials, and then using those credentials to make a request to Amazon Web Services.
365
- * </p>
366
- * </li>
367
- * <li>
368
- * <p>
369
- * <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
370
- * contain sample apps that show how to invoke the identity providers. The toolkits then
371
- * show how to use the information from these providers to get and use temporary
372
- * security credentials. </p>
373
- * </li>
374
- * <li>
375
- * <p>
376
- * <a href="http://aws.amazon.com/articles/web-identity-federation-with-mobile-applications">Web Identity
377
- * Federation with Mobile Applications</a>. This article discusses web identity
378
- * federation and shows an example of how to use web identity federation to get access
379
- * to content in Amazon S3. </p>
380
- * </li>
381
- * </ul>
382
- */
21
+
383
22
  assumeRoleWithWebIdentity(args: AssumeRoleWithWebIdentityCommandInput, options?: __HttpHandlerOptions): Promise<AssumeRoleWithWebIdentityCommandOutput>;
384
23
  assumeRoleWithWebIdentity(args: AssumeRoleWithWebIdentityCommandInput, cb: (err: any, data?: AssumeRoleWithWebIdentityCommandOutput) => void): void;
385
24
  assumeRoleWithWebIdentity(args: AssumeRoleWithWebIdentityCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: AssumeRoleWithWebIdentityCommandOutput) => void): void;
386
- /**
387
- * <p>Decodes additional information about the authorization status of a request from an
388
- * encoded message returned in response to an Amazon Web Services request.</p>
389
- * <p>For example, if a user is not authorized to perform an operation that he or she has
390
- * requested, the request returns a <code>Client.UnauthorizedOperation</code> response (an
391
- * HTTP 403 response). Some Amazon Web Services operations additionally return an encoded message that can
392
- * provide details about this authorization failure. </p>
393
- * <note>
394
- * <p>Only certain Amazon Web Services operations return an encoded authorization message. The
395
- * documentation for an individual operation indicates whether that operation returns an
396
- * encoded message in addition to returning an HTTP code.</p>
397
- * </note>
398
- * <p>The message is encoded because the details of the authorization status can constitute
399
- * privileged information that the user who requested the operation should not see. To decode
400
- * an authorization status message, a user must be granted permissions via an IAM policy to
401
- * request the <code>DecodeAuthorizationMessage</code>
402
- * (<code>sts:DecodeAuthorizationMessage</code>) action. </p>
403
- * <p>The decoded message includes the following type of information:</p>
404
- * <ul>
405
- * <li>
406
- * <p>Whether the request was denied due to an explicit deny or due to the absence of an
407
- * 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
408
- * <i>IAM User Guide</i>. </p>
409
- * </li>
410
- * <li>
411
- * <p>The principal who made the request.</p>
412
- * </li>
413
- * <li>
414
- * <p>The requested action.</p>
415
- * </li>
416
- * <li>
417
- * <p>The requested resource.</p>
418
- * </li>
419
- * <li>
420
- * <p>The values of condition keys in the context of the user's request.</p>
421
- * </li>
422
- * </ul>
423
- */
25
+
424
26
  decodeAuthorizationMessage(args: DecodeAuthorizationMessageCommandInput, options?: __HttpHandlerOptions): Promise<DecodeAuthorizationMessageCommandOutput>;
425
27
  decodeAuthorizationMessage(args: DecodeAuthorizationMessageCommandInput, cb: (err: any, data?: DecodeAuthorizationMessageCommandOutput) => void): void;
426
28
  decodeAuthorizationMessage(args: DecodeAuthorizationMessageCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: DecodeAuthorizationMessageCommandOutput) => void): void;
427
- /**
428
- * <p>Returns the account identifier for the specified access key ID.</p>
429
- * <p>Access keys consist of two parts: an access key ID (for example,
430
- * <code>AKIAIOSFODNN7EXAMPLE</code>) and a secret access key (for example,
431
- * <code>wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY</code>). For more information about
432
- * access keys, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_access-keys.html">Managing Access Keys for IAM
433
- * Users</a> in the <i>IAM User Guide</i>.</p>
434
- * <p>When you pass an access key ID to this operation, it returns the ID of the Amazon Web Services
435
- * account to which the keys belong. Access key IDs beginning with <code>AKIA</code> are
436
- * long-term credentials for an IAM user or the Amazon Web Services account root user. Access key IDs
437
- * beginning with <code>ASIA</code> are temporary credentials that are created using STS
438
- * operations. If the account in the response belongs to you, you can sign in as the root
439
- * 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
440
- * requested the temporary credentials for an <code>ASIA</code> access key, view the STS
441
- * events in your <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/cloudtrail-integration.html">CloudTrail logs</a> in the
442
- * <i>IAM User Guide</i>.</p>
443
- * <p>This operation does not indicate the state of the access key. The key might be active,
444
- * inactive, or deleted. Active keys might not have permissions to perform an operation.
445
- * Providing a deleted access key might return an error that the key doesn't exist.</p>
446
- */
29
+
447
30
  getAccessKeyInfo(args: GetAccessKeyInfoCommandInput, options?: __HttpHandlerOptions): Promise<GetAccessKeyInfoCommandOutput>;
448
31
  getAccessKeyInfo(args: GetAccessKeyInfoCommandInput, cb: (err: any, data?: GetAccessKeyInfoCommandOutput) => void): void;
449
32
  getAccessKeyInfo(args: GetAccessKeyInfoCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: GetAccessKeyInfoCommandOutput) => void): void;
450
- /**
451
- * <p>Returns details about the IAM user or role whose credentials are used to call the
452
- * operation.</p>
453
- * <note>
454
- * <p>No permissions are required to perform this operation. If an administrator adds a
455
- * policy to your IAM user or role that explicitly denies access to the
456
- * <code>sts:GetCallerIdentity</code> action, you can still perform this operation.
457
- * Permissions are not required because the same information is returned when an IAM
458
- * 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
459
- * <i>IAM User Guide</i>.</p>
460
- * </note>
461
- */
33
+
462
34
  getCallerIdentity(args: GetCallerIdentityCommandInput, options?: __HttpHandlerOptions): Promise<GetCallerIdentityCommandOutput>;
463
35
  getCallerIdentity(args: GetCallerIdentityCommandInput, cb: (err: any, data?: GetCallerIdentityCommandOutput) => void): void;
464
36
  getCallerIdentity(args: GetCallerIdentityCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: GetCallerIdentityCommandOutput) => void): void;
465
- /**
466
- * <p>Returns a set of temporary security credentials (consisting of an access key ID, a
467
- * secret access key, and a security token) for a federated user. A typical use is in a proxy
468
- * application that gets temporary security credentials on behalf of distributed applications
469
- * inside a corporate network. You must call the <code>GetFederationToken</code> operation
470
- * using the long-term security credentials of an IAM user. As a result, this call is
471
- * appropriate in contexts where those credentials can be safely stored, usually in a
472
- * server-based application. For a comparison of <code>GetFederationToken</code> with the
473
- * other API operations that produce temporary credentials, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html">Requesting Temporary Security
474
- * Credentials</a> and <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison">Comparing the
475
- * STS API operations</a> in the <i>IAM User Guide</i>.</p>
476
- * <note>
477
- * <p>You can create a mobile-based or browser-based app that can authenticate users using
478
- * a web identity provider like Login with Amazon, Facebook, Google, or an OpenID
479
- * Connect-compatible identity provider. In this case, we recommend that you use <a href="http://aws.amazon.com/cognito/">Amazon Cognito</a> or
480
- * <code>AssumeRoleWithWebIdentity</code>. For more information, see <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> in the
481
- * <i>IAM User Guide</i>.</p>
482
- * </note>
483
- * <p>You can also call <code>GetFederationToken</code> using the security credentials of an
484
- * Amazon Web Services account root user, but we do not recommend it. Instead, we recommend that you create
485
- * an IAM user for the purpose of the proxy application. Then attach a policy to the IAM
486
- * user that limits federated users to only the actions and resources that they need to
487
- * access. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/best-practices.html">IAM Best Practices</a> in the
488
- * <i>IAM User Guide</i>. </p>
489
- * <p>
490
- * <b>Session duration</b>
491
- * </p>
492
- * <p>The temporary credentials are valid for the specified duration, from 900 seconds (15
493
- * minutes) up to a maximum of 129,600 seconds (36 hours). The default session duration is
494
- * 43,200 seconds (12 hours). Temporary credentials that are obtained by using Amazon Web Services account
495
- * root user credentials have a maximum duration of 3,600 seconds (1 hour).</p>
496
- * <p>
497
- * <b>Permissions</b>
498
- * </p>
499
- * <p>You can use the temporary credentials created by <code>GetFederationToken</code> in any
500
- * Amazon Web Services service except the following:</p>
501
- * <ul>
502
- * <li>
503
- * <p>You cannot call any IAM operations using the CLI or the Amazon Web Services API. </p>
504
- * </li>
505
- * <li>
506
- * <p>You cannot call any STS operations except <code>GetCallerIdentity</code>.</p>
507
- * </li>
508
- * </ul>
509
- * <p>You must pass an inline or managed <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session">session policy</a> to
510
- * this operation. You can pass a single JSON policy document to use as an inline session
511
- * policy. You can also specify up to 10 managed policies to use as managed session policies.
512
- * The plaintext that you use for both inline and managed session policies can't exceed 2,048
513
- * characters.</p>
514
- * <p>Though the session policy parameters are optional, if you do not pass a policy, then the
515
- * resulting federated user session has no permissions. When you pass session policies, the
516
- * session permissions are the intersection of the IAM user policies and the session
517
- * policies that you pass. This gives you a way to further restrict the permissions for a
518
- * federated user. You cannot use session policies to grant more permissions than those that
519
- * are defined in the permissions policy of the IAM user. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session">Session
520
- * Policies</a> in the <i>IAM User Guide</i>. For information about
521
- * using <code>GetFederationToken</code> to create temporary security credentials, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_getfederationtoken">GetFederationToken—Federation Through a Custom Identity Broker</a>. </p>
522
- * <p>You can use the credentials to access a resource that has a resource-based policy. If
523
- * that policy specifically references the federated user session in the
524
- * <code>Principal</code> element of the policy, the session has the permissions allowed by
525
- * the policy. These permissions are granted in addition to the permissions granted by the
526
- * session policies.</p>
527
- * <p>
528
- * <b>Tags</b>
529
- * </p>
530
- * <p>(Optional) You can pass tag key-value pairs to your session. These are called session
531
- * tags. For more 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
532
- * <i>IAM User Guide</i>.</p>
533
- * <note>
534
- * <p>You can create a mobile-based or browser-based app that can authenticate users
535
- * using a web identity provider like Login with Amazon, Facebook, Google, or an OpenID
536
- * Connect-compatible identity provider. In this case, we recommend that you use <a href="http://aws.amazon.com/cognito/">Amazon Cognito</a> or
537
- * <code>AssumeRoleWithWebIdentity</code>. For more information, see <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> in the
538
- * <i>IAM User Guide</i>.</p>
539
- * </note>
540
- * <p>You can also call <code>GetFederationToken</code> using the security credentials of an
541
- * Amazon Web Services account root user, but we do not recommend it. Instead, we recommend that you
542
- * create an IAM user for the purpose of the proxy application. Then attach a policy to
543
- * the IAM user that limits federated users to only the actions and resources that they
544
- * need to access. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/best-practices.html">IAM Best Practices</a> in the
545
- * <i>IAM User Guide</i>. </p>
546
- * <p>
547
- * <b>Session duration</b>
548
- * </p>
549
- * <p>The temporary credentials are valid for the specified duration, from 900 seconds (15
550
- * minutes) up to a maximum of 129,600 seconds (36 hours). The default session duration is
551
- * 43,200 seconds (12 hours). Temporary credentials that are obtained by using Amazon Web Services
552
- * account root user credentials have a maximum duration of 3,600 seconds (1 hour).</p>
553
- * <p>
554
- * <b>Permissions</b>
555
- * </p>
556
- * <p>You can use the temporary credentials created by <code>GetFederationToken</code> in
557
- * any Amazon Web Services service except the following:</p>
558
- * <ul>
559
- * <li>
560
- * <p>You cannot call any IAM operations using the CLI or the Amazon Web Services API.
561
- * </p>
562
- * </li>
563
- * <li>
564
- * <p>You cannot call any STS operations except
565
- * <code>GetCallerIdentity</code>.</p>
566
- * </li>
567
- * </ul>
568
- * <p>You must pass an inline or managed <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session">session policy</a> to
569
- * this operation. You can pass a single JSON policy document to use as an inline session
570
- * policy. You can also specify up to 10 managed policies to use as managed session
571
- * policies. The plain text that you use for both inline and managed session policies can't
572
- * exceed 2,048 characters.</p>
573
- * <p>Though the session policy parameters are optional, if you do not pass a policy, then
574
- * the resulting federated user session has no permissions. When you pass session policies,
575
- * the session permissions are the intersection of the IAM user policies and the session
576
- * policies that you pass. This gives you a way to further restrict the permissions for a
577
- * federated user. You cannot use session policies to grant more permissions than those
578
- * that are defined in the permissions policy of the IAM user. For more information, see
579
- * <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session">Session Policies</a>
580
- * in the <i>IAM User Guide</i>. For information about using
581
- * <code>GetFederationToken</code> to create temporary security credentials, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_getfederationtoken">GetFederationToken—Federation Through a Custom Identity Broker</a>. </p>
582
- * <p>You can use the credentials to access a resource that has a resource-based policy. If
583
- * that policy specifically references the federated user session in the
584
- * <code>Principal</code> element of the policy, the session has the permissions
585
- * allowed by the policy. These permissions are granted in addition to the permissions
586
- * granted by the session policies.</p>
587
- * <p>
588
- * <b>Tags</b>
589
- * </p>
590
- * <p>(Optional) You can pass tag key-value pairs to your session. These are called session
591
- * tags. For more 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
592
- * the <i>IAM User Guide</i>.</p>
593
- * <p>An administrator must grant you the permissions necessary to pass session tags. The
594
- * administrator can also create granular permissions to allow you to pass only specific
595
- * session tags. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/tutorial_attribute-based-access-control.html">Tutorial: Using
596
- * Tags for Attribute-Based Access Control</a> in the
597
- * <i>IAM User Guide</i>.</p>
598
- * <p>Tag key–value pairs are not case sensitive, but case is preserved. This means that you
599
- * cannot have separate <code>Department</code> and <code>department</code> tag keys.
600
- * Assume that the user that you are federating has the
601
- * <code>Department</code>=<code>Marketing</code> tag and you pass the
602
- * <code>department</code>=<code>engineering</code> session tag.
603
- * <code>Department</code> and <code>department</code> are not saved as separate tags,
604
- * and the session tag passed in the request takes precedence over the user tag.</p>
605
- */
37
+
606
38
  getFederationToken(args: GetFederationTokenCommandInput, options?: __HttpHandlerOptions): Promise<GetFederationTokenCommandOutput>;
607
39
  getFederationToken(args: GetFederationTokenCommandInput, cb: (err: any, data?: GetFederationTokenCommandOutput) => void): void;
608
40
  getFederationToken(args: GetFederationTokenCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: GetFederationTokenCommandOutput) => void): void;
609
- /**
610
- * <p>Returns a set of temporary credentials for an Amazon Web Services account or IAM user. The
611
- * credentials consist of an access key ID, a secret access key, and a security token.
612
- * Typically, you use <code>GetSessionToken</code> if you want to use MFA to protect
613
- * programmatic calls to specific Amazon Web Services API operations like Amazon EC2 <code>StopInstances</code>.
614
- * MFA-enabled IAM users would need to call <code>GetSessionToken</code> and submit an MFA
615
- * code that is associated with their MFA device. Using the temporary security credentials
616
- * that are returned from the call, IAM users can then make programmatic calls to API
617
- * operations that require MFA authentication. If you do not supply a correct MFA code, then
618
- * the API returns an access denied error. For a comparison of <code>GetSessionToken</code>
619
- * with the other API operations that produce temporary credentials, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html">Requesting
620
- * Temporary Security Credentials</a> and <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison">Comparing the
621
- * STS API operations</a> in the <i>IAM User Guide</i>.</p>
622
- * <p>
623
- * <b>Session Duration</b>
624
- * </p>
625
- * <p>The <code>GetSessionToken</code> operation must be called by using the long-term Amazon Web Services
626
- * security credentials of the Amazon Web Services account root user or an IAM user. Credentials that are
627
- * created by IAM users are valid for the duration that you specify. This duration can range
628
- * from 900 seconds (15 minutes) up to a maximum of 129,600 seconds (36 hours), with a default
629
- * of 43,200 seconds (12 hours). Credentials based on account credentials can range from 900
630
- * seconds (15 minutes) up to 3,600 seconds (1 hour), with a default of 1 hour. </p>
631
- * <p>
632
- * <b>Permissions</b>
633
- * </p>
634
- * <p>The temporary security credentials created by <code>GetSessionToken</code> can be used
635
- * to make API calls to any Amazon Web Services service with the following exceptions:</p>
636
- * <ul>
637
- * <li>
638
- * <p>You cannot call any IAM API operations unless MFA authentication information is
639
- * included in the request.</p>
640
- * </li>
641
- * <li>
642
- * <p>You cannot call any STS API <i>except</i>
643
- * <code>AssumeRole</code> or <code>GetCallerIdentity</code>.</p>
644
- * </li>
645
- * </ul>
646
- * <note>
647
- * <p>We recommend that you do not call <code>GetSessionToken</code> with Amazon Web Services account
648
- * root user credentials. Instead, follow our <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/best-practices.html#create-iam-users">best practices</a> by
649
- * creating one or more IAM users, giving them the necessary permissions, and using IAM
650
- * users for everyday interaction with Amazon Web Services. </p>
651
- * </note>
652
- * <p>The credentials that are returned by <code>GetSessionToken</code> are based on
653
- * permissions associated with the user whose credentials were used to call the operation. If
654
- * <code>GetSessionToken</code> is called using Amazon Web Services account root user credentials, the
655
- * temporary credentials have root user permissions. Similarly, if
656
- * <code>GetSessionToken</code> is called using the credentials of an IAM user, the
657
- * temporary credentials have the same permissions as the IAM user. </p>
658
- * <p>For more information about using <code>GetSessionToken</code> to create temporary
659
- * credentials, go to <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_getsessiontoken">Temporary
660
- * Credentials for Users in Untrusted Environments</a> in the
661
- * <i>IAM User Guide</i>. </p>
662
- */
41
+
663
42
  getSessionToken(args: GetSessionTokenCommandInput, options?: __HttpHandlerOptions): Promise<GetSessionTokenCommandOutput>;
664
43
  getSessionToken(args: GetSessionTokenCommandInput, cb: (err: any, data?: GetSessionTokenCommandOutput) => void): void;
665
44
  getSessionToken(args: GetSessionTokenCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: GetSessionTokenCommandOutput) => void): void;