aws-sdk-core 3.226.3 → 3.233.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 +53 -0
- data/VERSION +1 -1
- data/lib/aws-sdk-core/endpoints.rb +37 -13
- data/lib/aws-sdk-core/plugins/credentials_configuration.rb +75 -59
- data/lib/aws-sdk-core/plugins/sign.rb +23 -28
- data/lib/aws-sdk-core/plugins/stub_responses.rb +6 -0
- data/lib/aws-sdk-core/plugins/user_agent.rb +2 -1
- data/lib/aws-sdk-core/shared_config.rb +10 -0
- data/lib/aws-sdk-core/static_token_provider.rb +1 -2
- data/lib/aws-sdk-core/token.rb +3 -3
- data/lib/aws-sdk-core/token_provider.rb +4 -0
- data/lib/aws-sdk-core/token_provider_chain.rb +2 -6
- data/lib/aws-sdk-sso/client.rb +24 -17
- data/lib/aws-sdk-sso/endpoint_provider.rb +2 -2
- data/lib/aws-sdk-sso.rb +1 -1
- data/lib/aws-sdk-ssooidc/client.rb +43 -23
- data/lib/aws-sdk-ssooidc/client_api.rb +5 -0
- data/lib/aws-sdk-ssooidc/errors.rb +10 -0
- data/lib/aws-sdk-ssooidc/types.rb +27 -15
- data/lib/aws-sdk-ssooidc.rb +1 -1
- data/lib/aws-sdk-sts/client.rb +24 -17
- data/lib/aws-sdk-sts/customizations.rb +0 -1
- data/lib/aws-sdk-sts/presigner.rb +2 -6
- data/lib/aws-sdk-sts.rb +1 -1
- metadata +15 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f37e6727e5279cbbd03f6df6988d8c24c0eded16e39ec239431e8aed96fbc696
|
4
|
+
data.tar.gz: 37b13a3e128f56672ed802a5b5450be306d5eeef608222c6cc2dda891356d28d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7cf0124bf65cf6618b4c14919800bb881920fb6673f34ac6302448dc642c5f7dd051e844904a82e0134c02ab1ea58f1e3b3ccb7d455b9541e09c0c0e45795bae
|
7
|
+
data.tar.gz: 33d8cb8d286ab0384e2c18d7f43cac14d93147ad3f5b54b6636bea55d4581c2b81cb520c12bab5ea5eceec34ee635d23a04c1038582e2fd69e198636191f66ba
|
data/CHANGELOG.md
CHANGED
@@ -1,6 +1,59 @@
|
|
1
1
|
Unreleased Changes
|
2
2
|
------------------
|
3
3
|
|
4
|
+
3.233.0 (2025-09-23)
|
5
|
+
------------------
|
6
|
+
|
7
|
+
* Feature - Updated Aws::SSOOIDC::Client with the latest API changes.
|
8
|
+
|
9
|
+
* Feature - This release includes exception definition and documentation updates.
|
10
|
+
|
11
|
+
3.232.0 (2025-08-28)
|
12
|
+
------------------
|
13
|
+
|
14
|
+
* Feature - Updated Aws::SSO::Client with the latest API changes.
|
15
|
+
|
16
|
+
* Feature - Remove incorrect endpoint tests
|
17
|
+
|
18
|
+
3.231.0 (2025-08-26)
|
19
|
+
------------------
|
20
|
+
|
21
|
+
* Feature - Remove incorrect endpoint tests
|
22
|
+
|
23
|
+
* Feature - Add support for ENV as credential source for `AssumeRoleCredentials`.
|
24
|
+
|
25
|
+
3.230.0 (2025-08-21)
|
26
|
+
------------------
|
27
|
+
|
28
|
+
* Feature - Remove incorrect endpoint tests
|
29
|
+
|
30
|
+
3.229.0 (2025-08-04)
|
31
|
+
------------------
|
32
|
+
|
33
|
+
* Feature - Updated Aws::STS::Client with the latest API changes.
|
34
|
+
|
35
|
+
* Feature - Updated Aws::SSOOIDC::Client with the latest API changes.
|
36
|
+
|
37
|
+
* Feature - Updated Aws::SSO::Client with the latest API changes.
|
38
|
+
|
39
|
+
3.228.0 (2025-07-31)
|
40
|
+
------------------
|
41
|
+
|
42
|
+
* Feature - Add `bigdecimal` as a dependency. For systems that are not able to build native extension gems, prefer the locally installed `bigdecimal` with `bundle install --prefer-local`.
|
43
|
+
|
44
|
+
3.227.0 (2025-07-21)
|
45
|
+
------------------
|
46
|
+
|
47
|
+
* Feature - Updated Aws::STS::Client with the latest API changes.
|
48
|
+
|
49
|
+
* Feature - Updated Aws::SSOOIDC::Client with the latest API changes.
|
50
|
+
|
51
|
+
* Feature - Updated Aws::SSO::Client with the latest API changes.
|
52
|
+
|
53
|
+
* Feature - Support an auth scheme signing preference list using `ENV['AWS_AUTH_SCHEME_PREFERENCE']` or `auth_scheme_preference` in shared configuration.
|
54
|
+
|
55
|
+
* Feature - Support metric tracking for Bedrock Bearer tokens.
|
56
|
+
|
4
57
|
3.226.3 (2025-07-17)
|
5
58
|
------------------
|
6
59
|
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
3.
|
1
|
+
3.233.0
|
@@ -19,19 +19,28 @@ require 'aws-sigv4'
|
|
19
19
|
module Aws
|
20
20
|
# @api private
|
21
21
|
module Endpoints
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
22
|
+
# Maps config auth scheme preferences to endpoint auth scheme names.
|
23
|
+
ENDPOINT_AUTH_PREFERENCE_MAP = {
|
24
|
+
'sigv4' => %w[sigv4 sigv4-s3express],
|
25
|
+
'sigv4a' => ['sigv4a'],
|
26
|
+
'httpBearerAuth' => ['bearer'],
|
27
|
+
'noAuth' => ['none']
|
28
|
+
}.freeze
|
29
|
+
SUPPORTED_ENDPOINT_AUTH = ENDPOINT_AUTH_PREFERENCE_MAP.values.flatten.freeze
|
30
|
+
|
31
|
+
# Maps configured auth scheme preferences to modeled auth traits.
|
32
|
+
MODELED_AUTH_PREFERENCE_MAP = {
|
33
|
+
'sigv4' => 'aws.auth#sigv4',
|
34
|
+
'sigv4a' => 'aws.auth#sigv4a',
|
35
|
+
'httpBearerAuth' => 'smithy.api#httpBearerAuth',
|
36
|
+
'noAuth' => 'smithy.api#noAuth'
|
37
|
+
}.freeze
|
38
|
+
SUPPORTED_MODELED_AUTH = MODELED_AUTH_PREFERENCE_MAP.values.freeze
|
28
39
|
|
29
40
|
class << self
|
30
41
|
def resolve_auth_scheme(context, endpoint)
|
31
42
|
if endpoint && (auth_schemes = endpoint.properties['authSchemes'])
|
32
|
-
auth_scheme = auth_schemes.
|
33
|
-
Aws::Plugins::Sign::SUPPORTED_AUTH_TYPES.include?(scheme['name'])
|
34
|
-
end
|
43
|
+
auth_scheme = endpoint_auth_scheme_preference(auth_schemes, context.config.auth_scheme_preference)
|
35
44
|
raise 'No supported auth scheme for this endpoint.' unless auth_scheme
|
36
45
|
|
37
46
|
merge_signing_defaults(auth_scheme, context.config)
|
@@ -42,6 +51,16 @@ module Aws
|
|
42
51
|
|
43
52
|
private
|
44
53
|
|
54
|
+
def endpoint_auth_scheme_preference(auth_schemes, preferred_auth)
|
55
|
+
ordered_auth = preferred_auth.each_with_object([]) do |pref, list|
|
56
|
+
next unless ENDPOINT_AUTH_PREFERENCE_MAP.key?(pref)
|
57
|
+
|
58
|
+
ENDPOINT_AUTH_PREFERENCE_MAP[pref].each { |name| list << { 'name' => name } }
|
59
|
+
end
|
60
|
+
ordered_auth += auth_schemes
|
61
|
+
ordered_auth.find { |auth| SUPPORTED_ENDPOINT_AUTH.include?(auth['name']) }
|
62
|
+
end
|
63
|
+
|
45
64
|
def merge_signing_defaults(auth_scheme, config)
|
46
65
|
if %w[sigv4 sigv4a sigv4-s3express].include?(auth_scheme['name'])
|
47
66
|
auth_scheme['signingName'] ||= sigv4_name(config)
|
@@ -64,13 +83,12 @@ module Aws
|
|
64
83
|
end
|
65
84
|
|
66
85
|
def sigv4_name(config)
|
67
|
-
config.api.metadata['signingName'] ||
|
68
|
-
config.api.metadata['endpointPrefix']
|
86
|
+
config.api.metadata['signingName'] || config.api.metadata['endpointPrefix']
|
69
87
|
end
|
70
88
|
|
71
89
|
def default_auth_scheme(context)
|
72
|
-
if (
|
73
|
-
auth =
|
90
|
+
if (modeled_auth = default_api_auth(context))
|
91
|
+
auth = modeled_auth_scheme_preference(modeled_auth, context.config.auth_scheme_preference)
|
74
92
|
case auth
|
75
93
|
when 'aws.auth#sigv4', 'aws.auth#sigv4a'
|
76
94
|
auth_scheme = { 'name' => auth.split('#').last }
|
@@ -93,6 +111,12 @@ module Aws
|
|
93
111
|
end
|
94
112
|
end
|
95
113
|
|
114
|
+
def modeled_auth_scheme_preference(modeled_auth, preferred_auth)
|
115
|
+
ordered_auth = preferred_auth.map { |pref| MODELED_AUTH_PREFERENCE_MAP[pref] }.compact
|
116
|
+
ordered_auth += modeled_auth
|
117
|
+
ordered_auth.find { |auth| SUPPORTED_MODELED_AUTH.include?(auth) }
|
118
|
+
end
|
119
|
+
|
96
120
|
def default_api_auth(context)
|
97
121
|
context.config.api.operation(context.operation_name)['auth'] ||
|
98
122
|
context.config.api.metadata['auth']
|
@@ -14,64 +14,68 @@ module Aws
|
|
14
14
|
|
15
15
|
option(:account_id, doc_type: String, docstring: '')
|
16
16
|
|
17
|
-
option(
|
17
|
+
option(
|
18
|
+
:profile,
|
18
19
|
doc_default: 'default',
|
19
20
|
doc_type: String,
|
20
|
-
docstring:
|
21
|
-
Used when loading credentials from the shared credentials file
|
22
|
-
|
21
|
+
docstring: <<~DOCS)
|
22
|
+
Used when loading credentials from the shared credentials file at `HOME/.aws/credentials`.
|
23
|
+
When not specified, 'default' is used.
|
23
24
|
DOCS
|
24
25
|
|
25
|
-
option(
|
26
|
+
option(
|
27
|
+
:credentials,
|
26
28
|
required: true,
|
27
29
|
doc_type: 'Aws::CredentialProvider',
|
28
30
|
rbs_type: 'untyped',
|
29
|
-
docstring:
|
30
|
-
Your AWS credentials. This can be
|
31
|
-
following classes:
|
31
|
+
docstring: <<~DOCS
|
32
|
+
Your AWS credentials used for authentication. This can be any class that includes and implements
|
33
|
+
`Aws::CredentialProvider`, or instance of any one of the following classes:
|
32
34
|
|
33
|
-
* `Aws::Credentials` - Used for configuring static, non-refreshing
|
34
|
-
|
35
|
+
* `Aws::Credentials` - Used for configuring static, non-refreshing
|
36
|
+
credentials.
|
35
37
|
|
36
|
-
* `Aws::SharedCredentials` - Used for loading static credentials from a
|
37
|
-
|
38
|
+
* `Aws::SharedCredentials` - Used for loading static credentials from a
|
39
|
+
shared file, such as `~/.aws/config`.
|
38
40
|
|
39
|
-
* `Aws::AssumeRoleCredentials` - Used when you need to assume a role.
|
41
|
+
* `Aws::AssumeRoleCredentials` - Used when you need to assume a role.
|
40
42
|
|
41
|
-
* `Aws::AssumeRoleWebIdentityCredentials` - Used when you need to
|
42
|
-
|
43
|
+
* `Aws::AssumeRoleWebIdentityCredentials` - Used when you need to
|
44
|
+
assume a role after providing credentials via the web.
|
43
45
|
|
44
|
-
* `Aws::SSOCredentials` - Used for loading credentials from AWS SSO using an
|
45
|
-
|
46
|
+
* `Aws::SSOCredentials` - Used for loading credentials from AWS SSO using an
|
47
|
+
access token generated from `aws login`.
|
46
48
|
|
47
|
-
* `Aws::ProcessCredentials` - Used for loading credentials from a
|
48
|
-
|
49
|
+
* `Aws::ProcessCredentials` - Used for loading credentials from a
|
50
|
+
process that outputs to stdout.
|
49
51
|
|
50
|
-
* `Aws::InstanceProfileCredentials` - Used for loading credentials
|
51
|
-
|
52
|
+
* `Aws::InstanceProfileCredentials` - Used for loading credentials
|
53
|
+
from an EC2 IMDS on an EC2 instance.
|
52
54
|
|
53
|
-
* `Aws::ECSCredentials` - Used for loading credentials from
|
54
|
-
|
55
|
+
* `Aws::ECSCredentials` - Used for loading credentials from
|
56
|
+
instances running in ECS.
|
55
57
|
|
56
|
-
* `Aws::CognitoIdentityCredentials` - Used for loading credentials
|
57
|
-
|
58
|
+
* `Aws::CognitoIdentityCredentials` - Used for loading credentials
|
59
|
+
from the Cognito Identity service.
|
58
60
|
|
59
|
-
When `:credentials` are not configured directly, the following
|
60
|
-
locations will be searched for credentials:
|
61
|
+
When `:credentials` are not configured directly, the following locations will be searched for credentials:
|
61
62
|
|
62
|
-
* `Aws.config[:credentials]`
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
*
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
63
|
+
* `Aws.config[:credentials]`
|
64
|
+
|
65
|
+
* The `:access_key_id`, `:secret_access_key`, `:session_token`, and
|
66
|
+
`:account_id` options.
|
67
|
+
|
68
|
+
* `ENV['AWS_ACCESS_KEY_ID']`, `ENV['AWS_SECRET_ACCESS_KEY']`,
|
69
|
+
`ENV['AWS_SESSION_TOKEN']`, and `ENV['AWS_ACCOUNT_ID']`.
|
70
|
+
|
71
|
+
* `~/.aws/credentials`
|
72
|
+
|
73
|
+
* `~/.aws/config`
|
74
|
+
|
75
|
+
* EC2/ECS IMDS instance profile - When used by default, the timeouts are very aggressive.
|
76
|
+
Construct and pass an instance of `Aws::InstanceProfileCredentials` or `Aws::ECSCredentials` to
|
77
|
+
enable retries and extended timeouts. Instance profile credential fetching can be disabled by
|
78
|
+
setting `ENV['AWS_EC2_METADATA_DISABLED']` to `true`.
|
75
79
|
DOCS
|
76
80
|
) do |config|
|
77
81
|
CredentialProviderChain.new(config).resolve
|
@@ -81,31 +85,43 @@ locations will be searched for credentials:
|
|
81
85
|
|
82
86
|
option(:instance_profile_credentials_timeout, 1)
|
83
87
|
|
84
|
-
option(
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
following classes:
|
88
|
+
option(
|
89
|
+
:token_provider,
|
90
|
+
doc_type: 'Aws::TokenProvider',
|
91
|
+
rbs_type: 'untyped',
|
92
|
+
docstring: <<~DOCS
|
93
|
+
Your Bearer token used for authentication. This can be any class that includes and implements
|
94
|
+
`Aws::TokenProvider`, or instance of any one of the following classes:
|
91
95
|
|
92
|
-
* `Aws::StaticTokenProvider` - Used for configuring static, non-refreshing
|
93
|
-
|
96
|
+
* `Aws::StaticTokenProvider` - Used for configuring static, non-refreshing
|
97
|
+
tokens.
|
94
98
|
|
95
|
-
* `Aws::SSOTokenProvider` - Used for loading tokens from AWS SSO using an
|
96
|
-
|
99
|
+
* `Aws::SSOTokenProvider` - Used for loading tokens from AWS SSO using an
|
100
|
+
access token generated from `aws login`.
|
97
101
|
|
98
|
-
When `:token_provider` is not configured directly, the `Aws::TokenProviderChain`
|
99
|
-
will be used to search for tokens configured for your profile in shared configuration files.
|
100
|
-
|
102
|
+
When `:token_provider` is not configured directly, the `Aws::TokenProviderChain`
|
103
|
+
will be used to search for tokens configured for your profile in shared configuration files.
|
104
|
+
DOCS
|
101
105
|
) do |config|
|
102
|
-
|
103
|
-
StaticTokenProvider.new('token')
|
104
|
-
else
|
105
|
-
TokenProviderChain.new(config).resolve
|
106
|
-
end
|
106
|
+
TokenProviderChain.new(config).resolve
|
107
107
|
end
|
108
108
|
|
109
|
+
option(
|
110
|
+
:auth_scheme_preference,
|
111
|
+
doc_type: 'Array<String>',
|
112
|
+
rbs_type: 'Array[String]',
|
113
|
+
docstring: <<~DOCS
|
114
|
+
A list of preferred authentication schemes to use when making a request. Supported values are:
|
115
|
+
`sigv4`, `sigv4a`, `httpBearerAuth`, and `noAuth`. When set using `ENV['AWS_AUTH_SCHEME_PREFERENCE']` or in
|
116
|
+
shared config as `auth_scheme_preference`, the value should be a comma-separated list.
|
117
|
+
DOCS
|
118
|
+
) do |config|
|
119
|
+
value =
|
120
|
+
ENV['AWS_AUTH_SCHEME_PREFERENCE'] ||
|
121
|
+
Aws.shared_config.auth_scheme_preference(profile: config.profile) ||
|
122
|
+
''
|
123
|
+
value.gsub(' ', '').gsub("\t", '').split(',')
|
124
|
+
end
|
109
125
|
end
|
110
126
|
end
|
111
127
|
end
|
@@ -13,9 +13,6 @@ module Aws
|
|
13
13
|
option(:sigv4_region)
|
14
14
|
option(:unsigned_operations, default: [])
|
15
15
|
|
16
|
-
supported_auth_types = %w[sigv4 bearer sigv4-s3express sigv4a none]
|
17
|
-
SUPPORTED_AUTH_TYPES = supported_auth_types.freeze
|
18
|
-
|
19
16
|
def add_handlers(handlers, cfg)
|
20
17
|
operations = cfg.api.operation_names - cfg.unsigned_operations
|
21
18
|
handlers.add(Handler, step: :sign, operations: operations)
|
@@ -32,7 +29,7 @@ module Aws
|
|
32
29
|
}
|
33
30
|
SignatureV4.new(auth_scheme, config, sigv4_overrides)
|
34
31
|
when 'bearer'
|
35
|
-
Bearer.new
|
32
|
+
Bearer.new(config)
|
36
33
|
else
|
37
34
|
NullSigner.new
|
38
35
|
end
|
@@ -41,7 +38,6 @@ module Aws
|
|
41
38
|
class Handler < Seahorse::Client::Handler
|
42
39
|
def call(context)
|
43
40
|
# Skip signing if using sigv2 signing from s3_signer in S3
|
44
|
-
credentials = nil
|
45
41
|
unless v2_signing?(context.config)
|
46
42
|
signer = Sign.signer_for(
|
47
43
|
context[:auth_scheme],
|
@@ -49,18 +45,22 @@ module Aws
|
|
49
45
|
context[:sigv4_region],
|
50
46
|
context[:sigv4_credentials]
|
51
47
|
)
|
52
|
-
credentials = signer.credentials if signer.is_a?(SignatureV4)
|
53
48
|
signer.sign(context)
|
54
49
|
end
|
55
|
-
with_metrics(
|
50
|
+
with_metrics(signer) { @handler.call(context) }
|
56
51
|
end
|
57
52
|
|
58
53
|
private
|
59
54
|
|
60
|
-
def with_metrics(
|
61
|
-
|
62
|
-
|
63
|
-
|
55
|
+
def with_metrics(signer, &block)
|
56
|
+
case signer
|
57
|
+
when SignatureV4
|
58
|
+
Aws::Plugins::UserAgent.metric(*signer.credentials.metrics, &block)
|
59
|
+
when Bearer
|
60
|
+
Aws::Plugins::UserAgent.metric(*signer.token_provider.metrics, &block)
|
61
|
+
else
|
62
|
+
block.call
|
63
|
+
end
|
64
64
|
end
|
65
65
|
|
66
66
|
def v2_signing?(config)
|
@@ -72,21 +72,19 @@ module Aws
|
|
72
72
|
|
73
73
|
# @api private
|
74
74
|
class Bearer
|
75
|
-
def initialize
|
75
|
+
def initialize(config)
|
76
|
+
@token_provider = config.token_provider
|
76
77
|
end
|
77
78
|
|
79
|
+
attr_reader :token_provider
|
80
|
+
|
78
81
|
def sign(context)
|
79
82
|
if context.http_request.endpoint.scheme != 'https'
|
80
|
-
raise ArgumentError,
|
81
|
-
'Unable to use bearer authorization on non https endpoint.'
|
83
|
+
raise ArgumentError, 'Unable to use bearer authorization on non https endpoint.'
|
82
84
|
end
|
85
|
+
raise Errors::MissingBearerTokenError unless @token_provider && @token_provider.set?
|
83
86
|
|
84
|
-
|
85
|
-
|
86
|
-
raise Errors::MissingBearerTokenError unless token_provider&.set?
|
87
|
-
|
88
|
-
context.http_request.headers['Authorization'] =
|
89
|
-
"Bearer #{token_provider.token.token}"
|
87
|
+
context.http_request.headers['Authorization'] = "Bearer #{@token_provider.token.token}"
|
90
88
|
end
|
91
89
|
|
92
90
|
def presign_url(*args)
|
@@ -100,16 +98,11 @@ module Aws
|
|
100
98
|
|
101
99
|
# @api private
|
102
100
|
class SignatureV4
|
103
|
-
attr_reader :signer
|
104
|
-
|
105
101
|
def initialize(auth_scheme, config, sigv4_overrides = {})
|
106
102
|
scheme_name = auth_scheme['name']
|
107
|
-
|
108
103
|
unless %w[sigv4 sigv4a sigv4-s3express].include?(scheme_name)
|
109
|
-
raise ArgumentError,
|
110
|
-
"Expected sigv4, sigv4a, or sigv4-s3express auth scheme, got #{scheme_name}"
|
104
|
+
raise ArgumentError, "Expected sigv4, sigv4a, or sigv4-s3express auth scheme, got #{scheme_name}"
|
111
105
|
end
|
112
|
-
|
113
106
|
region = if scheme_name == 'sigv4a'
|
114
107
|
auth_scheme['signingRegionSet'].join(',')
|
115
108
|
else
|
@@ -121,8 +114,8 @@ module Aws
|
|
121
114
|
region: sigv4_overrides[:region] || config.sigv4_region || region,
|
122
115
|
credentials_provider: sigv4_overrides[:credentials] || config.credentials,
|
123
116
|
signing_algorithm: scheme_name.to_sym,
|
124
|
-
uri_escape_path:
|
125
|
-
normalize_path:
|
117
|
+
uri_escape_path: !auth_scheme['disableDoubleEncoding'],
|
118
|
+
normalize_path: !auth_scheme['disableNormalizePath'],
|
126
119
|
unsigned_headers: %w[content-length user-agent x-amzn-trace-id expect transfer-encoding connection]
|
127
120
|
)
|
128
121
|
rescue Aws::Sigv4::Errors::MissingCredentialsError
|
@@ -130,6 +123,8 @@ module Aws
|
|
130
123
|
end
|
131
124
|
end
|
132
125
|
|
126
|
+
attr_reader :signer
|
127
|
+
|
133
128
|
def sign(context)
|
134
129
|
req = context.http_request
|
135
130
|
|
@@ -29,6 +29,12 @@ requests are made, and retries are disabled.
|
|
29
29
|
end
|
30
30
|
end
|
31
31
|
|
32
|
+
option(:token_provider) do |config|
|
33
|
+
if config.stub_responses
|
34
|
+
StaticTokenProvider.new('stubbed-token')
|
35
|
+
end
|
36
|
+
end
|
37
|
+
|
32
38
|
option(:stubs) { {} }
|
33
39
|
option(:stubs_mutex) { Mutex.new }
|
34
40
|
option(:api_requests) { [] }
|
@@ -203,6 +203,7 @@ module Aws
|
|
203
203
|
config_reader(
|
204
204
|
:region,
|
205
205
|
:account_id_endpoint_mode,
|
206
|
+
:auth_scheme_preference,
|
206
207
|
:sigv4a_signing_region_set,
|
207
208
|
:ca_bundle,
|
208
209
|
:credential_process,
|
@@ -368,6 +369,15 @@ module Aws
|
|
368
369
|
)
|
369
370
|
when 'EcsContainer'
|
370
371
|
ECSCredentials.new
|
372
|
+
when 'Environment'
|
373
|
+
creds = Credentials.new(
|
374
|
+
ENV['AWS_ACCESS_KEY_ID'],
|
375
|
+
ENV['AWS_SECRET_ACCESS_KEY'],
|
376
|
+
ENV['AWS_SESSION_TOKEN'],
|
377
|
+
account_id: ENV['AWS_ACCOUNT_ID']
|
378
|
+
)
|
379
|
+
creds.metrics = ['CREDENTIALS_ENV_VARS']
|
380
|
+
creds
|
371
381
|
else
|
372
382
|
raise Errors::InvalidCredentialSourceError, "Unsupported credential_source: #{credential_source}"
|
373
383
|
end
|
@@ -2,12 +2,11 @@
|
|
2
2
|
|
3
3
|
module Aws
|
4
4
|
class StaticTokenProvider
|
5
|
-
|
6
5
|
include TokenProvider
|
7
6
|
|
8
7
|
# @param [String] token
|
9
8
|
# @param [Time] expiration
|
10
|
-
def initialize(token, expiration=nil)
|
9
|
+
def initialize(token, expiration = nil)
|
11
10
|
@token = Token.new(token, expiration)
|
12
11
|
end
|
13
12
|
end
|
data/lib/aws-sdk-core/token.rb
CHANGED
@@ -3,9 +3,9 @@
|
|
3
3
|
module Aws
|
4
4
|
class Token
|
5
5
|
|
6
|
-
# @param [String] token
|
7
|
-
# @param [Time] expiration
|
8
|
-
def initialize(token, expiration=nil)
|
6
|
+
# @param [String, nil] token
|
7
|
+
# @param [Time, nil] expiration
|
8
|
+
def initialize(token, expiration = nil)
|
9
9
|
@token = token
|
10
10
|
@expiration = expiration
|
11
11
|
end
|
@@ -27,17 +27,13 @@ module Aws
|
|
27
27
|
|
28
28
|
def static_profile_sso_token(options)
|
29
29
|
if Aws.shared_config.config_enabled? && options[:config] && options[:config].profile
|
30
|
-
Aws.shared_config.sso_token_from_config(
|
31
|
-
profile: options[:config].profile
|
32
|
-
)
|
30
|
+
Aws.shared_config.sso_token_from_config(profile: options[:config].profile)
|
33
31
|
end
|
34
32
|
end
|
35
33
|
|
36
|
-
|
37
34
|
def sso_token(options)
|
38
|
-
profile_name = determine_profile_name(options)
|
39
35
|
if Aws.shared_config.config_enabled?
|
40
|
-
Aws.shared_config.sso_token_from_config(profile:
|
36
|
+
Aws.shared_config.sso_token_from_config(profile: determine_profile_name(options))
|
41
37
|
end
|
42
38
|
rescue Errors::NoSuchProfileError
|
43
39
|
nil
|
data/lib/aws-sdk-sso/client.rb
CHANGED
@@ -95,8 +95,8 @@ module Aws::SSO
|
|
95
95
|
# class name or an instance of a plugin class.
|
96
96
|
#
|
97
97
|
# @option options [required, Aws::CredentialProvider] :credentials
|
98
|
-
# Your AWS credentials. This can be
|
99
|
-
# following classes:
|
98
|
+
# Your AWS credentials used for authentication. This can be any class that includes and implements
|
99
|
+
# `Aws::CredentialProvider`, or instance of any one of the following classes:
|
100
100
|
#
|
101
101
|
# * `Aws::Credentials` - Used for configuring static, non-refreshing
|
102
102
|
# credentials.
|
@@ -124,22 +124,24 @@ module Aws::SSO
|
|
124
124
|
# * `Aws::CognitoIdentityCredentials` - Used for loading credentials
|
125
125
|
# from the Cognito Identity service.
|
126
126
|
#
|
127
|
-
# When `:credentials` are not configured directly, the following
|
128
|
-
# locations will be searched for credentials:
|
127
|
+
# When `:credentials` are not configured directly, the following locations will be searched for credentials:
|
129
128
|
#
|
130
129
|
# * `Aws.config[:credentials]`
|
130
|
+
#
|
131
131
|
# * The `:access_key_id`, `:secret_access_key`, `:session_token`, and
|
132
132
|
# `:account_id` options.
|
133
|
-
#
|
134
|
-
#
|
133
|
+
#
|
134
|
+
# * `ENV['AWS_ACCESS_KEY_ID']`, `ENV['AWS_SECRET_ACCESS_KEY']`,
|
135
|
+
# `ENV['AWS_SESSION_TOKEN']`, and `ENV['AWS_ACCOUNT_ID']`.
|
136
|
+
#
|
135
137
|
# * `~/.aws/credentials`
|
138
|
+
#
|
136
139
|
# * `~/.aws/config`
|
137
|
-
#
|
138
|
-
#
|
139
|
-
# `Aws::InstanceProfileCredentials` or `Aws::ECSCredentials` to
|
140
|
-
# enable retries and extended timeouts. Instance profile credential
|
141
|
-
#
|
142
|
-
# to true.
|
140
|
+
#
|
141
|
+
# * EC2/ECS IMDS instance profile - When used by default, the timeouts are very aggressive.
|
142
|
+
# Construct and pass an instance of `Aws::InstanceProfileCredentials` or `Aws::ECSCredentials` to
|
143
|
+
# enable retries and extended timeouts. Instance profile credential fetching can be disabled by
|
144
|
+
# setting `ENV['AWS_EC2_METADATA_DISABLED']` to `true`.
|
143
145
|
#
|
144
146
|
# @option options [required, String] :region
|
145
147
|
# The AWS region to connect to. The configured `:region` is
|
@@ -167,6 +169,11 @@ module Aws::SSO
|
|
167
169
|
# When false, the request will raise a `RetryCapacityNotAvailableError` and will
|
168
170
|
# not retry instead of sleeping.
|
169
171
|
#
|
172
|
+
# @option options [Array<String>] :auth_scheme_preference
|
173
|
+
# A list of preferred authentication schemes to use when making a request. Supported values are:
|
174
|
+
# `sigv4`, `sigv4a`, `httpBearerAuth`, and `noAuth`. When set using `ENV['AWS_AUTH_SCHEME_PREFERENCE']` or in
|
175
|
+
# shared config as `auth_scheme_preference`, the value should be a comma-separated list.
|
176
|
+
#
|
170
177
|
# @option options [Boolean] :client_side_monitoring (false)
|
171
178
|
# When `true`, client-side metrics will be collected for all API requests from
|
172
179
|
# this client.
|
@@ -253,8 +260,8 @@ module Aws::SSO
|
|
253
260
|
# 4 times. Used in `standard` and `adaptive` retry modes.
|
254
261
|
#
|
255
262
|
# @option options [String] :profile ("default")
|
256
|
-
# Used when loading credentials from the shared credentials file
|
257
|
-
#
|
263
|
+
# Used when loading credentials from the shared credentials file at `HOME/.aws/credentials`.
|
264
|
+
# When not specified, 'default' is used.
|
258
265
|
#
|
259
266
|
# @option options [String] :request_checksum_calculation ("when_supported")
|
260
267
|
# Determines when a checksum will be calculated for request payloads. Values are:
|
@@ -367,8 +374,8 @@ module Aws::SSO
|
|
367
374
|
# `Aws::Telemetry::OTelProvider` for telemetry provider.
|
368
375
|
#
|
369
376
|
# @option options [Aws::TokenProvider] :token_provider
|
370
|
-
#
|
371
|
-
# following classes:
|
377
|
+
# Your Bearer token used for authentication. This can be any class that includes and implements
|
378
|
+
# `Aws::TokenProvider`, or instance of any one of the following classes:
|
372
379
|
#
|
373
380
|
# * `Aws::StaticTokenProvider` - Used for configuring static, non-refreshing
|
374
381
|
# tokens.
|
@@ -691,7 +698,7 @@ module Aws::SSO
|
|
691
698
|
tracer: tracer
|
692
699
|
)
|
693
700
|
context[:gem_name] = 'aws-sdk-core'
|
694
|
-
context[:gem_version] = '3.
|
701
|
+
context[:gem_version] = '3.233.0'
|
695
702
|
Seahorse::Client::Request.new(handlers, context)
|
696
703
|
end
|
697
704
|
|
@@ -28,8 +28,8 @@ module Aws::SSO
|
|
28
28
|
raise ArgumentError, "FIPS and DualStack are enabled, but this partition does not support one or both"
|
29
29
|
end
|
30
30
|
if Aws::Endpoints::Matchers.boolean_equals?(parameters.use_fips, true)
|
31
|
-
if Aws::Endpoints::Matchers.boolean_equals?(
|
32
|
-
if Aws::Endpoints::Matchers.string_equals?(
|
31
|
+
if Aws::Endpoints::Matchers.boolean_equals?(Aws::Endpoints::Matchers.attr(partition_result, "supportsFIPS"), true)
|
32
|
+
if Aws::Endpoints::Matchers.string_equals?(Aws::Endpoints::Matchers.attr(partition_result, "name"), "aws-us-gov")
|
33
33
|
return Aws::Endpoints::Endpoint.new(url: "https://portal.sso.#{parameters.region}.amazonaws.com", headers: {}, properties: {})
|
34
34
|
end
|
35
35
|
return Aws::Endpoints::Endpoint.new(url: "https://portal.sso-fips.#{parameters.region}.#{partition_result['dnsSuffix']}", headers: {}, properties: {})
|
data/lib/aws-sdk-sso.rb
CHANGED
@@ -95,8 +95,8 @@ module Aws::SSOOIDC
|
|
95
95
|
# class name or an instance of a plugin class.
|
96
96
|
#
|
97
97
|
# @option options [required, Aws::CredentialProvider] :credentials
|
98
|
-
# Your AWS credentials. This can be
|
99
|
-
# following classes:
|
98
|
+
# Your AWS credentials used for authentication. This can be any class that includes and implements
|
99
|
+
# `Aws::CredentialProvider`, or instance of any one of the following classes:
|
100
100
|
#
|
101
101
|
# * `Aws::Credentials` - Used for configuring static, non-refreshing
|
102
102
|
# credentials.
|
@@ -124,22 +124,24 @@ module Aws::SSOOIDC
|
|
124
124
|
# * `Aws::CognitoIdentityCredentials` - Used for loading credentials
|
125
125
|
# from the Cognito Identity service.
|
126
126
|
#
|
127
|
-
# When `:credentials` are not configured directly, the following
|
128
|
-
# locations will be searched for credentials:
|
127
|
+
# When `:credentials` are not configured directly, the following locations will be searched for credentials:
|
129
128
|
#
|
130
129
|
# * `Aws.config[:credentials]`
|
130
|
+
#
|
131
131
|
# * The `:access_key_id`, `:secret_access_key`, `:session_token`, and
|
132
132
|
# `:account_id` options.
|
133
|
-
#
|
134
|
-
#
|
133
|
+
#
|
134
|
+
# * `ENV['AWS_ACCESS_KEY_ID']`, `ENV['AWS_SECRET_ACCESS_KEY']`,
|
135
|
+
# `ENV['AWS_SESSION_TOKEN']`, and `ENV['AWS_ACCOUNT_ID']`.
|
136
|
+
#
|
135
137
|
# * `~/.aws/credentials`
|
138
|
+
#
|
136
139
|
# * `~/.aws/config`
|
137
|
-
#
|
138
|
-
#
|
139
|
-
# `Aws::InstanceProfileCredentials` or `Aws::ECSCredentials` to
|
140
|
-
# enable retries and extended timeouts. Instance profile credential
|
141
|
-
#
|
142
|
-
# to true.
|
140
|
+
#
|
141
|
+
# * EC2/ECS IMDS instance profile - When used by default, the timeouts are very aggressive.
|
142
|
+
# Construct and pass an instance of `Aws::InstanceProfileCredentials` or `Aws::ECSCredentials` to
|
143
|
+
# enable retries and extended timeouts. Instance profile credential fetching can be disabled by
|
144
|
+
# setting `ENV['AWS_EC2_METADATA_DISABLED']` to `true`.
|
143
145
|
#
|
144
146
|
# @option options [required, String] :region
|
145
147
|
# The AWS region to connect to. The configured `:region` is
|
@@ -167,6 +169,11 @@ module Aws::SSOOIDC
|
|
167
169
|
# When false, the request will raise a `RetryCapacityNotAvailableError` and will
|
168
170
|
# not retry instead of sleeping.
|
169
171
|
#
|
172
|
+
# @option options [Array<String>] :auth_scheme_preference
|
173
|
+
# A list of preferred authentication schemes to use when making a request. Supported values are:
|
174
|
+
# `sigv4`, `sigv4a`, `httpBearerAuth`, and `noAuth`. When set using `ENV['AWS_AUTH_SCHEME_PREFERENCE']` or in
|
175
|
+
# shared config as `auth_scheme_preference`, the value should be a comma-separated list.
|
176
|
+
#
|
170
177
|
# @option options [Boolean] :client_side_monitoring (false)
|
171
178
|
# When `true`, client-side metrics will be collected for all API requests from
|
172
179
|
# this client.
|
@@ -253,8 +260,8 @@ module Aws::SSOOIDC
|
|
253
260
|
# 4 times. Used in `standard` and `adaptive` retry modes.
|
254
261
|
#
|
255
262
|
# @option options [String] :profile ("default")
|
256
|
-
# Used when loading credentials from the shared credentials file
|
257
|
-
#
|
263
|
+
# Used when loading credentials from the shared credentials file at `HOME/.aws/credentials`.
|
264
|
+
# When not specified, 'default' is used.
|
258
265
|
#
|
259
266
|
# @option options [String] :request_checksum_calculation ("when_supported")
|
260
267
|
# Determines when a checksum will be calculated for request payloads. Values are:
|
@@ -367,8 +374,8 @@ module Aws::SSOOIDC
|
|
367
374
|
# `Aws::Telemetry::OTelProvider` for telemetry provider.
|
368
375
|
#
|
369
376
|
# @option options [Aws::TokenProvider] :token_provider
|
370
|
-
#
|
371
|
-
# following classes:
|
377
|
+
# Your Bearer token used for authentication. This can be any class that includes and implements
|
378
|
+
# `Aws::TokenProvider`, or instance of any one of the following classes:
|
372
379
|
#
|
373
380
|
# * `Aws::StaticTokenProvider` - Used for configuring static, non-refreshing
|
374
381
|
# tokens.
|
@@ -516,10 +523,9 @@ module Aws::SSOOIDC
|
|
516
523
|
# [1]: https://docs.aws.amazon.com/singlesignon/latest/OIDCAPIReference/Welcome.html
|
517
524
|
#
|
518
525
|
# @option params [Array<String>] :scope
|
519
|
-
# The list of scopes for which authorization is requested.
|
520
|
-
#
|
521
|
-
#
|
522
|
-
# that are configured for the client during the call to RegisterClient.
|
526
|
+
# The list of scopes for which authorization is requested. This
|
527
|
+
# parameter has no effect; the access token will always include all
|
528
|
+
# scopes configured during client registration.
|
523
529
|
#
|
524
530
|
# @option params [String] :redirect_uri
|
525
531
|
# Used only when calling this API for the Authorization Code grant type.
|
@@ -608,12 +614,26 @@ module Aws::SSOOIDC
|
|
608
614
|
req.send_request(options)
|
609
615
|
end
|
610
616
|
|
611
|
-
# Creates and returns access and refresh tokens for
|
612
|
-
# applications that are authenticated using IAM
|
617
|
+
# Creates and returns access and refresh tokens for authorized client
|
618
|
+
# applications that are authenticated using any IAM entity, such as a
|
619
|
+
# service role or user. These tokens might contain defined scopes that
|
620
|
+
# specify permissions such as `read:profile` or `write:data`. Through
|
621
|
+
# downscoping, you can use the scopes parameter to request tokens with
|
622
|
+
# reduced permissions compared to the original client application's
|
623
|
+
# permissions or, if applicable, the refresh token's scopes. The access
|
613
624
|
# token can be used to fetch short-lived credentials for the assigned
|
614
625
|
# Amazon Web Services accounts or to access application APIs using
|
615
626
|
# `bearer` authentication.
|
616
627
|
#
|
628
|
+
# <note markdown="1"> This API is used with Signature Version 4. For more information, see
|
629
|
+
# [Amazon Web Services Signature Version 4 for API Requests][1].
|
630
|
+
#
|
631
|
+
# </note>
|
632
|
+
#
|
633
|
+
#
|
634
|
+
#
|
635
|
+
# [1]: https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_sigv.html
|
636
|
+
#
|
617
637
|
# @option params [required, String] :client_id
|
618
638
|
# The unique identifier string for the client or application. This value
|
619
639
|
# is an application ARN that has OAuth grants configured.
|
@@ -1061,7 +1081,7 @@ module Aws::SSOOIDC
|
|
1061
1081
|
tracer: tracer
|
1062
1082
|
)
|
1063
1083
|
context[:gem_name] = 'aws-sdk-core'
|
1064
|
-
context[:gem_version] = '3.
|
1084
|
+
context[:gem_version] = '3.233.0'
|
1065
1085
|
Seahorse::Client::Request.new(handlers, context)
|
1066
1086
|
end
|
1067
1087
|
|
@@ -15,6 +15,7 @@ module Aws::SSOOIDC
|
|
15
15
|
include Seahorse::Model
|
16
16
|
|
17
17
|
AccessDeniedException = Shapes::StructureShape.new(name: 'AccessDeniedException')
|
18
|
+
AccessDeniedExceptionReason = Shapes::StringShape.new(name: 'AccessDeniedExceptionReason')
|
18
19
|
AccessToken = Shapes::StringShape.new(name: 'AccessToken')
|
19
20
|
ArnType = Shapes::StringShape.new(name: 'ArnType')
|
20
21
|
Assertion = Shapes::StringShape.new(name: 'Assertion')
|
@@ -46,6 +47,7 @@ module Aws::SSOOIDC
|
|
46
47
|
InvalidGrantException = Shapes::StructureShape.new(name: 'InvalidGrantException')
|
47
48
|
InvalidRedirectUriException = Shapes::StructureShape.new(name: 'InvalidRedirectUriException')
|
48
49
|
InvalidRequestException = Shapes::StructureShape.new(name: 'InvalidRequestException')
|
50
|
+
InvalidRequestExceptionReason = Shapes::StringShape.new(name: 'InvalidRequestExceptionReason')
|
49
51
|
InvalidRequestRegionException = Shapes::StructureShape.new(name: 'InvalidRequestRegionException')
|
50
52
|
InvalidScopeException = Shapes::StructureShape.new(name: 'InvalidScopeException')
|
51
53
|
Location = Shapes::StringShape.new(name: 'Location')
|
@@ -69,6 +71,7 @@ module Aws::SSOOIDC
|
|
69
71
|
UserCode = Shapes::StringShape.new(name: 'UserCode')
|
70
72
|
|
71
73
|
AccessDeniedException.add_member(:error, Shapes::ShapeRef.new(shape: Error, location_name: "error"))
|
74
|
+
AccessDeniedException.add_member(:reason, Shapes::ShapeRef.new(shape: AccessDeniedExceptionReason, location_name: "reason"))
|
72
75
|
AccessDeniedException.add_member(:error_description, Shapes::ShapeRef.new(shape: ErrorDescription, location_name: "error_description"))
|
73
76
|
AccessDeniedException.struct_class = Types::AccessDeniedException
|
74
77
|
|
@@ -147,6 +150,7 @@ module Aws::SSOOIDC
|
|
147
150
|
InvalidRedirectUriException.struct_class = Types::InvalidRedirectUriException
|
148
151
|
|
149
152
|
InvalidRequestException.add_member(:error, Shapes::ShapeRef.new(shape: Error, location_name: "error"))
|
153
|
+
InvalidRequestException.add_member(:reason, Shapes::ShapeRef.new(shape: InvalidRequestExceptionReason, location_name: "reason"))
|
150
154
|
InvalidRequestException.add_member(:error_description, Shapes::ShapeRef.new(shape: ErrorDescription, location_name: "error_description"))
|
151
155
|
InvalidRequestException.struct_class = Types::InvalidRequestException
|
152
156
|
|
@@ -282,6 +286,7 @@ module Aws::SSOOIDC
|
|
282
286
|
o.errors << Shapes::ShapeRef.new(shape: InternalServerException)
|
283
287
|
o.errors << Shapes::ShapeRef.new(shape: InvalidRedirectUriException)
|
284
288
|
o.errors << Shapes::ShapeRef.new(shape: UnsupportedGrantTypeException)
|
289
|
+
o.errors << Shapes::ShapeRef.new(shape: SlowDownException)
|
285
290
|
end)
|
286
291
|
|
287
292
|
api.add_operation(:start_device_authorization, Seahorse::Model::Operation.new.tap do |o|
|
@@ -62,6 +62,11 @@ module Aws::SSOOIDC
|
|
62
62
|
@data[:error]
|
63
63
|
end
|
64
64
|
|
65
|
+
# @return [String]
|
66
|
+
def reason
|
67
|
+
@data[:reason]
|
68
|
+
end
|
69
|
+
|
65
70
|
# @return [String]
|
66
71
|
def error_description
|
67
72
|
@data[:error_description]
|
@@ -222,6 +227,11 @@ module Aws::SSOOIDC
|
|
222
227
|
@data[:error]
|
223
228
|
end
|
224
229
|
|
230
|
+
# @return [String]
|
231
|
+
def reason
|
232
|
+
@data[:reason]
|
233
|
+
end
|
234
|
+
|
225
235
|
# @return [String]
|
226
236
|
def error_description
|
227
237
|
@data[:error_description]
|
@@ -17,6 +17,10 @@ module Aws::SSOOIDC
|
|
17
17
|
# `access_denied`.
|
18
18
|
# @return [String]
|
19
19
|
#
|
20
|
+
# @!attribute [rw] reason
|
21
|
+
# A string that uniquely identifies a reason for the error.
|
22
|
+
# @return [String]
|
23
|
+
#
|
20
24
|
# @!attribute [rw] error_description
|
21
25
|
# Human-readable text providing additional information, used to assist
|
22
26
|
# the client developer in understanding the error that occurred.
|
@@ -26,6 +30,7 @@ module Aws::SSOOIDC
|
|
26
30
|
#
|
27
31
|
class AccessDeniedException < Struct.new(
|
28
32
|
:error,
|
33
|
+
:reason,
|
29
34
|
:error_description)
|
30
35
|
SENSITIVE = []
|
31
36
|
include Aws::Structure
|
@@ -54,14 +59,20 @@ module Aws::SSOOIDC
|
|
54
59
|
end
|
55
60
|
|
56
61
|
# This structure contains Amazon Web Services-specific parameter
|
57
|
-
# extensions
|
58
|
-
#
|
62
|
+
# extensions and the [identity context][1].
|
63
|
+
#
|
64
|
+
#
|
65
|
+
#
|
66
|
+
# [1]: https://docs.aws.amazon.com/singlesignon/latest/userguide/trustedidentitypropagation-overview.html
|
59
67
|
#
|
60
68
|
# @!attribute [rw] identity_context
|
61
|
-
#
|
62
|
-
#
|
63
|
-
#
|
64
|
-
#
|
69
|
+
# The trusted context assertion is signed and encrypted by STS. It
|
70
|
+
# provides access to `sts:identity_context` claim in the `idToken`
|
71
|
+
# without JWT parsing
|
72
|
+
#
|
73
|
+
# Identity context comprises information that Amazon Web Services
|
74
|
+
# services use to make authorization decisions when they receive
|
75
|
+
# requests.
|
65
76
|
# @return [String]
|
66
77
|
#
|
67
78
|
# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/AwsAdditionalDetails AWS API Documentation
|
@@ -122,11 +133,9 @@ module Aws::SSOOIDC
|
|
122
133
|
# @return [String]
|
123
134
|
#
|
124
135
|
# @!attribute [rw] scope
|
125
|
-
# The list of scopes for which authorization is requested.
|
126
|
-
#
|
127
|
-
#
|
128
|
-
# scopes that are configured for the client during the call to
|
129
|
-
# RegisterClient.
|
136
|
+
# The list of scopes for which authorization is requested. This
|
137
|
+
# parameter has no effect; the access token will always include all
|
138
|
+
# scopes configured during client registration.
|
130
139
|
# @return [Array<String>]
|
131
140
|
#
|
132
141
|
# @!attribute [rw] redirect_uri
|
@@ -376,10 +385,8 @@ module Aws::SSOOIDC
|
|
376
385
|
# @return [Array<String>]
|
377
386
|
#
|
378
387
|
# @!attribute [rw] aws_additional_details
|
379
|
-
# A structure containing information from
|
380
|
-
#
|
381
|
-
# `idToken`. This provides direct access to identity information
|
382
|
-
# without requiring JWT parsing.
|
388
|
+
# A structure containing information from IAM Identity Center managed
|
389
|
+
# user and group information.
|
383
390
|
# @return [Types::AwsAdditionalDetails]
|
384
391
|
#
|
385
392
|
# @see http://docs.aws.amazon.com/goto/WebAPI/sso-oidc-2019-06-10/CreateTokenWithIAMResponse AWS API Documentation
|
@@ -538,6 +545,10 @@ module Aws::SSOOIDC
|
|
538
545
|
# `invalid_request`.
|
539
546
|
# @return [String]
|
540
547
|
#
|
548
|
+
# @!attribute [rw] reason
|
549
|
+
# A string that uniquely identifies a reason for the error.
|
550
|
+
# @return [String]
|
551
|
+
#
|
541
552
|
# @!attribute [rw] error_description
|
542
553
|
# Human-readable text providing additional information, used to assist
|
543
554
|
# the client developer in understanding the error that occurred.
|
@@ -547,6 +558,7 @@ module Aws::SSOOIDC
|
|
547
558
|
#
|
548
559
|
class InvalidRequestException < Struct.new(
|
549
560
|
:error,
|
561
|
+
:reason,
|
550
562
|
:error_description)
|
551
563
|
SENSITIVE = []
|
552
564
|
include Aws::Structure
|
data/lib/aws-sdk-ssooidc.rb
CHANGED
data/lib/aws-sdk-sts/client.rb
CHANGED
@@ -97,8 +97,8 @@ module Aws::STS
|
|
97
97
|
# class name or an instance of a plugin class.
|
98
98
|
#
|
99
99
|
# @option options [required, Aws::CredentialProvider] :credentials
|
100
|
-
# Your AWS credentials. This can be
|
101
|
-
# following classes:
|
100
|
+
# Your AWS credentials used for authentication. This can be any class that includes and implements
|
101
|
+
# `Aws::CredentialProvider`, or instance of any one of the following classes:
|
102
102
|
#
|
103
103
|
# * `Aws::Credentials` - Used for configuring static, non-refreshing
|
104
104
|
# credentials.
|
@@ -126,22 +126,24 @@ module Aws::STS
|
|
126
126
|
# * `Aws::CognitoIdentityCredentials` - Used for loading credentials
|
127
127
|
# from the Cognito Identity service.
|
128
128
|
#
|
129
|
-
# When `:credentials` are not configured directly, the following
|
130
|
-
# locations will be searched for credentials:
|
129
|
+
# When `:credentials` are not configured directly, the following locations will be searched for credentials:
|
131
130
|
#
|
132
131
|
# * `Aws.config[:credentials]`
|
132
|
+
#
|
133
133
|
# * The `:access_key_id`, `:secret_access_key`, `:session_token`, and
|
134
134
|
# `:account_id` options.
|
135
|
-
#
|
136
|
-
#
|
135
|
+
#
|
136
|
+
# * `ENV['AWS_ACCESS_KEY_ID']`, `ENV['AWS_SECRET_ACCESS_KEY']`,
|
137
|
+
# `ENV['AWS_SESSION_TOKEN']`, and `ENV['AWS_ACCOUNT_ID']`.
|
138
|
+
#
|
137
139
|
# * `~/.aws/credentials`
|
140
|
+
#
|
138
141
|
# * `~/.aws/config`
|
139
|
-
#
|
140
|
-
#
|
141
|
-
# `Aws::InstanceProfileCredentials` or `Aws::ECSCredentials` to
|
142
|
-
# enable retries and extended timeouts. Instance profile credential
|
143
|
-
#
|
144
|
-
# to true.
|
142
|
+
#
|
143
|
+
# * EC2/ECS IMDS instance profile - When used by default, the timeouts are very aggressive.
|
144
|
+
# Construct and pass an instance of `Aws::InstanceProfileCredentials` or `Aws::ECSCredentials` to
|
145
|
+
# enable retries and extended timeouts. Instance profile credential fetching can be disabled by
|
146
|
+
# setting `ENV['AWS_EC2_METADATA_DISABLED']` to `true`.
|
145
147
|
#
|
146
148
|
# @option options [required, String] :region
|
147
149
|
# The AWS region to connect to. The configured `:region` is
|
@@ -169,6 +171,11 @@ module Aws::STS
|
|
169
171
|
# When false, the request will raise a `RetryCapacityNotAvailableError` and will
|
170
172
|
# not retry instead of sleeping.
|
171
173
|
#
|
174
|
+
# @option options [Array<String>] :auth_scheme_preference
|
175
|
+
# A list of preferred authentication schemes to use when making a request. Supported values are:
|
176
|
+
# `sigv4`, `sigv4a`, `httpBearerAuth`, and `noAuth`. When set using `ENV['AWS_AUTH_SCHEME_PREFERENCE']` or in
|
177
|
+
# shared config as `auth_scheme_preference`, the value should be a comma-separated list.
|
178
|
+
#
|
172
179
|
# @option options [Boolean] :client_side_monitoring (false)
|
173
180
|
# When `true`, client-side metrics will be collected for all API requests from
|
174
181
|
# this client.
|
@@ -255,8 +262,8 @@ module Aws::STS
|
|
255
262
|
# 4 times. Used in `standard` and `adaptive` retry modes.
|
256
263
|
#
|
257
264
|
# @option options [String] :profile ("default")
|
258
|
-
# Used when loading credentials from the shared credentials file
|
259
|
-
#
|
265
|
+
# Used when loading credentials from the shared credentials file at `HOME/.aws/credentials`.
|
266
|
+
# When not specified, 'default' is used.
|
260
267
|
#
|
261
268
|
# @option options [String] :request_checksum_calculation ("when_supported")
|
262
269
|
# Determines when a checksum will be calculated for request payloads. Values are:
|
@@ -374,8 +381,8 @@ module Aws::STS
|
|
374
381
|
# `Aws::Telemetry::OTelProvider` for telemetry provider.
|
375
382
|
#
|
376
383
|
# @option options [Aws::TokenProvider] :token_provider
|
377
|
-
#
|
378
|
-
# following classes:
|
384
|
+
# Your Bearer token used for authentication. This can be any class that includes and implements
|
385
|
+
# `Aws::TokenProvider`, or instance of any one of the following classes:
|
379
386
|
#
|
380
387
|
# * `Aws::StaticTokenProvider` - Used for configuring static, non-refreshing
|
381
388
|
# tokens.
|
@@ -2594,7 +2601,7 @@ module Aws::STS
|
|
2594
2601
|
tracer: tracer
|
2595
2602
|
)
|
2596
2603
|
context[:gem_name] = 'aws-sdk-core'
|
2597
|
-
context[:gem_version] = '3.
|
2604
|
+
context[:gem_version] = '3.233.0'
|
2598
2605
|
Seahorse::Client::Request.new(handlers, context)
|
2599
2606
|
end
|
2600
2607
|
|
@@ -53,13 +53,9 @@ module Aws
|
|
53
53
|
use_fips: context.config.use_fips_endpoint,
|
54
54
|
use_global_endpoint: context.config.sts_regional_endpoints == 'legacy'
|
55
55
|
)
|
56
|
-
endpoint = context.config.endpoint_provider
|
57
|
-
.resolve_endpoint(endpoint_params)
|
56
|
+
endpoint = context.config.endpoint_provider.resolve_endpoint(endpoint_params)
|
58
57
|
auth_scheme = Aws::Endpoints.resolve_auth_scheme(context, endpoint)
|
59
|
-
|
60
|
-
signer = Aws::Plugins::Sign.signer_for(
|
61
|
-
auth_scheme, context.config
|
62
|
-
)
|
58
|
+
signer = Aws::Plugins::Sign.signer_for(auth_scheme, context.config)
|
63
59
|
|
64
60
|
signer.presign_url(
|
65
61
|
http_method: 'GET',
|
data/lib/aws-sdk-sts.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: aws-sdk-core
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.
|
4
|
+
version: 3.233.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Amazon Web Services
|
@@ -77,6 +77,20 @@ dependencies:
|
|
77
77
|
- - ">="
|
78
78
|
- !ruby/object:Gem::Version
|
79
79
|
version: '0'
|
80
|
+
- !ruby/object:Gem::Dependency
|
81
|
+
name: bigdecimal
|
82
|
+
requirement: !ruby/object:Gem::Requirement
|
83
|
+
requirements:
|
84
|
+
- - ">="
|
85
|
+
- !ruby/object:Gem::Version
|
86
|
+
version: '0'
|
87
|
+
type: :runtime
|
88
|
+
prerelease: false
|
89
|
+
version_requirements: !ruby/object:Gem::Requirement
|
90
|
+
requirements:
|
91
|
+
- - ">="
|
92
|
+
- !ruby/object:Gem::Version
|
93
|
+
version: '0'
|
80
94
|
- !ruby/object:Gem::Dependency
|
81
95
|
name: jmespath
|
82
96
|
requirement: !ruby/object:Gem::Requirement
|