aws-sdk-s3 1.136.0 → 1.176.1
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 +250 -1
- data/VERSION +1 -1
- data/lib/aws-sdk-s3/access_grants_credentials.rb +57 -0
- data/lib/aws-sdk-s3/access_grants_credentials_provider.rb +250 -0
- data/lib/aws-sdk-s3/bucket.rb +671 -139
- data/lib/aws-sdk-s3/bucket_acl.rb +12 -12
- data/lib/aws-sdk-s3/bucket_cors.rb +16 -16
- data/lib/aws-sdk-s3/bucket_lifecycle.rb +21 -16
- data/lib/aws-sdk-s3/bucket_lifecycle_configuration.rb +74 -17
- data/lib/aws-sdk-s3/bucket_logging.rb +19 -12
- data/lib/aws-sdk-s3/bucket_notification.rb +6 -6
- data/lib/aws-sdk-s3/bucket_policy.rb +62 -18
- data/lib/aws-sdk-s3/bucket_region_cache.rb +9 -5
- data/lib/aws-sdk-s3/bucket_request_payment.rb +12 -12
- data/lib/aws-sdk-s3/bucket_tagging.rb +16 -16
- data/lib/aws-sdk-s3/bucket_versioning.rb +32 -32
- data/lib/aws-sdk-s3/bucket_website.rb +16 -16
- data/lib/aws-sdk-s3/client.rb +7597 -2823
- data/lib/aws-sdk-s3/client_api.rb +288 -22
- data/lib/aws-sdk-s3/customizations/bucket.rb +1 -1
- data/lib/aws-sdk-s3/customizations/errors.rb +15 -2
- data/lib/aws-sdk-s3/customizations/object.rb +11 -5
- data/lib/aws-sdk-s3/customizations/object_summary.rb +5 -0
- data/lib/aws-sdk-s3/customizations/object_version.rb +13 -0
- data/lib/aws-sdk-s3/customizations.rb +25 -31
- data/lib/aws-sdk-s3/encryption/client.rb +2 -2
- data/lib/aws-sdk-s3/encryption/kms_cipher_provider.rb +2 -2
- data/lib/aws-sdk-s3/encryptionV2/client.rb +2 -2
- data/lib/aws-sdk-s3/encryptionV2/kms_cipher_provider.rb +2 -2
- data/lib/aws-sdk-s3/endpoint_parameters.rb +53 -18
- data/lib/aws-sdk-s3/endpoint_provider.rb +125 -6
- data/lib/aws-sdk-s3/endpoints.rb +545 -1261
- data/lib/aws-sdk-s3/errors.rb +47 -0
- data/lib/aws-sdk-s3/express_credentials.rb +55 -0
- data/lib/aws-sdk-s3/express_credentials_provider.rb +59 -0
- data/lib/aws-sdk-s3/file_downloader.rb +1 -2
- data/lib/aws-sdk-s3/file_uploader.rb +1 -1
- data/lib/aws-sdk-s3/multipart_file_uploader.rb +4 -4
- data/lib/aws-sdk-s3/multipart_stream_uploader.rb +6 -5
- data/lib/aws-sdk-s3/multipart_upload.rb +139 -36
- data/lib/aws-sdk-s3/multipart_upload_part.rb +175 -54
- data/lib/aws-sdk-s3/object.rb +1923 -313
- data/lib/aws-sdk-s3/object_acl.rb +34 -22
- data/lib/aws-sdk-s3/object_copier.rb +1 -1
- data/lib/aws-sdk-s3/object_multipart_copier.rb +10 -8
- data/lib/aws-sdk-s3/object_summary.rb +1690 -250
- data/lib/aws-sdk-s3/object_version.rb +397 -67
- data/lib/aws-sdk-s3/plugins/access_grants.rb +178 -0
- data/lib/aws-sdk-s3/plugins/endpoints.rb +32 -208
- data/lib/aws-sdk-s3/plugins/express_session_auth.rb +97 -0
- data/lib/aws-sdk-s3/plugins/http_200_errors.rb +55 -18
- data/lib/aws-sdk-s3/plugins/location_constraint.rb +3 -1
- data/lib/aws-sdk-s3/plugins/md5s.rb +2 -1
- data/lib/aws-sdk-s3/plugins/s3_signer.rb +7 -2
- data/lib/aws-sdk-s3/presigner.rb +5 -2
- data/lib/aws-sdk-s3/resource.rb +121 -22
- data/lib/aws-sdk-s3/types.rb +5960 -1526
- data/lib/aws-sdk-s3.rb +35 -31
- data/sig/bucket.rbs +221 -0
- data/sig/bucket_acl.rbs +78 -0
- data/sig/bucket_cors.rbs +69 -0
- data/sig/bucket_lifecycle.rbs +88 -0
- data/sig/bucket_lifecycle_configuration.rbs +115 -0
- data/sig/bucket_logging.rbs +76 -0
- data/sig/bucket_notification.rbs +114 -0
- data/sig/bucket_policy.rbs +59 -0
- data/sig/bucket_request_payment.rbs +54 -0
- data/sig/bucket_tagging.rbs +65 -0
- data/sig/bucket_versioning.rbs +77 -0
- data/sig/bucket_website.rbs +93 -0
- data/sig/client.rbs +2450 -0
- data/sig/customizations/bucket.rbs +19 -0
- data/sig/customizations/object.rbs +38 -0
- data/sig/customizations/object_summary.rbs +35 -0
- data/sig/errors.rbs +42 -0
- data/sig/multipart_upload.rbs +113 -0
- data/sig/multipart_upload_part.rbs +105 -0
- data/sig/object.rbs +448 -0
- data/sig/object_acl.rbs +86 -0
- data/sig/object_summary.rbs +340 -0
- data/sig/object_version.rbs +140 -0
- data/sig/resource.rbs +132 -0
- data/sig/types.rbs +2682 -0
- data/sig/waiters.rbs +95 -0
- metadata +44 -11
@@ -134,7 +134,7 @@ module Aws
|
|
134
134
|
|
135
135
|
# @api private
|
136
136
|
def load
|
137
|
-
@data = Aws::Plugins::UserAgent.
|
137
|
+
@data = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
|
138
138
|
client.list_buckets.buckets.find { |b| b.name == name }
|
139
139
|
end
|
140
140
|
raise "unable to load bucket #{name}" if @data.nil?
|
@@ -3,8 +3,8 @@
|
|
3
3
|
module Aws
|
4
4
|
module S3
|
5
5
|
module Errors
|
6
|
-
# Hijack PermanentRedirect dynamic error to
|
7
|
-
# and
|
6
|
+
# Hijack PermanentRedirect dynamic error to include the bucket, region,
|
7
|
+
# and endpoint.
|
8
8
|
class PermanentRedirect < ServiceError
|
9
9
|
# @param [Seahorse::Client::RequestContext] context
|
10
10
|
# @param [String] message
|
@@ -22,6 +22,19 @@ module Aws
|
|
22
22
|
super(context, message, data)
|
23
23
|
end
|
24
24
|
end
|
25
|
+
|
26
|
+
# Hijack PermanentRedirect (HeadBucket case - no body) dynamic error to
|
27
|
+
# include the region.
|
28
|
+
class Http301Error < ServiceError
|
29
|
+
# @param [Seahorse::Client::RequestContext] context
|
30
|
+
# @param [String] message
|
31
|
+
# @param [Aws::S3::Types::PermanentRedirect] _data
|
32
|
+
def initialize(context, message, _data = Aws::EmptyStructure.new)
|
33
|
+
data = Aws::S3::Types::PermanentRedirect.new(message: message)
|
34
|
+
data.region = context.http_response.headers['x-amz-bucket-region']
|
35
|
+
super(context, message, data)
|
36
|
+
end
|
37
|
+
end
|
25
38
|
end
|
26
39
|
end
|
27
40
|
end
|
@@ -76,7 +76,7 @@ module Aws
|
|
76
76
|
# @see #copy_to
|
77
77
|
#
|
78
78
|
def copy_from(source, options = {})
|
79
|
-
Aws::Plugins::UserAgent.
|
79
|
+
Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
|
80
80
|
if Hash === source && source[:copy_source]
|
81
81
|
# for backwards compatibility
|
82
82
|
@client.copy_object(source.merge(bucket: bucket_name, key: key))
|
@@ -119,7 +119,7 @@ module Aws
|
|
119
119
|
# object.copy_to('src-bucket/src-key', multipart_copy: true)
|
120
120
|
#
|
121
121
|
def copy_to(target, options = {})
|
122
|
-
Aws::Plugins::UserAgent.
|
122
|
+
Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
|
123
123
|
ObjectCopier.new(self, options).copy_to(target, options)
|
124
124
|
end
|
125
125
|
end
|
@@ -390,7 +390,7 @@ module Aws
|
|
390
390
|
tempfile: uploading_options.delete(:tempfile),
|
391
391
|
part_size: uploading_options.delete(:part_size)
|
392
392
|
)
|
393
|
-
Aws::Plugins::UserAgent.
|
393
|
+
Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
|
394
394
|
uploader.upload(
|
395
395
|
uploading_options.merge(bucket: bucket_name, key: key),
|
396
396
|
&block
|
@@ -473,7 +473,7 @@ module Aws
|
|
473
473
|
multipart_threshold: uploading_options.delete(:multipart_threshold),
|
474
474
|
client: client
|
475
475
|
)
|
476
|
-
response = Aws::Plugins::UserAgent.
|
476
|
+
response = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
|
477
477
|
uploader.upload(
|
478
478
|
source,
|
479
479
|
uploading_options.merge(bucket: bucket_name, key: key)
|
@@ -551,7 +551,7 @@ module Aws
|
|
551
551
|
# @see Client#head_object
|
552
552
|
def download_file(destination, options = {})
|
553
553
|
downloader = FileDownloader.new(client: client)
|
554
|
-
Aws::Plugins::UserAgent.
|
554
|
+
Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
|
555
555
|
downloader.download(
|
556
556
|
destination,
|
557
557
|
options.merge(bucket: bucket_name, key: key)
|
@@ -559,6 +559,12 @@ module Aws
|
|
559
559
|
end
|
560
560
|
true
|
561
561
|
end
|
562
|
+
|
563
|
+
class Collection < Aws::Resources::Collection
|
564
|
+
alias_method :delete, :batch_delete!
|
565
|
+
extend Aws::Deprecations
|
566
|
+
deprecated :delete, use: :batch_delete!
|
567
|
+
end
|
562
568
|
end
|
563
569
|
end
|
564
570
|
end
|
@@ -80,6 +80,11 @@ module Aws
|
|
80
80
|
object.download_file(destination, options)
|
81
81
|
end
|
82
82
|
|
83
|
+
class Collection < Aws::Resources::Collection
|
84
|
+
alias_method :delete, :batch_delete!
|
85
|
+
extend Aws::Deprecations
|
86
|
+
deprecated :delete, use: :batch_delete!
|
87
|
+
end
|
83
88
|
end
|
84
89
|
end
|
85
90
|
end
|
@@ -0,0 +1,13 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Aws
|
4
|
+
module S3
|
5
|
+
class ObjectVersion
|
6
|
+
class Collection < Aws::Resources::Collection
|
7
|
+
alias_method :delete, :batch_delete!
|
8
|
+
extend Aws::Deprecations
|
9
|
+
deprecated :delete, use: :batch_delete!
|
10
|
+
end
|
11
|
+
end
|
12
|
+
end
|
13
|
+
end
|
@@ -1,36 +1,30 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
3
|
+
module Aws
|
4
|
+
module S3
|
5
|
+
# utility classes
|
6
|
+
autoload :BucketRegionCache, 'aws-sdk-s3/bucket_region_cache'
|
7
|
+
autoload :Encryption, 'aws-sdk-s3/encryption'
|
8
|
+
autoload :EncryptionV2, 'aws-sdk-s3/encryption_v2'
|
9
|
+
autoload :FilePart, 'aws-sdk-s3/file_part'
|
10
|
+
autoload :FileUploader, 'aws-sdk-s3/file_uploader'
|
11
|
+
autoload :FileDownloader, 'aws-sdk-s3/file_downloader'
|
12
|
+
autoload :LegacySigner, 'aws-sdk-s3/legacy_signer'
|
13
|
+
autoload :MultipartFileUploader, 'aws-sdk-s3/multipart_file_uploader'
|
14
|
+
autoload :MultipartStreamUploader, 'aws-sdk-s3/multipart_stream_uploader'
|
15
|
+
autoload :MultipartUploadError, 'aws-sdk-s3/multipart_upload_error'
|
16
|
+
autoload :ObjectCopier, 'aws-sdk-s3/object_copier'
|
17
|
+
autoload :ObjectMultipartCopier, 'aws-sdk-s3/object_multipart_copier'
|
18
|
+
autoload :PresignedPost, 'aws-sdk-s3/presigned_post'
|
19
|
+
autoload :Presigner, 'aws-sdk-s3/presigner'
|
18
20
|
|
19
|
-
#
|
20
|
-
|
21
|
-
|
22
|
-
require 'aws-sdk-s3/customizations/object'
|
23
|
-
require 'aws-sdk-s3/customizations/object_summary'
|
24
|
-
require 'aws-sdk-s3/customizations/multipart_upload'
|
25
|
-
require 'aws-sdk-s3/customizations/types/list_object_versions_output'
|
26
|
-
require 'aws-sdk-s3/customizations/types/permanent_redirect'
|
21
|
+
# s3 express session auth
|
22
|
+
autoload :ExpressCredentials, 'aws-sdk-s3/express_credentials'
|
23
|
+
autoload :ExpressCredentialsProvider, 'aws-sdk-s3/express_credentials_provider'
|
27
24
|
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
klass.send(:alias_method, :delete, :batch_delete!)
|
34
|
-
klass.extend Aws::Deprecations
|
35
|
-
klass.send(:deprecated, :delete, use: :batch_delete!)
|
25
|
+
# s3 access grants auth
|
26
|
+
|
27
|
+
autoload :AccessGrantsCredentials, 'aws-sdk-s3/access_grants_credentials'
|
28
|
+
autoload :AccessGrantsCredentialsProvider, 'aws-sdk-s3/access_grants_credentials_provider'
|
29
|
+
end
|
36
30
|
end
|
@@ -270,7 +270,7 @@ module Aws
|
|
270
270
|
envelope_location: @envelope_location,
|
271
271
|
instruction_file_suffix: @instruction_file_suffix,
|
272
272
|
}
|
273
|
-
Aws::Plugins::UserAgent.
|
273
|
+
Aws::Plugins::UserAgent.metric('S3_CRYPTO_V1N') do
|
274
274
|
req.send_request
|
275
275
|
end
|
276
276
|
end
|
@@ -300,7 +300,7 @@ module Aws
|
|
300
300
|
envelope_location: envelope_location,
|
301
301
|
instruction_file_suffix: instruction_file_suffix,
|
302
302
|
}
|
303
|
-
Aws::Plugins::UserAgent.
|
303
|
+
Aws::Plugins::UserAgent.metric('S3_CRYPTO_V1N') do
|
304
304
|
req.send_request(target: block)
|
305
305
|
end
|
306
306
|
end
|
@@ -17,7 +17,7 @@ module Aws
|
|
17
17
|
# envelope and encryption cipher.
|
18
18
|
def encryption_cipher
|
19
19
|
encryption_context = { "kms_cmk_id" => @kms_key_id }
|
20
|
-
key_data = Aws::Plugins::UserAgent.
|
20
|
+
key_data = Aws::Plugins::UserAgent.metric('S3_CRYPTO_V1N') do
|
21
21
|
@kms_client.generate_data_key(
|
22
22
|
key_id: @kms_key_id,
|
23
23
|
encryption_context: encryption_context,
|
@@ -60,7 +60,7 @@ module Aws
|
|
60
60
|
"#{envelope['x-amz-wrap-alg']}"
|
61
61
|
end
|
62
62
|
|
63
|
-
key = Aws::Plugins::UserAgent.
|
63
|
+
key = Aws::Plugins::UserAgent.metric('S3_CRYPTO_V1N') do
|
64
64
|
@kms_client.decrypt(
|
65
65
|
ciphertext_blob: decode64(envelope['x-amz-key-v2']),
|
66
66
|
encryption_context: encryption_context
|
@@ -361,7 +361,7 @@ module Aws
|
|
361
361
|
instruction_file_suffix: @instruction_file_suffix,
|
362
362
|
kms_encryption_context: kms_encryption_context
|
363
363
|
}
|
364
|
-
Aws::Plugins::UserAgent.
|
364
|
+
Aws::Plugins::UserAgent.metric('S3_CRYPTO_V2') do
|
365
365
|
req.send_request
|
366
366
|
end
|
367
367
|
end
|
@@ -416,7 +416,7 @@ module Aws
|
|
416
416
|
kms_allow_decrypt_with_any_cmk: kms_any_cmk_mode,
|
417
417
|
security_profile: security_profile
|
418
418
|
}
|
419
|
-
Aws::Plugins::UserAgent.
|
419
|
+
Aws::Plugins::UserAgent.metric('S3_CRYPTO_V2') do
|
420
420
|
req.send_request(target: block)
|
421
421
|
end
|
422
422
|
end
|
@@ -24,7 +24,7 @@ module Aws
|
|
24
24
|
def encryption_cipher(options = {})
|
25
25
|
validate_key_for_encryption
|
26
26
|
encryption_context = build_encryption_context(@content_encryption_schema, options)
|
27
|
-
key_data = Aws::Plugins::UserAgent.
|
27
|
+
key_data = Aws::Plugins::UserAgent.metric('S3_CRYPTO_V2') do
|
28
28
|
@kms_client.generate_data_key(
|
29
29
|
key_id: @kms_key_id,
|
30
30
|
encryption_context: encryption_context,
|
@@ -85,7 +85,7 @@ module Aws
|
|
85
85
|
decrypt_options[:key_id] = @kms_key_id
|
86
86
|
end
|
87
87
|
|
88
|
-
key = Aws::Plugins::UserAgent.
|
88
|
+
key = Aws::Plugins::UserAgent.metric('S3_CRYPTO_V2') do
|
89
89
|
@kms_client.decrypt(decrypt_options).plaintext
|
90
90
|
end
|
91
91
|
iv = decode64(envelope['x-amz-iv'])
|
@@ -55,6 +55,21 @@ module Aws::S3
|
|
55
55
|
#
|
56
56
|
# @return [Boolean]
|
57
57
|
#
|
58
|
+
# @!attribute key
|
59
|
+
# The S3 Key used to send the request. This is an optional parameter that will be set automatically for operations that are scoped to an S3 Key.
|
60
|
+
#
|
61
|
+
# @return [String]
|
62
|
+
#
|
63
|
+
# @!attribute prefix
|
64
|
+
# The S3 Prefix used to send the request. This is an optional parameter that will be set automatically for operations that are scoped to an S3 Prefix.
|
65
|
+
#
|
66
|
+
# @return [String]
|
67
|
+
#
|
68
|
+
# @!attribute copy_source
|
69
|
+
# The Copy Source used for Copy Object request. This is an optional parameter that will be set automatically for operations that are scoped to Copy Source.
|
70
|
+
#
|
71
|
+
# @return [String]
|
72
|
+
#
|
58
73
|
# @!attribute disable_access_points
|
59
74
|
# Internal parameter to disable Access Point Buckets
|
60
75
|
#
|
@@ -70,6 +85,16 @@ module Aws::S3
|
|
70
85
|
#
|
71
86
|
# @return [Boolean]
|
72
87
|
#
|
88
|
+
# @!attribute use_s3_express_control_endpoint
|
89
|
+
# Internal parameter to indicate whether S3Express operation should use control plane, (ex. CreateBucket)
|
90
|
+
#
|
91
|
+
# @return [Boolean]
|
92
|
+
#
|
93
|
+
# @!attribute disable_s3_express_session_auth
|
94
|
+
# Parameter to indicate whether S3Express session auth should be disabled
|
95
|
+
#
|
96
|
+
# @return [Boolean]
|
97
|
+
#
|
73
98
|
EndpointParameters = Struct.new(
|
74
99
|
:bucket,
|
75
100
|
:region,
|
@@ -80,9 +105,14 @@ module Aws::S3
|
|
80
105
|
:accelerate,
|
81
106
|
:use_global_endpoint,
|
82
107
|
:use_object_lambda_endpoint,
|
108
|
+
:key,
|
109
|
+
:prefix,
|
110
|
+
:copy_source,
|
83
111
|
:disable_access_points,
|
84
112
|
:disable_multi_region_access_points,
|
85
113
|
:use_arn_region,
|
114
|
+
:use_s3_express_control_endpoint,
|
115
|
+
:disable_s3_express_session_auth,
|
86
116
|
) do
|
87
117
|
include Aws::Structure
|
88
118
|
|
@@ -98,9 +128,14 @@ module Aws::S3
|
|
98
128
|
'Accelerate' => :accelerate,
|
99
129
|
'UseGlobalEndpoint' => :use_global_endpoint,
|
100
130
|
'UseObjectLambdaEndpoint' => :use_object_lambda_endpoint,
|
131
|
+
'Key' => :key,
|
132
|
+
'Prefix' => :prefix,
|
133
|
+
'CopySource' => :copy_source,
|
101
134
|
'DisableAccessPoints' => :disable_access_points,
|
102
135
|
'DisableMultiRegionAccessPoints' => :disable_multi_region_access_points,
|
103
136
|
'UseArnRegion' => :use_arn_region,
|
137
|
+
'UseS3ExpressControlEndpoint' => :use_s3_express_control_endpoint,
|
138
|
+
'DisableS3ExpressSessionAuth' => :disable_s3_express_session_auth,
|
104
139
|
}.freeze
|
105
140
|
end
|
106
141
|
|
@@ -109,38 +144,38 @@ module Aws::S3
|
|
109
144
|
self[:region] = options[:region]
|
110
145
|
self[:use_fips] = options[:use_fips]
|
111
146
|
self[:use_fips] = false if self[:use_fips].nil?
|
112
|
-
if self[:use_fips].nil?
|
113
|
-
raise ArgumentError, "Missing required EndpointParameter: :use_fips"
|
114
|
-
end
|
115
147
|
self[:use_dual_stack] = options[:use_dual_stack]
|
116
148
|
self[:use_dual_stack] = false if self[:use_dual_stack].nil?
|
117
|
-
if self[:use_dual_stack].nil?
|
118
|
-
raise ArgumentError, "Missing required EndpointParameter: :use_dual_stack"
|
119
|
-
end
|
120
149
|
self[:endpoint] = options[:endpoint]
|
121
150
|
self[:force_path_style] = options[:force_path_style]
|
122
151
|
self[:force_path_style] = false if self[:force_path_style].nil?
|
123
|
-
if self[:force_path_style].nil?
|
124
|
-
raise ArgumentError, "Missing required EndpointParameter: :force_path_style"
|
125
|
-
end
|
126
152
|
self[:accelerate] = options[:accelerate]
|
127
153
|
self[:accelerate] = false if self[:accelerate].nil?
|
128
|
-
if self[:accelerate].nil?
|
129
|
-
raise ArgumentError, "Missing required EndpointParameter: :accelerate"
|
130
|
-
end
|
131
154
|
self[:use_global_endpoint] = options[:use_global_endpoint]
|
132
155
|
self[:use_global_endpoint] = false if self[:use_global_endpoint].nil?
|
133
|
-
if self[:use_global_endpoint].nil?
|
134
|
-
raise ArgumentError, "Missing required EndpointParameter: :use_global_endpoint"
|
135
|
-
end
|
136
156
|
self[:use_object_lambda_endpoint] = options[:use_object_lambda_endpoint]
|
157
|
+
self[:key] = options[:key]
|
158
|
+
self[:prefix] = options[:prefix]
|
159
|
+
self[:copy_source] = options[:copy_source]
|
137
160
|
self[:disable_access_points] = options[:disable_access_points]
|
138
161
|
self[:disable_multi_region_access_points] = options[:disable_multi_region_access_points]
|
139
162
|
self[:disable_multi_region_access_points] = false if self[:disable_multi_region_access_points].nil?
|
140
|
-
if self[:disable_multi_region_access_points].nil?
|
141
|
-
raise ArgumentError, "Missing required EndpointParameter: :disable_multi_region_access_points"
|
142
|
-
end
|
143
163
|
self[:use_arn_region] = options[:use_arn_region]
|
164
|
+
self[:use_s3_express_control_endpoint] = options[:use_s3_express_control_endpoint]
|
165
|
+
self[:disable_s3_express_session_auth] = options[:disable_s3_express_session_auth]
|
166
|
+
end
|
167
|
+
|
168
|
+
def self.create(config, options={})
|
169
|
+
new({
|
170
|
+
region: config.region,
|
171
|
+
use_fips: config.use_fips_endpoint,
|
172
|
+
endpoint: (config.endpoint.to_s unless config.regional_endpoint),
|
173
|
+
force_path_style: config.force_path_style,
|
174
|
+
use_global_endpoint: config.s3_us_east_1_regional_endpoint == 'legacy',
|
175
|
+
disable_multi_region_access_points: config.s3_disable_multiregion_access_points,
|
176
|
+
use_arn_region: config.s3_use_arn_region,
|
177
|
+
disable_s3_express_session_auth: config.disable_s3_express_session_auth,
|
178
|
+
}.merge(options))
|
144
179
|
end
|
145
180
|
end
|
146
181
|
end
|
@@ -19,9 +19,14 @@ module Aws::S3
|
|
19
19
|
accelerate = parameters.accelerate
|
20
20
|
use_global_endpoint = parameters.use_global_endpoint
|
21
21
|
use_object_lambda_endpoint = parameters.use_object_lambda_endpoint
|
22
|
+
key = parameters.key
|
23
|
+
prefix = parameters.prefix
|
24
|
+
copy_source = parameters.copy_source
|
22
25
|
disable_access_points = parameters.disable_access_points
|
23
26
|
disable_multi_region_access_points = parameters.disable_multi_region_access_points
|
24
27
|
use_arn_region = parameters.use_arn_region
|
28
|
+
use_s3_express_control_endpoint = parameters.use_s3_express_control_endpoint
|
29
|
+
disable_s3_express_session_auth = parameters.disable_s3_express_session_auth
|
25
30
|
if Aws::Endpoints::Matchers.set?(region)
|
26
31
|
if Aws::Endpoints::Matchers.boolean_equals?(accelerate, true) && Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
|
27
32
|
raise ArgumentError, "Accelerate cannot be used with FIPS"
|
@@ -38,6 +43,120 @@ module Aws::S3
|
|
38
43
|
if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true) && (partition_result = Aws::Endpoints::Matchers.aws_partition(region)) && Aws::Endpoints::Matchers.string_equals?(Aws::Endpoints::Matchers.attr(partition_result, "name"), "aws-cn")
|
39
44
|
raise ArgumentError, "Partition does not support FIPS"
|
40
45
|
end
|
46
|
+
if Aws::Endpoints::Matchers.set?(bucket) && (bucket_suffix = Aws::Endpoints::Matchers.substring(bucket, 0, 6, true)) && Aws::Endpoints::Matchers.string_equals?(bucket_suffix, "--x-s3")
|
47
|
+
if Aws::Endpoints::Matchers.boolean_equals?(use_dual_stack, true)
|
48
|
+
raise ArgumentError, "S3Express does not support Dual-stack."
|
49
|
+
end
|
50
|
+
if Aws::Endpoints::Matchers.boolean_equals?(accelerate, true)
|
51
|
+
raise ArgumentError, "S3Express does not support S3 Accelerate."
|
52
|
+
end
|
53
|
+
if Aws::Endpoints::Matchers.set?(endpoint) && (url = Aws::Endpoints::Matchers.parse_url(endpoint))
|
54
|
+
if Aws::Endpoints::Matchers.set?(disable_s3_express_session_auth) && Aws::Endpoints::Matchers.boolean_equals?(disable_s3_express_session_auth, true)
|
55
|
+
if Aws::Endpoints::Matchers.boolean_equals?(Aws::Endpoints::Matchers.attr(url, "isIp"), true)
|
56
|
+
if (uri_encoded_bucket = Aws::Endpoints::Matchers.uri_encode(bucket))
|
57
|
+
return Aws::Endpoints::Endpoint.new(url: "#{url['scheme']}://#{url['authority']}/#{uri_encoded_bucket}#{url['path']}", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
58
|
+
end
|
59
|
+
end
|
60
|
+
if Aws::Endpoints::Matchers.aws_virtual_hostable_s3_bucket?(bucket, false)
|
61
|
+
return Aws::Endpoints::Endpoint.new(url: "#{url['scheme']}://#{bucket}.#{url['authority']}#{url['path']}", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
62
|
+
end
|
63
|
+
raise ArgumentError, "S3Express bucket name is not a valid virtual hostable name."
|
64
|
+
end
|
65
|
+
if Aws::Endpoints::Matchers.boolean_equals?(Aws::Endpoints::Matchers.attr(url, "isIp"), true)
|
66
|
+
if (uri_encoded_bucket = Aws::Endpoints::Matchers.uri_encode(bucket))
|
67
|
+
return Aws::Endpoints::Endpoint.new(url: "#{url['scheme']}://#{url['authority']}/#{uri_encoded_bucket}#{url['path']}", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4-s3express", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
68
|
+
end
|
69
|
+
end
|
70
|
+
if Aws::Endpoints::Matchers.aws_virtual_hostable_s3_bucket?(bucket, false)
|
71
|
+
return Aws::Endpoints::Endpoint.new(url: "#{url['scheme']}://#{bucket}.#{url['authority']}#{url['path']}", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4-s3express", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
72
|
+
end
|
73
|
+
raise ArgumentError, "S3Express bucket name is not a valid virtual hostable name."
|
74
|
+
end
|
75
|
+
if Aws::Endpoints::Matchers.set?(use_s3_express_control_endpoint) && Aws::Endpoints::Matchers.boolean_equals?(use_s3_express_control_endpoint, true)
|
76
|
+
if (uri_encoded_bucket = Aws::Endpoints::Matchers.uri_encode(bucket)) && Aws::Endpoints::Matchers.not(Aws::Endpoints::Matchers.set?(endpoint))
|
77
|
+
if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
|
78
|
+
return Aws::Endpoints::Endpoint.new(url: "https://s3express-control-fips.#{region}.amazonaws.com/#{uri_encoded_bucket}", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
79
|
+
end
|
80
|
+
return Aws::Endpoints::Endpoint.new(url: "https://s3express-control.#{region}.amazonaws.com/#{uri_encoded_bucket}", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
81
|
+
end
|
82
|
+
end
|
83
|
+
if Aws::Endpoints::Matchers.aws_virtual_hostable_s3_bucket?(bucket, false)
|
84
|
+
if Aws::Endpoints::Matchers.set?(disable_s3_express_session_auth) && Aws::Endpoints::Matchers.boolean_equals?(disable_s3_express_session_auth, true)
|
85
|
+
if (s3express_availability_zone_id = Aws::Endpoints::Matchers.substring(bucket, 6, 14, true)) && (s3express_availability_zone_delim = Aws::Endpoints::Matchers.substring(bucket, 14, 16, true)) && Aws::Endpoints::Matchers.string_equals?(s3express_availability_zone_delim, "--")
|
86
|
+
if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
|
87
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.s3express-fips-#{s3express_availability_zone_id}.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
88
|
+
end
|
89
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.s3express-#{s3express_availability_zone_id}.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
90
|
+
end
|
91
|
+
if (s3express_availability_zone_id = Aws::Endpoints::Matchers.substring(bucket, 6, 15, true)) && (s3express_availability_zone_delim = Aws::Endpoints::Matchers.substring(bucket, 15, 17, true)) && Aws::Endpoints::Matchers.string_equals?(s3express_availability_zone_delim, "--")
|
92
|
+
if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
|
93
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.s3express-fips-#{s3express_availability_zone_id}.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
94
|
+
end
|
95
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.s3express-#{s3express_availability_zone_id}.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
96
|
+
end
|
97
|
+
if (s3express_availability_zone_id = Aws::Endpoints::Matchers.substring(bucket, 6, 19, true)) && (s3express_availability_zone_delim = Aws::Endpoints::Matchers.substring(bucket, 19, 21, true)) && Aws::Endpoints::Matchers.string_equals?(s3express_availability_zone_delim, "--")
|
98
|
+
if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
|
99
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.s3express-fips-#{s3express_availability_zone_id}.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
100
|
+
end
|
101
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.s3express-#{s3express_availability_zone_id}.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
102
|
+
end
|
103
|
+
if (s3express_availability_zone_id = Aws::Endpoints::Matchers.substring(bucket, 6, 20, true)) && (s3express_availability_zone_delim = Aws::Endpoints::Matchers.substring(bucket, 20, 22, true)) && Aws::Endpoints::Matchers.string_equals?(s3express_availability_zone_delim, "--")
|
104
|
+
if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
|
105
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.s3express-fips-#{s3express_availability_zone_id}.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
106
|
+
end
|
107
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.s3express-#{s3express_availability_zone_id}.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
108
|
+
end
|
109
|
+
if (s3express_availability_zone_id = Aws::Endpoints::Matchers.substring(bucket, 6, 26, true)) && (s3express_availability_zone_delim = Aws::Endpoints::Matchers.substring(bucket, 26, 28, true)) && Aws::Endpoints::Matchers.string_equals?(s3express_availability_zone_delim, "--")
|
110
|
+
if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
|
111
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.s3express-fips-#{s3express_availability_zone_id}.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
112
|
+
end
|
113
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.s3express-#{s3express_availability_zone_id}.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
114
|
+
end
|
115
|
+
raise ArgumentError, "Unrecognized S3Express bucket name format."
|
116
|
+
end
|
117
|
+
if (s3express_availability_zone_id = Aws::Endpoints::Matchers.substring(bucket, 6, 14, true)) && (s3express_availability_zone_delim = Aws::Endpoints::Matchers.substring(bucket, 14, 16, true)) && Aws::Endpoints::Matchers.string_equals?(s3express_availability_zone_delim, "--")
|
118
|
+
if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
|
119
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.s3express-fips-#{s3express_availability_zone_id}.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4-s3express", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
120
|
+
end
|
121
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.s3express-#{s3express_availability_zone_id}.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4-s3express", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
122
|
+
end
|
123
|
+
if (s3express_availability_zone_id = Aws::Endpoints::Matchers.substring(bucket, 6, 15, true)) && (s3express_availability_zone_delim = Aws::Endpoints::Matchers.substring(bucket, 15, 17, true)) && Aws::Endpoints::Matchers.string_equals?(s3express_availability_zone_delim, "--")
|
124
|
+
if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
|
125
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.s3express-fips-#{s3express_availability_zone_id}.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4-s3express", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
126
|
+
end
|
127
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.s3express-#{s3express_availability_zone_id}.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4-s3express", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
128
|
+
end
|
129
|
+
if (s3express_availability_zone_id = Aws::Endpoints::Matchers.substring(bucket, 6, 19, true)) && (s3express_availability_zone_delim = Aws::Endpoints::Matchers.substring(bucket, 19, 21, true)) && Aws::Endpoints::Matchers.string_equals?(s3express_availability_zone_delim, "--")
|
130
|
+
if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
|
131
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.s3express-fips-#{s3express_availability_zone_id}.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4-s3express", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
132
|
+
end
|
133
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.s3express-#{s3express_availability_zone_id}.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4-s3express", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
134
|
+
end
|
135
|
+
if (s3express_availability_zone_id = Aws::Endpoints::Matchers.substring(bucket, 6, 20, true)) && (s3express_availability_zone_delim = Aws::Endpoints::Matchers.substring(bucket, 20, 22, true)) && Aws::Endpoints::Matchers.string_equals?(s3express_availability_zone_delim, "--")
|
136
|
+
if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
|
137
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.s3express-fips-#{s3express_availability_zone_id}.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4-s3express", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
138
|
+
end
|
139
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.s3express-#{s3express_availability_zone_id}.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4-s3express", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
140
|
+
end
|
141
|
+
if (s3express_availability_zone_id = Aws::Endpoints::Matchers.substring(bucket, 6, 26, true)) && (s3express_availability_zone_delim = Aws::Endpoints::Matchers.substring(bucket, 26, 28, true)) && Aws::Endpoints::Matchers.string_equals?(s3express_availability_zone_delim, "--")
|
142
|
+
if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
|
143
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.s3express-fips-#{s3express_availability_zone_id}.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4-s3express", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
144
|
+
end
|
145
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.s3express-#{s3express_availability_zone_id}.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4-s3express", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
146
|
+
end
|
147
|
+
raise ArgumentError, "Unrecognized S3Express bucket name format."
|
148
|
+
end
|
149
|
+
raise ArgumentError, "S3Express bucket name is not a valid virtual hostable name."
|
150
|
+
end
|
151
|
+
if Aws::Endpoints::Matchers.not(Aws::Endpoints::Matchers.set?(bucket)) && Aws::Endpoints::Matchers.set?(use_s3_express_control_endpoint) && Aws::Endpoints::Matchers.boolean_equals?(use_s3_express_control_endpoint, true)
|
152
|
+
if Aws::Endpoints::Matchers.set?(endpoint) && (url = Aws::Endpoints::Matchers.parse_url(endpoint))
|
153
|
+
return Aws::Endpoints::Endpoint.new(url: "#{url['scheme']}://#{url['authority']}#{url['path']}", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
154
|
+
end
|
155
|
+
if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
|
156
|
+
return Aws::Endpoints::Endpoint.new(url: "https://s3express-control-fips.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
157
|
+
end
|
158
|
+
return Aws::Endpoints::Endpoint.new(url: "https://s3express-control.#{region}.amazonaws.com", headers: {}, properties: {"backend"=>"S3Express", "authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3express", "signingRegion"=>"#{region}"}]})
|
159
|
+
end
|
41
160
|
if Aws::Endpoints::Matchers.set?(bucket) && (hardware_type = Aws::Endpoints::Matchers.substring(bucket, 49, 50, true)) && (region_prefix = Aws::Endpoints::Matchers.substring(bucket, 8, 12, true)) && (bucket_alias_suffix = Aws::Endpoints::Matchers.substring(bucket, 0, 7, true)) && (outpost_id = Aws::Endpoints::Matchers.substring(bucket, 32, 49, true)) && (region_partition = Aws::Endpoints::Matchers.aws_partition(region)) && Aws::Endpoints::Matchers.string_equals?(bucket_alias_suffix, "--op-s3")
|
42
161
|
if Aws::Endpoints::Matchers.valid_host_label?(outpost_id, false)
|
43
162
|
if Aws::Endpoints::Matchers.string_equals?(hardware_type, "e")
|
@@ -46,10 +165,10 @@ module Aws::S3
|
|
46
165
|
raise ArgumentError, "Expected a endpoint to be specified but no endpoint was found"
|
47
166
|
end
|
48
167
|
if Aws::Endpoints::Matchers.set?(endpoint) && (url = Aws::Endpoints::Matchers.parse_url(endpoint))
|
49
|
-
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.ec2.#{url['authority']}", headers: {}, properties: {"authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3-outposts", "signingRegion"=>"#{region}"}]})
|
168
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.ec2.#{url['authority']}", headers: {}, properties: {"authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4a", "signingName"=>"s3-outposts", "signingRegionSet"=>["*"]}, {"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3-outposts", "signingRegion"=>"#{region}"}]})
|
50
169
|
end
|
51
170
|
end
|
52
|
-
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.ec2.s3-outposts.#{region}.#{region_partition['dnsSuffix']}", headers: {}, properties: {"authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3-outposts", "signingRegion"=>"#{region}"}]})
|
171
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.ec2.s3-outposts.#{region}.#{region_partition['dnsSuffix']}", headers: {}, properties: {"authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4a", "signingName"=>"s3-outposts", "signingRegionSet"=>["*"]}, {"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3-outposts", "signingRegion"=>"#{region}"}]})
|
53
172
|
end
|
54
173
|
if Aws::Endpoints::Matchers.string_equals?(hardware_type, "o")
|
55
174
|
if Aws::Endpoints::Matchers.string_equals?(region_prefix, "beta")
|
@@ -57,10 +176,10 @@ module Aws::S3
|
|
57
176
|
raise ArgumentError, "Expected a endpoint to be specified but no endpoint was found"
|
58
177
|
end
|
59
178
|
if Aws::Endpoints::Matchers.set?(endpoint) && (url = Aws::Endpoints::Matchers.parse_url(endpoint))
|
60
|
-
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.op-#{outpost_id}.#{url['authority']}", headers: {}, properties: {"authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3-outposts", "signingRegion"=>"#{region}"}]})
|
179
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.op-#{outpost_id}.#{url['authority']}", headers: {}, properties: {"authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4a", "signingName"=>"s3-outposts", "signingRegionSet"=>["*"]}, {"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3-outposts", "signingRegion"=>"#{region}"}]})
|
61
180
|
end
|
62
181
|
end
|
63
|
-
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.op-#{outpost_id}.s3-outposts.#{region}.#{region_partition['dnsSuffix']}", headers: {}, properties: {"authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3-outposts", "signingRegion"=>"#{region}"}]})
|
182
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{bucket}.op-#{outpost_id}.s3-outposts.#{region}.#{region_partition['dnsSuffix']}", headers: {}, properties: {"authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4a", "signingName"=>"s3-outposts", "signingRegionSet"=>["*"]}, {"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3-outposts", "signingRegion"=>"#{region}"}]})
|
64
183
|
end
|
65
184
|
raise ArgumentError, "Unrecognized hardware type: \"Expected hardware type o or e but got #{hardware_type}\""
|
66
185
|
end
|
@@ -331,9 +450,9 @@ module Aws::S3
|
|
331
450
|
if (access_point_name = Aws::Endpoints::Matchers.attr(bucket_arn, "resourceId[3]"))
|
332
451
|
if Aws::Endpoints::Matchers.string_equals?(outpost_type, "accesspoint")
|
333
452
|
if Aws::Endpoints::Matchers.set?(endpoint) && (url = Aws::Endpoints::Matchers.parse_url(endpoint))
|
334
|
-
return Aws::Endpoints::Endpoint.new(url: "https://#{access_point_name}-#{bucket_arn['accountId']}.#{outpost_id}.#{url['authority']}", headers: {}, properties: {"authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3-outposts", "signingRegion"=>"#{bucket_arn['region']}"}]})
|
453
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{access_point_name}-#{bucket_arn['accountId']}.#{outpost_id}.#{url['authority']}", headers: {}, properties: {"authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4a", "signingName"=>"s3-outposts", "signingRegionSet"=>["*"]}, {"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3-outposts", "signingRegion"=>"#{bucket_arn['region']}"}]})
|
335
454
|
end
|
336
|
-
return Aws::Endpoints::Endpoint.new(url: "https://#{access_point_name}-#{bucket_arn['accountId']}.#{outpost_id}.s3-outposts.#{bucket_arn['region']}.#{bucket_partition['dnsSuffix']}", headers: {}, properties: {"authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3-outposts", "signingRegion"=>"#{bucket_arn['region']}"}]})
|
455
|
+
return Aws::Endpoints::Endpoint.new(url: "https://#{access_point_name}-#{bucket_arn['accountId']}.#{outpost_id}.s3-outposts.#{bucket_arn['region']}.#{bucket_partition['dnsSuffix']}", headers: {}, properties: {"authSchemes"=>[{"disableDoubleEncoding"=>true, "name"=>"sigv4a", "signingName"=>"s3-outposts", "signingRegionSet"=>["*"]}, {"disableDoubleEncoding"=>true, "name"=>"sigv4", "signingName"=>"s3-outposts", "signingRegion"=>"#{bucket_arn['region']}"}]})
|
337
456
|
end
|
338
457
|
raise ArgumentError, "Expected an outpost type `accesspoint`, found #{outpost_type}"
|
339
458
|
end
|