aws-sdk-core 3.237.0 → 3.238.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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +11 -0
- data/VERSION +1 -1
- data/lib/aws-sdk-core/credential_provider_chain.rb +23 -0
- data/lib/aws-sdk-core/errors.rb +3 -0
- data/lib/aws-sdk-core/login_credentials.rb +229 -0
- data/lib/aws-sdk-core/plugins/user_agent.rb +3 -1
- data/lib/aws-sdk-core/shared_config.rb +18 -0
- data/lib/aws-sdk-core.rb +4 -0
- data/lib/aws-sdk-signin/client.rb +604 -0
- data/lib/aws-sdk-signin/client_api.rb +119 -0
- data/lib/aws-sdk-signin/customizations.rb +1 -0
- data/lib/aws-sdk-signin/endpoint_parameters.rb +69 -0
- data/lib/aws-sdk-signin/endpoint_provider.rb +59 -0
- data/lib/aws-sdk-signin/endpoints.rb +20 -0
- data/lib/aws-sdk-signin/errors.rb +122 -0
- data/lib/aws-sdk-signin/plugins/endpoints.rb +77 -0
- data/lib/aws-sdk-signin/resource.rb +26 -0
- data/lib/aws-sdk-signin/types.rb +299 -0
- data/lib/aws-sdk-signin.rb +63 -0
- data/lib/aws-sdk-sso/client.rb +1 -1
- data/lib/aws-sdk-sso.rb +1 -1
- data/lib/aws-sdk-ssooidc/client.rb +1 -1
- data/lib/aws-sdk-ssooidc.rb +1 -1
- data/lib/aws-sdk-sts/client.rb +73 -2
- data/lib/aws-sdk-sts/client_api.rb +46 -0
- data/lib/aws-sdk-sts/errors.rb +48 -0
- data/lib/aws-sdk-sts/types.rb +127 -0
- data/lib/aws-sdk-sts.rb +1 -1
- metadata +13 -1
|
@@ -0,0 +1,299 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# WARNING ABOUT GENERATED CODE
|
|
4
|
+
#
|
|
5
|
+
# This file is generated. See the contributing guide for more information:
|
|
6
|
+
# https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
|
|
7
|
+
#
|
|
8
|
+
# WARNING ABOUT GENERATED CODE
|
|
9
|
+
|
|
10
|
+
module Aws::Signin
|
|
11
|
+
module Types
|
|
12
|
+
|
|
13
|
+
# Error thrown for access denied scenarios with flexible HTTP status
|
|
14
|
+
# mapping
|
|
15
|
+
#
|
|
16
|
+
# Runtime HTTP Status Code Mapping:
|
|
17
|
+
#
|
|
18
|
+
# * HTTP 401 (Unauthorized): TOKEN\_EXPIRED, AUTHCODE\_EXPIRED
|
|
19
|
+
# * HTTP 403 (Forbidden): USER\_CREDENTIALS\_CHANGED,
|
|
20
|
+
# INSUFFICIENT\_PERMISSIONS
|
|
21
|
+
#
|
|
22
|
+
# The specific HTTP status code is determined at runtime based on the
|
|
23
|
+
# error enum value. Consumers should use the error field to determine
|
|
24
|
+
# the specific access denial reason.
|
|
25
|
+
#
|
|
26
|
+
# @!attribute [rw] error
|
|
27
|
+
# OAuth 2.0 error code indicating the specific type of access denial
|
|
28
|
+
# Can be TOKEN\_EXPIRED, AUTHCODE\_EXPIRED,
|
|
29
|
+
# USER\_CREDENTIALS\_CHANGED, or INSUFFICIENT\_PERMISSIONS
|
|
30
|
+
# @return [String]
|
|
31
|
+
#
|
|
32
|
+
# @!attribute [rw] message
|
|
33
|
+
# Detailed message explaining the access denial Provides specific
|
|
34
|
+
# information about why access was denied
|
|
35
|
+
# @return [String]
|
|
36
|
+
#
|
|
37
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/signin-2023-01-01/AccessDeniedException AWS API Documentation
|
|
38
|
+
#
|
|
39
|
+
class AccessDeniedException < Struct.new(
|
|
40
|
+
:error,
|
|
41
|
+
:message)
|
|
42
|
+
SENSITIVE = []
|
|
43
|
+
include Aws::Structure
|
|
44
|
+
end
|
|
45
|
+
|
|
46
|
+
# AWS credentials structure containing temporary access credentials
|
|
47
|
+
#
|
|
48
|
+
# The scoped-down, 15 minute duration AWS credentials. Scoping down will
|
|
49
|
+
# be based on CLI policy (CLI team needs to create it). Similar to cloud
|
|
50
|
+
# shell implementation.
|
|
51
|
+
#
|
|
52
|
+
# @!attribute [rw] access_key_id
|
|
53
|
+
# AWS access key ID for temporary credentials
|
|
54
|
+
# @return [String]
|
|
55
|
+
#
|
|
56
|
+
# @!attribute [rw] secret_access_key
|
|
57
|
+
# AWS secret access key for temporary credentials
|
|
58
|
+
# @return [String]
|
|
59
|
+
#
|
|
60
|
+
# @!attribute [rw] session_token
|
|
61
|
+
# AWS session token for temporary credentials
|
|
62
|
+
# @return [String]
|
|
63
|
+
#
|
|
64
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/signin-2023-01-01/AccessToken AWS API Documentation
|
|
65
|
+
#
|
|
66
|
+
class AccessToken < Struct.new(
|
|
67
|
+
:access_key_id,
|
|
68
|
+
:secret_access_key,
|
|
69
|
+
:session_token)
|
|
70
|
+
SENSITIVE = []
|
|
71
|
+
include Aws::Structure
|
|
72
|
+
end
|
|
73
|
+
|
|
74
|
+
# Input structure for CreateOAuth2Token operation
|
|
75
|
+
#
|
|
76
|
+
# Contains flattened token operation inputs for both authorization code
|
|
77
|
+
# and refresh token flows. The operation type is determined by the
|
|
78
|
+
# grant\_type parameter in the request body.
|
|
79
|
+
#
|
|
80
|
+
# @!attribute [rw] token_input
|
|
81
|
+
# Flattened token operation inputs The specific operation is
|
|
82
|
+
# determined by grant\_type in the request body
|
|
83
|
+
# @return [Types::CreateOAuth2TokenRequestBody]
|
|
84
|
+
#
|
|
85
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/signin-2023-01-01/CreateOAuth2TokenRequest AWS API Documentation
|
|
86
|
+
#
|
|
87
|
+
class CreateOAuth2TokenRequest < Struct.new(
|
|
88
|
+
:token_input)
|
|
89
|
+
SENSITIVE = []
|
|
90
|
+
include Aws::Structure
|
|
91
|
+
end
|
|
92
|
+
|
|
93
|
+
# Request body payload for CreateOAuth2Token operation
|
|
94
|
+
#
|
|
95
|
+
# The operation type is determined by the grant\_type parameter:
|
|
96
|
+
#
|
|
97
|
+
# * grant\_type=authorization\_code: Requires code, redirect\_uri,
|
|
98
|
+
# code\_verifier
|
|
99
|
+
# * grant\_type=refresh\_token: Requires refresh\_token
|
|
100
|
+
#
|
|
101
|
+
# @!attribute [rw] client_id
|
|
102
|
+
# The client identifier (ARN) used during Sign-In onboarding Required
|
|
103
|
+
# for both authorization code and refresh token flows
|
|
104
|
+
# @return [String]
|
|
105
|
+
#
|
|
106
|
+
# @!attribute [rw] grant_type
|
|
107
|
+
# OAuth 2.0 grant type - determines which flow is used Must be
|
|
108
|
+
# "authorization\_code" or "refresh\_token"
|
|
109
|
+
# @return [String]
|
|
110
|
+
#
|
|
111
|
+
# @!attribute [rw] code
|
|
112
|
+
# The authorization code received from /v1/authorize Required only
|
|
113
|
+
# when grant\_type=authorization\_code
|
|
114
|
+
# @return [String]
|
|
115
|
+
#
|
|
116
|
+
# @!attribute [rw] redirect_uri
|
|
117
|
+
# The redirect URI that must match the original authorization request
|
|
118
|
+
# Required only when grant\_type=authorization\_code
|
|
119
|
+
# @return [String]
|
|
120
|
+
#
|
|
121
|
+
# @!attribute [rw] code_verifier
|
|
122
|
+
# PKCE code verifier to prove possession of the original code
|
|
123
|
+
# challenge Required only when grant\_type=authorization\_code
|
|
124
|
+
# @return [String]
|
|
125
|
+
#
|
|
126
|
+
# @!attribute [rw] refresh_token
|
|
127
|
+
# The refresh token returned from auth\_code redemption Required only
|
|
128
|
+
# when grant\_type=refresh\_token
|
|
129
|
+
# @return [String]
|
|
130
|
+
#
|
|
131
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/signin-2023-01-01/CreateOAuth2TokenRequestBody AWS API Documentation
|
|
132
|
+
#
|
|
133
|
+
class CreateOAuth2TokenRequestBody < Struct.new(
|
|
134
|
+
:client_id,
|
|
135
|
+
:grant_type,
|
|
136
|
+
:code,
|
|
137
|
+
:redirect_uri,
|
|
138
|
+
:code_verifier,
|
|
139
|
+
:refresh_token)
|
|
140
|
+
SENSITIVE = [:refresh_token]
|
|
141
|
+
include Aws::Structure
|
|
142
|
+
end
|
|
143
|
+
|
|
144
|
+
# Output structure for CreateOAuth2Token operation
|
|
145
|
+
#
|
|
146
|
+
# Contains flattened token operation outputs for both authorization code
|
|
147
|
+
# and refresh token flows. The response content depends on the
|
|
148
|
+
# grant\_type from the original request.
|
|
149
|
+
#
|
|
150
|
+
# @!attribute [rw] token_output
|
|
151
|
+
# Flattened token operation outputs The specific response fields
|
|
152
|
+
# depend on the grant\_type used in the request
|
|
153
|
+
# @return [Types::CreateOAuth2TokenResponseBody]
|
|
154
|
+
#
|
|
155
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/signin-2023-01-01/CreateOAuth2TokenResponse AWS API Documentation
|
|
156
|
+
#
|
|
157
|
+
class CreateOAuth2TokenResponse < Struct.new(
|
|
158
|
+
:token_output)
|
|
159
|
+
SENSITIVE = []
|
|
160
|
+
include Aws::Structure
|
|
161
|
+
end
|
|
162
|
+
|
|
163
|
+
# Response body payload for CreateOAuth2Token operation
|
|
164
|
+
#
|
|
165
|
+
# The response content depends on the grant\_type from the request:
|
|
166
|
+
#
|
|
167
|
+
# * grant\_type=authorization\_code: Returns all fields including
|
|
168
|
+
# refresh\_token and id\_token
|
|
169
|
+
# * grant\_type=refresh\_token: Returns access\_token, token\_type,
|
|
170
|
+
# expires\_in, refresh\_token (no id\_token)
|
|
171
|
+
#
|
|
172
|
+
# @!attribute [rw] access_token
|
|
173
|
+
# Scoped-down AWS credentials (15 minute duration) Present for both
|
|
174
|
+
# authorization code redemption and token refresh
|
|
175
|
+
# @return [Types::AccessToken]
|
|
176
|
+
#
|
|
177
|
+
# @!attribute [rw] token_type
|
|
178
|
+
# Token type indicating this is AWS SigV4 credentials Value is
|
|
179
|
+
# "aws\_sigv4" for both flows
|
|
180
|
+
# @return [String]
|
|
181
|
+
#
|
|
182
|
+
# @!attribute [rw] expires_in
|
|
183
|
+
# Time to expiry in seconds (maximum 900) Present for both
|
|
184
|
+
# authorization code redemption and token refresh
|
|
185
|
+
# @return [Integer]
|
|
186
|
+
#
|
|
187
|
+
# @!attribute [rw] refresh_token
|
|
188
|
+
# Encrypted refresh token with cnf.jkt (SHA-256 thumbprint of
|
|
189
|
+
# presented jwk) Always present in responses (required for both flows)
|
|
190
|
+
# @return [String]
|
|
191
|
+
#
|
|
192
|
+
# @!attribute [rw] id_token
|
|
193
|
+
# ID token containing user identity information Present only in
|
|
194
|
+
# authorization code redemption response
|
|
195
|
+
# (grant\_type=authorization\_code) Not included in token refresh
|
|
196
|
+
# responses
|
|
197
|
+
# @return [String]
|
|
198
|
+
#
|
|
199
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/signin-2023-01-01/CreateOAuth2TokenResponseBody AWS API Documentation
|
|
200
|
+
#
|
|
201
|
+
class CreateOAuth2TokenResponseBody < Struct.new(
|
|
202
|
+
:access_token,
|
|
203
|
+
:token_type,
|
|
204
|
+
:expires_in,
|
|
205
|
+
:refresh_token,
|
|
206
|
+
:id_token)
|
|
207
|
+
SENSITIVE = [:access_token, :refresh_token]
|
|
208
|
+
include Aws::Structure
|
|
209
|
+
end
|
|
210
|
+
|
|
211
|
+
# Error thrown when an internal server error occurs
|
|
212
|
+
#
|
|
213
|
+
# HTTP Status Code: 500 Internal Server Error
|
|
214
|
+
#
|
|
215
|
+
# Used for unexpected server-side errors that prevent request
|
|
216
|
+
# processing.
|
|
217
|
+
#
|
|
218
|
+
# @!attribute [rw] error
|
|
219
|
+
# OAuth 2.0 error code indicating server error Will be SERVER\_ERROR
|
|
220
|
+
# for internal server errors
|
|
221
|
+
# @return [String]
|
|
222
|
+
#
|
|
223
|
+
# @!attribute [rw] message
|
|
224
|
+
# Detailed message explaining the server error May include error
|
|
225
|
+
# details for debugging purposes
|
|
226
|
+
# @return [String]
|
|
227
|
+
#
|
|
228
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/signin-2023-01-01/InternalServerException AWS API Documentation
|
|
229
|
+
#
|
|
230
|
+
class InternalServerException < Struct.new(
|
|
231
|
+
:error,
|
|
232
|
+
:message)
|
|
233
|
+
SENSITIVE = []
|
|
234
|
+
include Aws::Structure
|
|
235
|
+
end
|
|
236
|
+
|
|
237
|
+
# Error thrown when rate limit is exceeded
|
|
238
|
+
#
|
|
239
|
+
# HTTP Status Code: 429 Too Many Requests
|
|
240
|
+
#
|
|
241
|
+
# Possible OAuth2ErrorCode values:
|
|
242
|
+
#
|
|
243
|
+
# * INVALID\_REQUEST: Rate limiting, too many requests, abuse prevention
|
|
244
|
+
#
|
|
245
|
+
# Possible causes:
|
|
246
|
+
#
|
|
247
|
+
# * Too many token requests from the same client
|
|
248
|
+
# * Rate limiting based on client\_id or IP address
|
|
249
|
+
# * Abuse prevention mechanisms triggered
|
|
250
|
+
# * Service protection against excessive token generation
|
|
251
|
+
#
|
|
252
|
+
# @!attribute [rw] error
|
|
253
|
+
# OAuth 2.0 error code indicating the specific type of error Will be
|
|
254
|
+
# INVALID\_REQUEST for rate limiting scenarios
|
|
255
|
+
# @return [String]
|
|
256
|
+
#
|
|
257
|
+
# @!attribute [rw] message
|
|
258
|
+
# Detailed message about the rate limiting May include retry-after
|
|
259
|
+
# information or rate limit details
|
|
260
|
+
# @return [String]
|
|
261
|
+
#
|
|
262
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/signin-2023-01-01/TooManyRequestsError AWS API Documentation
|
|
263
|
+
#
|
|
264
|
+
class TooManyRequestsError < Struct.new(
|
|
265
|
+
:error,
|
|
266
|
+
:message)
|
|
267
|
+
SENSITIVE = []
|
|
268
|
+
include Aws::Structure
|
|
269
|
+
end
|
|
270
|
+
|
|
271
|
+
# Error thrown when request validation fails
|
|
272
|
+
#
|
|
273
|
+
# HTTP Status Code: 400 Bad Request
|
|
274
|
+
#
|
|
275
|
+
# Used for request validation errors such as malformed parameters,
|
|
276
|
+
# missing required fields, or invalid parameter values.
|
|
277
|
+
#
|
|
278
|
+
# @!attribute [rw] error
|
|
279
|
+
# OAuth 2.0 error code indicating validation failure Will be
|
|
280
|
+
# INVALID\_REQUEST for validation errors
|
|
281
|
+
# @return [String]
|
|
282
|
+
#
|
|
283
|
+
# @!attribute [rw] message
|
|
284
|
+
# Detailed message explaining the validation failure Provides specific
|
|
285
|
+
# information about which validation failed
|
|
286
|
+
# @return [String]
|
|
287
|
+
#
|
|
288
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/signin-2023-01-01/ValidationException AWS API Documentation
|
|
289
|
+
#
|
|
290
|
+
class ValidationException < Struct.new(
|
|
291
|
+
:error,
|
|
292
|
+
:message)
|
|
293
|
+
SENSITIVE = []
|
|
294
|
+
include Aws::Structure
|
|
295
|
+
end
|
|
296
|
+
|
|
297
|
+
end
|
|
298
|
+
end
|
|
299
|
+
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# WARNING ABOUT GENERATED CODE
|
|
4
|
+
#
|
|
5
|
+
# This file is generated. See the contributing guide for more information:
|
|
6
|
+
# https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
|
|
7
|
+
#
|
|
8
|
+
# WARNING ABOUT GENERATED CODE
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
unless Module.const_defined?(:Aws)
|
|
12
|
+
require 'aws-sdk-core'
|
|
13
|
+
require 'aws-sigv4'
|
|
14
|
+
end
|
|
15
|
+
|
|
16
|
+
Aws::Plugins::GlobalConfiguration.add_identifier(:signin)
|
|
17
|
+
|
|
18
|
+
# This module provides support for AWS Sign-In Service. This module is available in the
|
|
19
|
+
# `aws-sdk-signin` gem.
|
|
20
|
+
#
|
|
21
|
+
# # Client
|
|
22
|
+
#
|
|
23
|
+
# The {Client} class provides one method for each API operation. Operation
|
|
24
|
+
# methods each accept a hash of request parameters and return a response
|
|
25
|
+
# structure.
|
|
26
|
+
#
|
|
27
|
+
# signin = Aws::Signin::Client.new
|
|
28
|
+
# resp = signin.create_o_auth_2_token(params)
|
|
29
|
+
#
|
|
30
|
+
# See {Client} for more information.
|
|
31
|
+
#
|
|
32
|
+
# # Errors
|
|
33
|
+
#
|
|
34
|
+
# Errors returned from AWS Sign-In Service are defined in the
|
|
35
|
+
# {Errors} module and all extend {Errors::ServiceError}.
|
|
36
|
+
#
|
|
37
|
+
# begin
|
|
38
|
+
# # do stuff
|
|
39
|
+
# rescue Aws::Signin::Errors::ServiceError
|
|
40
|
+
# # rescues all AWS Sign-In Service API errors
|
|
41
|
+
# end
|
|
42
|
+
#
|
|
43
|
+
# See {Errors} for more information.
|
|
44
|
+
#
|
|
45
|
+
# @!group service
|
|
46
|
+
module Aws::Signin
|
|
47
|
+
autoload :Types, 'aws-sdk-signin/types'
|
|
48
|
+
autoload :ClientApi, 'aws-sdk-signin/client_api'
|
|
49
|
+
module Plugins
|
|
50
|
+
autoload :Endpoints, 'aws-sdk-signin/plugins/endpoints.rb'
|
|
51
|
+
end
|
|
52
|
+
autoload :Client, 'aws-sdk-signin/client'
|
|
53
|
+
autoload :Errors, 'aws-sdk-signin/errors'
|
|
54
|
+
autoload :Resource, 'aws-sdk-signin/resource'
|
|
55
|
+
autoload :EndpointParameters, 'aws-sdk-signin/endpoint_parameters'
|
|
56
|
+
autoload :EndpointProvider, 'aws-sdk-signin/endpoint_provider'
|
|
57
|
+
autoload :Endpoints, 'aws-sdk-signin/endpoints'
|
|
58
|
+
|
|
59
|
+
GEM_VERSION = '1.0.0'
|
|
60
|
+
|
|
61
|
+
end
|
|
62
|
+
|
|
63
|
+
require_relative 'aws-sdk-signin/customizations'
|
data/lib/aws-sdk-sso/client.rb
CHANGED
data/lib/aws-sdk-sso.rb
CHANGED
data/lib/aws-sdk-ssooidc.rb
CHANGED
data/lib/aws-sdk-sts/client.rb
CHANGED
|
@@ -2097,9 +2097,15 @@ module Aws::STS
|
|
|
2097
2097
|
req.send_request(options)
|
|
2098
2098
|
end
|
|
2099
2099
|
|
|
2100
|
-
#
|
|
2100
|
+
# Exchanges a trade-in token for temporary Amazon Web Services
|
|
2101
|
+
# credentials with the permissions associated with the assumed
|
|
2102
|
+
# principal. This operation allows you to obtain credentials for a
|
|
2103
|
+
# specific principal based on a trade-in token, enabling delegation of
|
|
2104
|
+
# access to Amazon Web Services resources.
|
|
2101
2105
|
#
|
|
2102
2106
|
# @option params [required, String] :trade_in_token
|
|
2107
|
+
# The token to exchange for temporary Amazon Web Services credentials.
|
|
2108
|
+
# This token must be valid and unexpired at the time of the request.
|
|
2103
2109
|
#
|
|
2104
2110
|
# @return [Types::GetDelegatedAccessTokenResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
|
2105
2111
|
#
|
|
@@ -2636,6 +2642,71 @@ module Aws::STS
|
|
|
2636
2642
|
req.send_request(options)
|
|
2637
2643
|
end
|
|
2638
2644
|
|
|
2645
|
+
# Returns a signed JSON Web Token (JWT) that represents the calling
|
|
2646
|
+
# Amazon Web Services identity. The returned JWT can be used to
|
|
2647
|
+
# authenticate with external services that support OIDC discovery. The
|
|
2648
|
+
# token is signed by Amazon Web Services STS and can be publicly
|
|
2649
|
+
# verified using the verification keys published at the issuer's JWKS
|
|
2650
|
+
# endpoint.
|
|
2651
|
+
#
|
|
2652
|
+
# @option params [required, Array<String>] :audience
|
|
2653
|
+
# The intended recipient of the web identity token. This value populates
|
|
2654
|
+
# the `aud` claim in the JWT and should identify the service or
|
|
2655
|
+
# application that will validate and use the token. The external service
|
|
2656
|
+
# should verify this claim to ensure the token was intended for their
|
|
2657
|
+
# use.
|
|
2658
|
+
#
|
|
2659
|
+
# @option params [Integer] :duration_seconds
|
|
2660
|
+
# The duration, in seconds, for which the JSON Web Token (JWT) will
|
|
2661
|
+
# remain valid. The value can range from 60 seconds (1 minute) to 3600
|
|
2662
|
+
# seconds (1 hour). If not specified, the default duration is 300
|
|
2663
|
+
# seconds (5 minutes). The token is designed to be short-lived and
|
|
2664
|
+
# should be used for proof of identity, then exchanged for credentials
|
|
2665
|
+
# or short-lived tokens in the external service.
|
|
2666
|
+
#
|
|
2667
|
+
# @option params [required, String] :signing_algorithm
|
|
2668
|
+
# The cryptographic algorithm to use for signing the JSON Web Token
|
|
2669
|
+
# (JWT). Valid values are RS256 (RSA with SHA-256) and ES384 (ECDSA
|
|
2670
|
+
# using P-384 curve with SHA-384).
|
|
2671
|
+
#
|
|
2672
|
+
# @option params [Array<Types::Tag>] :tags
|
|
2673
|
+
# An optional list of tags to include in the JSON Web Token (JWT). These
|
|
2674
|
+
# tags are added as custom claims to the JWT and can be used by the
|
|
2675
|
+
# downstream service for authorization decisions.
|
|
2676
|
+
#
|
|
2677
|
+
# @return [Types::GetWebIdentityTokenResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
|
2678
|
+
#
|
|
2679
|
+
# * {Types::GetWebIdentityTokenResponse#web_identity_token #web_identity_token} => String
|
|
2680
|
+
# * {Types::GetWebIdentityTokenResponse#expiration #expiration} => Time
|
|
2681
|
+
#
|
|
2682
|
+
# @example Request syntax with placeholder values
|
|
2683
|
+
#
|
|
2684
|
+
# resp = client.get_web_identity_token({
|
|
2685
|
+
# audience: ["webIdentityTokenAudienceStringType"], # required
|
|
2686
|
+
# duration_seconds: 1,
|
|
2687
|
+
# signing_algorithm: "jwtAlgorithmType", # required
|
|
2688
|
+
# tags: [
|
|
2689
|
+
# {
|
|
2690
|
+
# key: "tagKeyType", # required
|
|
2691
|
+
# value: "tagValueType", # required
|
|
2692
|
+
# },
|
|
2693
|
+
# ],
|
|
2694
|
+
# })
|
|
2695
|
+
#
|
|
2696
|
+
# @example Response structure
|
|
2697
|
+
#
|
|
2698
|
+
# resp.web_identity_token #=> String
|
|
2699
|
+
# resp.expiration #=> Time
|
|
2700
|
+
#
|
|
2701
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetWebIdentityToken AWS API Documentation
|
|
2702
|
+
#
|
|
2703
|
+
# @overload get_web_identity_token(params = {})
|
|
2704
|
+
# @param [Hash] params ({})
|
|
2705
|
+
def get_web_identity_token(params = {}, options = {})
|
|
2706
|
+
req = build_request(:get_web_identity_token, params)
|
|
2707
|
+
req.send_request(options)
|
|
2708
|
+
end
|
|
2709
|
+
|
|
2639
2710
|
# @!endgroup
|
|
2640
2711
|
|
|
2641
2712
|
# @param params ({})
|
|
@@ -2654,7 +2725,7 @@ module Aws::STS
|
|
|
2654
2725
|
tracer: tracer
|
|
2655
2726
|
)
|
|
2656
2727
|
context[:gem_name] = 'aws-sdk-core'
|
|
2657
|
-
context[:gem_version] = '3.
|
|
2728
|
+
context[:gem_version] = '3.238.0'
|
|
2658
2729
|
Seahorse::Client::Request.new(handlers, context)
|
|
2659
2730
|
end
|
|
2660
2731
|
|
|
@@ -40,13 +40,17 @@ module Aws::STS
|
|
|
40
40
|
GetFederationTokenResponse = Shapes::StructureShape.new(name: 'GetFederationTokenResponse')
|
|
41
41
|
GetSessionTokenRequest = Shapes::StructureShape.new(name: 'GetSessionTokenRequest')
|
|
42
42
|
GetSessionTokenResponse = Shapes::StructureShape.new(name: 'GetSessionTokenResponse')
|
|
43
|
+
GetWebIdentityTokenRequest = Shapes::StructureShape.new(name: 'GetWebIdentityTokenRequest')
|
|
44
|
+
GetWebIdentityTokenResponse = Shapes::StructureShape.new(name: 'GetWebIdentityTokenResponse')
|
|
43
45
|
IDPCommunicationErrorException = Shapes::StructureShape.new(name: 'IDPCommunicationErrorException', error: {"code" => "IDPCommunicationError", "httpStatusCode" => 400, "senderFault" => true})
|
|
44
46
|
IDPRejectedClaimException = Shapes::StructureShape.new(name: 'IDPRejectedClaimException', error: {"code" => "IDPRejectedClaim", "httpStatusCode" => 403, "senderFault" => true})
|
|
45
47
|
InvalidAuthorizationMessageException = Shapes::StructureShape.new(name: 'InvalidAuthorizationMessageException', error: {"code" => "InvalidAuthorizationMessageException", "httpStatusCode" => 400, "senderFault" => true})
|
|
46
48
|
InvalidIdentityTokenException = Shapes::StructureShape.new(name: 'InvalidIdentityTokenException', error: {"code" => "InvalidIdentityToken", "httpStatusCode" => 400, "senderFault" => true})
|
|
47
49
|
Issuer = Shapes::StringShape.new(name: 'Issuer')
|
|
50
|
+
JWTPayloadSizeExceededException = Shapes::StructureShape.new(name: 'JWTPayloadSizeExceededException', error: {"code" => "JWTPayloadSizeExceededException", "httpStatusCode" => 400, "senderFault" => true})
|
|
48
51
|
MalformedPolicyDocumentException = Shapes::StructureShape.new(name: 'MalformedPolicyDocumentException', error: {"code" => "MalformedPolicyDocument", "httpStatusCode" => 400, "senderFault" => true})
|
|
49
52
|
NameQualifier = Shapes::StringShape.new(name: 'NameQualifier')
|
|
53
|
+
OutboundWebIdentityFederationDisabledException = Shapes::StructureShape.new(name: 'OutboundWebIdentityFederationDisabledException', error: {"code" => "OutboundWebIdentityFederationDisabledException", "httpStatusCode" => 403, "senderFault" => true})
|
|
50
54
|
PackedPolicyTooLargeException = Shapes::StructureShape.new(name: 'PackedPolicyTooLargeException', error: {"code" => "PackedPolicyTooLarge", "httpStatusCode" => 400, "senderFault" => true})
|
|
51
55
|
PolicyDescriptorType = Shapes::StructureShape.new(name: 'PolicyDescriptorType')
|
|
52
56
|
ProvidedContext = Shapes::StructureShape.new(name: 'ProvidedContext')
|
|
@@ -54,6 +58,7 @@ module Aws::STS
|
|
|
54
58
|
RegionDisabledException = Shapes::StructureShape.new(name: 'RegionDisabledException', error: {"code" => "RegionDisabledException", "httpStatusCode" => 403, "senderFault" => true})
|
|
55
59
|
RootDurationSecondsType = Shapes::IntegerShape.new(name: 'RootDurationSecondsType')
|
|
56
60
|
SAMLAssertionType = Shapes::StringShape.new(name: 'SAMLAssertionType')
|
|
61
|
+
SessionDurationEscalationException = Shapes::StructureShape.new(name: 'SessionDurationEscalationException', error: {"code" => "SessionDurationEscalationException", "httpStatusCode" => 403, "senderFault" => true})
|
|
57
62
|
Subject = Shapes::StringShape.new(name: 'Subject')
|
|
58
63
|
SubjectType = Shapes::StringShape.new(name: 'SubjectType')
|
|
59
64
|
Tag = Shapes::StructureShape.new(name: 'Tag')
|
|
@@ -77,14 +82,18 @@ module Aws::STS
|
|
|
77
82
|
idpRejectedClaimMessage = Shapes::StringShape.new(name: 'idpRejectedClaimMessage')
|
|
78
83
|
invalidAuthorizationMessage = Shapes::StringShape.new(name: 'invalidAuthorizationMessage')
|
|
79
84
|
invalidIdentityTokenMessage = Shapes::StringShape.new(name: 'invalidIdentityTokenMessage')
|
|
85
|
+
jwtAlgorithmType = Shapes::StringShape.new(name: 'jwtAlgorithmType')
|
|
86
|
+
jwtPayloadSizeExceededException = Shapes::StringShape.new(name: 'jwtPayloadSizeExceededException')
|
|
80
87
|
malformedPolicyDocumentMessage = Shapes::StringShape.new(name: 'malformedPolicyDocumentMessage')
|
|
81
88
|
nonNegativeIntegerType = Shapes::IntegerShape.new(name: 'nonNegativeIntegerType')
|
|
89
|
+
outboundWebIdentityFederationDisabledException = Shapes::StringShape.new(name: 'outboundWebIdentityFederationDisabledException')
|
|
82
90
|
packedPolicyTooLargeMessage = Shapes::StringShape.new(name: 'packedPolicyTooLargeMessage')
|
|
83
91
|
policyDescriptorListType = Shapes::ListShape.new(name: 'policyDescriptorListType')
|
|
84
92
|
regionDisabledMessage = Shapes::StringShape.new(name: 'regionDisabledMessage')
|
|
85
93
|
roleDurationSecondsType = Shapes::IntegerShape.new(name: 'roleDurationSecondsType')
|
|
86
94
|
roleSessionNameType = Shapes::StringShape.new(name: 'roleSessionNameType')
|
|
87
95
|
serialNumberType = Shapes::StringShape.new(name: 'serialNumberType')
|
|
96
|
+
sessionDurationEscalationException = Shapes::StringShape.new(name: 'sessionDurationEscalationException')
|
|
88
97
|
sessionPolicyDocumentType = Shapes::StringShape.new(name: 'sessionPolicyDocumentType')
|
|
89
98
|
sourceIdentityType = Shapes::StringShape.new(name: 'sourceIdentityType')
|
|
90
99
|
tagKeyListType = Shapes::ListShape.new(name: 'tagKeyListType')
|
|
@@ -99,6 +108,10 @@ module Aws::STS
|
|
|
99
108
|
userIdType = Shapes::StringShape.new(name: 'userIdType')
|
|
100
109
|
userNameType = Shapes::StringShape.new(name: 'userNameType')
|
|
101
110
|
webIdentitySubjectType = Shapes::StringShape.new(name: 'webIdentitySubjectType')
|
|
111
|
+
webIdentityTokenAudienceListType = Shapes::ListShape.new(name: 'webIdentityTokenAudienceListType')
|
|
112
|
+
webIdentityTokenAudienceStringType = Shapes::StringShape.new(name: 'webIdentityTokenAudienceStringType')
|
|
113
|
+
webIdentityTokenDurationSecondsType = Shapes::IntegerShape.new(name: 'webIdentityTokenDurationSecondsType')
|
|
114
|
+
webIdentityTokenType = Shapes::StringShape.new(name: 'webIdentityTokenType')
|
|
102
115
|
|
|
103
116
|
AssumeRoleRequest.add_member(:role_arn, Shapes::ShapeRef.new(shape: arnType, required: true, location_name: "RoleArn"))
|
|
104
117
|
AssumeRoleRequest.add_member(:role_session_name, Shapes::ShapeRef.new(shape: roleSessionNameType, required: true, location_name: "RoleSessionName"))
|
|
@@ -233,6 +246,16 @@ module Aws::STS
|
|
|
233
246
|
GetSessionTokenResponse.add_member(:credentials, Shapes::ShapeRef.new(shape: Credentials, location_name: "Credentials"))
|
|
234
247
|
GetSessionTokenResponse.struct_class = Types::GetSessionTokenResponse
|
|
235
248
|
|
|
249
|
+
GetWebIdentityTokenRequest.add_member(:audience, Shapes::ShapeRef.new(shape: webIdentityTokenAudienceListType, required: true, location_name: "Audience"))
|
|
250
|
+
GetWebIdentityTokenRequest.add_member(:duration_seconds, Shapes::ShapeRef.new(shape: webIdentityTokenDurationSecondsType, location_name: "DurationSeconds"))
|
|
251
|
+
GetWebIdentityTokenRequest.add_member(:signing_algorithm, Shapes::ShapeRef.new(shape: jwtAlgorithmType, required: true, location_name: "SigningAlgorithm"))
|
|
252
|
+
GetWebIdentityTokenRequest.add_member(:tags, Shapes::ShapeRef.new(shape: tagListType, location_name: "Tags"))
|
|
253
|
+
GetWebIdentityTokenRequest.struct_class = Types::GetWebIdentityTokenRequest
|
|
254
|
+
|
|
255
|
+
GetWebIdentityTokenResponse.add_member(:web_identity_token, Shapes::ShapeRef.new(shape: webIdentityTokenType, location_name: "WebIdentityToken"))
|
|
256
|
+
GetWebIdentityTokenResponse.add_member(:expiration, Shapes::ShapeRef.new(shape: dateType, location_name: "Expiration"))
|
|
257
|
+
GetWebIdentityTokenResponse.struct_class = Types::GetWebIdentityTokenResponse
|
|
258
|
+
|
|
236
259
|
IDPCommunicationErrorException.add_member(:message, Shapes::ShapeRef.new(shape: idpCommunicationErrorMessage, location_name: "message"))
|
|
237
260
|
IDPCommunicationErrorException.struct_class = Types::IDPCommunicationErrorException
|
|
238
261
|
|
|
@@ -245,9 +268,15 @@ module Aws::STS
|
|
|
245
268
|
InvalidIdentityTokenException.add_member(:message, Shapes::ShapeRef.new(shape: invalidIdentityTokenMessage, location_name: "message"))
|
|
246
269
|
InvalidIdentityTokenException.struct_class = Types::InvalidIdentityTokenException
|
|
247
270
|
|
|
271
|
+
JWTPayloadSizeExceededException.add_member(:message, Shapes::ShapeRef.new(shape: jwtPayloadSizeExceededException, location_name: "message"))
|
|
272
|
+
JWTPayloadSizeExceededException.struct_class = Types::JWTPayloadSizeExceededException
|
|
273
|
+
|
|
248
274
|
MalformedPolicyDocumentException.add_member(:message, Shapes::ShapeRef.new(shape: malformedPolicyDocumentMessage, location_name: "message"))
|
|
249
275
|
MalformedPolicyDocumentException.struct_class = Types::MalformedPolicyDocumentException
|
|
250
276
|
|
|
277
|
+
OutboundWebIdentityFederationDisabledException.add_member(:message, Shapes::ShapeRef.new(shape: outboundWebIdentityFederationDisabledException, location_name: "message"))
|
|
278
|
+
OutboundWebIdentityFederationDisabledException.struct_class = Types::OutboundWebIdentityFederationDisabledException
|
|
279
|
+
|
|
251
280
|
PackedPolicyTooLargeException.add_member(:message, Shapes::ShapeRef.new(shape: packedPolicyTooLargeMessage, location_name: "message"))
|
|
252
281
|
PackedPolicyTooLargeException.struct_class = Types::PackedPolicyTooLargeException
|
|
253
282
|
|
|
@@ -263,6 +292,9 @@ module Aws::STS
|
|
|
263
292
|
RegionDisabledException.add_member(:message, Shapes::ShapeRef.new(shape: regionDisabledMessage, location_name: "message"))
|
|
264
293
|
RegionDisabledException.struct_class = Types::RegionDisabledException
|
|
265
294
|
|
|
295
|
+
SessionDurationEscalationException.add_member(:message, Shapes::ShapeRef.new(shape: sessionDurationEscalationException, location_name: "message"))
|
|
296
|
+
SessionDurationEscalationException.struct_class = Types::SessionDurationEscalationException
|
|
297
|
+
|
|
266
298
|
Tag.add_member(:key, Shapes::ShapeRef.new(shape: tagKeyType, required: true, location_name: "Key"))
|
|
267
299
|
Tag.add_member(:value, Shapes::ShapeRef.new(shape: tagValueType, required: true, location_name: "Value"))
|
|
268
300
|
Tag.struct_class = Types::Tag
|
|
@@ -273,6 +305,8 @@ module Aws::STS
|
|
|
273
305
|
|
|
274
306
|
tagListType.member = Shapes::ShapeRef.new(shape: Tag)
|
|
275
307
|
|
|
308
|
+
webIdentityTokenAudienceListType.member = Shapes::ShapeRef.new(shape: webIdentityTokenAudienceStringType)
|
|
309
|
+
|
|
276
310
|
|
|
277
311
|
# @api private
|
|
278
312
|
API = Seahorse::Model::Api.new.tap do |api|
|
|
@@ -382,6 +416,7 @@ module Aws::STS
|
|
|
382
416
|
o.output = Shapes::ShapeRef.new(shape: GetDelegatedAccessTokenResponse)
|
|
383
417
|
o.errors << Shapes::ShapeRef.new(shape: ExpiredTradeInTokenException)
|
|
384
418
|
o.errors << Shapes::ShapeRef.new(shape: RegionDisabledException)
|
|
419
|
+
o.errors << Shapes::ShapeRef.new(shape: PackedPolicyTooLargeException)
|
|
385
420
|
end)
|
|
386
421
|
|
|
387
422
|
api.add_operation(:get_federation_token, Seahorse::Model::Operation.new.tap do |o|
|
|
@@ -403,6 +438,17 @@ module Aws::STS
|
|
|
403
438
|
o.output = Shapes::ShapeRef.new(shape: GetSessionTokenResponse)
|
|
404
439
|
o.errors << Shapes::ShapeRef.new(shape: RegionDisabledException)
|
|
405
440
|
end)
|
|
441
|
+
|
|
442
|
+
api.add_operation(:get_web_identity_token, Seahorse::Model::Operation.new.tap do |o|
|
|
443
|
+
o.name = "GetWebIdentityToken"
|
|
444
|
+
o.http_method = "POST"
|
|
445
|
+
o.http_request_uri = "/"
|
|
446
|
+
o.input = Shapes::ShapeRef.new(shape: GetWebIdentityTokenRequest)
|
|
447
|
+
o.output = Shapes::ShapeRef.new(shape: GetWebIdentityTokenResponse)
|
|
448
|
+
o.errors << Shapes::ShapeRef.new(shape: SessionDurationEscalationException)
|
|
449
|
+
o.errors << Shapes::ShapeRef.new(shape: OutboundWebIdentityFederationDisabledException)
|
|
450
|
+
o.errors << Shapes::ShapeRef.new(shape: JWTPayloadSizeExceededException)
|
|
451
|
+
end)
|
|
406
452
|
end
|
|
407
453
|
|
|
408
454
|
end
|