aws-sdk-core 3.210.0 → 3.217.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (44) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +75 -0
  3. data/VERSION +1 -1
  4. data/lib/aws-defaults/default_configuration.rb +1 -2
  5. data/lib/aws-sdk-core/arn.rb +1 -3
  6. data/lib/aws-sdk-core/cbor/decoder.rb +0 -2
  7. data/lib/aws-sdk-core/cbor/encoder.rb +2 -2
  8. data/lib/aws-sdk-core/cbor.rb +3 -56
  9. data/lib/aws-sdk-core/client_stubs.rb +7 -7
  10. data/lib/aws-sdk-core/json/error_handler.rb +2 -1
  11. data/lib/aws-sdk-core/json/handler.rb +1 -0
  12. data/lib/aws-sdk-core/log/param_formatter.rb +7 -3
  13. data/lib/aws-sdk-core/plugins/checksum_algorithm.rb +332 -170
  14. data/lib/aws-sdk-core/plugins/http_checksum.rb +2 -8
  15. data/lib/aws-sdk-core/plugins/sign.rb +1 -1
  16. data/lib/aws-sdk-core/plugins/user_agent.rb +10 -1
  17. data/lib/aws-sdk-core/rest/request/headers.rb +2 -2
  18. data/lib/aws-sdk-core/rpc_v2/builder.rb +1 -1
  19. data/lib/aws-sdk-core/{cbor → rpc_v2}/cbor_engine.rb +4 -5
  20. data/lib/aws-sdk-core/rpc_v2/content_type_handler.rb +3 -1
  21. data/lib/aws-sdk-core/rpc_v2/error_handler.rb +3 -2
  22. data/lib/aws-sdk-core/rpc_v2/handler.rb +2 -1
  23. data/lib/aws-sdk-core/rpc_v2/parser.rb +1 -1
  24. data/lib/aws-sdk-core/rpc_v2.rb +65 -2
  25. data/lib/aws-sdk-core/shared_config.rb +2 -0
  26. data/lib/aws-sdk-core/stubbing/protocols/ec2.rb +12 -11
  27. data/lib/aws-sdk-core/stubbing/protocols/json.rb +11 -10
  28. data/lib/aws-sdk-core/stubbing/protocols/query.rb +7 -6
  29. data/lib/aws-sdk-core/stubbing/protocols/rest.rb +2 -1
  30. data/lib/aws-sdk-core/stubbing/protocols/rest_json.rb +9 -8
  31. data/lib/aws-sdk-core/stubbing/protocols/rest_xml.rb +6 -5
  32. data/lib/aws-sdk-core/stubbing/protocols/rpc_v2.rb +13 -15
  33. data/lib/aws-sdk-core/stubbing.rb +2 -2
  34. data/lib/aws-sdk-sso/client.rb +24 -1
  35. data/lib/aws-sdk-sso.rb +1 -1
  36. data/lib/aws-sdk-ssooidc/client.rb +48 -19
  37. data/lib/aws-sdk-ssooidc/types.rb +20 -15
  38. data/lib/aws-sdk-ssooidc.rb +1 -1
  39. data/lib/aws-sdk-sts/client.rb +231 -52
  40. data/lib/aws-sdk-sts/client_api.rb +23 -0
  41. data/lib/aws-sdk-sts/types.rb +170 -28
  42. data/lib/aws-sdk-sts.rb +1 -1
  43. data/lib/seahorse/client/response.rb +2 -0
  44. metadata +3 -3
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 76363f1349adc61b88e879efab4d38e965f416da75d819575e8bd1f81a2260d1
4
- data.tar.gz: e9c8c07d912cc51bd4a0a19dca27263e2efc9f553280b81710db280101e6901a
3
+ metadata.gz: 13c7508d3fe8738d7cf214927f7ce2c56291b98bd48140df95f9b870f4d47b22
4
+ data.tar.gz: b02761bcdae833ec72bde159bfbdebeaf31cbe6d1a133218b2431fcbb9678bef
5
5
  SHA512:
6
- metadata.gz: a2b2155fa24f865908843d89c30b40f93aeaa5fb4ec314082b3413d98f387ee169c5a81c0bf6d10a2afd9522b8d616e87568811a2736c2a32664034b8555a11b
7
- data.tar.gz: f5c59bf455b3f8d7cfe6ddeb977f8502bfba42f85a4b2fdc1ab47d043b5cc6921bcca8444a5941b0e0c2d50bdbe208d477f03c0ea0ca2928af62e841debd3784
6
+ metadata.gz: 97147bdd4fd7e610d78e9b058cc8b0db1b4dc88dcb7ec16aa4c9f08819d3c4e6acc965ddc8591b8e52f0f34b33c2beec1a76bdf39bbb6e34b405dd8c63fbe348
7
+ data.tar.gz: 8290e9fae3593b24ae2247882bdaced352fb4f86989b20493473ffa84685ede8c6ff7c4e46397a5711a0eeeedbd8bee5b3b8205571babb937f25f9b9e38e35bf
data/CHANGELOG.md CHANGED
@@ -1,6 +1,81 @@
1
1
  Unreleased Changes
2
2
  ------------------
3
3
 
4
+ 3.217.1 (2025-01-30)
5
+ ------------------
6
+
7
+ * Issue - Add `transfer-encoding` and `connection` to list of unsigned sigv4 headers.
8
+
9
+ 3.217.0 (2025-01-24)
10
+ ------------------
11
+
12
+ * Feature - Updated Aws::SSOOIDC::Client with the latest API changes.
13
+
14
+ * Feature - Fixed typos in the descriptions.
15
+
16
+ 3.216.1 (2025-01-22)
17
+ ------------------
18
+
19
+ * Issue - Use epoch seconds instead of milliseconds in cbor encode/decode.
20
+
21
+ * Issue - Add handling of block in response delegation (#3169).
22
+
23
+ 3.216.0 (2025-01-15)
24
+ ------------------
25
+
26
+ * Feature - Updated Aws::STS::Client with the latest API changes.
27
+
28
+ * Feature - Updated Aws::SSOOIDC::Client with the latest API changes.
29
+
30
+ * Feature - Updated Aws::SSO::Client with the latest API changes.
31
+
32
+ * Feature - Always calculate request checksums for operations that support or require it. Supported config options are `when_supported` and `when_required`. The default value is `when_supported`. This option is configured in code with `:request_checksum_calculation`, in the shared config file as `request_checksum_calculation`, and in the ENV as `ENV['AWS_REQUEST_CHECKSUM_CALCULATION']`.
33
+
34
+ * Feature - Always validate response checksums for operations that support or require it. Supported config options are `when_supported` and `when_required`. The default value is `when_supported`. This option is configured in code with `:response_checksum_validation`, in the shared config file as `response_checksum_validation`, and in the ENV as `ENV['AWS_RESPONSE_CHECKSUM_VALIDATION']`.
35
+
36
+ * Feature - Support CRC64NVME checksums through the `aws-crt` gem.
37
+
38
+ 3.215.1 (2025-01-14)
39
+ ------------------
40
+
41
+ * Issue - Fixed error when attempting to log an unlinked tempfile.
42
+
43
+ 3.215.0 (2025-01-10)
44
+ ------------------
45
+
46
+ * Feature - Updated Aws::STS::Client with the latest API changes.
47
+
48
+ * Feature - Fixed typos in the descriptions.
49
+
50
+ 3.214.1 (2024-12-28)
51
+ ------------------
52
+
53
+ * Issue - Fix documentation that references a non-existent method.
54
+
55
+ 3.214.0 (2024-11-25)
56
+ ------------------
57
+
58
+ * Feature - Updated configuration values for `defaults_mode`.
59
+
60
+ 3.213.0 (2024-11-14)
61
+ ------------------
62
+
63
+ * Feature - Updated Aws::STS::Client with the latest API changes.
64
+
65
+ * Feature - This release introduces the new API 'AssumeRoot', which returns short-term credentials that you can use to perform privileged tasks.
66
+
67
+ 3.212.0 (2024-11-06)
68
+ ------------------
69
+
70
+ * Feature - Updated Aws::STS::Client with the latest API changes.
71
+
72
+ 3.211.0 (2024-10-21)
73
+ ------------------
74
+
75
+ * Feature - Support functionality for services that migrate from AWS Query to AWS JSON or CBOR.
76
+
77
+ * Issue - Fix RPCv2 protocol to always send an Accept header for CBOR.
78
+
4
79
  3.210.0 (2024-10-18)
5
80
  ------------------
6
81
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 3.210.0
1
+ 3.217.1
@@ -128,8 +128,7 @@ module Aws
128
128
  "override" => 3100
129
129
  }
130
130
  },
131
- "in-region" => {
132
- },
131
+ "in-region" => {},
133
132
  "cross-region" => {
134
133
  "connectTimeoutInMillis" => {
135
134
  "override" => 3100
@@ -24,9 +24,7 @@ module Aws
24
24
  # arn.resource
25
25
  # # => foo/bar
26
26
  #
27
- # # Note: parser available for parsing resource details
28
- # @see Aws::ARNParser#parse_resource
29
- #
27
+ # @see ARNParser
30
28
  # @see https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#genref-arns
31
29
  class ARN
32
30
 
@@ -61,9 +61,7 @@ module Aws
61
61
  when :tag
62
62
  case (tag = read_tag)
63
63
  when TAG_TYPE_EPOCH
64
- type = peek_type
65
64
  item = decode_item
66
- item /= 1000.0 if type == :integer
67
65
  Time.at(item)
68
66
  when TAG_TYPE_BIGNUM, TAG_TYPE_NEG_BIGNUM
69
67
  read_bignum(tag)
@@ -226,8 +226,8 @@ module Aws
226
226
 
227
227
  def add_time(value)
228
228
  head(MAJOR_TYPE_TAG, TAG_TYPE_EPOCH)
229
- epoch_ms = (value.to_f * 1000).to_i
230
- add_integer(epoch_ms)
229
+ epoch = value.to_f
230
+ add_double(epoch)
231
231
  end
232
232
 
233
233
  def bignum_to_bytes(value)
@@ -1,5 +1,8 @@
1
1
  # frozen_string_literal: true
2
2
 
3
+ require_relative 'cbor/encoder'
4
+ require_relative 'cbor/decoder'
5
+
3
6
  module Aws
4
7
  # @api private
5
8
  module Cbor
@@ -46,61 +49,5 @@ module Aws
46
49
  super("Unexpected additional information: #{add_info}")
47
50
  end
48
51
  end
49
-
50
- class << self
51
- # @param [Symbol,Class] engine
52
- # Must be one of the following values:
53
- #
54
- # * :cbor
55
- #
56
- def engine=(engine)
57
- @engine = Class === engine ? engine : load_engine(engine)
58
- end
59
-
60
- # @return [Class] Returns the default engine.
61
- # One of:
62
- #
63
- # * {CborEngine}
64
- #
65
- def engine
66
- set_default_engine unless @engine
67
- @engine
68
- end
69
-
70
- def encode(data)
71
- @engine.encode(data)
72
- end
73
-
74
- def decode(bytes)
75
- bytes.force_encoding(Encoding::BINARY)
76
- @engine.decode(bytes)
77
- end
78
-
79
- def set_default_engine
80
- [:cbor].each do |name|
81
- @engine ||= try_load_engine(name)
82
- end
83
-
84
- unless @engine
85
- raise 'Unable to find a compatible cbor library.'
86
- end
87
- end
88
-
89
- private
90
-
91
- def load_engine(name)
92
- require "aws-sdk-core/cbor/#{name}_engine"
93
- const_name = name[0].upcase + name[1..-1] + 'Engine'
94
- const_get(const_name)
95
- end
96
-
97
- def try_load_engine(name)
98
- load_engine(name)
99
- rescue LoadError
100
- false
101
- end
102
- end
103
-
104
- set_default_engine
105
52
  end
106
53
  end
@@ -307,14 +307,14 @@ module Aws
307
307
 
308
308
  def protocol_helper
309
309
  case config.api.metadata['protocol']
310
- when 'json' then Stubbing::Protocols::Json
311
- when 'rest-json' then Stubbing::Protocols::RestJson
312
- when 'rest-xml' then Stubbing::Protocols::RestXml
313
- when 'query' then Stubbing::Protocols::Query
314
- when 'ec2' then Stubbing::Protocols::EC2
310
+ when 'json' then Stubbing::Protocols::Json
311
+ when 'rest-json' then Stubbing::Protocols::RestJson
312
+ when 'rest-xml' then Stubbing::Protocols::RestXml
313
+ when 'query' then Stubbing::Protocols::Query
314
+ when 'ec2' then Stubbing::Protocols::EC2
315
315
  when 'smithy-rpc-v2-cbor' then Stubbing::Protocols::RpcV2
316
- when 'api-gateway' then Stubbing::Protocols::ApiGateway
317
- else raise "unsupported protocol"
316
+ when 'api-gateway' then Stubbing::Protocols::ApiGateway
317
+ else raise 'unsupported protocol'
318
318
  end.new
319
319
  end
320
320
  end
@@ -26,7 +26,8 @@ module Aws
26
26
  def error_code(json, context)
27
27
  code =
28
28
  if aws_query_error?(context)
29
- error = context.http_response.headers['x-amzn-query-error'].split(';')[0]
29
+ query_header = context.http_response.headers['x-amzn-query-error']
30
+ error, _type = query_header.split(';') # type not supported
30
31
  remove_prefix(error, context)
31
32
  else
32
33
  json['__type']
@@ -21,6 +21,7 @@ module Aws
21
21
  context.http_request.http_method = 'POST'
22
22
  context.http_request.headers['Content-Type'] = content_type(context)
23
23
  context.http_request.headers['X-Amz-Target'] = target(context)
24
+ context.http_request.headers['X-Amzn-Query-Mode'] = 'true' if query_compatible?(context)
24
25
  context.http_request.body = build_body(context)
25
26
  end
26
27
 
@@ -51,13 +51,17 @@ module Aws
51
51
  when String then summarize_string(value)
52
52
  when Hash then '{' + summarize_hash(value) + '}'
53
53
  when Array then summarize_array(value)
54
- when File then summarize_file(value.path)
55
- when Pathname then summarize_file(value)
54
+ when File then summarize_file(value)
55
+ when Pathname then summarize_filepath(value)
56
56
  else value.inspect
57
57
  end
58
58
  end
59
59
 
60
- def summarize_file(path)
60
+ def summarize_file(file)
61
+ "#<File:#{file.path} (#{file.size} bytes)>"
62
+ end
63
+
64
+ def summarize_filepath(path)
61
65
  "#<File:#{path} (#{File.size(path)} bytes)>"
62
66
  end
63
67