aws-sdk-core 3.171.1 → 3.199.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 +363 -0
- data/VERSION +1 -1
- data/lib/aws-defaults/default_configuration.rb +4 -4
- data/lib/aws-sdk-core/binary/decode_handler.rb +3 -9
- data/lib/aws-sdk-core/binary/encode_handler.rb +1 -1
- data/lib/aws-sdk-core/binary/event_builder.rb +34 -37
- data/lib/aws-sdk-core/binary/event_stream_decoder.rb +1 -0
- data/lib/aws-sdk-core/binary/event_stream_encoder.rb +4 -3
- data/lib/aws-sdk-core/cbor/cbor_engine.rb +19 -0
- data/lib/aws-sdk-core/cbor/decoder.rb +310 -0
- data/lib/aws-sdk-core/cbor/encoder.rb +243 -0
- data/lib/aws-sdk-core/cbor.rb +106 -0
- data/lib/aws-sdk-core/client_stubs.rb +18 -14
- data/lib/aws-sdk-core/credential_provider.rb +4 -1
- data/lib/aws-sdk-core/ec2_metadata.rb +1 -1
- data/lib/aws-sdk-core/ecs_credentials.rb +78 -11
- data/lib/aws-sdk-core/endpoints/matchers.rb +18 -10
- data/lib/aws-sdk-core/endpoints.rb +6 -2
- data/lib/aws-sdk-core/error_handler.rb +41 -0
- data/lib/aws-sdk-core/errors.rb +3 -3
- data/lib/aws-sdk-core/event_emitter.rb +0 -16
- data/lib/aws-sdk-core/ini_parser.rb +7 -0
- data/lib/aws-sdk-core/instance_profile_credentials.rb +55 -32
- data/lib/aws-sdk-core/json/builder.rb +8 -1
- data/lib/aws-sdk-core/json/error_handler.rb +15 -10
- data/lib/aws-sdk-core/json/handler.rb +12 -6
- data/lib/aws-sdk-core/json/json_engine.rb +3 -1
- data/lib/aws-sdk-core/json/oj_engine.rb +7 -1
- data/lib/aws-sdk-core/json/parser.rb +33 -3
- data/lib/aws-sdk-core/json.rb +43 -14
- data/lib/aws-sdk-core/log/formatter.rb +6 -0
- data/lib/aws-sdk-core/lru_cache.rb +75 -0
- data/lib/aws-sdk-core/pageable_response.rb +3 -1
- data/lib/aws-sdk-core/param_validator.rb +9 -4
- data/lib/aws-sdk-core/plugins/checksum_algorithm.rb +5 -3
- data/lib/aws-sdk-core/plugins/client_metrics_plugin.rb +1 -0
- data/lib/aws-sdk-core/plugins/client_metrics_send_plugin.rb +14 -2
- data/lib/aws-sdk-core/plugins/credentials_configuration.rb +2 -0
- data/lib/aws-sdk-core/plugins/global_configuration.rb +8 -9
- data/lib/aws-sdk-core/plugins/http_checksum.rb +2 -1
- data/lib/aws-sdk-core/plugins/invocation_id.rb +1 -11
- data/lib/aws-sdk-core/plugins/logging.rb +2 -0
- data/lib/aws-sdk-core/plugins/protocols/api_gateway.rb +3 -1
- data/lib/aws-sdk-core/plugins/protocols/ec2.rb +2 -24
- data/lib/aws-sdk-core/plugins/protocols/json_rpc.rb +6 -8
- data/lib/aws-sdk-core/plugins/protocols/query.rb +4 -2
- data/lib/aws-sdk-core/plugins/protocols/rest_json.rb +3 -15
- data/lib/aws-sdk-core/plugins/protocols/rest_xml.rb +3 -0
- data/lib/aws-sdk-core/plugins/protocols/rpc_v2.rb +17 -0
- data/lib/aws-sdk-core/plugins/regional_endpoint.rb +109 -33
- data/lib/aws-sdk-core/plugins/request_compression.rb +226 -0
- data/lib/aws-sdk-core/plugins/retry_errors.rb +12 -3
- data/lib/aws-sdk-core/plugins/sign.rb +24 -13
- data/lib/aws-sdk-core/plugins/stub_responses.rb +1 -0
- data/lib/aws-sdk-core/plugins/user_agent.rb +152 -14
- data/lib/aws-sdk-core/process_credentials.rb +45 -27
- data/lib/aws-sdk-core/query/ec2_handler.rb +27 -0
- data/lib/aws-sdk-core/query/ec2_param_builder.rb +5 -7
- data/lib/aws-sdk-core/query/handler.rb +4 -4
- data/lib/aws-sdk-core/query/param_builder.rb +2 -2
- data/lib/aws-sdk-core/query.rb +2 -1
- data/lib/aws-sdk-core/refreshing_credentials.rb +12 -12
- data/lib/aws-sdk-core/rest/content_type_handler.rb +60 -0
- data/lib/aws-sdk-core/rest/handler.rb +3 -4
- data/lib/aws-sdk-core/rest/request/body.rb +32 -5
- data/lib/aws-sdk-core/rest/request/endpoint.rb +24 -4
- data/lib/aws-sdk-core/rest/request/headers.rb +15 -7
- data/lib/aws-sdk-core/rest/request/querystring_builder.rb +62 -36
- data/lib/aws-sdk-core/rest/response/body.rb +15 -1
- data/lib/aws-sdk-core/rest/response/header_list_parser.rb +79 -0
- data/lib/aws-sdk-core/rest/response/headers.rb +8 -3
- data/lib/aws-sdk-core/rest.rb +1 -0
- data/lib/aws-sdk-core/rpc_v2/builder.rb +62 -0
- data/lib/aws-sdk-core/rpc_v2/content_type_handler.rb +45 -0
- data/lib/aws-sdk-core/rpc_v2/error_handler.rb +84 -0
- data/lib/aws-sdk-core/rpc_v2/handler.rb +74 -0
- data/lib/aws-sdk-core/rpc_v2/parser.rb +90 -0
- data/lib/aws-sdk-core/rpc_v2.rb +6 -0
- data/lib/aws-sdk-core/shared_config.rb +48 -18
- data/lib/aws-sdk-core/sso_credentials.rb +1 -1
- data/lib/aws-sdk-core/stubbing/protocols/rpc_v2.rb +41 -0
- data/lib/aws-sdk-core/stubbing/stub_data.rb +11 -0
- data/lib/aws-sdk-core/util.rb +39 -0
- data/lib/aws-sdk-core/waiters/poller.rb +4 -2
- data/lib/aws-sdk-core/xml/builder.rb +17 -9
- data/lib/aws-sdk-core/xml/error_handler.rb +32 -42
- data/lib/aws-sdk-core/xml/parser/frame.rb +4 -20
- data/lib/aws-sdk-core/xml/parser/stack.rb +2 -0
- data/lib/aws-sdk-core/xml/parser.rb +2 -6
- data/lib/aws-sdk-core.rb +7 -2
- data/lib/aws-sdk-sso/client.rb +94 -46
- data/lib/aws-sdk-sso/endpoint_provider.rb +30 -24
- data/lib/aws-sdk-sso/endpoints.rb +1 -0
- data/lib/aws-sdk-sso/plugins/endpoints.rb +4 -2
- data/lib/aws-sdk-sso.rb +1 -1
- data/lib/aws-sdk-ssooidc/client.rb +479 -74
- data/lib/aws-sdk-ssooidc/client_api.rb +78 -1
- data/lib/aws-sdk-ssooidc/endpoint_provider.rb +30 -24
- data/lib/aws-sdk-ssooidc/endpoints.rb +15 -0
- data/lib/aws-sdk-ssooidc/errors.rb +52 -0
- data/lib/aws-sdk-ssooidc/plugins/endpoints.rb +6 -2
- data/lib/aws-sdk-ssooidc/types.rb +372 -51
- data/lib/aws-sdk-ssooidc.rb +1 -1
- data/lib/aws-sdk-sts/client.rb +219 -157
- data/lib/aws-sdk-sts/client_api.rb +20 -9
- data/lib/aws-sdk-sts/endpoint_provider.rb +81 -78
- data/lib/aws-sdk-sts/endpoints.rb +1 -0
- data/lib/aws-sdk-sts/plugins/endpoints.rb +4 -2
- data/lib/aws-sdk-sts/presigner.rb +1 -1
- data/lib/aws-sdk-sts/types.rb +49 -11
- data/lib/aws-sdk-sts.rb +1 -1
- data/lib/seahorse/client/async_base.rb +1 -1
- data/lib/seahorse/client/async_response.rb +19 -0
- data/lib/seahorse/client/base.rb +18 -7
- data/lib/seahorse/client/configuration.rb +0 -4
- data/lib/seahorse/client/h2/handler.rb +1 -0
- data/lib/seahorse/client/handler.rb +1 -1
- data/lib/seahorse/client/net_http/connection_pool.rb +3 -9
- data/lib/seahorse/client/net_http/patches.rb +1 -4
- data/lib/seahorse/client/plugin.rb +9 -0
- data/lib/seahorse/client/plugins/endpoint.rb +0 -1
- data/lib/seahorse/client/plugins/h2.rb +3 -3
- data/lib/seahorse/client/plugins/net_http.rb +48 -16
- data/lib/seahorse/client/plugins/request_callback.rb +31 -0
- data/lib/seahorse/client/response.rb +6 -0
- data/lib/seahorse/model/operation.rb +3 -0
- data/lib/seahorse/model/shapes.rb +2 -2
- data/sig/aws-sdk-core/client_stubs.rbs +10 -0
- data/sig/aws-sdk-core/errors.rbs +22 -0
- data/sig/aws-sdk-core/resources/collection.rbs +21 -0
- data/sig/aws-sdk-core/structure.rbs +4 -0
- data/sig/aws-sdk-core/waiters/errors.rbs +20 -0
- data/sig/aws-sdk-core.rbs +7 -0
- data/sig/seahorse/client/base.rbs +25 -0
- data/sig/seahorse/client/handler_builder.rbs +16 -0
- data/sig/seahorse/client/response.rbs +61 -0
- metadata +44 -17
- /data/lib/aws-sdk-core/xml/parser/{engines/libxml.rb → libxml_engine.rb} +0 -0
- /data/lib/aws-sdk-core/xml/parser/{engines/nokogiri.rb → nokogiri_engine.rb} +0 -0
- /data/lib/aws-sdk-core/xml/parser/{engines/oga.rb → oga_engine.rb} +0 -0
- /data/lib/aws-sdk-core/xml/parser/{engines/ox.rb → ox_engine.rb} +0 -0
- /data/lib/aws-sdk-core/xml/parser/{engines/rexml.rb → rexml_engine.rb} +0 -0
data/lib/aws-sdk-sso/client.rb
CHANGED
|
@@ -22,12 +22,14 @@ require 'aws-sdk-core/plugins/endpoint_pattern.rb'
|
|
|
22
22
|
require 'aws-sdk-core/plugins/response_paging.rb'
|
|
23
23
|
require 'aws-sdk-core/plugins/stub_responses.rb'
|
|
24
24
|
require 'aws-sdk-core/plugins/idempotency_token.rb'
|
|
25
|
+
require 'aws-sdk-core/plugins/invocation_id.rb'
|
|
25
26
|
require 'aws-sdk-core/plugins/jsonvalue_converter.rb'
|
|
26
27
|
require 'aws-sdk-core/plugins/client_metrics_plugin.rb'
|
|
27
28
|
require 'aws-sdk-core/plugins/client_metrics_send_plugin.rb'
|
|
28
29
|
require 'aws-sdk-core/plugins/transfer_encoding.rb'
|
|
29
30
|
require 'aws-sdk-core/plugins/http_checksum.rb'
|
|
30
31
|
require 'aws-sdk-core/plugins/checksum_algorithm.rb'
|
|
32
|
+
require 'aws-sdk-core/plugins/request_compression.rb'
|
|
31
33
|
require 'aws-sdk-core/plugins/defaults_mode.rb'
|
|
32
34
|
require 'aws-sdk-core/plugins/recursion_detection.rb'
|
|
33
35
|
require 'aws-sdk-core/plugins/sign.rb'
|
|
@@ -71,12 +73,14 @@ module Aws::SSO
|
|
|
71
73
|
add_plugin(Aws::Plugins::ResponsePaging)
|
|
72
74
|
add_plugin(Aws::Plugins::StubResponses)
|
|
73
75
|
add_plugin(Aws::Plugins::IdempotencyToken)
|
|
76
|
+
add_plugin(Aws::Plugins::InvocationId)
|
|
74
77
|
add_plugin(Aws::Plugins::JsonvalueConverter)
|
|
75
78
|
add_plugin(Aws::Plugins::ClientMetricsPlugin)
|
|
76
79
|
add_plugin(Aws::Plugins::ClientMetricsSendPlugin)
|
|
77
80
|
add_plugin(Aws::Plugins::TransferEncoding)
|
|
78
81
|
add_plugin(Aws::Plugins::HttpChecksum)
|
|
79
82
|
add_plugin(Aws::Plugins::ChecksumAlgorithm)
|
|
83
|
+
add_plugin(Aws::Plugins::RequestCompression)
|
|
80
84
|
add_plugin(Aws::Plugins::DefaultsMode)
|
|
81
85
|
add_plugin(Aws::Plugins::RecursionDetection)
|
|
82
86
|
add_plugin(Aws::Plugins::Sign)
|
|
@@ -85,6 +89,11 @@ module Aws::SSO
|
|
|
85
89
|
|
|
86
90
|
# @overload initialize(options)
|
|
87
91
|
# @param [Hash] options
|
|
92
|
+
#
|
|
93
|
+
# @option options [Array<Seahorse::Client::Plugin>] :plugins ([]])
|
|
94
|
+
# A list of plugins to apply to the client. Each plugin is either a
|
|
95
|
+
# class name or an instance of a plugin class.
|
|
96
|
+
#
|
|
88
97
|
# @option options [required, Aws::CredentialProvider] :credentials
|
|
89
98
|
# Your AWS credentials. This can be an instance of any one of the
|
|
90
99
|
# following classes:
|
|
@@ -190,10 +199,20 @@ module Aws::SSO
|
|
|
190
199
|
# Set to true to disable SDK automatically adding host prefix
|
|
191
200
|
# to default service endpoint when available.
|
|
192
201
|
#
|
|
193
|
-
# @option options [
|
|
194
|
-
#
|
|
195
|
-
#
|
|
196
|
-
#
|
|
202
|
+
# @option options [Boolean] :disable_request_compression (false)
|
|
203
|
+
# When set to 'true' the request body will not be compressed
|
|
204
|
+
# for supported operations.
|
|
205
|
+
#
|
|
206
|
+
# @option options [String, URI::HTTPS, URI::HTTP] :endpoint
|
|
207
|
+
# Normally you should not configure the `:endpoint` option
|
|
208
|
+
# directly. This is normally constructed from the `:region`
|
|
209
|
+
# option. Configuring `:endpoint` is normally reserved for
|
|
210
|
+
# connecting to test or custom endpoints. The endpoint should
|
|
211
|
+
# be a URI formatted like:
|
|
212
|
+
#
|
|
213
|
+
# 'http://example.com'
|
|
214
|
+
# 'https://example.com'
|
|
215
|
+
# 'http://example.com:123'
|
|
197
216
|
#
|
|
198
217
|
# @option options [Integer] :endpoint_cache_max_entries (1000)
|
|
199
218
|
# Used for the maximum size limit of the LRU cache storing endpoints data
|
|
@@ -210,6 +229,10 @@ module Aws::SSO
|
|
|
210
229
|
# @option options [Boolean] :endpoint_discovery (false)
|
|
211
230
|
# When set to `true`, endpoint discovery will be enabled for operations when available.
|
|
212
231
|
#
|
|
232
|
+
# @option options [Boolean] :ignore_configured_endpoint_urls
|
|
233
|
+
# Setting to true disables use of endpoint URLs provided via environment
|
|
234
|
+
# variables and the shared configuration file.
|
|
235
|
+
#
|
|
213
236
|
# @option options [Aws::Log::Formatter] :log_formatter (Aws::Log::Formatter.default)
|
|
214
237
|
# The log formatter.
|
|
215
238
|
#
|
|
@@ -230,6 +253,11 @@ module Aws::SSO
|
|
|
230
253
|
# Used when loading credentials from the shared credentials file
|
|
231
254
|
# at HOME/.aws/credentials. When not specified, 'default' is used.
|
|
232
255
|
#
|
|
256
|
+
# @option options [Integer] :request_min_compression_size_bytes (10240)
|
|
257
|
+
# The minimum size in bytes that triggers compression for request
|
|
258
|
+
# bodies. The value must be non-negative integer value between 0
|
|
259
|
+
# and 10485780 bytes inclusive.
|
|
260
|
+
#
|
|
233
261
|
# @option options [Proc] :retry_backoff
|
|
234
262
|
# A proc or lambda used for backoff. Defaults to 2**retries * retry_base_delay.
|
|
235
263
|
# This option is only used in the `legacy` retry mode.
|
|
@@ -274,6 +302,11 @@ module Aws::SSO
|
|
|
274
302
|
# throttling. This is a provisional mode that may change behavior
|
|
275
303
|
# in the future.
|
|
276
304
|
#
|
|
305
|
+
# @option options [String] :sdk_ua_app_id
|
|
306
|
+
# A unique and opaque application ID that is appended to the
|
|
307
|
+
# User-Agent header as app/sdk_ua_app_id. It should have a
|
|
308
|
+
# maximum length of 50. This variable is sourced from environment
|
|
309
|
+
# variable AWS_SDK_UA_APP_ID or the shared config profile attribute sdk_ua_app_id.
|
|
277
310
|
#
|
|
278
311
|
# @option options [String] :secret_access_key
|
|
279
312
|
#
|
|
@@ -317,50 +350,65 @@ module Aws::SSO
|
|
|
317
350
|
# @option options [Aws::SSO::EndpointProvider] :endpoint_provider
|
|
318
351
|
# The endpoint provider used to resolve endpoints. Any object that responds to `#resolve_endpoint(parameters)` where `parameters` is a Struct similar to `Aws::SSO::EndpointParameters`
|
|
319
352
|
#
|
|
320
|
-
# @option options [
|
|
321
|
-
#
|
|
322
|
-
#
|
|
323
|
-
#
|
|
324
|
-
#
|
|
325
|
-
#
|
|
326
|
-
#
|
|
327
|
-
#
|
|
328
|
-
#
|
|
329
|
-
#
|
|
330
|
-
#
|
|
331
|
-
# @option options [Float] :
|
|
332
|
-
#
|
|
333
|
-
#
|
|
334
|
-
#
|
|
335
|
-
#
|
|
336
|
-
#
|
|
337
|
-
#
|
|
338
|
-
#
|
|
339
|
-
#
|
|
340
|
-
#
|
|
341
|
-
#
|
|
342
|
-
#
|
|
343
|
-
#
|
|
344
|
-
#
|
|
345
|
-
#
|
|
346
|
-
#
|
|
347
|
-
#
|
|
353
|
+
# @option options [Float] :http_continue_timeout (1)
|
|
354
|
+
# The number of seconds to wait for a 100-continue response before sending the
|
|
355
|
+
# request body. This option has no effect unless the request has "Expect"
|
|
356
|
+
# header set to "100-continue". Defaults to `nil` which disables this
|
|
357
|
+
# behaviour. This value can safely be set per request on the session.
|
|
358
|
+
#
|
|
359
|
+
# @option options [Float] :http_idle_timeout (5)
|
|
360
|
+
# The number of seconds a connection is allowed to sit idle before it
|
|
361
|
+
# is considered stale. Stale connections are closed and removed from the
|
|
362
|
+
# pool before making a request.
|
|
363
|
+
#
|
|
364
|
+
# @option options [Float] :http_open_timeout (15)
|
|
365
|
+
# The default number of seconds to wait for response data.
|
|
366
|
+
# This value can safely be set per-request on the session.
|
|
367
|
+
#
|
|
368
|
+
# @option options [URI::HTTP,String] :http_proxy
|
|
369
|
+
# A proxy to send requests through. Formatted like 'http://proxy.com:123'.
|
|
370
|
+
#
|
|
371
|
+
# @option options [Float] :http_read_timeout (60)
|
|
372
|
+
# The default number of seconds to wait for response data.
|
|
373
|
+
# This value can safely be set per-request on the session.
|
|
374
|
+
#
|
|
375
|
+
# @option options [Boolean] :http_wire_trace (false)
|
|
376
|
+
# When `true`, HTTP debug output will be sent to the `:logger`.
|
|
377
|
+
#
|
|
378
|
+
# @option options [Proc] :on_chunk_received
|
|
379
|
+
# When a Proc object is provided, it will be used as callback when each chunk
|
|
380
|
+
# of the response body is received. It provides three arguments: the chunk,
|
|
381
|
+
# the number of bytes received, and the total number of
|
|
382
|
+
# bytes in the response (or nil if the server did not send a `content-length`).
|
|
383
|
+
#
|
|
384
|
+
# @option options [Proc] :on_chunk_sent
|
|
385
|
+
# When a Proc object is provided, it will be used as callback when each chunk
|
|
386
|
+
# of the request body is sent. It provides three arguments: the chunk,
|
|
387
|
+
# the number of bytes read from the body, and the total number of
|
|
388
|
+
# bytes in the body.
|
|
389
|
+
#
|
|
390
|
+
# @option options [Boolean] :raise_response_errors (true)
|
|
391
|
+
# When `true`, response errors are raised.
|
|
392
|
+
#
|
|
393
|
+
# @option options [String] :ssl_ca_bundle
|
|
394
|
+
# Full path to the SSL certificate authority bundle file that should be used when
|
|
395
|
+
# verifying peer certificates. If you do not pass `:ssl_ca_bundle` or
|
|
396
|
+
# `:ssl_ca_directory` the the system default will be used if available.
|
|
397
|
+
#
|
|
398
|
+
# @option options [String] :ssl_ca_directory
|
|
399
|
+
# Full path of the directory that contains the unbundled SSL certificate
|
|
400
|
+
# authority files for verifying peer certificates. If you do
|
|
401
|
+
# not pass `:ssl_ca_bundle` or `:ssl_ca_directory` the the system
|
|
402
|
+
# default will be used if available.
|
|
348
403
|
#
|
|
349
|
-
# @option options [
|
|
350
|
-
#
|
|
351
|
-
# connection.
|
|
404
|
+
# @option options [String] :ssl_ca_store
|
|
405
|
+
# Sets the X509::Store to verify peer certificate.
|
|
352
406
|
#
|
|
353
|
-
# @option options [
|
|
354
|
-
#
|
|
355
|
-
# verifying peer certificates. If you do not pass
|
|
356
|
-
# `:ssl_ca_bundle` or `:ssl_ca_directory` the the system default
|
|
357
|
-
# will be used if available.
|
|
407
|
+
# @option options [Float] :ssl_timeout
|
|
408
|
+
# Sets the SSL timeout in seconds
|
|
358
409
|
#
|
|
359
|
-
# @option options [
|
|
360
|
-
#
|
|
361
|
-
# authority files for verifying peer certificates. If you do
|
|
362
|
-
# not pass `:ssl_ca_bundle` or `:ssl_ca_directory` the the
|
|
363
|
-
# system default will be used if available.
|
|
410
|
+
# @option options [Boolean] :ssl_verify_peer (true)
|
|
411
|
+
# When `true`, SSL peer certificates are verified when establishing a connection.
|
|
364
412
|
#
|
|
365
413
|
def initialize(*args)
|
|
366
414
|
super
|
|
@@ -585,7 +633,7 @@ module Aws::SSO
|
|
|
585
633
|
params: params,
|
|
586
634
|
config: config)
|
|
587
635
|
context[:gem_name] = 'aws-sdk-core'
|
|
588
|
-
context[:gem_version] = '3.
|
|
636
|
+
context[:gem_version] = '3.199.0'
|
|
589
637
|
Seahorse::Client::Request.new(handlers, context)
|
|
590
638
|
end
|
|
591
639
|
|
|
@@ -14,36 +14,42 @@ module Aws::SSO
|
|
|
14
14
|
use_dual_stack = parameters.use_dual_stack
|
|
15
15
|
use_fips = parameters.use_fips
|
|
16
16
|
endpoint = parameters.endpoint
|
|
17
|
-
if
|
|
18
|
-
if Aws::Endpoints::Matchers.set?(endpoint) && (url = Aws::Endpoints::Matchers.parse_url(endpoint))
|
|
19
|
-
if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
|
|
20
|
-
raise ArgumentError, "Invalid Configuration: FIPS and custom endpoint are not supported"
|
|
21
|
-
end
|
|
22
|
-
if Aws::Endpoints::Matchers.boolean_equals?(use_dual_stack, true)
|
|
23
|
-
raise ArgumentError, "Invalid Configuration: Dualstack and custom endpoint are not supported"
|
|
24
|
-
end
|
|
25
|
-
return Aws::Endpoints::Endpoint.new(url: endpoint, headers: {}, properties: {})
|
|
26
|
-
end
|
|
27
|
-
if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true) && Aws::Endpoints::Matchers.boolean_equals?(use_dual_stack, true)
|
|
28
|
-
if Aws::Endpoints::Matchers.boolean_equals?(true, Aws::Endpoints::Matchers.attr(partition_result, "supportsFIPS")) && Aws::Endpoints::Matchers.boolean_equals?(true, Aws::Endpoints::Matchers.attr(partition_result, "supportsDualStack"))
|
|
29
|
-
return Aws::Endpoints::Endpoint.new(url: "https://portal.sso-fips.#{region}.#{partition_result['dualStackDnsSuffix']}", headers: {}, properties: {})
|
|
30
|
-
end
|
|
31
|
-
raise ArgumentError, "FIPS and DualStack are enabled, but this partition does not support one or both"
|
|
32
|
-
end
|
|
17
|
+
if Aws::Endpoints::Matchers.set?(endpoint)
|
|
33
18
|
if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
|
|
34
|
-
|
|
35
|
-
return Aws::Endpoints::Endpoint.new(url: "https://portal.sso-fips.#{region}.#{partition_result['dnsSuffix']}", headers: {}, properties: {})
|
|
36
|
-
end
|
|
37
|
-
raise ArgumentError, "FIPS is enabled but this partition does not support FIPS"
|
|
19
|
+
raise ArgumentError, "Invalid Configuration: FIPS and custom endpoint are not supported"
|
|
38
20
|
end
|
|
39
21
|
if Aws::Endpoints::Matchers.boolean_equals?(use_dual_stack, true)
|
|
40
|
-
|
|
41
|
-
|
|
22
|
+
raise ArgumentError, "Invalid Configuration: Dualstack and custom endpoint are not supported"
|
|
23
|
+
end
|
|
24
|
+
return Aws::Endpoints::Endpoint.new(url: endpoint, headers: {}, properties: {})
|
|
25
|
+
end
|
|
26
|
+
if Aws::Endpoints::Matchers.set?(region)
|
|
27
|
+
if (partition_result = Aws::Endpoints::Matchers.aws_partition(region))
|
|
28
|
+
if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true) && Aws::Endpoints::Matchers.boolean_equals?(use_dual_stack, true)
|
|
29
|
+
if Aws::Endpoints::Matchers.boolean_equals?(true, Aws::Endpoints::Matchers.attr(partition_result, "supportsFIPS")) && Aws::Endpoints::Matchers.boolean_equals?(true, Aws::Endpoints::Matchers.attr(partition_result, "supportsDualStack"))
|
|
30
|
+
return Aws::Endpoints::Endpoint.new(url: "https://portal.sso-fips.#{region}.#{partition_result['dualStackDnsSuffix']}", headers: {}, properties: {})
|
|
31
|
+
end
|
|
32
|
+
raise ArgumentError, "FIPS and DualStack are enabled, but this partition does not support one or both"
|
|
33
|
+
end
|
|
34
|
+
if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
|
|
35
|
+
if Aws::Endpoints::Matchers.boolean_equals?(true, Aws::Endpoints::Matchers.attr(partition_result, "supportsFIPS"))
|
|
36
|
+
if Aws::Endpoints::Matchers.string_equals?("aws-us-gov", Aws::Endpoints::Matchers.attr(partition_result, "name"))
|
|
37
|
+
return Aws::Endpoints::Endpoint.new(url: "https://portal.sso.#{region}.amazonaws.com", headers: {}, properties: {})
|
|
38
|
+
end
|
|
39
|
+
return Aws::Endpoints::Endpoint.new(url: "https://portal.sso-fips.#{region}.#{partition_result['dnsSuffix']}", headers: {}, properties: {})
|
|
40
|
+
end
|
|
41
|
+
raise ArgumentError, "FIPS is enabled but this partition does not support FIPS"
|
|
42
|
+
end
|
|
43
|
+
if Aws::Endpoints::Matchers.boolean_equals?(use_dual_stack, true)
|
|
44
|
+
if Aws::Endpoints::Matchers.boolean_equals?(true, Aws::Endpoints::Matchers.attr(partition_result, "supportsDualStack"))
|
|
45
|
+
return Aws::Endpoints::Endpoint.new(url: "https://portal.sso.#{region}.#{partition_result['dualStackDnsSuffix']}", headers: {}, properties: {})
|
|
46
|
+
end
|
|
47
|
+
raise ArgumentError, "DualStack is enabled but this partition does not support DualStack"
|
|
42
48
|
end
|
|
43
|
-
|
|
49
|
+
return Aws::Endpoints::Endpoint.new(url: "https://portal.sso.#{region}.#{partition_result['dnsSuffix']}", headers: {}, properties: {})
|
|
44
50
|
end
|
|
45
|
-
return Aws::Endpoints::Endpoint.new(url: "https://portal.sso.#{region}.#{partition_result['dnsSuffix']}", headers: {}, properties: {})
|
|
46
51
|
end
|
|
52
|
+
raise ArgumentError, "Invalid Configuration: Missing Region"
|
|
47
53
|
raise ArgumentError, 'No endpoint could be resolved'
|
|
48
54
|
|
|
49
55
|
end
|
|
@@ -14,6 +14,7 @@ module Aws::SSO
|
|
|
14
14
|
option(
|
|
15
15
|
:endpoint_provider,
|
|
16
16
|
doc_type: 'Aws::SSO::EndpointProvider',
|
|
17
|
+
rbs_type: 'untyped',
|
|
17
18
|
docstring: 'The endpoint provider used to resolve endpoints. Any '\
|
|
18
19
|
'object that responds to `#resolve_endpoint(parameters)` '\
|
|
19
20
|
'where `parameters` is a Struct similar to '\
|
|
@@ -25,16 +26,17 @@ module Aws::SSO
|
|
|
25
26
|
# @api private
|
|
26
27
|
class Handler < Seahorse::Client::Handler
|
|
27
28
|
def call(context)
|
|
28
|
-
# If endpoint was discovered, do not resolve or apply the endpoint.
|
|
29
29
|
unless context[:discovered_endpoint]
|
|
30
30
|
params = parameters_for_operation(context)
|
|
31
31
|
endpoint = context.config.endpoint_provider.resolve_endpoint(params)
|
|
32
32
|
|
|
33
33
|
context.http_request.endpoint = endpoint.url
|
|
34
34
|
apply_endpoint_headers(context, endpoint.headers)
|
|
35
|
+
|
|
36
|
+
context[:endpoint_params] = params
|
|
37
|
+
context[:endpoint_properties] = endpoint.properties
|
|
35
38
|
end
|
|
36
39
|
|
|
37
|
-
context[:endpoint_params] = params
|
|
38
40
|
context[:auth_scheme] =
|
|
39
41
|
Aws::Endpoints.resolve_auth_scheme(context, endpoint)
|
|
40
42
|
|