aws-sdk-s3control 1.53.0 → 1.55.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.
@@ -13,9 +13,13 @@ require 'aws-sdk-core'
13
13
 
14
14
  require_relative 'aws-sdk-s3control/types'
15
15
  require_relative 'aws-sdk-s3control/client_api'
16
+ require_relative 'aws-sdk-s3control/plugins/endpoints.rb'
16
17
  require_relative 'aws-sdk-s3control/client'
17
18
  require_relative 'aws-sdk-s3control/errors'
18
19
  require_relative 'aws-sdk-s3control/resource'
20
+ require_relative 'aws-sdk-s3control/endpoint_parameters'
21
+ require_relative 'aws-sdk-s3control/endpoint_provider'
22
+ require_relative 'aws-sdk-s3control/endpoints'
19
23
  require_relative 'aws-sdk-s3control/customizations'
20
24
 
21
25
  # This module provides support for AWS S3 Control. This module is available in the
@@ -48,6 +52,6 @@ require_relative 'aws-sdk-s3control/customizations'
48
52
  # @!group service
49
53
  module Aws::S3Control
50
54
 
51
- GEM_VERSION = '1.53.0'
55
+ GEM_VERSION = '1.55.0'
52
56
 
53
57
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws-sdk-s3control
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.53.0
4
+ version: 1.55.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Amazon Web Services
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-10-19 00:00:00.000000000 Z
11
+ date: 2022-11-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sigv4
@@ -33,7 +33,7 @@ dependencies:
33
33
  version: '3'
34
34
  - - ">="
35
35
  - !ruby/object:Gem::Version
36
- version: 3.127.0
36
+ version: 3.165.0
37
37
  type: :runtime
38
38
  prerelease: false
39
39
  version_requirements: !ruby/object:Gem::Requirement
@@ -43,7 +43,7 @@ dependencies:
43
43
  version: '3'
44
44
  - - ">="
45
45
  - !ruby/object:Gem::Version
46
- version: 3.127.0
46
+ version: 3.165.0
47
47
  description: Official AWS Ruby gem for AWS S3 Control. This gem is part of the AWS
48
48
  SDK for Ruby.
49
49
  email:
@@ -61,10 +61,13 @@ files:
61
61
  - lib/aws-sdk-s3control/client.rb
62
62
  - lib/aws-sdk-s3control/client_api.rb
63
63
  - lib/aws-sdk-s3control/customizations.rb
64
+ - lib/aws-sdk-s3control/endpoint_parameters.rb
65
+ - lib/aws-sdk-s3control/endpoint_provider.rb
66
+ - lib/aws-sdk-s3control/endpoints.rb
64
67
  - lib/aws-sdk-s3control/errors.rb
65
68
  - lib/aws-sdk-s3control/plugins/arn.rb
66
69
  - lib/aws-sdk-s3control/plugins/dualstack.rb
67
- - lib/aws-sdk-s3control/plugins/s3_control_signer.rb
70
+ - lib/aws-sdk-s3control/plugins/endpoints.rb
68
71
  - lib/aws-sdk-s3control/plugins/s3_host_id.rb
69
72
  - lib/aws-sdk-s3control/resource.rb
70
73
  - lib/aws-sdk-s3control/types.rb
@@ -1,97 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require 'aws-sigv4'
4
-
5
- module Aws
6
- module S3Control
7
- module Plugins
8
- # This plugin is an implementation detail and may be modified.
9
- # @api private
10
- class S3ControlSigner < Seahorse::Client::Plugin
11
- SPECIAL_OUTPOST_OPERATIONS = [
12
- 'CreateBucket',
13
- 'ListRegionalBuckets'
14
- ].freeze
15
-
16
- option(:sigv4_signer) do |cfg|
17
- S3ControlSigner.build_v4_signer(
18
- service: 's3',
19
- region: cfg.sigv4_region,
20
- credentials: cfg.credentials
21
- )
22
- end
23
-
24
- option(:sigv4_region) do |cfg|
25
- raise Aws::Errors::MissingRegionError if cfg.region.nil?
26
-
27
- Aws::Partitions::EndpointProvider.signing_region(cfg.region, 's3-control')
28
- end
29
-
30
- def add_handlers(handlers, _cfg)
31
- handlers.add(V4Handler, step: :sign)
32
- end
33
-
34
- class V4Handler < Seahorse::Client::Handler
35
- def call(context)
36
- Aws::Plugins::SignatureV4.apply_signature(
37
- context: context,
38
- signer: sigv4_signer(context)
39
- )
40
- @handler.call(context)
41
- end
42
-
43
- private
44
-
45
- def sigv4_signer(context)
46
- if (arn = context.metadata[:s3_arn]) &&
47
- arn[:arn].respond_to?(:outpost_id)
48
- S3ControlSigner.build_v4_signer(
49
- service: 's3-outposts',
50
- region: arn[:resolved_region],
51
- credentials: context.config.credentials
52
- )
53
- elsif outpost_operation?(context)
54
- # outpost operations should go to the outposts endpoint only if
55
- # it's not a custom endpoint. the ARN class changes this for ARNs
56
- if context.config.regional_endpoint
57
- fips = context.config.use_fips_endpoint
58
- context.http_request.endpoint.host =
59
- "s3-outposts#{'-fips' if fips}.#{context.config.region}.amazonaws.com"
60
- end
61
- S3ControlSigner.build_v4_signer(
62
- service: 's3-outposts',
63
- region: context.config.region,
64
- credentials: context.config.credentials
65
- )
66
- else
67
- context.config.sigv4_signer
68
- end
69
- end
70
-
71
- # Some operations do not take an ARN parameter and are special cases
72
- # For these operations, the presence of the outpost_id parameter
73
- # must trigger special endpoint and signer redirection
74
- def outpost_operation?(context)
75
- SPECIAL_OUTPOST_OPERATIONS.include?(context.operation.name) &&
76
- context.params[:outpost_id]
77
- end
78
- end
79
-
80
- class << self
81
- # @option options [required, String] :region
82
- # @option options [required, #credentials] :credentials
83
- # @api private
84
- def build_v4_signer(options = {})
85
- Aws::Sigv4::Signer.new(
86
- service: options[:service],
87
- region: options[:region],
88
- credentials_provider: options[:credentials],
89
- uri_escape_path: false,
90
- unsigned_headers: ['content-length', 'x-amzn-trace-id']
91
- )
92
- end
93
- end
94
- end
95
- end
96
- end
97
- end