aws-sdk-s3 1.128.0 → 1.199.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 +450 -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 +720 -128
- data/lib/aws-sdk-s3/bucket_acl.rb +18 -17
- data/lib/aws-sdk-s3/bucket_cors.rb +22 -21
- data/lib/aws-sdk-s3/bucket_lifecycle.rb +23 -18
- data/lib/aws-sdk-s3/bucket_lifecycle_configuration.rb +76 -19
- data/lib/aws-sdk-s3/bucket_logging.rb +21 -14
- data/lib/aws-sdk-s3/bucket_notification.rb +6 -6
- data/lib/aws-sdk-s3/bucket_policy.rb +65 -20
- data/lib/aws-sdk-s3/bucket_region_cache.rb +9 -5
- data/lib/aws-sdk-s3/bucket_request_payment.rb +15 -15
- data/lib/aws-sdk-s3/bucket_tagging.rb +19 -19
- data/lib/aws-sdk-s3/bucket_versioning.rb +41 -41
- data/lib/aws-sdk-s3/bucket_website.rb +19 -19
- data/lib/aws-sdk-s3/client.rb +9352 -3264
- data/lib/aws-sdk-s3/client_api.rb +697 -164
- data/lib/aws-sdk-s3/customizations/bucket.rb +1 -1
- data/lib/aws-sdk-s3/customizations/errors.rb +16 -3
- data/lib/aws-sdk-s3/customizations/object.rb +112 -56
- 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 +26 -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 +54 -15
- data/lib/aws-sdk-s3/endpoint_provider.rb +439 -456
- data/lib/aws-sdk-s3/endpoints.rb +629 -1261
- data/lib/aws-sdk-s3/errors.rb +58 -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 +156 -69
- data/lib/aws-sdk-s3/file_uploader.rb +4 -6
- data/lib/aws-sdk-s3/legacy_signer.rb +2 -1
- data/lib/aws-sdk-s3/multipart_download_error.rb +8 -0
- data/lib/aws-sdk-s3/multipart_file_uploader.rb +56 -69
- data/lib/aws-sdk-s3/multipart_stream_uploader.rb +84 -91
- data/lib/aws-sdk-s3/multipart_upload.rb +179 -26
- data/lib/aws-sdk-s3/multipart_upload_error.rb +3 -4
- data/lib/aws-sdk-s3/multipart_upload_part.rb +201 -60
- data/lib/aws-sdk-s3/object.rb +2007 -281
- data/lib/aws-sdk-s3/object_acl.rb +43 -23
- data/lib/aws-sdk-s3/object_copier.rb +1 -1
- data/lib/aws-sdk-s3/object_multipart_copier.rb +44 -25
- data/lib/aws-sdk-s3/object_summary.rb +1735 -232
- data/lib/aws-sdk-s3/object_version.rb +394 -52
- data/lib/aws-sdk-s3/plugins/access_grants.rb +178 -0
- data/lib/aws-sdk-s3/plugins/checksum_algorithm.rb +31 -0
- data/lib/aws-sdk-s3/plugins/endpoints.rb +32 -208
- data/lib/aws-sdk-s3/plugins/express_session_auth.rb +88 -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 +10 -70
- data/lib/aws-sdk-s3/plugins/s3_signer.rb +7 -2
- data/lib/aws-sdk-s3/plugins/streaming_retry.rb +5 -7
- data/lib/aws-sdk-s3/plugins/url_encoded_keys.rb +2 -1
- data/lib/aws-sdk-s3/presigned_post.rb +52 -43
- data/lib/aws-sdk-s3/presigner.rb +9 -7
- data/lib/aws-sdk-s3/resource.rb +127 -22
- data/lib/aws-sdk-s3/transfer_manager.rb +252 -0
- data/lib/aws-sdk-s3/types.rb +8068 -1887
- data/lib/aws-sdk-s3.rb +35 -31
- data/sig/bucket.rbs +231 -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 +2584 -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 +44 -0
- data/sig/multipart_upload.rbs +120 -0
- data/sig/multipart_upload_part.rbs +109 -0
- data/sig/object.rbs +462 -0
- data/sig/object_acl.rbs +86 -0
- data/sig/object_summary.rbs +345 -0
- data/sig/object_version.rbs +143 -0
- data/sig/resource.rbs +141 -0
- data/sig/types.rbs +2866 -0
- data/sig/waiters.rbs +95 -0
- metadata +44 -12
- data/lib/aws-sdk-s3/plugins/skip_whole_multipart_get_checksums.rb +0 -31
data/lib/aws-sdk-s3/object.rb
CHANGED
@@ -45,6 +45,10 @@ module Aws::S3
|
|
45
45
|
# Specifies whether the object retrieved was (true) or was not (false) a
|
46
46
|
# Delete Marker. If false, this response header does not appear in the
|
47
47
|
# response.
|
48
|
+
#
|
49
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
50
|
+
#
|
51
|
+
# </note>
|
48
52
|
# @return [Boolean]
|
49
53
|
def delete_marker
|
50
54
|
data[:delete_marker]
|
@@ -56,10 +60,21 @@ module Aws::S3
|
|
56
60
|
data[:accept_ranges]
|
57
61
|
end
|
58
62
|
|
59
|
-
# If the object expiration is configured (see
|
60
|
-
#
|
61
|
-
# `rule-id` key-value pairs
|
62
|
-
# value of the `rule-id` is
|
63
|
+
# If the object expiration is configured (see [
|
64
|
+
# `PutBucketLifecycleConfiguration` ][1]), the response includes this
|
65
|
+
# header. It includes the `expiry-date` and `rule-id` key-value pairs
|
66
|
+
# providing object expiration information. The value of the `rule-id` is
|
67
|
+
# URL-encoded.
|
68
|
+
#
|
69
|
+
# <note markdown="1"> Object expiration information is not returned in directory buckets and
|
70
|
+
# this header returns the value "`NotImplemented`" in all responses
|
71
|
+
# for directory buckets.
|
72
|
+
#
|
73
|
+
# </note>
|
74
|
+
#
|
75
|
+
#
|
76
|
+
#
|
77
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketLifecycleConfiguration.html
|
63
78
|
# @return [String]
|
64
79
|
def expiration
|
65
80
|
data[:expiration]
|
@@ -82,6 +97,13 @@ module Aws::S3
|
|
82
97
|
# For more information about archiving objects, see [Transitioning
|
83
98
|
# Objects: General Considerations][2].
|
84
99
|
#
|
100
|
+
# <note markdown="1"> This functionality is not supported for directory buckets. Directory
|
101
|
+
# buckets only support `EXPRESS_ONEZONE` (the S3 Express One Zone
|
102
|
+
# storage class) in Availability Zones and `ONEZONE_IA` (the S3 One
|
103
|
+
# Zone-Infrequent Access storage class) in Dedicated Local Zones.
|
104
|
+
#
|
105
|
+
# </note>
|
106
|
+
#
|
85
107
|
#
|
86
108
|
#
|
87
109
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_RestoreObject.html
|
@@ -92,12 +114,16 @@ module Aws::S3
|
|
92
114
|
end
|
93
115
|
|
94
116
|
# The archive state of the head object.
|
117
|
+
#
|
118
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
119
|
+
#
|
120
|
+
# </note>
|
95
121
|
# @return [String]
|
96
122
|
def archive_status
|
97
123
|
data[:archive_status]
|
98
124
|
end
|
99
125
|
|
100
|
-
#
|
126
|
+
# Date and time when the object was last modified.
|
101
127
|
# @return [Time]
|
102
128
|
def last_modified
|
103
129
|
data[:last_modified]
|
@@ -109,11 +135,14 @@ module Aws::S3
|
|
109
135
|
data[:content_length]
|
110
136
|
end
|
111
137
|
|
112
|
-
# The
|
113
|
-
# only be present if
|
114
|
-
#
|
115
|
-
#
|
116
|
-
#
|
138
|
+
# The Base64 encoded, 32-bit `CRC32 checksum` of the object. This
|
139
|
+
# checksum is only be present if the checksum was uploaded with the
|
140
|
+
# object. When you use an API operation on an object that was uploaded
|
141
|
+
# using multipart uploads, this value may not be a direct checksum value
|
142
|
+
# of the full object. Instead, it's a calculation based on the checksum
|
143
|
+
# values of each individual part. For more information about how
|
144
|
+
# checksums are calculated with multipart uploads, see [ Checking object
|
145
|
+
# integrity][1] in the *Amazon S3 User Guide*.
|
117
146
|
#
|
118
147
|
#
|
119
148
|
#
|
@@ -123,11 +152,14 @@ module Aws::S3
|
|
123
152
|
data[:checksum_crc32]
|
124
153
|
end
|
125
154
|
|
126
|
-
# The
|
127
|
-
# only
|
128
|
-
#
|
129
|
-
#
|
130
|
-
#
|
155
|
+
# The Base64 encoded, 32-bit `CRC32C` checksum of the object. This
|
156
|
+
# checksum is only present if the checksum was uploaded with the object.
|
157
|
+
# When you use an API operation on an object that was uploaded using
|
158
|
+
# multipart uploads, this value may not be a direct checksum value of
|
159
|
+
# the full object. Instead, it's a calculation based on the checksum
|
160
|
+
# values of each individual part. For more information about how
|
161
|
+
# checksums are calculated with multipart uploads, see [ Checking object
|
162
|
+
# integrity][1] in the *Amazon S3 User Guide*.
|
131
163
|
#
|
132
164
|
#
|
133
165
|
#
|
@@ -137,11 +169,26 @@ module Aws::S3
|
|
137
169
|
data[:checksum_crc32c]
|
138
170
|
end
|
139
171
|
|
140
|
-
# The
|
141
|
-
#
|
142
|
-
#
|
143
|
-
#
|
144
|
-
#
|
172
|
+
# The Base64 encoded, 64-bit `CRC64NVME` checksum of the object. For
|
173
|
+
# more information, see [Checking object integrity in the Amazon S3 User
|
174
|
+
# Guide][1].
|
175
|
+
#
|
176
|
+
#
|
177
|
+
#
|
178
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html
|
179
|
+
# @return [String]
|
180
|
+
def checksum_crc64nvme
|
181
|
+
data[:checksum_crc64nvme]
|
182
|
+
end
|
183
|
+
|
184
|
+
# The Base64 encoded, 160-bit `SHA1` digest of the object. This will
|
185
|
+
# only be present if the object was uploaded with the object. When you
|
186
|
+
# use the API operation on an object that was uploaded using multipart
|
187
|
+
# uploads, this value may not be a direct checksum value of the full
|
188
|
+
# object. Instead, it's a calculation based on the checksum values of
|
189
|
+
# each individual part. For more information about how checksums are
|
190
|
+
# calculated with multipart uploads, see [ Checking object integrity][1]
|
191
|
+
# in the *Amazon S3 User Guide*.
|
145
192
|
#
|
146
193
|
#
|
147
194
|
#
|
@@ -151,11 +198,14 @@ module Aws::S3
|
|
151
198
|
data[:checksum_sha1]
|
152
199
|
end
|
153
200
|
|
154
|
-
# The
|
155
|
-
# only be present if
|
156
|
-
#
|
157
|
-
#
|
158
|
-
#
|
201
|
+
# The Base64 encoded, 256-bit `SHA256` digest of the object. This will
|
202
|
+
# only be present if the object was uploaded with the object. When you
|
203
|
+
# use an API operation on an object that was uploaded using multipart
|
204
|
+
# uploads, this value may not be a direct checksum value of the full
|
205
|
+
# object. Instead, it's a calculation based on the checksum values of
|
206
|
+
# each individual part. For more information about how checksums are
|
207
|
+
# calculated with multipart uploads, see [ Checking object integrity][1]
|
208
|
+
# in the *Amazon S3 User Guide*.
|
159
209
|
#
|
160
210
|
#
|
161
211
|
#
|
@@ -165,6 +215,21 @@ module Aws::S3
|
|
165
215
|
data[:checksum_sha256]
|
166
216
|
end
|
167
217
|
|
218
|
+
# The checksum type, which determines how part-level checksums are
|
219
|
+
# combined to create an object-level checksum for multipart objects. You
|
220
|
+
# can use this header response to verify that the checksum type that is
|
221
|
+
# received is the same checksum type that was specified in
|
222
|
+
# `CreateMultipartUpload` request. For more information, see [Checking
|
223
|
+
# object integrity in the Amazon S3 User Guide][1].
|
224
|
+
#
|
225
|
+
#
|
226
|
+
#
|
227
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html
|
228
|
+
# @return [String]
|
229
|
+
def checksum_type
|
230
|
+
data[:checksum_type]
|
231
|
+
end
|
232
|
+
|
168
233
|
# An entity tag (ETag) is an opaque identifier assigned by a web server
|
169
234
|
# to a specific version of a resource found at a URL.
|
170
235
|
# @return [String]
|
@@ -177,12 +242,20 @@ module Aws::S3
|
|
177
242
|
# API like SOAP that supports more flexible metadata than the REST API.
|
178
243
|
# For example, using SOAP, you can create metadata whose values are not
|
179
244
|
# legal HTTP headers.
|
245
|
+
#
|
246
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
247
|
+
#
|
248
|
+
# </note>
|
180
249
|
# @return [Integer]
|
181
250
|
def missing_meta
|
182
251
|
data[:missing_meta]
|
183
252
|
end
|
184
253
|
|
185
|
-
# Version of the object.
|
254
|
+
# Version ID of the object.
|
255
|
+
#
|
256
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
257
|
+
#
|
258
|
+
# </note>
|
186
259
|
# @return [String]
|
187
260
|
def version_id
|
188
261
|
data[:version_id]
|
@@ -200,7 +273,7 @@ module Aws::S3
|
|
200
273
|
data[:content_disposition]
|
201
274
|
end
|
202
275
|
|
203
|
-
#
|
276
|
+
# Indicates what content encodings have been applied to the object and
|
204
277
|
# thus what decoding mechanisms must be applied to obtain the media-type
|
205
278
|
# referenced by the Content-Type header field.
|
206
279
|
# @return [String]
|
@@ -220,6 +293,13 @@ module Aws::S3
|
|
220
293
|
data[:content_type]
|
221
294
|
end
|
222
295
|
|
296
|
+
# The portion of the object returned in the response for a `GET`
|
297
|
+
# request.
|
298
|
+
# @return [String]
|
299
|
+
def content_range
|
300
|
+
data[:content_range]
|
301
|
+
end
|
302
|
+
|
223
303
|
# The date and time at which the object is no longer cacheable.
|
224
304
|
# @return [Time]
|
225
305
|
def expires
|
@@ -234,13 +314,22 @@ module Aws::S3
|
|
234
314
|
# If the bucket is configured as a website, redirects requests for this
|
235
315
|
# object to another object in the same bucket or to an external URL.
|
236
316
|
# Amazon S3 stores the value of this header in the object metadata.
|
317
|
+
#
|
318
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
319
|
+
#
|
320
|
+
# </note>
|
237
321
|
# @return [String]
|
238
322
|
def website_redirect_location
|
239
323
|
data[:website_redirect_location]
|
240
324
|
end
|
241
325
|
|
242
|
-
# The server-side encryption algorithm used when
|
243
|
-
# Amazon S3
|
326
|
+
# The server-side encryption algorithm used when you store this object
|
327
|
+
# in Amazon S3 or Amazon FSx.
|
328
|
+
#
|
329
|
+
# <note markdown="1"> When accessing data stored in Amazon FSx file systems using S3 access
|
330
|
+
# points, the only valid server side encryption option is `aws:fsx`.
|
331
|
+
#
|
332
|
+
# </note>
|
244
333
|
# @return [String]
|
245
334
|
def server_side_encryption
|
246
335
|
data[:server_side_encryption]
|
@@ -253,25 +342,32 @@ module Aws::S3
|
|
253
342
|
end
|
254
343
|
|
255
344
|
# If server-side encryption with a customer-provided encryption key was
|
256
|
-
# requested, the response will include this header
|
257
|
-
# encryption algorithm used.
|
345
|
+
# requested, the response will include this header to confirm the
|
346
|
+
# encryption algorithm that's used.
|
347
|
+
#
|
348
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
349
|
+
#
|
350
|
+
# </note>
|
258
351
|
# @return [String]
|
259
352
|
def sse_customer_algorithm
|
260
353
|
data[:sse_customer_algorithm]
|
261
354
|
end
|
262
355
|
|
263
356
|
# If server-side encryption with a customer-provided encryption key was
|
264
|
-
# requested, the response will include this header to provide
|
265
|
-
# message integrity verification of the customer-provided
|
266
|
-
# key.
|
357
|
+
# requested, the response will include this header to provide the
|
358
|
+
# round-trip message integrity verification of the customer-provided
|
359
|
+
# encryption key.
|
360
|
+
#
|
361
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
362
|
+
#
|
363
|
+
# </note>
|
267
364
|
# @return [String]
|
268
365
|
def sse_customer_key_md5
|
269
366
|
data[:sse_customer_key_md5]
|
270
367
|
end
|
271
368
|
|
272
|
-
# If present,
|
273
|
-
#
|
274
|
-
# object.
|
369
|
+
# If present, indicates the ID of the KMS key that was used for object
|
370
|
+
# encryption.
|
275
371
|
# @return [String]
|
276
372
|
def ssekms_key_id
|
277
373
|
data[:ssekms_key_id]
|
@@ -290,6 +386,13 @@ module Aws::S3
|
|
290
386
|
#
|
291
387
|
# For more information, see [Storage Classes][1].
|
292
388
|
#
|
389
|
+
# <note markdown="1"> <b>Directory buckets </b> - Directory buckets only support
|
390
|
+
# `EXPRESS_ONEZONE` (the S3 Express One Zone storage class) in
|
391
|
+
# Availability Zones and `ONEZONE_IA` (the S3 One Zone-Infrequent Access
|
392
|
+
# storage class) in Dedicated Local Zones.
|
393
|
+
#
|
394
|
+
# </note>
|
395
|
+
#
|
293
396
|
#
|
294
397
|
#
|
295
398
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/storage-class-intro.html
|
@@ -299,7 +402,17 @@ module Aws::S3
|
|
299
402
|
end
|
300
403
|
|
301
404
|
# If present, indicates that the requester was successfully charged for
|
302
|
-
# the request.
|
405
|
+
# the request. For more information, see [Using Requester Pays buckets
|
406
|
+
# for storage transfers and usage][1] in the *Amazon Simple Storage
|
407
|
+
# Service user guide*.
|
408
|
+
#
|
409
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
410
|
+
#
|
411
|
+
# </note>
|
412
|
+
#
|
413
|
+
#
|
414
|
+
#
|
415
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/RequesterPaysBuckets.html
|
303
416
|
# @return [String]
|
304
417
|
def request_charged
|
305
418
|
data[:request_charged]
|
@@ -342,6 +455,10 @@ module Aws::S3
|
|
342
455
|
#
|
343
456
|
# For more information, see [Replication][1].
|
344
457
|
#
|
458
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
459
|
+
#
|
460
|
+
# </note>
|
461
|
+
#
|
345
462
|
#
|
346
463
|
#
|
347
464
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/NotificationHowTo.html
|
@@ -358,11 +475,33 @@ module Aws::S3
|
|
358
475
|
data[:parts_count]
|
359
476
|
end
|
360
477
|
|
478
|
+
# The number of tags, if any, on the object, when you have the relevant
|
479
|
+
# permission to read object tags.
|
480
|
+
#
|
481
|
+
# You can use [GetObjectTagging][1] to retrieve the tag set associated
|
482
|
+
# with an object.
|
483
|
+
#
|
484
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
485
|
+
#
|
486
|
+
# </note>
|
487
|
+
#
|
488
|
+
#
|
489
|
+
#
|
490
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectTagging.html
|
491
|
+
# @return [Integer]
|
492
|
+
def tag_count
|
493
|
+
data[:tag_count]
|
494
|
+
end
|
495
|
+
|
361
496
|
# The Object Lock mode, if any, that's in effect for this object. This
|
362
497
|
# header is only returned if the requester has the
|
363
498
|
# `s3:GetObjectRetention` permission. For more information about S3
|
364
499
|
# Object Lock, see [Object Lock][1].
|
365
500
|
#
|
501
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
502
|
+
#
|
503
|
+
# </note>
|
504
|
+
#
|
366
505
|
#
|
367
506
|
#
|
368
507
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lock.html
|
@@ -374,6 +513,10 @@ module Aws::S3
|
|
374
513
|
# The date and time when the Object Lock retention period expires. This
|
375
514
|
# header is only returned if the requester has the
|
376
515
|
# `s3:GetObjectRetention` permission.
|
516
|
+
#
|
517
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
518
|
+
#
|
519
|
+
# </note>
|
377
520
|
# @return [Time]
|
378
521
|
def object_lock_retain_until_date
|
379
522
|
data[:object_lock_retain_until_date]
|
@@ -385,6 +528,10 @@ module Aws::S3
|
|
385
528
|
# specified version of this object has never had a legal hold applied.
|
386
529
|
# For more information about S3 Object Lock, see [Object Lock][1].
|
387
530
|
#
|
531
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
532
|
+
#
|
533
|
+
# </note>
|
534
|
+
#
|
388
535
|
#
|
389
536
|
#
|
390
537
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lock.html
|
@@ -407,7 +554,7 @@ module Aws::S3
|
|
407
554
|
#
|
408
555
|
# @return [self]
|
409
556
|
def load
|
410
|
-
resp = Aws::Plugins::UserAgent.
|
557
|
+
resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
|
411
558
|
@client.head_object(
|
412
559
|
bucket: @bucket_name,
|
413
560
|
key: @key
|
@@ -457,7 +604,7 @@ module Aws::S3
|
|
457
604
|
options, params = separate_params_and_options(options)
|
458
605
|
waiter = Waiters::ObjectExists.new(options)
|
459
606
|
yield_waiter_and_warn(waiter, &block) if block_given?
|
460
|
-
Aws::Plugins::UserAgent.
|
607
|
+
Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
|
461
608
|
waiter.wait(params.merge(bucket: @bucket_name,
|
462
609
|
key: @key))
|
463
610
|
end
|
@@ -478,7 +625,7 @@ module Aws::S3
|
|
478
625
|
options, params = separate_params_and_options(options)
|
479
626
|
waiter = Waiters::ObjectNotExists.new(options)
|
480
627
|
yield_waiter_and_warn(waiter, &block) if block_given?
|
481
|
-
Aws::Plugins::UserAgent.
|
628
|
+
Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
|
482
629
|
waiter.wait(params.merge(bucket: @bucket_name,
|
483
630
|
key: @key))
|
484
631
|
end
|
@@ -583,7 +730,7 @@ module Aws::S3
|
|
583
730
|
:retry
|
584
731
|
end
|
585
732
|
end
|
586
|
-
Aws::Plugins::UserAgent.
|
733
|
+
Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
|
587
734
|
Aws::Waiters::Waiter.new(options).wait({})
|
588
735
|
end
|
589
736
|
end
|
@@ -595,7 +742,7 @@ module Aws::S3
|
|
595
742
|
# object.copy_from({
|
596
743
|
# acl: "private", # accepts private, public-read, public-read-write, authenticated-read, aws-exec-read, bucket-owner-read, bucket-owner-full-control
|
597
744
|
# cache_control: "CacheControl",
|
598
|
-
# checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256
|
745
|
+
# checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256, CRC64NVME
|
599
746
|
# content_disposition: "ContentDisposition",
|
600
747
|
# content_encoding: "ContentEncoding",
|
601
748
|
# content_language: "ContentLanguage",
|
@@ -615,8 +762,8 @@ module Aws::S3
|
|
615
762
|
# },
|
616
763
|
# metadata_directive: "COPY", # accepts COPY, REPLACE
|
617
764
|
# tagging_directive: "COPY", # accepts COPY, REPLACE
|
618
|
-
# server_side_encryption: "AES256", # accepts AES256, aws:kms, aws:kms:dsse
|
619
|
-
# storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW
|
765
|
+
# server_side_encryption: "AES256", # accepts AES256, aws:fsx, aws:kms, aws:kms:dsse
|
766
|
+
# storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW, EXPRESS_ONEZONE, FSX_OPENZFS
|
620
767
|
# website_redirect_location: "WebsiteRedirectLocation",
|
621
768
|
# sse_customer_algorithm: "SSECustomerAlgorithm",
|
622
769
|
# sse_customer_key: "SSECustomerKey",
|
@@ -637,40 +784,98 @@ module Aws::S3
|
|
637
784
|
# })
|
638
785
|
# @param [Hash] options ({})
|
639
786
|
# @option options [String] :acl
|
640
|
-
# The canned ACL to apply to the object.
|
787
|
+
# The canned access control list (ACL) to apply to the object.
|
788
|
+
#
|
789
|
+
# When you copy an object, the ACL metadata is not preserved and is set
|
790
|
+
# to `private` by default. Only the owner has full access control. To
|
791
|
+
# override the default ACL setting, specify a new ACL when you generate
|
792
|
+
# a copy request. For more information, see [Using ACLs][1].
|
793
|
+
#
|
794
|
+
# If the destination bucket that you're copying objects to uses the
|
795
|
+
# bucket owner enforced setting for S3 Object Ownership, ACLs are
|
796
|
+
# disabled and no longer affect permissions. Buckets that use this
|
797
|
+
# setting only accept `PUT` requests that don't specify an ACL or `PUT`
|
798
|
+
# requests that specify bucket owner full control ACLs, such as the
|
799
|
+
# `bucket-owner-full-control` canned ACL or an equivalent form of this
|
800
|
+
# ACL expressed in the XML format. For more information, see
|
801
|
+
# [Controlling ownership of objects and disabling ACLs][2] in the
|
802
|
+
# *Amazon S3 User Guide*.
|
803
|
+
#
|
804
|
+
# <note markdown="1"> * If your destination bucket uses the bucket owner enforced setting
|
805
|
+
# for Object Ownership, all objects written to the bucket by any
|
806
|
+
# account will be owned by the bucket owner.
|
641
807
|
#
|
642
|
-
# This
|
808
|
+
# * This functionality is not supported for directory buckets.
|
809
|
+
#
|
810
|
+
# * This functionality is not supported for Amazon S3 on Outposts.
|
811
|
+
#
|
812
|
+
# </note>
|
813
|
+
#
|
814
|
+
#
|
815
|
+
#
|
816
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/S3_ACLs_UsingACLs.html
|
817
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/about-object-ownership.html
|
643
818
|
# @option options [String] :cache_control
|
644
|
-
# Specifies caching behavior along the request/reply chain.
|
819
|
+
# Specifies the caching behavior along the request/reply chain.
|
645
820
|
# @option options [String] :checksum_algorithm
|
646
|
-
# Indicates the algorithm you want Amazon S3 to use to create the
|
821
|
+
# Indicates the algorithm that you want Amazon S3 to use to create the
|
647
822
|
# checksum for the object. For more information, see [Checking object
|
648
823
|
# integrity][1] in the *Amazon S3 User Guide*.
|
649
824
|
#
|
825
|
+
# When you copy an object, if the source object has a checksum, that
|
826
|
+
# checksum value will be copied to the new object by default. If the
|
827
|
+
# `CopyObject` request does not include this `x-amz-checksum-algorithm`
|
828
|
+
# header, the checksum algorithm will be copied from the source object
|
829
|
+
# to the destination object (if it's present on the source object). You
|
830
|
+
# can optionally specify a different checksum algorithm to use with the
|
831
|
+
# `x-amz-checksum-algorithm` header. Unrecognized or unsupported values
|
832
|
+
# will respond with the HTTP status code `400 Bad Request`.
|
833
|
+
#
|
834
|
+
# <note markdown="1"> For directory buckets, when you use Amazon Web Services SDKs, `CRC32`
|
835
|
+
# is the default checksum algorithm that's used for performance.
|
836
|
+
#
|
837
|
+
# </note>
|
838
|
+
#
|
650
839
|
#
|
651
840
|
#
|
652
841
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html
|
653
842
|
# @option options [String] :content_disposition
|
654
|
-
# Specifies presentational information for the object.
|
843
|
+
# Specifies presentational information for the object. Indicates whether
|
844
|
+
# an object should be displayed in a web browser or downloaded as a
|
845
|
+
# file. It allows specifying the desired filename for the downloaded
|
846
|
+
# file.
|
655
847
|
# @option options [String] :content_encoding
|
656
848
|
# Specifies what content encodings have been applied to the object and
|
657
849
|
# thus what decoding mechanisms must be applied to obtain the media-type
|
658
850
|
# referenced by the Content-Type header field.
|
851
|
+
#
|
852
|
+
# <note markdown="1"> For directory buckets, only the `aws-chunked` value is supported in
|
853
|
+
# this header field.
|
854
|
+
#
|
855
|
+
# </note>
|
659
856
|
# @option options [String] :content_language
|
660
857
|
# The language the content is in.
|
661
858
|
# @option options [String] :content_type
|
662
|
-
# A standard MIME type
|
859
|
+
# A standard MIME type that describes the format of the object data.
|
663
860
|
# @option options [required, String] :copy_source
|
664
|
-
# Specifies the source object for the copy operation.
|
665
|
-
#
|
666
|
-
# the
|
861
|
+
# Specifies the source object for the copy operation. The source object
|
862
|
+
# can be up to 5 GB. If the source object is an object that was uploaded
|
863
|
+
# by using a multipart upload, the object copy will be a single part
|
864
|
+
# object after the source object is copied to the destination bucket.
|
865
|
+
#
|
866
|
+
# You specify the value of the copy source in one of two formats,
|
867
|
+
# depending on whether you want to access the source object through an
|
868
|
+
# [access point][1]:
|
667
869
|
#
|
668
870
|
# * For objects not accessed through an access point, specify the name
|
669
871
|
# of the source bucket and the key of the source object, separated by
|
670
872
|
# a slash (/). For example, to copy the object `reports/january.pdf`
|
671
|
-
# from the bucket `awsexamplebucket`, use
|
873
|
+
# from the general purpose bucket `awsexamplebucket`, use
|
672
874
|
# `awsexamplebucket/reports/january.pdf`. The value must be
|
673
|
-
# URL-encoded.
|
875
|
+
# URL-encoded. To copy the object `reports/january.pdf` from the
|
876
|
+
# directory bucket `awsexamplebucket--use1-az5--x-s3`, use
|
877
|
+
# `awsexamplebucket--use1-az5--x-s3/reports/january.pdf`. The value
|
878
|
+
# must be URL-encoded.
|
674
879
|
#
|
675
880
|
# * For objects accessed through access points, specify the Amazon
|
676
881
|
# Resource Name (ARN) of the object as accessed through the access
|
@@ -682,9 +887,11 @@ module Aws::S3
|
|
682
887
|
# `arn:aws:s3:us-west-2:123456789012:accesspoint/my-access-point/object/reports/january.pdf`.
|
683
888
|
# The value must be URL encoded.
|
684
889
|
#
|
685
|
-
# <note markdown="1"> Amazon S3 supports copy operations using
|
686
|
-
#
|
687
|
-
#
|
890
|
+
# <note markdown="1"> * Amazon S3 supports copy operations using Access points only when
|
891
|
+
# the source and destination buckets are in the same Amazon Web
|
892
|
+
# Services Region.
|
893
|
+
#
|
894
|
+
# * Access points are not supported by directory buckets.
|
688
895
|
#
|
689
896
|
# </note>
|
690
897
|
#
|
@@ -697,156 +904,574 @@ module Aws::S3
|
|
697
904
|
# `arn:aws:s3-outposts:us-west-2:123456789012:outpost/my-outpost/object/reports/january.pdf`.
|
698
905
|
# The value must be URL-encoded.
|
699
906
|
#
|
700
|
-
#
|
701
|
-
#
|
907
|
+
# If your source bucket versioning is enabled, the `x-amz-copy-source`
|
908
|
+
# header by default identifies the current version of an object to copy.
|
909
|
+
# If the current version is a delete marker, Amazon S3 behaves as if the
|
910
|
+
# object was deleted. To copy a different version, use the `versionId`
|
911
|
+
# query parameter. Specifically, append `?versionId=<version-id>` to the
|
912
|
+
# value (for example,
|
702
913
|
# `awsexamplebucket/reports/january.pdf?versionId=QUpfdndhfd8438MNFDN93jdnJFkdmqnh893`).
|
703
914
|
# If you don't specify a version ID, Amazon S3 copies the latest
|
704
915
|
# version of the source object.
|
705
916
|
#
|
917
|
+
# If you enable versioning on the destination bucket, Amazon S3
|
918
|
+
# generates a unique version ID for the copied object. This version ID
|
919
|
+
# is different from the version ID of the source object. Amazon S3
|
920
|
+
# returns the version ID of the copied object in the `x-amz-version-id`
|
921
|
+
# response header in the response.
|
922
|
+
#
|
923
|
+
# If you do not enable versioning or suspend it on the destination
|
924
|
+
# bucket, the version ID that Amazon S3 generates in the
|
925
|
+
# `x-amz-version-id` response header is always null.
|
926
|
+
#
|
927
|
+
# <note markdown="1"> **Directory buckets** - S3 Versioning isn't enabled and supported for
|
928
|
+
# directory buckets.
|
929
|
+
#
|
930
|
+
# </note>
|
931
|
+
#
|
706
932
|
#
|
707
933
|
#
|
708
934
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/access-points.html
|
709
935
|
# @option options [String] :copy_source_if_match
|
710
936
|
# Copies the object if its entity tag (ETag) matches the specified tag.
|
937
|
+
#
|
938
|
+
# If both the `x-amz-copy-source-if-match` and
|
939
|
+
# `x-amz-copy-source-if-unmodified-since` headers are present in the
|
940
|
+
# request and evaluate as follows, Amazon S3 returns `200 OK` and copies
|
941
|
+
# the data:
|
942
|
+
#
|
943
|
+
# * `x-amz-copy-source-if-match` condition evaluates to true
|
944
|
+
#
|
945
|
+
# * `x-amz-copy-source-if-unmodified-since` condition evaluates to false
|
711
946
|
# @option options [Time,DateTime,Date,Integer,String] :copy_source_if_modified_since
|
712
947
|
# Copies the object if it has been modified since the specified time.
|
948
|
+
#
|
949
|
+
# If both the `x-amz-copy-source-if-none-match` and
|
950
|
+
# `x-amz-copy-source-if-modified-since` headers are present in the
|
951
|
+
# request and evaluate as follows, Amazon S3 returns the `412
|
952
|
+
# Precondition Failed` response code:
|
953
|
+
#
|
954
|
+
# * `x-amz-copy-source-if-none-match` condition evaluates to false
|
955
|
+
#
|
956
|
+
# * `x-amz-copy-source-if-modified-since` condition evaluates to true
|
713
957
|
# @option options [String] :copy_source_if_none_match
|
714
958
|
# Copies the object if its entity tag (ETag) is different than the
|
715
959
|
# specified ETag.
|
960
|
+
#
|
961
|
+
# If both the `x-amz-copy-source-if-none-match` and
|
962
|
+
# `x-amz-copy-source-if-modified-since` headers are present in the
|
963
|
+
# request and evaluate as follows, Amazon S3 returns the `412
|
964
|
+
# Precondition Failed` response code:
|
965
|
+
#
|
966
|
+
# * `x-amz-copy-source-if-none-match` condition evaluates to false
|
967
|
+
#
|
968
|
+
# * `x-amz-copy-source-if-modified-since` condition evaluates to true
|
716
969
|
# @option options [Time,DateTime,Date,Integer,String] :copy_source_if_unmodified_since
|
717
970
|
# Copies the object if it hasn't been modified since the specified
|
718
971
|
# time.
|
972
|
+
#
|
973
|
+
# If both the `x-amz-copy-source-if-match` and
|
974
|
+
# `x-amz-copy-source-if-unmodified-since` headers are present in the
|
975
|
+
# request and evaluate as follows, Amazon S3 returns `200 OK` and copies
|
976
|
+
# the data:
|
977
|
+
#
|
978
|
+
# * `x-amz-copy-source-if-match` condition evaluates to true
|
979
|
+
#
|
980
|
+
# * `x-amz-copy-source-if-unmodified-since` condition evaluates to false
|
719
981
|
# @option options [Time,DateTime,Date,Integer,String] :expires
|
720
982
|
# The date and time at which the object is no longer cacheable.
|
721
983
|
# @option options [String] :grant_full_control
|
722
984
|
# Gives the grantee READ, READ\_ACP, and WRITE\_ACP permissions on the
|
723
985
|
# object.
|
724
986
|
#
|
725
|
-
# This
|
987
|
+
# <note markdown="1"> * This functionality is not supported for directory buckets.
|
988
|
+
#
|
989
|
+
# * This functionality is not supported for Amazon S3 on Outposts.
|
990
|
+
#
|
991
|
+
# </note>
|
726
992
|
# @option options [String] :grant_read
|
727
993
|
# Allows grantee to read the object data and its metadata.
|
728
994
|
#
|
729
|
-
# This
|
995
|
+
# <note markdown="1"> * This functionality is not supported for directory buckets.
|
996
|
+
#
|
997
|
+
# * This functionality is not supported for Amazon S3 on Outposts.
|
998
|
+
#
|
999
|
+
# </note>
|
730
1000
|
# @option options [String] :grant_read_acp
|
731
1001
|
# Allows grantee to read the object ACL.
|
732
1002
|
#
|
733
|
-
# This
|
1003
|
+
# <note markdown="1"> * This functionality is not supported for directory buckets.
|
1004
|
+
#
|
1005
|
+
# * This functionality is not supported for Amazon S3 on Outposts.
|
1006
|
+
#
|
1007
|
+
# </note>
|
734
1008
|
# @option options [String] :grant_write_acp
|
735
1009
|
# Allows grantee to write the ACL for the applicable object.
|
736
1010
|
#
|
737
|
-
# This
|
1011
|
+
# <note markdown="1"> * This functionality is not supported for directory buckets.
|
1012
|
+
#
|
1013
|
+
# * This functionality is not supported for Amazon S3 on Outposts.
|
1014
|
+
#
|
1015
|
+
# </note>
|
738
1016
|
# @option options [Hash<String,String>] :metadata
|
739
1017
|
# A map of metadata to store with the object in S3.
|
740
1018
|
# @option options [String] :metadata_directive
|
741
1019
|
# Specifies whether the metadata is copied from the source object or
|
742
|
-
# replaced with metadata provided in the request.
|
1020
|
+
# replaced with metadata that's provided in the request. When copying
|
1021
|
+
# an object, you can preserve all metadata (the default) or specify new
|
1022
|
+
# metadata. If this header isn’t specified, `COPY` is the default
|
1023
|
+
# behavior.
|
1024
|
+
#
|
1025
|
+
# **General purpose bucket** - For general purpose buckets, when you
|
1026
|
+
# grant permissions, you can use the `s3:x-amz-metadata-directive`
|
1027
|
+
# condition key to enforce certain metadata behavior when objects are
|
1028
|
+
# uploaded. For more information, see [Amazon S3 condition key
|
1029
|
+
# examples][1] in the *Amazon S3 User Guide*.
|
1030
|
+
#
|
1031
|
+
# <note markdown="1"> `x-amz-website-redirect-location` is unique to each object and is not
|
1032
|
+
# copied when using the `x-amz-metadata-directive` header. To copy the
|
1033
|
+
# value, you must specify `x-amz-website-redirect-location` in the
|
1034
|
+
# request header.
|
1035
|
+
#
|
1036
|
+
# </note>
|
1037
|
+
#
|
1038
|
+
#
|
1039
|
+
#
|
1040
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/amazon-s3-policy-keys.html
|
743
1041
|
# @option options [String] :tagging_directive
|
744
|
-
# Specifies whether the object tag-set
|
745
|
-
# or replaced with tag-set provided in the request.
|
1042
|
+
# Specifies whether the object tag-set is copied from the source object
|
1043
|
+
# or replaced with the tag-set that's provided in the request.
|
1044
|
+
#
|
1045
|
+
# The default value is `COPY`.
|
1046
|
+
#
|
1047
|
+
# <note markdown="1"> **Directory buckets** - For directory buckets in a `CopyObject`
|
1048
|
+
# operation, only the empty tag-set is supported. Any requests that
|
1049
|
+
# attempt to write non-empty tags into directory buckets will receive a
|
1050
|
+
# `501 Not Implemented` status code. When the destination bucket is a
|
1051
|
+
# directory bucket, you will receive a `501 Not Implemented` response in
|
1052
|
+
# any of the following situations:
|
1053
|
+
#
|
1054
|
+
# * When you attempt to `COPY` the tag-set from an S3 source object that
|
1055
|
+
# has non-empty tags.
|
1056
|
+
#
|
1057
|
+
# * When you attempt to `REPLACE` the tag-set of a source object and set
|
1058
|
+
# a non-empty value to `x-amz-tagging`.
|
1059
|
+
#
|
1060
|
+
# * When you don't set the `x-amz-tagging-directive` header and the
|
1061
|
+
# source object has non-empty tags. This is because the default value
|
1062
|
+
# of `x-amz-tagging-directive` is `COPY`.
|
1063
|
+
#
|
1064
|
+
# Because only the empty tag-set is supported for directory buckets in a
|
1065
|
+
# `CopyObject` operation, the following situations are allowed:
|
1066
|
+
#
|
1067
|
+
# * When you attempt to `COPY` the tag-set from a directory bucket
|
1068
|
+
# source object that has no tags to a general purpose bucket. It
|
1069
|
+
# copies an empty tag-set to the destination object.
|
1070
|
+
#
|
1071
|
+
# * When you attempt to `REPLACE` the tag-set of a directory bucket
|
1072
|
+
# source object and set the `x-amz-tagging` value of the directory
|
1073
|
+
# bucket destination object to empty.
|
1074
|
+
#
|
1075
|
+
# * When you attempt to `REPLACE` the tag-set of a general purpose
|
1076
|
+
# bucket source object that has non-empty tags and set the
|
1077
|
+
# `x-amz-tagging` value of the directory bucket destination object to
|
1078
|
+
# empty.
|
1079
|
+
#
|
1080
|
+
# * When you attempt to `REPLACE` the tag-set of a directory bucket
|
1081
|
+
# source object and don't set the `x-amz-tagging` value of the
|
1082
|
+
# directory bucket destination object. This is because the default
|
1083
|
+
# value of `x-amz-tagging` is the empty value.
|
1084
|
+
#
|
1085
|
+
# </note>
|
746
1086
|
# @option options [String] :server_side_encryption
|
747
1087
|
# The server-side encryption algorithm used when storing this object in
|
748
|
-
# Amazon S3
|
1088
|
+
# Amazon S3. Unrecognized or unsupported values won’t write a
|
1089
|
+
# destination object and will receive a `400 Bad Request` response.
|
1090
|
+
#
|
1091
|
+
# Amazon S3 automatically encrypts all new objects that are copied to an
|
1092
|
+
# S3 bucket. When copying an object, if you don't specify encryption
|
1093
|
+
# information in your copy request, the encryption setting of the target
|
1094
|
+
# object is set to the default encryption configuration of the
|
1095
|
+
# destination bucket. By default, all buckets have a base level of
|
1096
|
+
# encryption configuration that uses server-side encryption with Amazon
|
1097
|
+
# S3 managed keys (SSE-S3). If the destination bucket has a different
|
1098
|
+
# default encryption configuration, Amazon S3 uses the corresponding
|
1099
|
+
# encryption key to encrypt the target object copy.
|
1100
|
+
#
|
1101
|
+
# With server-side encryption, Amazon S3 encrypts your data as it writes
|
1102
|
+
# your data to disks in its data centers and decrypts the data when you
|
1103
|
+
# access it. For more information about server-side encryption, see
|
1104
|
+
# [Using Server-Side Encryption][1] in the *Amazon S3 User Guide*.
|
1105
|
+
#
|
1106
|
+
# <b>General purpose buckets </b>
|
1107
|
+
#
|
1108
|
+
# * For general purpose buckets, there are the following supported
|
1109
|
+
# options for server-side encryption: server-side encryption with Key
|
1110
|
+
# Management Service (KMS) keys (SSE-KMS), dual-layer server-side
|
1111
|
+
# encryption with Amazon Web Services KMS keys (DSSE-KMS), and
|
1112
|
+
# server-side encryption with customer-provided encryption keys
|
1113
|
+
# (SSE-C). Amazon S3 uses the corresponding KMS key, or a
|
1114
|
+
# customer-provided key to encrypt the target object copy.
|
1115
|
+
#
|
1116
|
+
# * When you perform a `CopyObject` operation, if you want to use a
|
1117
|
+
# different type of encryption setting for the target object, you can
|
1118
|
+
# specify appropriate encryption-related headers to encrypt the target
|
1119
|
+
# object with an Amazon S3 managed key, a KMS key, or a
|
1120
|
+
# customer-provided key. If the encryption setting in your request is
|
1121
|
+
# different from the default encryption configuration of the
|
1122
|
+
# destination bucket, the encryption setting in your request takes
|
1123
|
+
# precedence.
|
1124
|
+
#
|
1125
|
+
# <b>Directory buckets </b>
|
1126
|
+
#
|
1127
|
+
# * For directory buckets, there are only two supported options for
|
1128
|
+
# server-side encryption: server-side encryption with Amazon S3
|
1129
|
+
# managed keys (SSE-S3) (`AES256`) and server-side encryption with KMS
|
1130
|
+
# keys (SSE-KMS) (`aws:kms`). We recommend that the bucket's default
|
1131
|
+
# encryption uses the desired encryption configuration and you don't
|
1132
|
+
# override the bucket default encryption in your `CreateSession`
|
1133
|
+
# requests or `PUT` object requests. Then, new objects are
|
1134
|
+
# automatically encrypted with the desired encryption settings. For
|
1135
|
+
# more information, see [Protecting data with server-side
|
1136
|
+
# encryption][2] in the *Amazon S3 User Guide*. For more information
|
1137
|
+
# about the encryption overriding behaviors in directory buckets, see
|
1138
|
+
# [Specifying server-side encryption with KMS for new object
|
1139
|
+
# uploads][3].
|
1140
|
+
#
|
1141
|
+
# * To encrypt new object copies to a directory bucket with SSE-KMS, we
|
1142
|
+
# recommend you specify SSE-KMS as the directory bucket's default
|
1143
|
+
# encryption configuration with a KMS key (specifically, a [customer
|
1144
|
+
# managed key][4]). The [Amazon Web Services managed key][5]
|
1145
|
+
# (`aws/s3`) isn't supported. Your SSE-KMS configuration can only
|
1146
|
+
# support 1 [customer managed key][4] per directory bucket for the
|
1147
|
+
# lifetime of the bucket. After you specify a customer managed key for
|
1148
|
+
# SSE-KMS, you can't override the customer managed key for the
|
1149
|
+
# bucket's SSE-KMS configuration. Then, when you perform a
|
1150
|
+
# `CopyObject` operation and want to specify server-side encryption
|
1151
|
+
# settings for new object copies with SSE-KMS in the
|
1152
|
+
# encryption-related request headers, you must ensure the encryption
|
1153
|
+
# key is the same customer managed key that you specified for the
|
1154
|
+
# directory bucket's default encryption configuration.
|
1155
|
+
#
|
1156
|
+
# * <b>S3 access points for Amazon FSx </b> - When accessing data stored
|
1157
|
+
# in Amazon FSx file systems using S3 access points, the only valid
|
1158
|
+
# server side encryption option is `aws:fsx`. All Amazon FSx file
|
1159
|
+
# systems have encryption configured by default and are encrypted at
|
1160
|
+
# rest. Data is automatically encrypted before being written to the
|
1161
|
+
# file system, and automatically decrypted as it is read. These
|
1162
|
+
# processes are handled transparently by Amazon FSx.
|
1163
|
+
#
|
1164
|
+
#
|
1165
|
+
#
|
1166
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/serv-side-encryption.html
|
1167
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-serv-side-encryption.html
|
1168
|
+
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-specifying-kms-encryption.html
|
1169
|
+
# [4]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk
|
1170
|
+
# [5]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk
|
749
1171
|
# @option options [String] :storage_class
|
750
|
-
#
|
751
|
-
#
|
752
|
-
#
|
753
|
-
#
|
754
|
-
#
|
1172
|
+
# If the `x-amz-storage-class` header is not used, the copied object
|
1173
|
+
# will be stored in the `STANDARD` Storage Class by default. The
|
1174
|
+
# `STANDARD` storage class provides high durability and high
|
1175
|
+
# availability. Depending on performance needs, you can specify a
|
1176
|
+
# different Storage Class.
|
1177
|
+
#
|
1178
|
+
# <note markdown="1"> * <b>Directory buckets </b> - Directory buckets only support
|
1179
|
+
# `EXPRESS_ONEZONE` (the S3 Express One Zone storage class) in
|
1180
|
+
# Availability Zones and `ONEZONE_IA` (the S3 One Zone-Infrequent
|
1181
|
+
# Access storage class) in Dedicated Local Zones. Unsupported storage
|
1182
|
+
# class values won't write a destination object and will respond with
|
1183
|
+
# the HTTP status code `400 Bad Request`.
|
1184
|
+
#
|
1185
|
+
# * <b>Amazon S3 on Outposts </b> - S3 on Outposts only uses the
|
1186
|
+
# `OUTPOSTS` Storage Class.
|
1187
|
+
#
|
1188
|
+
# </note>
|
1189
|
+
#
|
1190
|
+
# You can use the `CopyObject` action to change the storage class of an
|
1191
|
+
# object that is already stored in Amazon S3 by using the
|
1192
|
+
# `x-amz-storage-class` header. For more information, see [Storage
|
1193
|
+
# Classes][1] in the *Amazon S3 User Guide*.
|
1194
|
+
#
|
1195
|
+
# Before using an object as a source object for the copy operation, you
|
1196
|
+
# must restore a copy of it if it meets any of the following conditions:
|
1197
|
+
#
|
1198
|
+
# * The storage class of the source object is `GLACIER` or
|
1199
|
+
# `DEEP_ARCHIVE`.
|
1200
|
+
#
|
1201
|
+
# * The storage class of the source object is `INTELLIGENT_TIERING` and
|
1202
|
+
# it's [S3 Intelligent-Tiering access tier][2] is `Archive Access` or
|
1203
|
+
# `Deep Archive Access`.
|
1204
|
+
#
|
1205
|
+
# For more information, see [RestoreObject][3] and [Copying Objects][4]
|
755
1206
|
# in the *Amazon S3 User Guide*.
|
756
1207
|
#
|
757
1208
|
#
|
758
1209
|
#
|
759
1210
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/storage-class-intro.html
|
1211
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/intelligent-tiering-overview.html#intel-tiering-tier-definition
|
1212
|
+
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_RestoreObject.html
|
1213
|
+
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/dev/CopyingObjectsExamples.html
|
760
1214
|
# @option options [String] :website_redirect_location
|
761
|
-
# If the bucket is configured as a website, redirects
|
762
|
-
# object to another object in the same bucket or
|
763
|
-
# Amazon S3 stores the value of this header in the
|
764
|
-
# value is unique to each object and is not copied
|
765
|
-
# `x-amz-metadata-directive` header. Instead, you may opt
|
766
|
-
# this header in combination with the
|
1215
|
+
# If the destination bucket is configured as a website, redirects
|
1216
|
+
# requests for this object copy to another object in the same bucket or
|
1217
|
+
# to an external URL. Amazon S3 stores the value of this header in the
|
1218
|
+
# object metadata. This value is unique to each object and is not copied
|
1219
|
+
# when using the `x-amz-metadata-directive` header. Instead, you may opt
|
1220
|
+
# to provide this header in combination with the
|
1221
|
+
# `x-amz-metadata-directive` header.
|
1222
|
+
#
|
1223
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
1224
|
+
#
|
1225
|
+
# </note>
|
767
1226
|
# @option options [String] :sse_customer_algorithm
|
768
|
-
# Specifies the algorithm to use
|
769
|
-
# example, AES256).
|
1227
|
+
# Specifies the algorithm to use when encrypting the object (for
|
1228
|
+
# example, `AES256`).
|
1229
|
+
#
|
1230
|
+
# When you perform a `CopyObject` operation, if you want to use a
|
1231
|
+
# different type of encryption setting for the target object, you can
|
1232
|
+
# specify appropriate encryption-related headers to encrypt the target
|
1233
|
+
# object with an Amazon S3 managed key, a KMS key, or a
|
1234
|
+
# customer-provided key. If the encryption setting in your request is
|
1235
|
+
# different from the default encryption configuration of the destination
|
1236
|
+
# bucket, the encryption setting in your request takes precedence.
|
1237
|
+
#
|
1238
|
+
# <note markdown="1"> This functionality is not supported when the destination bucket is a
|
1239
|
+
# directory bucket.
|
1240
|
+
#
|
1241
|
+
# </note>
|
770
1242
|
# @option options [String] :sse_customer_key
|
771
1243
|
# Specifies the customer-provided encryption key for Amazon S3 to use in
|
772
1244
|
# encrypting data. This value is used to store the object and then it is
|
773
|
-
# discarded
|
1245
|
+
# discarded. Amazon S3 does not store the encryption key. The key must
|
774
1246
|
# be appropriate for use with the algorithm specified in the
|
775
1247
|
# `x-amz-server-side-encryption-customer-algorithm` header.
|
1248
|
+
#
|
1249
|
+
# <note markdown="1"> This functionality is not supported when the destination bucket is a
|
1250
|
+
# directory bucket.
|
1251
|
+
#
|
1252
|
+
# </note>
|
776
1253
|
# @option options [String] :sse_customer_key_md5
|
777
1254
|
# Specifies the 128-bit MD5 digest of the encryption key according to
|
778
1255
|
# RFC 1321. Amazon S3 uses this header for a message integrity check to
|
779
1256
|
# ensure that the encryption key was transmitted without error.
|
1257
|
+
#
|
1258
|
+
# <note markdown="1"> This functionality is not supported when the destination bucket is a
|
1259
|
+
# directory bucket.
|
1260
|
+
#
|
1261
|
+
# </note>
|
780
1262
|
# @option options [String] :ssekms_key_id
|
781
|
-
# Specifies the KMS key ID
|
782
|
-
# requests for an object protected by
|
783
|
-
# via SSL or using SigV4. For
|
784
|
-
#
|
785
|
-
# CLI, see [Specifying the
|
786
|
-
# Authentication][1] in the *Amazon S3 User
|
1263
|
+
# Specifies the KMS key ID (Key ID, Key ARN, or Key Alias) to use for
|
1264
|
+
# object encryption. All GET and PUT requests for an object protected by
|
1265
|
+
# KMS will fail if they're not made via SSL or using SigV4. For
|
1266
|
+
# information about configuring any of the officially supported Amazon
|
1267
|
+
# Web Services SDKs and Amazon Web Services CLI, see [Specifying the
|
1268
|
+
# Signature Version in Request Authentication][1] in the *Amazon S3 User
|
1269
|
+
# Guide*.
|
1270
|
+
#
|
1271
|
+
# **Directory buckets** - To encrypt data using SSE-KMS, it's
|
1272
|
+
# recommended to specify the `x-amz-server-side-encryption` header to
|
1273
|
+
# `aws:kms`. Then, the `x-amz-server-side-encryption-aws-kms-key-id`
|
1274
|
+
# header implicitly uses the bucket's default KMS customer managed key
|
1275
|
+
# ID. If you want to explicitly set the `
|
1276
|
+
# x-amz-server-side-encryption-aws-kms-key-id` header, it must match the
|
1277
|
+
# bucket's default customer managed key (using key ID or ARN, not
|
1278
|
+
# alias). Your SSE-KMS configuration can only support 1 [customer
|
1279
|
+
# managed key][2] per directory bucket's lifetime. The [Amazon Web
|
1280
|
+
# Services managed key][3] (`aws/s3`) isn't supported. Incorrect key
|
1281
|
+
# specification results in an HTTP `400 Bad Request` error.
|
787
1282
|
#
|
788
1283
|
#
|
789
1284
|
#
|
790
1285
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingAWSSDK.html#specify-signature-version
|
1286
|
+
# [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk
|
1287
|
+
# [3]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk
|
791
1288
|
# @option options [String] :ssekms_encryption_context
|
792
|
-
# Specifies the Amazon Web Services KMS Encryption Context
|
793
|
-
#
|
794
|
-
#
|
1289
|
+
# Specifies the Amazon Web Services KMS Encryption Context as an
|
1290
|
+
# additional encryption context to use for the destination object
|
1291
|
+
# encryption. The value of this header is a base64-encoded UTF-8 string
|
1292
|
+
# holding JSON with the encryption context key-value pairs.
|
1293
|
+
#
|
1294
|
+
# **General purpose buckets** - This value must be explicitly added to
|
1295
|
+
# specify encryption context for `CopyObject` requests if you want an
|
1296
|
+
# additional encryption context for your destination object. The
|
1297
|
+
# additional encryption context of the source object won't be copied to
|
1298
|
+
# the destination object. For more information, see [Encryption
|
1299
|
+
# context][1] in the *Amazon S3 User Guide*.
|
1300
|
+
#
|
1301
|
+
# **Directory buckets** - You can optionally provide an explicit
|
1302
|
+
# encryption context value. The value must match the default encryption
|
1303
|
+
# context - the bucket Amazon Resource Name (ARN). An additional
|
1304
|
+
# encryption context value is not supported.
|
1305
|
+
#
|
1306
|
+
#
|
1307
|
+
#
|
1308
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/UsingKMSEncryption.html#encryption-context
|
795
1309
|
# @option options [Boolean] :bucket_key_enabled
|
796
1310
|
# Specifies whether Amazon S3 should use an S3 Bucket Key for object
|
797
1311
|
# encryption with server-side encryption using Key Management Service
|
798
|
-
# (KMS) keys (SSE-KMS).
|
799
|
-
#
|
1312
|
+
# (KMS) keys (SSE-KMS). If a target object uses SSE-KMS, you can enable
|
1313
|
+
# an S3 Bucket Key for the object.
|
1314
|
+
#
|
1315
|
+
# Setting this header to `true` causes Amazon S3 to use an S3 Bucket Key
|
1316
|
+
# for object encryption with SSE-KMS. Specifying this header with a COPY
|
1317
|
+
# action doesn’t affect bucket-level settings for S3 Bucket Key.
|
1318
|
+
#
|
1319
|
+
# For more information, see [Amazon S3 Bucket Keys][1] in the *Amazon S3
|
1320
|
+
# User Guide*.
|
1321
|
+
#
|
1322
|
+
# <note markdown="1"> **Directory buckets** - S3 Bucket Keys aren't supported, when you
|
1323
|
+
# copy SSE-KMS encrypted objects from general purpose buckets to
|
1324
|
+
# directory buckets, from directory buckets to general purpose buckets,
|
1325
|
+
# or between directory buckets, through [CopyObject][2]. In this case,
|
1326
|
+
# Amazon S3 makes a call to KMS every time a copy request is made for a
|
1327
|
+
# KMS-encrypted object.
|
1328
|
+
#
|
1329
|
+
# </note>
|
1330
|
+
#
|
800
1331
|
#
|
801
|
-
#
|
802
|
-
#
|
1332
|
+
#
|
1333
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/bucket-key.html
|
1334
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html
|
803
1335
|
# @option options [String] :copy_source_sse_customer_algorithm
|
804
1336
|
# Specifies the algorithm to use when decrypting the source object (for
|
805
|
-
# example, AES256).
|
1337
|
+
# example, `AES256`).
|
1338
|
+
#
|
1339
|
+
# If the source object for the copy is stored in Amazon S3 using SSE-C,
|
1340
|
+
# you must provide the necessary encryption information in your request
|
1341
|
+
# so that Amazon S3 can decrypt the object for copying.
|
1342
|
+
#
|
1343
|
+
# <note markdown="1"> This functionality is not supported when the source object is in a
|
1344
|
+
# directory bucket.
|
1345
|
+
#
|
1346
|
+
# </note>
|
806
1347
|
# @option options [String] :copy_source_sse_customer_key
|
807
1348
|
# Specifies the customer-provided encryption key for Amazon S3 to use to
|
808
1349
|
# decrypt the source object. The encryption key provided in this header
|
809
|
-
# must be one that was used when the source object was created.
|
1350
|
+
# must be the same one that was used when the source object was created.
|
1351
|
+
#
|
1352
|
+
# If the source object for the copy is stored in Amazon S3 using SSE-C,
|
1353
|
+
# you must provide the necessary encryption information in your request
|
1354
|
+
# so that Amazon S3 can decrypt the object for copying.
|
1355
|
+
#
|
1356
|
+
# <note markdown="1"> This functionality is not supported when the source object is in a
|
1357
|
+
# directory bucket.
|
1358
|
+
#
|
1359
|
+
# </note>
|
810
1360
|
# @option options [String] :copy_source_sse_customer_key_md5
|
811
1361
|
# Specifies the 128-bit MD5 digest of the encryption key according to
|
812
1362
|
# RFC 1321. Amazon S3 uses this header for a message integrity check to
|
813
1363
|
# ensure that the encryption key was transmitted without error.
|
1364
|
+
#
|
1365
|
+
# If the source object for the copy is stored in Amazon S3 using SSE-C,
|
1366
|
+
# you must provide the necessary encryption information in your request
|
1367
|
+
# so that Amazon S3 can decrypt the object for copying.
|
1368
|
+
#
|
1369
|
+
# <note markdown="1"> This functionality is not supported when the source object is in a
|
1370
|
+
# directory bucket.
|
1371
|
+
#
|
1372
|
+
# </note>
|
814
1373
|
# @option options [String] :request_payer
|
815
1374
|
# Confirms that the requester knows that they will be charged for the
|
816
1375
|
# request. Bucket owners need not specify this parameter in their
|
817
|
-
# requests.
|
1376
|
+
# requests. If either the source or destination S3 bucket has Requester
|
1377
|
+
# Pays enabled, the requester will pay for corresponding charges to copy
|
1378
|
+
# the object. For information about downloading objects from Requester
|
818
1379
|
# Pays buckets, see [Downloading Objects in Requester Pays Buckets][1]
|
819
1380
|
# in the *Amazon S3 User Guide*.
|
820
1381
|
#
|
1382
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
1383
|
+
#
|
1384
|
+
# </note>
|
1385
|
+
#
|
821
1386
|
#
|
822
1387
|
#
|
823
1388
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
|
824
1389
|
# @option options [String] :tagging
|
825
|
-
# The tag-set for the object
|
826
|
-
# in conjunction with the `
|
827
|
-
#
|
1390
|
+
# The tag-set for the object copy in the destination bucket. This value
|
1391
|
+
# must be used in conjunction with the `x-amz-tagging-directive` if you
|
1392
|
+
# choose `REPLACE` for the `x-amz-tagging-directive`. If you choose
|
1393
|
+
# `COPY` for the `x-amz-tagging-directive`, you don't need to set the
|
1394
|
+
# `x-amz-tagging` header, because the tag-set will be copied from the
|
1395
|
+
# source object directly. The tag-set must be encoded as URL Query
|
1396
|
+
# parameters.
|
1397
|
+
#
|
1398
|
+
# The default value is the empty value.
|
1399
|
+
#
|
1400
|
+
# <note markdown="1"> **Directory buckets** - For directory buckets in a `CopyObject`
|
1401
|
+
# operation, only the empty tag-set is supported. Any requests that
|
1402
|
+
# attempt to write non-empty tags into directory buckets will receive a
|
1403
|
+
# `501 Not Implemented` status code. When the destination bucket is a
|
1404
|
+
# directory bucket, you will receive a `501 Not Implemented` response in
|
1405
|
+
# any of the following situations:
|
1406
|
+
#
|
1407
|
+
# * When you attempt to `COPY` the tag-set from an S3 source object that
|
1408
|
+
# has non-empty tags.
|
1409
|
+
#
|
1410
|
+
# * When you attempt to `REPLACE` the tag-set of a source object and set
|
1411
|
+
# a non-empty value to `x-amz-tagging`.
|
1412
|
+
#
|
1413
|
+
# * When you don't set the `x-amz-tagging-directive` header and the
|
1414
|
+
# source object has non-empty tags. This is because the default value
|
1415
|
+
# of `x-amz-tagging-directive` is `COPY`.
|
1416
|
+
#
|
1417
|
+
# Because only the empty tag-set is supported for directory buckets in a
|
1418
|
+
# `CopyObject` operation, the following situations are allowed:
|
1419
|
+
#
|
1420
|
+
# * When you attempt to `COPY` the tag-set from a directory bucket
|
1421
|
+
# source object that has no tags to a general purpose bucket. It
|
1422
|
+
# copies an empty tag-set to the destination object.
|
1423
|
+
#
|
1424
|
+
# * When you attempt to `REPLACE` the tag-set of a directory bucket
|
1425
|
+
# source object and set the `x-amz-tagging` value of the directory
|
1426
|
+
# bucket destination object to empty.
|
1427
|
+
#
|
1428
|
+
# * When you attempt to `REPLACE` the tag-set of a general purpose
|
1429
|
+
# bucket source object that has non-empty tags and set the
|
1430
|
+
# `x-amz-tagging` value of the directory bucket destination object to
|
1431
|
+
# empty.
|
1432
|
+
#
|
1433
|
+
# * When you attempt to `REPLACE` the tag-set of a directory bucket
|
1434
|
+
# source object and don't set the `x-amz-tagging` value of the
|
1435
|
+
# directory bucket destination object. This is because the default
|
1436
|
+
# value of `x-amz-tagging` is the empty value.
|
1437
|
+
#
|
1438
|
+
# </note>
|
828
1439
|
# @option options [String] :object_lock_mode
|
829
|
-
# The Object Lock mode that you want to apply to the
|
1440
|
+
# The Object Lock mode that you want to apply to the object copy.
|
1441
|
+
#
|
1442
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
1443
|
+
#
|
1444
|
+
# </note>
|
830
1445
|
# @option options [Time,DateTime,Date,Integer,String] :object_lock_retain_until_date
|
831
|
-
# The date and time when you want the
|
1446
|
+
# The date and time when you want the Object Lock of the object copy to
|
832
1447
|
# expire.
|
1448
|
+
#
|
1449
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
1450
|
+
#
|
1451
|
+
# </note>
|
833
1452
|
# @option options [String] :object_lock_legal_hold_status
|
834
|
-
# Specifies whether you want to apply a legal hold to the
|
1453
|
+
# Specifies whether you want to apply a legal hold to the object copy.
|
1454
|
+
#
|
1455
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
1456
|
+
#
|
1457
|
+
# </note>
|
835
1458
|
# @option options [String] :expected_bucket_owner
|
836
1459
|
# The account ID of the expected destination bucket owner. If the
|
837
|
-
#
|
838
|
-
# with the HTTP status code `403
|
1460
|
+
# account ID that you provide does not match the actual owner of the
|
1461
|
+
# destination bucket, the request fails with the HTTP status code `403
|
1462
|
+
# Forbidden` (access denied).
|
839
1463
|
# @option options [String] :expected_source_bucket_owner
|
840
|
-
# The account ID of the expected source bucket owner. If the
|
841
|
-
#
|
842
|
-
# HTTP status code `403 Forbidden` (access
|
1464
|
+
# The account ID of the expected source bucket owner. If the account ID
|
1465
|
+
# that you provide does not match the actual owner of the source bucket,
|
1466
|
+
# the request fails with the HTTP status code `403 Forbidden` (access
|
1467
|
+
# denied).
|
843
1468
|
# @return [Types::CopyObjectOutput]
|
844
1469
|
def copy_from(options = {})
|
845
1470
|
options = options.merge(
|
846
1471
|
bucket: @bucket_name,
|
847
1472
|
key: @key
|
848
1473
|
)
|
849
|
-
resp = Aws::Plugins::UserAgent.
|
1474
|
+
resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
|
850
1475
|
@client.copy_object(options)
|
851
1476
|
end
|
852
1477
|
resp.data
|
@@ -860,6 +1485,9 @@ module Aws::S3
|
|
860
1485
|
# request_payer: "requester", # accepts requester
|
861
1486
|
# bypass_governance_retention: false,
|
862
1487
|
# expected_bucket_owner: "AccountId",
|
1488
|
+
# if_match: "IfMatch",
|
1489
|
+
# if_match_last_modified_time: Time.now,
|
1490
|
+
# if_match_size: 1,
|
863
1491
|
# })
|
864
1492
|
# @param [Hash] options ({})
|
865
1493
|
# @option options [String] :mfa
|
@@ -867,15 +1495,30 @@ module Aws::S3
|
|
867
1495
|
# space, and the value that is displayed on your authentication device.
|
868
1496
|
# Required to permanently delete a versioned object if versioning is
|
869
1497
|
# configured with MFA delete enabled.
|
1498
|
+
#
|
1499
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
1500
|
+
#
|
1501
|
+
# </note>
|
870
1502
|
# @option options [String] :version_id
|
871
|
-
#
|
1503
|
+
# Version ID used to reference a specific version of the object.
|
1504
|
+
#
|
1505
|
+
# <note markdown="1"> For directory buckets in this API operation, only the `null` value of
|
1506
|
+
# the version ID is supported.
|
1507
|
+
#
|
1508
|
+
# </note>
|
872
1509
|
# @option options [String] :request_payer
|
873
1510
|
# Confirms that the requester knows that they will be charged for the
|
874
1511
|
# request. Bucket owners need not specify this parameter in their
|
875
|
-
# requests.
|
1512
|
+
# requests. If either the source or destination S3 bucket has Requester
|
1513
|
+
# Pays enabled, the requester will pay for corresponding charges to copy
|
1514
|
+
# the object. For information about downloading objects from Requester
|
876
1515
|
# Pays buckets, see [Downloading Objects in Requester Pays Buckets][1]
|
877
1516
|
# in the *Amazon S3 User Guide*.
|
878
1517
|
#
|
1518
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
1519
|
+
#
|
1520
|
+
# </note>
|
1521
|
+
#
|
879
1522
|
#
|
880
1523
|
#
|
881
1524
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
|
@@ -883,17 +1526,61 @@ module Aws::S3
|
|
883
1526
|
# Indicates whether S3 Object Lock should bypass Governance-mode
|
884
1527
|
# restrictions to process this operation. To use this header, you must
|
885
1528
|
# have the `s3:BypassGovernanceRetention` permission.
|
1529
|
+
#
|
1530
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
1531
|
+
#
|
1532
|
+
# </note>
|
886
1533
|
# @option options [String] :expected_bucket_owner
|
887
|
-
# The account ID of the expected bucket owner. If the
|
888
|
-
#
|
889
|
-
# Forbidden` (access denied).
|
1534
|
+
# The account ID of the expected bucket owner. If the account ID that
|
1535
|
+
# you provide does not match the actual owner of the bucket, the request
|
1536
|
+
# fails with the HTTP status code `403 Forbidden` (access denied).
|
1537
|
+
# @option options [String] :if_match
|
1538
|
+
# The `If-Match` header field makes the request method conditional on
|
1539
|
+
# ETags. If the ETag value does not match, the operation returns a `412
|
1540
|
+
# Precondition Failed` error. If the ETag matches or if the object
|
1541
|
+
# doesn't exist, the operation will return a `204 Success (No Content)
|
1542
|
+
# response`.
|
1543
|
+
#
|
1544
|
+
# For more information about conditional requests, see [RFC 7232][1].
|
1545
|
+
#
|
1546
|
+
# <note markdown="1"> This functionality is only supported for directory buckets.
|
1547
|
+
#
|
1548
|
+
# </note>
|
1549
|
+
#
|
1550
|
+
#
|
1551
|
+
#
|
1552
|
+
# [1]: https://tools.ietf.org/html/rfc7232
|
1553
|
+
# @option options [Time,DateTime,Date,Integer,String] :if_match_last_modified_time
|
1554
|
+
# If present, the object is deleted only if its modification times
|
1555
|
+
# matches the provided `Timestamp`. If the `Timestamp` values do not
|
1556
|
+
# match, the operation returns a `412 Precondition Failed` error. If the
|
1557
|
+
# `Timestamp` matches or if the object doesn’t exist, the operation
|
1558
|
+
# returns a `204 Success (No Content)` response.
|
1559
|
+
#
|
1560
|
+
# <note markdown="1"> This functionality is only supported for directory buckets.
|
1561
|
+
#
|
1562
|
+
# </note>
|
1563
|
+
# @option options [Integer] :if_match_size
|
1564
|
+
# If present, the object is deleted only if its size matches the
|
1565
|
+
# provided size in bytes. If the `Size` value does not match, the
|
1566
|
+
# operation returns a `412 Precondition Failed` error. If the `Size`
|
1567
|
+
# matches or if the object doesn’t exist, the operation returns a `204
|
1568
|
+
# Success (No Content)` response.
|
1569
|
+
#
|
1570
|
+
# <note markdown="1"> This functionality is only supported for directory buckets.
|
1571
|
+
#
|
1572
|
+
# </note>
|
1573
|
+
#
|
1574
|
+
# You can use the `If-Match`, `x-amz-if-match-last-modified-time` and
|
1575
|
+
# `x-amz-if-match-size` conditional headers in conjunction with
|
1576
|
+
# each-other or individually.
|
890
1577
|
# @return [Types::DeleteObjectOutput]
|
891
1578
|
def delete(options = {})
|
892
1579
|
options = options.merge(
|
893
1580
|
bucket: @bucket_name,
|
894
1581
|
key: @key
|
895
1582
|
)
|
896
|
-
resp = Aws::Plugins::UserAgent.
|
1583
|
+
resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
|
897
1584
|
@client.delete_object(options)
|
898
1585
|
end
|
899
1586
|
resp.data
|
@@ -925,18 +1612,64 @@ module Aws::S3
|
|
925
1612
|
# @param [Hash] options ({})
|
926
1613
|
# @option options [String] :if_match
|
927
1614
|
# Return the object only if its entity tag (ETag) is the same as the one
|
928
|
-
# specified; otherwise, return a 412
|
1615
|
+
# specified in this header; otherwise, return a `412 Precondition
|
1616
|
+
# Failed` error.
|
1617
|
+
#
|
1618
|
+
# If both of the `If-Match` and `If-Unmodified-Since` headers are
|
1619
|
+
# present in the request as follows: `If-Match` condition evaluates to
|
1620
|
+
# `true`, and; `If-Unmodified-Since` condition evaluates to `false`;
|
1621
|
+
# then, S3 returns `200 OK` and the data requested.
|
1622
|
+
#
|
1623
|
+
# For more information about conditional requests, see [RFC 7232][1].
|
1624
|
+
#
|
1625
|
+
#
|
1626
|
+
#
|
1627
|
+
# [1]: https://tools.ietf.org/html/rfc7232
|
929
1628
|
# @option options [Time,DateTime,Date,Integer,String] :if_modified_since
|
930
1629
|
# Return the object only if it has been modified since the specified
|
931
|
-
# time; otherwise, return a 304
|
1630
|
+
# time; otherwise, return a `304 Not Modified` error.
|
1631
|
+
#
|
1632
|
+
# If both of the `If-None-Match` and `If-Modified-Since` headers are
|
1633
|
+
# present in the request as follows:` If-None-Match` condition evaluates
|
1634
|
+
# to `false`, and; `If-Modified-Since` condition evaluates to `true`;
|
1635
|
+
# then, S3 returns `304 Not Modified` status code.
|
1636
|
+
#
|
1637
|
+
# For more information about conditional requests, see [RFC 7232][1].
|
1638
|
+
#
|
1639
|
+
#
|
1640
|
+
#
|
1641
|
+
# [1]: https://tools.ietf.org/html/rfc7232
|
932
1642
|
# @option options [String] :if_none_match
|
933
1643
|
# Return the object only if its entity tag (ETag) is different from the
|
934
|
-
# one specified; otherwise, return a 304
|
1644
|
+
# one specified in this header; otherwise, return a `304 Not Modified`
|
1645
|
+
# error.
|
1646
|
+
#
|
1647
|
+
# If both of the `If-None-Match` and `If-Modified-Since` headers are
|
1648
|
+
# present in the request as follows:` If-None-Match` condition evaluates
|
1649
|
+
# to `false`, and; `If-Modified-Since` condition evaluates to `true`;
|
1650
|
+
# then, S3 returns `304 Not Modified` HTTP status code.
|
1651
|
+
#
|
1652
|
+
# For more information about conditional requests, see [RFC 7232][1].
|
1653
|
+
#
|
1654
|
+
#
|
1655
|
+
#
|
1656
|
+
# [1]: https://tools.ietf.org/html/rfc7232
|
935
1657
|
# @option options [Time,DateTime,Date,Integer,String] :if_unmodified_since
|
936
1658
|
# Return the object only if it has not been modified since the specified
|
937
|
-
# time; otherwise, return a 412
|
1659
|
+
# time; otherwise, return a `412 Precondition Failed` error.
|
1660
|
+
#
|
1661
|
+
# If both of the `If-Match` and `If-Unmodified-Since` headers are
|
1662
|
+
# present in the request as follows: `If-Match` condition evaluates to
|
1663
|
+
# `true`, and; `If-Unmodified-Since` condition evaluates to `false`;
|
1664
|
+
# then, S3 returns `200 OK` and the data requested.
|
1665
|
+
#
|
1666
|
+
# For more information about conditional requests, see [RFC 7232][1].
|
1667
|
+
#
|
1668
|
+
#
|
1669
|
+
#
|
1670
|
+
# [1]: https://tools.ietf.org/html/rfc7232
|
938
1671
|
# @option options [String] :range
|
939
|
-
# Downloads the specified range
|
1672
|
+
# Downloads the specified byte range of an object. For more information
|
940
1673
|
# about the HTTP Range header, see
|
941
1674
|
# [https://www.rfc-editor.org/rfc/rfc9110.html#name-range][1].
|
942
1675
|
#
|
@@ -951,7 +1684,7 @@ module Aws::S3
|
|
951
1684
|
# @option options [String] :response_cache_control
|
952
1685
|
# Sets the `Cache-Control` header of the response.
|
953
1686
|
# @option options [String] :response_content_disposition
|
954
|
-
# Sets the `Content-Disposition` header of the response
|
1687
|
+
# Sets the `Content-Disposition` header of the response.
|
955
1688
|
# @option options [String] :response_content_encoding
|
956
1689
|
# Sets the `Content-Encoding` header of the response.
|
957
1690
|
# @option options [String] :response_content_language
|
@@ -961,27 +1694,128 @@ module Aws::S3
|
|
961
1694
|
# @option options [Time,DateTime,Date,Integer,String] :response_expires
|
962
1695
|
# Sets the `Expires` header of the response.
|
963
1696
|
# @option options [String] :version_id
|
964
|
-
#
|
1697
|
+
# Version ID used to reference a specific version of the object.
|
1698
|
+
#
|
1699
|
+
# By default, the `GetObject` operation returns the current version of
|
1700
|
+
# an object. To return a different version, use the `versionId`
|
1701
|
+
# subresource.
|
1702
|
+
#
|
1703
|
+
# <note markdown="1"> * If you include a `versionId` in your request header, you must have
|
1704
|
+
# the `s3:GetObjectVersion` permission to access a specific version of
|
1705
|
+
# an object. The `s3:GetObject` permission is not required in this
|
1706
|
+
# scenario.
|
1707
|
+
#
|
1708
|
+
# * If you request the current version of an object without a specific
|
1709
|
+
# `versionId` in the request header, only the `s3:GetObject`
|
1710
|
+
# permission is required. The `s3:GetObjectVersion` permission is not
|
1711
|
+
# required in this scenario.
|
1712
|
+
#
|
1713
|
+
# * **Directory buckets** - S3 Versioning isn't enabled and supported
|
1714
|
+
# for directory buckets. For this API operation, only the `null` value
|
1715
|
+
# of the version ID is supported by directory buckets. You can only
|
1716
|
+
# specify `null` to the `versionId` query parameter in the request.
|
1717
|
+
#
|
1718
|
+
# </note>
|
1719
|
+
#
|
1720
|
+
# For more information about versioning, see [PutBucketVersioning][1].
|
1721
|
+
#
|
1722
|
+
#
|
1723
|
+
#
|
1724
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketVersioning.html
|
965
1725
|
# @option options [String] :sse_customer_algorithm
|
966
|
-
# Specifies the algorithm to use
|
967
|
-
# example, AES256).
|
1726
|
+
# Specifies the algorithm to use when decrypting the object (for
|
1727
|
+
# example, `AES256`).
|
1728
|
+
#
|
1729
|
+
# If you encrypt an object by using server-side encryption with
|
1730
|
+
# customer-provided encryption keys (SSE-C) when you store the object in
|
1731
|
+
# Amazon S3, then when you GET the object, you must use the following
|
1732
|
+
# headers:
|
1733
|
+
#
|
1734
|
+
# * `x-amz-server-side-encryption-customer-algorithm`
|
1735
|
+
#
|
1736
|
+
# * `x-amz-server-side-encryption-customer-key`
|
1737
|
+
#
|
1738
|
+
# * `x-amz-server-side-encryption-customer-key-MD5`
|
1739
|
+
#
|
1740
|
+
# For more information about SSE-C, see [Server-Side Encryption (Using
|
1741
|
+
# Customer-Provided Encryption Keys)][1] in the *Amazon S3 User Guide*.
|
1742
|
+
#
|
1743
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
1744
|
+
#
|
1745
|
+
# </note>
|
1746
|
+
#
|
1747
|
+
#
|
1748
|
+
#
|
1749
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/ServerSideEncryptionCustomerKeys.html
|
968
1750
|
# @option options [String] :sse_customer_key
|
969
|
-
# Specifies the customer-provided encryption key
|
970
|
-
#
|
971
|
-
#
|
972
|
-
#
|
1751
|
+
# Specifies the customer-provided encryption key that you originally
|
1752
|
+
# provided for Amazon S3 to encrypt the data before storing it. This
|
1753
|
+
# value is used to decrypt the object when recovering it and must match
|
1754
|
+
# the one used when storing the data. The key must be appropriate for
|
1755
|
+
# use with the algorithm specified in the
|
973
1756
|
# `x-amz-server-side-encryption-customer-algorithm` header.
|
1757
|
+
#
|
1758
|
+
# If you encrypt an object by using server-side encryption with
|
1759
|
+
# customer-provided encryption keys (SSE-C) when you store the object in
|
1760
|
+
# Amazon S3, then when you GET the object, you must use the following
|
1761
|
+
# headers:
|
1762
|
+
#
|
1763
|
+
# * `x-amz-server-side-encryption-customer-algorithm`
|
1764
|
+
#
|
1765
|
+
# * `x-amz-server-side-encryption-customer-key`
|
1766
|
+
#
|
1767
|
+
# * `x-amz-server-side-encryption-customer-key-MD5`
|
1768
|
+
#
|
1769
|
+
# For more information about SSE-C, see [Server-Side Encryption (Using
|
1770
|
+
# Customer-Provided Encryption Keys)][1] in the *Amazon S3 User Guide*.
|
1771
|
+
#
|
1772
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
1773
|
+
#
|
1774
|
+
# </note>
|
1775
|
+
#
|
1776
|
+
#
|
1777
|
+
#
|
1778
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/ServerSideEncryptionCustomerKeys.html
|
974
1779
|
# @option options [String] :sse_customer_key_md5
|
975
|
-
# Specifies the 128-bit MD5 digest of the encryption
|
976
|
-
# RFC 1321. Amazon S3 uses this header for a message
|
977
|
-
# ensure that the encryption key was transmitted
|
1780
|
+
# Specifies the 128-bit MD5 digest of the customer-provided encryption
|
1781
|
+
# key according to RFC 1321. Amazon S3 uses this header for a message
|
1782
|
+
# integrity check to ensure that the encryption key was transmitted
|
1783
|
+
# without error.
|
1784
|
+
#
|
1785
|
+
# If you encrypt an object by using server-side encryption with
|
1786
|
+
# customer-provided encryption keys (SSE-C) when you store the object in
|
1787
|
+
# Amazon S3, then when you GET the object, you must use the following
|
1788
|
+
# headers:
|
1789
|
+
#
|
1790
|
+
# * `x-amz-server-side-encryption-customer-algorithm`
|
1791
|
+
#
|
1792
|
+
# * `x-amz-server-side-encryption-customer-key`
|
1793
|
+
#
|
1794
|
+
# * `x-amz-server-side-encryption-customer-key-MD5`
|
1795
|
+
#
|
1796
|
+
# For more information about SSE-C, see [Server-Side Encryption (Using
|
1797
|
+
# Customer-Provided Encryption Keys)][1] in the *Amazon S3 User Guide*.
|
1798
|
+
#
|
1799
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
1800
|
+
#
|
1801
|
+
# </note>
|
1802
|
+
#
|
1803
|
+
#
|
1804
|
+
#
|
1805
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/ServerSideEncryptionCustomerKeys.html
|
978
1806
|
# @option options [String] :request_payer
|
979
1807
|
# Confirms that the requester knows that they will be charged for the
|
980
1808
|
# request. Bucket owners need not specify this parameter in their
|
981
|
-
# requests.
|
1809
|
+
# requests. If either the source or destination S3 bucket has Requester
|
1810
|
+
# Pays enabled, the requester will pay for corresponding charges to copy
|
1811
|
+
# the object. For information about downloading objects from Requester
|
982
1812
|
# Pays buckets, see [Downloading Objects in Requester Pays Buckets][1]
|
983
1813
|
# in the *Amazon S3 User Guide*.
|
984
1814
|
#
|
1815
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
1816
|
+
#
|
1817
|
+
# </note>
|
1818
|
+
#
|
985
1819
|
#
|
986
1820
|
#
|
987
1821
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
|
@@ -991,9 +1825,9 @@ module Aws::S3
|
|
991
1825
|
# for the part specified. Useful for downloading just a part of an
|
992
1826
|
# object.
|
993
1827
|
# @option options [String] :expected_bucket_owner
|
994
|
-
# The account ID of the expected bucket owner. If the
|
995
|
-
#
|
996
|
-
# Forbidden` (access denied).
|
1828
|
+
# The account ID of the expected bucket owner. If the account ID that
|
1829
|
+
# you provide does not match the actual owner of the bucket, the request
|
1830
|
+
# fails with the HTTP status code `403 Forbidden` (access denied).
|
997
1831
|
# @option options [String] :checksum_mode
|
998
1832
|
# To retrieve the checksum, this mode must be enabled.
|
999
1833
|
# @return [Types::GetObjectOutput]
|
@@ -1002,7 +1836,7 @@ module Aws::S3
|
|
1002
1836
|
bucket: @bucket_name,
|
1003
1837
|
key: @key
|
1004
1838
|
)
|
1005
|
-
resp = Aws::Plugins::UserAgent.
|
1839
|
+
resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
|
1006
1840
|
@client.get_object(options, &block)
|
1007
1841
|
end
|
1008
1842
|
resp.data
|
@@ -1025,8 +1859,8 @@ module Aws::S3
|
|
1025
1859
|
# metadata: {
|
1026
1860
|
# "MetadataKey" => "MetadataValue",
|
1027
1861
|
# },
|
1028
|
-
# server_side_encryption: "AES256", # accepts AES256, aws:kms, aws:kms:dsse
|
1029
|
-
# storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW
|
1862
|
+
# server_side_encryption: "AES256", # accepts AES256, aws:fsx, aws:kms, aws:kms:dsse
|
1863
|
+
# storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW, EXPRESS_ONEZONE, FSX_OPENZFS
|
1030
1864
|
# website_redirect_location: "WebsiteRedirectLocation",
|
1031
1865
|
# sse_customer_algorithm: "SSECustomerAlgorithm",
|
1032
1866
|
# sse_customer_key: "SSECustomerKey",
|
@@ -1040,13 +1874,34 @@ module Aws::S3
|
|
1040
1874
|
# object_lock_retain_until_date: Time.now,
|
1041
1875
|
# object_lock_legal_hold_status: "ON", # accepts ON, OFF
|
1042
1876
|
# expected_bucket_owner: "AccountId",
|
1043
|
-
# checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256
|
1877
|
+
# checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256, CRC64NVME
|
1878
|
+
# checksum_type: "COMPOSITE", # accepts COMPOSITE, FULL_OBJECT
|
1044
1879
|
# })
|
1045
1880
|
# @param [Hash] options ({})
|
1046
1881
|
# @option options [String] :acl
|
1047
|
-
# The canned ACL to apply to the object.
|
1882
|
+
# The canned ACL to apply to the object. Amazon S3 supports a set of
|
1883
|
+
# predefined ACLs, known as *canned ACLs*. Each canned ACL has a
|
1884
|
+
# predefined set of grantees and permissions. For more information, see
|
1885
|
+
# [Canned ACL][1] in the *Amazon S3 User Guide*.
|
1886
|
+
#
|
1887
|
+
# By default, all objects are private. Only the owner has full access
|
1888
|
+
# control. When uploading an object, you can grant access permissions to
|
1889
|
+
# individual Amazon Web Services accounts or to predefined groups
|
1890
|
+
# defined by Amazon S3. These permissions are then added to the access
|
1891
|
+
# control list (ACL) on the new object. For more information, see [Using
|
1892
|
+
# ACLs][2]. One way to grant the permissions using the request headers
|
1893
|
+
# is to specify a canned ACL with the `x-amz-acl` request header.
|
1894
|
+
#
|
1895
|
+
# <note markdown="1"> * This functionality is not supported for directory buckets.
|
1896
|
+
#
|
1897
|
+
# * This functionality is not supported for Amazon S3 on Outposts.
|
1898
|
+
#
|
1899
|
+
# </note>
|
1048
1900
|
#
|
1049
|
-
#
|
1901
|
+
#
|
1902
|
+
#
|
1903
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html#CannedACL
|
1904
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/S3_ACLs_UsingACLs.html
|
1050
1905
|
# @option options [String] :cache_control
|
1051
1906
|
# Specifies caching behavior along the request/reply chain.
|
1052
1907
|
# @option options [String] :content_disposition
|
@@ -1055,41 +1910,343 @@ module Aws::S3
|
|
1055
1910
|
# Specifies what content encodings have been applied to the object and
|
1056
1911
|
# thus what decoding mechanisms must be applied to obtain the media-type
|
1057
1912
|
# referenced by the Content-Type header field.
|
1913
|
+
#
|
1914
|
+
# <note markdown="1"> For directory buckets, only the `aws-chunked` value is supported in
|
1915
|
+
# this header field.
|
1916
|
+
#
|
1917
|
+
# </note>
|
1058
1918
|
# @option options [String] :content_language
|
1059
|
-
# The language the content is in.
|
1919
|
+
# The language that the content is in.
|
1060
1920
|
# @option options [String] :content_type
|
1061
1921
|
# A standard MIME type describing the format of the object data.
|
1062
1922
|
# @option options [Time,DateTime,Date,Integer,String] :expires
|
1063
1923
|
# The date and time at which the object is no longer cacheable.
|
1064
1924
|
# @option options [String] :grant_full_control
|
1065
|
-
#
|
1066
|
-
# object.
|
1925
|
+
# Specify access permissions explicitly to give the grantee READ,
|
1926
|
+
# READ\_ACP, and WRITE\_ACP permissions on the object.
|
1927
|
+
#
|
1928
|
+
# By default, all objects are private. Only the owner has full access
|
1929
|
+
# control. When uploading an object, you can use this header to
|
1930
|
+
# explicitly grant access permissions to specific Amazon Web Services
|
1931
|
+
# accounts or groups. This header maps to specific permissions that
|
1932
|
+
# Amazon S3 supports in an ACL. For more information, see [Access
|
1933
|
+
# Control List (ACL) Overview][1] in the *Amazon S3 User Guide*.
|
1934
|
+
#
|
1935
|
+
# You specify each grantee as a type=value pair, where the type is one
|
1936
|
+
# of the following:
|
1937
|
+
#
|
1938
|
+
# * `id` – if the value specified is the canonical user ID of an Amazon
|
1939
|
+
# Web Services account
|
1940
|
+
#
|
1941
|
+
# * `uri` – if you are granting permissions to a predefined group
|
1942
|
+
#
|
1943
|
+
# * `emailAddress` – if the value specified is the email address of an
|
1944
|
+
# Amazon Web Services account
|
1945
|
+
#
|
1946
|
+
# <note markdown="1"> Using email addresses to specify a grantee is only supported in the
|
1947
|
+
# following Amazon Web Services Regions:
|
1948
|
+
#
|
1949
|
+
# * US East (N. Virginia)
|
1950
|
+
#
|
1951
|
+
# * US West (N. California)
|
1952
|
+
#
|
1953
|
+
# * US West (Oregon)
|
1954
|
+
#
|
1955
|
+
# * Asia Pacific (Singapore)
|
1956
|
+
#
|
1957
|
+
# * Asia Pacific (Sydney)
|
1958
|
+
#
|
1959
|
+
# * Asia Pacific (Tokyo)
|
1067
1960
|
#
|
1068
|
-
#
|
1961
|
+
# * Europe (Ireland)
|
1962
|
+
#
|
1963
|
+
# * South America (São Paulo)
|
1964
|
+
#
|
1965
|
+
# For a list of all the Amazon S3 supported Regions and endpoints, see
|
1966
|
+
# [Regions and Endpoints][2] in the Amazon Web Services General
|
1967
|
+
# Reference.
|
1968
|
+
#
|
1969
|
+
# </note>
|
1970
|
+
#
|
1971
|
+
# For example, the following `x-amz-grant-read` header grants the Amazon
|
1972
|
+
# Web Services accounts identified by account IDs permissions to read
|
1973
|
+
# object data and its metadata:
|
1974
|
+
#
|
1975
|
+
# `x-amz-grant-read: id="11112222333", id="444455556666" `
|
1976
|
+
#
|
1977
|
+
# <note markdown="1"> * This functionality is not supported for directory buckets.
|
1978
|
+
#
|
1979
|
+
# * This functionality is not supported for Amazon S3 on Outposts.
|
1980
|
+
#
|
1981
|
+
# </note>
|
1982
|
+
#
|
1983
|
+
#
|
1984
|
+
#
|
1985
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html
|
1986
|
+
# [2]: https://docs.aws.amazon.com/general/latest/gr/rande.html#s3_region
|
1069
1987
|
# @option options [String] :grant_read
|
1070
|
-
#
|
1988
|
+
# Specify access permissions explicitly to allow grantee to read the
|
1989
|
+
# object data and its metadata.
|
1990
|
+
#
|
1991
|
+
# By default, all objects are private. Only the owner has full access
|
1992
|
+
# control. When uploading an object, you can use this header to
|
1993
|
+
# explicitly grant access permissions to specific Amazon Web Services
|
1994
|
+
# accounts or groups. This header maps to specific permissions that
|
1995
|
+
# Amazon S3 supports in an ACL. For more information, see [Access
|
1996
|
+
# Control List (ACL) Overview][1] in the *Amazon S3 User Guide*.
|
1997
|
+
#
|
1998
|
+
# You specify each grantee as a type=value pair, where the type is one
|
1999
|
+
# of the following:
|
2000
|
+
#
|
2001
|
+
# * `id` – if the value specified is the canonical user ID of an Amazon
|
2002
|
+
# Web Services account
|
2003
|
+
#
|
2004
|
+
# * `uri` – if you are granting permissions to a predefined group
|
2005
|
+
#
|
2006
|
+
# * `emailAddress` – if the value specified is the email address of an
|
2007
|
+
# Amazon Web Services account
|
2008
|
+
#
|
2009
|
+
# <note markdown="1"> Using email addresses to specify a grantee is only supported in the
|
2010
|
+
# following Amazon Web Services Regions:
|
2011
|
+
#
|
2012
|
+
# * US East (N. Virginia)
|
2013
|
+
#
|
2014
|
+
# * US West (N. California)
|
2015
|
+
#
|
2016
|
+
# * US West (Oregon)
|
2017
|
+
#
|
2018
|
+
# * Asia Pacific (Singapore)
|
2019
|
+
#
|
2020
|
+
# * Asia Pacific (Sydney)
|
2021
|
+
#
|
2022
|
+
# * Asia Pacific (Tokyo)
|
2023
|
+
#
|
2024
|
+
# * Europe (Ireland)
|
1071
2025
|
#
|
1072
|
-
#
|
2026
|
+
# * South America (São Paulo)
|
2027
|
+
#
|
2028
|
+
# For a list of all the Amazon S3 supported Regions and endpoints, see
|
2029
|
+
# [Regions and Endpoints][2] in the Amazon Web Services General
|
2030
|
+
# Reference.
|
2031
|
+
#
|
2032
|
+
# </note>
|
2033
|
+
#
|
2034
|
+
# For example, the following `x-amz-grant-read` header grants the Amazon
|
2035
|
+
# Web Services accounts identified by account IDs permissions to read
|
2036
|
+
# object data and its metadata:
|
2037
|
+
#
|
2038
|
+
# `x-amz-grant-read: id="11112222333", id="444455556666" `
|
2039
|
+
#
|
2040
|
+
# <note markdown="1"> * This functionality is not supported for directory buckets.
|
2041
|
+
#
|
2042
|
+
# * This functionality is not supported for Amazon S3 on Outposts.
|
2043
|
+
#
|
2044
|
+
# </note>
|
2045
|
+
#
|
2046
|
+
#
|
2047
|
+
#
|
2048
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html
|
2049
|
+
# [2]: https://docs.aws.amazon.com/general/latest/gr/rande.html#s3_region
|
1073
2050
|
# @option options [String] :grant_read_acp
|
1074
|
-
#
|
2051
|
+
# Specify access permissions explicitly to allows grantee to read the
|
2052
|
+
# object ACL.
|
2053
|
+
#
|
2054
|
+
# By default, all objects are private. Only the owner has full access
|
2055
|
+
# control. When uploading an object, you can use this header to
|
2056
|
+
# explicitly grant access permissions to specific Amazon Web Services
|
2057
|
+
# accounts or groups. This header maps to specific permissions that
|
2058
|
+
# Amazon S3 supports in an ACL. For more information, see [Access
|
2059
|
+
# Control List (ACL) Overview][1] in the *Amazon S3 User Guide*.
|
2060
|
+
#
|
2061
|
+
# You specify each grantee as a type=value pair, where the type is one
|
2062
|
+
# of the following:
|
2063
|
+
#
|
2064
|
+
# * `id` – if the value specified is the canonical user ID of an Amazon
|
2065
|
+
# Web Services account
|
2066
|
+
#
|
2067
|
+
# * `uri` – if you are granting permissions to a predefined group
|
2068
|
+
#
|
2069
|
+
# * `emailAddress` – if the value specified is the email address of an
|
2070
|
+
# Amazon Web Services account
|
2071
|
+
#
|
2072
|
+
# <note markdown="1"> Using email addresses to specify a grantee is only supported in the
|
2073
|
+
# following Amazon Web Services Regions:
|
2074
|
+
#
|
2075
|
+
# * US East (N. Virginia)
|
2076
|
+
#
|
2077
|
+
# * US West (N. California)
|
2078
|
+
#
|
2079
|
+
# * US West (Oregon)
|
2080
|
+
#
|
2081
|
+
# * Asia Pacific (Singapore)
|
2082
|
+
#
|
2083
|
+
# * Asia Pacific (Sydney)
|
2084
|
+
#
|
2085
|
+
# * Asia Pacific (Tokyo)
|
2086
|
+
#
|
2087
|
+
# * Europe (Ireland)
|
2088
|
+
#
|
2089
|
+
# * South America (São Paulo)
|
2090
|
+
#
|
2091
|
+
# For a list of all the Amazon S3 supported Regions and endpoints, see
|
2092
|
+
# [Regions and Endpoints][2] in the Amazon Web Services General
|
2093
|
+
# Reference.
|
1075
2094
|
#
|
1076
|
-
#
|
2095
|
+
# </note>
|
2096
|
+
#
|
2097
|
+
# For example, the following `x-amz-grant-read` header grants the Amazon
|
2098
|
+
# Web Services accounts identified by account IDs permissions to read
|
2099
|
+
# object data and its metadata:
|
2100
|
+
#
|
2101
|
+
# `x-amz-grant-read: id="11112222333", id="444455556666" `
|
2102
|
+
#
|
2103
|
+
# <note markdown="1"> * This functionality is not supported for directory buckets.
|
2104
|
+
#
|
2105
|
+
# * This functionality is not supported for Amazon S3 on Outposts.
|
2106
|
+
#
|
2107
|
+
# </note>
|
2108
|
+
#
|
2109
|
+
#
|
2110
|
+
#
|
2111
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html
|
2112
|
+
# [2]: https://docs.aws.amazon.com/general/latest/gr/rande.html#s3_region
|
1077
2113
|
# @option options [String] :grant_write_acp
|
1078
|
-
#
|
2114
|
+
# Specify access permissions explicitly to allows grantee to allow
|
2115
|
+
# grantee to write the ACL for the applicable object.
|
2116
|
+
#
|
2117
|
+
# By default, all objects are private. Only the owner has full access
|
2118
|
+
# control. When uploading an object, you can use this header to
|
2119
|
+
# explicitly grant access permissions to specific Amazon Web Services
|
2120
|
+
# accounts or groups. This header maps to specific permissions that
|
2121
|
+
# Amazon S3 supports in an ACL. For more information, see [Access
|
2122
|
+
# Control List (ACL) Overview][1] in the *Amazon S3 User Guide*.
|
2123
|
+
#
|
2124
|
+
# You specify each grantee as a type=value pair, where the type is one
|
2125
|
+
# of the following:
|
2126
|
+
#
|
2127
|
+
# * `id` – if the value specified is the canonical user ID of an Amazon
|
2128
|
+
# Web Services account
|
2129
|
+
#
|
2130
|
+
# * `uri` – if you are granting permissions to a predefined group
|
2131
|
+
#
|
2132
|
+
# * `emailAddress` – if the value specified is the email address of an
|
2133
|
+
# Amazon Web Services account
|
2134
|
+
#
|
2135
|
+
# <note markdown="1"> Using email addresses to specify a grantee is only supported in the
|
2136
|
+
# following Amazon Web Services Regions:
|
2137
|
+
#
|
2138
|
+
# * US East (N. Virginia)
|
2139
|
+
#
|
2140
|
+
# * US West (N. California)
|
2141
|
+
#
|
2142
|
+
# * US West (Oregon)
|
2143
|
+
#
|
2144
|
+
# * Asia Pacific (Singapore)
|
2145
|
+
#
|
2146
|
+
# * Asia Pacific (Sydney)
|
2147
|
+
#
|
2148
|
+
# * Asia Pacific (Tokyo)
|
2149
|
+
#
|
2150
|
+
# * Europe (Ireland)
|
2151
|
+
#
|
2152
|
+
# * South America (São Paulo)
|
2153
|
+
#
|
2154
|
+
# For a list of all the Amazon S3 supported Regions and endpoints, see
|
2155
|
+
# [Regions and Endpoints][2] in the Amazon Web Services General
|
2156
|
+
# Reference.
|
2157
|
+
#
|
2158
|
+
# </note>
|
2159
|
+
#
|
2160
|
+
# For example, the following `x-amz-grant-read` header grants the Amazon
|
2161
|
+
# Web Services accounts identified by account IDs permissions to read
|
2162
|
+
# object data and its metadata:
|
2163
|
+
#
|
2164
|
+
# `x-amz-grant-read: id="11112222333", id="444455556666" `
|
2165
|
+
#
|
2166
|
+
# <note markdown="1"> * This functionality is not supported for directory buckets.
|
2167
|
+
#
|
2168
|
+
# * This functionality is not supported for Amazon S3 on Outposts.
|
2169
|
+
#
|
2170
|
+
# </note>
|
1079
2171
|
#
|
1080
|
-
#
|
2172
|
+
#
|
2173
|
+
#
|
2174
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html
|
2175
|
+
# [2]: https://docs.aws.amazon.com/general/latest/gr/rande.html#s3_region
|
1081
2176
|
# @option options [Hash<String,String>] :metadata
|
1082
2177
|
# A map of metadata to store with the object in S3.
|
1083
2178
|
# @option options [String] :server_side_encryption
|
1084
|
-
# The server-side encryption algorithm used when
|
1085
|
-
# Amazon S3
|
2179
|
+
# The server-side encryption algorithm used when you store this object
|
2180
|
+
# in Amazon S3 or Amazon FSx.
|
2181
|
+
#
|
2182
|
+
# * <b>Directory buckets </b> - For directory buckets, there are only
|
2183
|
+
# two supported options for server-side encryption: server-side
|
2184
|
+
# encryption with Amazon S3 managed keys (SSE-S3) (`AES256`) and
|
2185
|
+
# server-side encryption with KMS keys (SSE-KMS) (`aws:kms`). We
|
2186
|
+
# recommend that the bucket's default encryption uses the desired
|
2187
|
+
# encryption configuration and you don't override the bucket default
|
2188
|
+
# encryption in your `CreateSession` requests or `PUT` object
|
2189
|
+
# requests. Then, new objects are automatically encrypted with the
|
2190
|
+
# desired encryption settings. For more information, see [Protecting
|
2191
|
+
# data with server-side encryption][1] in the *Amazon S3 User Guide*.
|
2192
|
+
# For more information about the encryption overriding behaviors in
|
2193
|
+
# directory buckets, see [Specifying server-side encryption with KMS
|
2194
|
+
# for new object uploads][2].
|
2195
|
+
#
|
2196
|
+
# In the Zonal endpoint API calls (except [CopyObject][3] and
|
2197
|
+
# [UploadPartCopy][4]) using the REST API, the encryption request
|
2198
|
+
# headers must match the encryption settings that are specified in the
|
2199
|
+
# `CreateSession` request. You can't override the values of the
|
2200
|
+
# encryption settings (`x-amz-server-side-encryption`,
|
2201
|
+
# `x-amz-server-side-encryption-aws-kms-key-id`,
|
2202
|
+
# `x-amz-server-side-encryption-context`, and
|
2203
|
+
# `x-amz-server-side-encryption-bucket-key-enabled`) that are
|
2204
|
+
# specified in the `CreateSession` request. You don't need to
|
2205
|
+
# explicitly specify these encryption settings values in Zonal
|
2206
|
+
# endpoint API calls, and Amazon S3 will use the encryption settings
|
2207
|
+
# values from the `CreateSession` request to protect new objects in
|
2208
|
+
# the directory bucket.
|
2209
|
+
#
|
2210
|
+
# <note markdown="1"> When you use the CLI or the Amazon Web Services SDKs, for
|
2211
|
+
# `CreateSession`, the session token refreshes automatically to avoid
|
2212
|
+
# service interruptions when a session expires. The CLI or the Amazon
|
2213
|
+
# Web Services SDKs use the bucket's default encryption configuration
|
2214
|
+
# for the `CreateSession` request. It's not supported to override the
|
2215
|
+
# encryption settings values in the `CreateSession` request. So in the
|
2216
|
+
# Zonal endpoint API calls (except [CopyObject][3] and
|
2217
|
+
# [UploadPartCopy][4]), the encryption request headers must match the
|
2218
|
+
# default encryption configuration of the directory bucket.
|
2219
|
+
#
|
2220
|
+
# </note>
|
2221
|
+
#
|
2222
|
+
# * <b>S3 access points for Amazon FSx </b> - When accessing data stored
|
2223
|
+
# in Amazon FSx file systems using S3 access points, the only valid
|
2224
|
+
# server side encryption option is `aws:fsx`. All Amazon FSx file
|
2225
|
+
# systems have encryption configured by default and are encrypted at
|
2226
|
+
# rest. Data is automatically encrypted before being written to the
|
2227
|
+
# file system, and automatically decrypted as it is read. These
|
2228
|
+
# processes are handled transparently by Amazon FSx.
|
2229
|
+
#
|
2230
|
+
#
|
2231
|
+
#
|
2232
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-serv-side-encryption.html
|
2233
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-specifying-kms-encryption.html
|
2234
|
+
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html
|
2235
|
+
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html
|
1086
2236
|
# @option options [String] :storage_class
|
1087
2237
|
# By default, Amazon S3 uses the STANDARD Storage Class to store newly
|
1088
2238
|
# created objects. The STANDARD storage class provides high durability
|
1089
2239
|
# and high availability. Depending on performance needs, you can specify
|
1090
|
-
# a different Storage Class.
|
1091
|
-
#
|
1092
|
-
#
|
2240
|
+
# a different Storage Class. For more information, see [Storage
|
2241
|
+
# Classes][1] in the *Amazon S3 User Guide*.
|
2242
|
+
#
|
2243
|
+
# <note markdown="1"> * Directory buckets only support `EXPRESS_ONEZONE` (the S3 Express One
|
2244
|
+
# Zone storage class) in Availability Zones and `ONEZONE_IA` (the S3
|
2245
|
+
# One Zone-Infrequent Access storage class) in Dedicated Local Zones.
|
2246
|
+
#
|
2247
|
+
# * Amazon S3 on Outposts only uses the OUTPOSTS Storage Class.
|
2248
|
+
#
|
2249
|
+
# </note>
|
1093
2250
|
#
|
1094
2251
|
#
|
1095
2252
|
#
|
@@ -1098,83 +2255,172 @@ module Aws::S3
|
|
1098
2255
|
# If the bucket is configured as a website, redirects requests for this
|
1099
2256
|
# object to another object in the same bucket or to an external URL.
|
1100
2257
|
# Amazon S3 stores the value of this header in the object metadata.
|
2258
|
+
#
|
2259
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
2260
|
+
#
|
2261
|
+
# </note>
|
1101
2262
|
# @option options [String] :sse_customer_algorithm
|
1102
|
-
# Specifies the algorithm to use
|
2263
|
+
# Specifies the algorithm to use when encrypting the object (for
|
1103
2264
|
# example, AES256).
|
2265
|
+
#
|
2266
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
2267
|
+
#
|
2268
|
+
# </note>
|
1104
2269
|
# @option options [String] :sse_customer_key
|
1105
2270
|
# Specifies the customer-provided encryption key for Amazon S3 to use in
|
1106
2271
|
# encrypting data. This value is used to store the object and then it is
|
1107
2272
|
# discarded; Amazon S3 does not store the encryption key. The key must
|
1108
2273
|
# be appropriate for use with the algorithm specified in the
|
1109
2274
|
# `x-amz-server-side-encryption-customer-algorithm` header.
|
1110
|
-
# @option options [String] :sse_customer_key_md5
|
1111
|
-
# Specifies the 128-bit MD5 digest of the encryption key according to
|
1112
|
-
# RFC 1321. Amazon S3 uses this header for a message integrity check to
|
1113
|
-
# ensure that the encryption key was transmitted without error.
|
1114
|
-
# @option options [String] :ssekms_key_id
|
1115
|
-
# Specifies the ID of the symmetric encryption customer managed key to
|
1116
|
-
# use for object encryption. All GET and PUT requests for an object
|
1117
|
-
# protected by KMS will fail if they're not made via SSL or using
|
1118
|
-
# SigV4. For information about configuring any of the officially
|
1119
|
-
# supported Amazon Web Services SDKs and Amazon Web Services CLI, see
|
1120
|
-
# [Specifying the Signature Version in Request Authentication][1] in the
|
1121
|
-
# *Amazon S3 User Guide*.
|
1122
2275
|
#
|
2276
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
2277
|
+
#
|
2278
|
+
# </note>
|
2279
|
+
# @option options [String] :sse_customer_key_md5
|
2280
|
+
# Specifies the 128-bit MD5 digest of the customer-provided encryption
|
2281
|
+
# key according to RFC 1321. Amazon S3 uses this header for a message
|
2282
|
+
# integrity check to ensure that the encryption key was transmitted
|
2283
|
+
# without error.
|
1123
2284
|
#
|
2285
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
1124
2286
|
#
|
1125
|
-
#
|
2287
|
+
# </note>
|
2288
|
+
# @option options [String] :ssekms_key_id
|
2289
|
+
# Specifies the KMS key ID (Key ID, Key ARN, or Key Alias) to use for
|
2290
|
+
# object encryption. If the KMS key doesn't exist in the same account
|
2291
|
+
# that's issuing the command, you must use the full Key ARN not the Key
|
2292
|
+
# ID.
|
2293
|
+
#
|
2294
|
+
# **General purpose buckets** - If you specify
|
2295
|
+
# `x-amz-server-side-encryption` with `aws:kms` or `aws:kms:dsse`, this
|
2296
|
+
# header specifies the ID (Key ID, Key ARN, or Key Alias) of the KMS key
|
2297
|
+
# to use. If you specify `x-amz-server-side-encryption:aws:kms` or
|
2298
|
+
# `x-amz-server-side-encryption:aws:kms:dsse`, but do not provide
|
2299
|
+
# `x-amz-server-side-encryption-aws-kms-key-id`, Amazon S3 uses the
|
2300
|
+
# Amazon Web Services managed key (`aws/s3`) to protect the data.
|
2301
|
+
#
|
2302
|
+
# **Directory buckets** - To encrypt data using SSE-KMS, it's
|
2303
|
+
# recommended to specify the `x-amz-server-side-encryption` header to
|
2304
|
+
# `aws:kms`. Then, the `x-amz-server-side-encryption-aws-kms-key-id`
|
2305
|
+
# header implicitly uses the bucket's default KMS customer managed key
|
2306
|
+
# ID. If you want to explicitly set the `
|
2307
|
+
# x-amz-server-side-encryption-aws-kms-key-id` header, it must match the
|
2308
|
+
# bucket's default customer managed key (using key ID or ARN, not
|
2309
|
+
# alias). Your SSE-KMS configuration can only support 1 [customer
|
2310
|
+
# managed key][1] per directory bucket's lifetime. The [Amazon Web
|
2311
|
+
# Services managed key][2] (`aws/s3`) isn't supported. Incorrect key
|
2312
|
+
# specification results in an HTTP `400 Bad Request` error.
|
2313
|
+
#
|
2314
|
+
#
|
2315
|
+
#
|
2316
|
+
# [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk
|
2317
|
+
# [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk
|
1126
2318
|
# @option options [String] :ssekms_encryption_context
|
1127
2319
|
# Specifies the Amazon Web Services KMS Encryption Context to use for
|
1128
|
-
# object encryption. The value of this header is a
|
1129
|
-
#
|
2320
|
+
# object encryption. The value of this header is a Base64 encoded string
|
2321
|
+
# of a UTF-8 encoded JSON, which contains the encryption context as
|
2322
|
+
# key-value pairs.
|
2323
|
+
#
|
2324
|
+
# **Directory buckets** - You can optionally provide an explicit
|
2325
|
+
# encryption context value. The value must match the default encryption
|
2326
|
+
# context - the bucket Amazon Resource Name (ARN). An additional
|
2327
|
+
# encryption context value is not supported.
|
1130
2328
|
# @option options [Boolean] :bucket_key_enabled
|
1131
2329
|
# Specifies whether Amazon S3 should use an S3 Bucket Key for object
|
1132
2330
|
# encryption with server-side encryption using Key Management Service
|
1133
|
-
# (KMS) keys (SSE-KMS).
|
1134
|
-
# to use an S3 Bucket Key for object encryption with SSE-KMS.
|
2331
|
+
# (KMS) keys (SSE-KMS).
|
1135
2332
|
#
|
1136
|
-
#
|
2333
|
+
# **General purpose buckets** - Setting this header to `true` causes
|
2334
|
+
# Amazon S3 to use an S3 Bucket Key for object encryption with SSE-KMS.
|
2335
|
+
# Also, specifying this header with a PUT action doesn't affect
|
1137
2336
|
# bucket-level settings for S3 Bucket Key.
|
2337
|
+
#
|
2338
|
+
# **Directory buckets** - S3 Bucket Keys are always enabled for `GET`
|
2339
|
+
# and `PUT` operations in a directory bucket and can’t be disabled. S3
|
2340
|
+
# Bucket Keys aren't supported, when you copy SSE-KMS encrypted objects
|
2341
|
+
# from general purpose buckets to directory buckets, from directory
|
2342
|
+
# buckets to general purpose buckets, or between directory buckets,
|
2343
|
+
# through [CopyObject][1], [UploadPartCopy][2], [the Copy operation in
|
2344
|
+
# Batch Operations][3], or [the import jobs][4]. In this case, Amazon S3
|
2345
|
+
# makes a call to KMS every time a copy request is made for a
|
2346
|
+
# KMS-encrypted object.
|
2347
|
+
#
|
2348
|
+
#
|
2349
|
+
#
|
2350
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html
|
2351
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html
|
2352
|
+
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-objects-Batch-Ops
|
2353
|
+
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/create-import-job
|
1138
2354
|
# @option options [String] :request_payer
|
1139
2355
|
# Confirms that the requester knows that they will be charged for the
|
1140
2356
|
# request. Bucket owners need not specify this parameter in their
|
1141
|
-
# requests.
|
2357
|
+
# requests. If either the source or destination S3 bucket has Requester
|
2358
|
+
# Pays enabled, the requester will pay for corresponding charges to copy
|
2359
|
+
# the object. For information about downloading objects from Requester
|
1142
2360
|
# Pays buckets, see [Downloading Objects in Requester Pays Buckets][1]
|
1143
2361
|
# in the *Amazon S3 User Guide*.
|
1144
2362
|
#
|
2363
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
2364
|
+
#
|
2365
|
+
# </note>
|
2366
|
+
#
|
1145
2367
|
#
|
1146
2368
|
#
|
1147
2369
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
|
1148
2370
|
# @option options [String] :tagging
|
1149
2371
|
# The tag-set for the object. The tag-set must be encoded as URL Query
|
1150
2372
|
# parameters.
|
2373
|
+
#
|
2374
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
2375
|
+
#
|
2376
|
+
# </note>
|
1151
2377
|
# @option options [String] :object_lock_mode
|
1152
2378
|
# Specifies the Object Lock mode that you want to apply to the uploaded
|
1153
2379
|
# object.
|
2380
|
+
#
|
2381
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
2382
|
+
#
|
2383
|
+
# </note>
|
1154
2384
|
# @option options [Time,DateTime,Date,Integer,String] :object_lock_retain_until_date
|
1155
2385
|
# Specifies the date and time when you want the Object Lock to expire.
|
2386
|
+
#
|
2387
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
2388
|
+
#
|
2389
|
+
# </note>
|
1156
2390
|
# @option options [String] :object_lock_legal_hold_status
|
1157
2391
|
# Specifies whether you want to apply a legal hold to the uploaded
|
1158
2392
|
# object.
|
2393
|
+
#
|
2394
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
2395
|
+
#
|
2396
|
+
# </note>
|
1159
2397
|
# @option options [String] :expected_bucket_owner
|
1160
|
-
# The account ID of the expected bucket owner. If the
|
1161
|
-
#
|
1162
|
-
# Forbidden` (access denied).
|
2398
|
+
# The account ID of the expected bucket owner. If the account ID that
|
2399
|
+
# you provide does not match the actual owner of the bucket, the request
|
2400
|
+
# fails with the HTTP status code `403 Forbidden` (access denied).
|
1163
2401
|
# @option options [String] :checksum_algorithm
|
1164
|
-
# Indicates the algorithm you want Amazon S3 to use to create the
|
2402
|
+
# Indicates the algorithm that you want Amazon S3 to use to create the
|
1165
2403
|
# checksum for the object. For more information, see [Checking object
|
1166
2404
|
# integrity][1] in the *Amazon S3 User Guide*.
|
1167
2405
|
#
|
1168
2406
|
#
|
1169
2407
|
#
|
1170
2408
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html
|
2409
|
+
# @option options [String] :checksum_type
|
2410
|
+
# Indicates the checksum type that you want Amazon S3 to use to
|
2411
|
+
# calculate the object’s checksum value. For more information, see
|
2412
|
+
# [Checking object integrity in the Amazon S3 User Guide][1].
|
2413
|
+
#
|
2414
|
+
#
|
2415
|
+
#
|
2416
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html
|
1171
2417
|
# @return [MultipartUpload]
|
1172
2418
|
def initiate_multipart_upload(options = {})
|
1173
2419
|
options = options.merge(
|
1174
2420
|
bucket: @bucket_name,
|
1175
2421
|
key: @key
|
1176
2422
|
)
|
1177
|
-
resp = Aws::Plugins::UserAgent.
|
2423
|
+
resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
|
1178
2424
|
@client.create_multipart_upload(options)
|
1179
2425
|
end
|
1180
2426
|
MultipartUpload.new(
|
@@ -1197,21 +2443,25 @@ module Aws::S3
|
|
1197
2443
|
# content_length: 1,
|
1198
2444
|
# content_md5: "ContentMD5",
|
1199
2445
|
# content_type: "ContentType",
|
1200
|
-
# checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256
|
2446
|
+
# checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256, CRC64NVME
|
1201
2447
|
# checksum_crc32: "ChecksumCRC32",
|
1202
2448
|
# checksum_crc32c: "ChecksumCRC32C",
|
2449
|
+
# checksum_crc64nvme: "ChecksumCRC64NVME",
|
1203
2450
|
# checksum_sha1: "ChecksumSHA1",
|
1204
2451
|
# checksum_sha256: "ChecksumSHA256",
|
1205
2452
|
# expires: Time.now,
|
2453
|
+
# if_match: "IfMatch",
|
2454
|
+
# if_none_match: "IfNoneMatch",
|
1206
2455
|
# grant_full_control: "GrantFullControl",
|
1207
2456
|
# grant_read: "GrantRead",
|
1208
2457
|
# grant_read_acp: "GrantReadACP",
|
1209
2458
|
# grant_write_acp: "GrantWriteACP",
|
2459
|
+
# write_offset_bytes: 1,
|
1210
2460
|
# metadata: {
|
1211
2461
|
# "MetadataKey" => "MetadataValue",
|
1212
2462
|
# },
|
1213
|
-
# server_side_encryption: "AES256", # accepts AES256, aws:kms, aws:kms:dsse
|
1214
|
-
# storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW
|
2463
|
+
# server_side_encryption: "AES256", # accepts AES256, aws:fsx, aws:kms, aws:kms:dsse
|
2464
|
+
# storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW, EXPRESS_ONEZONE, FSX_OPENZFS
|
1215
2465
|
# website_redirect_location: "WebsiteRedirectLocation",
|
1216
2466
|
# sse_customer_algorithm: "SSECustomerAlgorithm",
|
1217
2467
|
# sse_customer_key: "SSECustomerKey",
|
@@ -1229,13 +2479,41 @@ module Aws::S3
|
|
1229
2479
|
# @param [Hash] options ({})
|
1230
2480
|
# @option options [String] :acl
|
1231
2481
|
# The canned ACL to apply to the object. For more information, see
|
1232
|
-
# [Canned ACL][1]
|
2482
|
+
# [Canned ACL][1] in the *Amazon S3 User Guide*.
|
2483
|
+
#
|
2484
|
+
# When adding a new object, you can use headers to grant ACL-based
|
2485
|
+
# permissions to individual Amazon Web Services accounts or to
|
2486
|
+
# predefined groups defined by Amazon S3. These permissions are then
|
2487
|
+
# added to the ACL on the object. By default, all objects are private.
|
2488
|
+
# Only the owner has full access control. For more information, see
|
2489
|
+
# [Access Control List (ACL) Overview][2] and [Managing ACLs Using the
|
2490
|
+
# REST API][3] in the *Amazon S3 User Guide*.
|
2491
|
+
#
|
2492
|
+
# If the bucket that you're uploading objects to uses the bucket owner
|
2493
|
+
# enforced setting for S3 Object Ownership, ACLs are disabled and no
|
2494
|
+
# longer affect permissions. Buckets that use this setting only accept
|
2495
|
+
# PUT requests that don't specify an ACL or PUT requests that specify
|
2496
|
+
# bucket owner full control ACLs, such as the
|
2497
|
+
# `bucket-owner-full-control` canned ACL or an equivalent form of this
|
2498
|
+
# ACL expressed in the XML format. PUT requests that contain other ACLs
|
2499
|
+
# (for example, custom grants to certain Amazon Web Services accounts)
|
2500
|
+
# fail and return a `400` error with the error code
|
2501
|
+
# `AccessControlListNotSupported`. For more information, see [
|
2502
|
+
# Controlling ownership of objects and disabling ACLs][4] in the *Amazon
|
2503
|
+
# S3 User Guide*.
|
2504
|
+
#
|
2505
|
+
# <note markdown="1"> * This functionality is not supported for directory buckets.
|
2506
|
+
#
|
2507
|
+
# * This functionality is not supported for Amazon S3 on Outposts.
|
1233
2508
|
#
|
1234
|
-
#
|
2509
|
+
# </note>
|
1235
2510
|
#
|
1236
2511
|
#
|
1237
2512
|
#
|
1238
2513
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html#CannedACL
|
2514
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html
|
2515
|
+
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-using-rest-api.html
|
2516
|
+
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/about-object-ownership.html
|
1239
2517
|
# @option options [String, StringIO, File] :body
|
1240
2518
|
# Object data.
|
1241
2519
|
# @option options [String] :cache_control
|
@@ -1274,7 +2552,7 @@ module Aws::S3
|
|
1274
2552
|
#
|
1275
2553
|
# [1]: https://www.rfc-editor.org/rfc/rfc9110.html#name-content-length
|
1276
2554
|
# @option options [String] :content_md5
|
1277
|
-
# The
|
2555
|
+
# The Base64 encoded 128-bit `MD5` digest of the message (without the
|
1278
2556
|
# headers) according to RFC 1864. This header can be used as a message
|
1279
2557
|
# integrity check to verify that the data is the same data that was
|
1280
2558
|
# originally sent. Although it is optional, we recommend using the
|
@@ -1282,9 +2560,22 @@ module Aws::S3
|
|
1282
2560
|
# information about REST request authentication, see [REST
|
1283
2561
|
# Authentication][1].
|
1284
2562
|
#
|
2563
|
+
# <note markdown="1"> The `Content-MD5` or `x-amz-sdk-checksum-algorithm` header is required
|
2564
|
+
# for any request to upload an object with a retention period configured
|
2565
|
+
# using Amazon S3 Object Lock. For more information, see [Uploading
|
2566
|
+
# objects to an Object Lock enabled bucket ][2] in the *Amazon S3 User
|
2567
|
+
# Guide*.
|
2568
|
+
#
|
2569
|
+
# </note>
|
2570
|
+
#
|
2571
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
2572
|
+
#
|
2573
|
+
# </note>
|
2574
|
+
#
|
1285
2575
|
#
|
1286
2576
|
#
|
1287
2577
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/RESTAuthentication.html
|
2578
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-lock-managing.html#object-lock-put-object
|
1288
2579
|
# @option options [String] :content_type
|
1289
2580
|
# A standard MIME type describing the format of the contents. For more
|
1290
2581
|
# information, see
|
@@ -1295,25 +2586,54 @@ module Aws::S3
|
|
1295
2586
|
# [1]: https://www.rfc-editor.org/rfc/rfc9110.html#name-content-type
|
1296
2587
|
# @option options [String] :checksum_algorithm
|
1297
2588
|
# Indicates the algorithm used to create the checksum for the object
|
1298
|
-
# when
|
1299
|
-
# functionality if
|
1300
|
-
# must be a corresponding `x-amz-checksum` or
|
1301
|
-
# sent. Otherwise, Amazon S3 fails the request
|
1302
|
-
# `400 Bad Request`.
|
1303
|
-
# integrity][1] in the *Amazon S3 User Guide*.
|
2589
|
+
# when you use the SDK. This header will not provide any additional
|
2590
|
+
# functionality if you don't use the SDK. When you send this header,
|
2591
|
+
# there must be a corresponding `x-amz-checksum-algorithm ` or
|
2592
|
+
# `x-amz-trailer` header sent. Otherwise, Amazon S3 fails the request
|
2593
|
+
# with the HTTP status code `400 Bad Request`.
|
1304
2594
|
#
|
1305
|
-
#
|
1306
|
-
#
|
2595
|
+
# For the `x-amz-checksum-algorithm ` header, replace ` algorithm ` with
|
2596
|
+
# the supported algorithm from the following list:
|
2597
|
+
#
|
2598
|
+
# * `CRC32`
|
2599
|
+
#
|
2600
|
+
# * `CRC32C`
|
2601
|
+
#
|
2602
|
+
# * `CRC64NVME`
|
2603
|
+
#
|
2604
|
+
# * `SHA1`
|
2605
|
+
#
|
2606
|
+
# * `SHA256`
|
2607
|
+
#
|
2608
|
+
# For more information, see [Checking object integrity][1] in the
|
2609
|
+
# *Amazon S3 User Guide*.
|
2610
|
+
#
|
2611
|
+
# If the individual checksum value you provide through
|
2612
|
+
# `x-amz-checksum-algorithm ` doesn't match the checksum algorithm you
|
2613
|
+
# set through `x-amz-sdk-checksum-algorithm`, Amazon S3 fails the
|
2614
|
+
# request with a `BadDigest` error.
|
2615
|
+
#
|
2616
|
+
# <note markdown="1"> The `Content-MD5` or `x-amz-sdk-checksum-algorithm` header is required
|
2617
|
+
# for any request to upload an object with a retention period configured
|
2618
|
+
# using Amazon S3 Object Lock. For more information, see [Uploading
|
2619
|
+
# objects to an Object Lock enabled bucket ][2] in the *Amazon S3 User
|
2620
|
+
# Guide*.
|
2621
|
+
#
|
2622
|
+
# </note>
|
2623
|
+
#
|
2624
|
+
# For directory buckets, when you use Amazon Web Services SDKs, `CRC32`
|
2625
|
+
# is the default checksum algorithm that's used for performance.
|
1307
2626
|
#
|
1308
2627
|
#
|
1309
2628
|
#
|
1310
2629
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html
|
2630
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-lock-managing.html#object-lock-put-object
|
1311
2631
|
# @option options [String] :checksum_crc32
|
1312
2632
|
# This header can be used as a data integrity check to verify that the
|
1313
2633
|
# data received is the same data that was originally sent. This header
|
1314
|
-
# specifies the
|
1315
|
-
# more information, see [Checking object integrity][1] in the
|
1316
|
-
# User Guide*.
|
2634
|
+
# specifies the Base64 encoded, 32-bit `CRC32` checksum of the object.
|
2635
|
+
# For more information, see [Checking object integrity][1] in the
|
2636
|
+
# *Amazon S3 User Guide*.
|
1317
2637
|
#
|
1318
2638
|
#
|
1319
2639
|
#
|
@@ -1321,17 +2641,28 @@ module Aws::S3
|
|
1321
2641
|
# @option options [String] :checksum_crc32c
|
1322
2642
|
# This header can be used as a data integrity check to verify that the
|
1323
2643
|
# data received is the same data that was originally sent. This header
|
1324
|
-
# specifies the
|
2644
|
+
# specifies the Base64 encoded, 32-bit `CRC32C` checksum of the object.
|
1325
2645
|
# For more information, see [Checking object integrity][1] in the
|
1326
2646
|
# *Amazon S3 User Guide*.
|
1327
2647
|
#
|
1328
2648
|
#
|
1329
2649
|
#
|
1330
2650
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html
|
2651
|
+
# @option options [String] :checksum_crc64nvme
|
2652
|
+
# This header can be used as a data integrity check to verify that the
|
2653
|
+
# data received is the same data that was originally sent. This header
|
2654
|
+
# specifies the Base64 encoded, 64-bit `CRC64NVME` checksum of the
|
2655
|
+
# object. The `CRC64NVME` checksum is always a full object checksum. For
|
2656
|
+
# more information, see [Checking object integrity in the Amazon S3 User
|
2657
|
+
# Guide][1].
|
2658
|
+
#
|
2659
|
+
#
|
2660
|
+
#
|
2661
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html
|
1331
2662
|
# @option options [String] :checksum_sha1
|
1332
2663
|
# This header can be used as a data integrity check to verify that the
|
1333
2664
|
# data received is the same data that was originally sent. This header
|
1334
|
-
# specifies the
|
2665
|
+
# specifies the Base64 encoded, 160-bit `SHA1` digest of the object. For
|
1335
2666
|
# more information, see [Checking object integrity][1] in the *Amazon S3
|
1336
2667
|
# User Guide*.
|
1337
2668
|
#
|
@@ -1341,7 +2672,7 @@ module Aws::S3
|
|
1341
2672
|
# @option options [String] :checksum_sha256
|
1342
2673
|
# This header can be used as a data integrity check to verify that the
|
1343
2674
|
# data received is the same data that was originally sent. This header
|
1344
|
-
# specifies the
|
2675
|
+
# specifies the Base64 encoded, 256-bit `SHA256` digest of the object.
|
1345
2676
|
# For more information, see [Checking object integrity][1] in the
|
1346
2677
|
# *Amazon S3 User Guide*.
|
1347
2678
|
#
|
@@ -1356,35 +2687,173 @@ module Aws::S3
|
|
1356
2687
|
#
|
1357
2688
|
#
|
1358
2689
|
# [1]: https://www.rfc-editor.org/rfc/rfc7234#section-5.3
|
2690
|
+
# @option options [String] :if_match
|
2691
|
+
# Uploads the object only if the ETag (entity tag) value provided during
|
2692
|
+
# the WRITE operation matches the ETag of the object in S3. If the ETag
|
2693
|
+
# values do not match, the operation returns a `412 Precondition Failed`
|
2694
|
+
# error.
|
2695
|
+
#
|
2696
|
+
# If a conflicting operation occurs during the upload S3 returns a `409
|
2697
|
+
# ConditionalRequestConflict` response. On a 409 failure you should
|
2698
|
+
# fetch the object's ETag and retry the upload.
|
2699
|
+
#
|
2700
|
+
# Expects the ETag value as a string.
|
2701
|
+
#
|
2702
|
+
# For more information about conditional requests, see [RFC 7232][1], or
|
2703
|
+
# [Conditional requests][2] in the *Amazon S3 User Guide*.
|
2704
|
+
#
|
2705
|
+
#
|
2706
|
+
#
|
2707
|
+
# [1]: https://tools.ietf.org/html/rfc7232
|
2708
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/conditional-requests.html
|
2709
|
+
# @option options [String] :if_none_match
|
2710
|
+
# Uploads the object only if the object key name does not already exist
|
2711
|
+
# in the bucket specified. Otherwise, Amazon S3 returns a `412
|
2712
|
+
# Precondition Failed` error.
|
2713
|
+
#
|
2714
|
+
# If a conflicting operation occurs during the upload S3 returns a `409
|
2715
|
+
# ConditionalRequestConflict` response. On a 409 failure you should
|
2716
|
+
# retry the upload.
|
2717
|
+
#
|
2718
|
+
# Expects the '*' (asterisk) character.
|
2719
|
+
#
|
2720
|
+
# For more information about conditional requests, see [RFC 7232][1], or
|
2721
|
+
# [Conditional requests][2] in the *Amazon S3 User Guide*.
|
2722
|
+
#
|
2723
|
+
#
|
2724
|
+
#
|
2725
|
+
# [1]: https://tools.ietf.org/html/rfc7232
|
2726
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/conditional-requests.html
|
1359
2727
|
# @option options [String] :grant_full_control
|
1360
2728
|
# Gives the grantee READ, READ\_ACP, and WRITE\_ACP permissions on the
|
1361
2729
|
# object.
|
1362
2730
|
#
|
1363
|
-
# This
|
2731
|
+
# <note markdown="1"> * This functionality is not supported for directory buckets.
|
2732
|
+
#
|
2733
|
+
# * This functionality is not supported for Amazon S3 on Outposts.
|
2734
|
+
#
|
2735
|
+
# </note>
|
1364
2736
|
# @option options [String] :grant_read
|
1365
2737
|
# Allows grantee to read the object data and its metadata.
|
1366
2738
|
#
|
1367
|
-
# This
|
2739
|
+
# <note markdown="1"> * This functionality is not supported for directory buckets.
|
2740
|
+
#
|
2741
|
+
# * This functionality is not supported for Amazon S3 on Outposts.
|
2742
|
+
#
|
2743
|
+
# </note>
|
1368
2744
|
# @option options [String] :grant_read_acp
|
1369
2745
|
# Allows grantee to read the object ACL.
|
1370
2746
|
#
|
1371
|
-
# This
|
2747
|
+
# <note markdown="1"> * This functionality is not supported for directory buckets.
|
2748
|
+
#
|
2749
|
+
# * This functionality is not supported for Amazon S3 on Outposts.
|
2750
|
+
#
|
2751
|
+
# </note>
|
1372
2752
|
# @option options [String] :grant_write_acp
|
1373
2753
|
# Allows grantee to write the ACL for the applicable object.
|
1374
2754
|
#
|
1375
|
-
# This
|
2755
|
+
# <note markdown="1"> * This functionality is not supported for directory buckets.
|
2756
|
+
#
|
2757
|
+
# * This functionality is not supported for Amazon S3 on Outposts.
|
2758
|
+
#
|
2759
|
+
# </note>
|
2760
|
+
# @option options [Integer] :write_offset_bytes
|
2761
|
+
# Specifies the offset for appending data to existing objects in bytes.
|
2762
|
+
# The offset must be equal to the size of the existing object being
|
2763
|
+
# appended to. If no object exists, setting this header to 0 will create
|
2764
|
+
# a new object.
|
2765
|
+
#
|
2766
|
+
# <note markdown="1"> This functionality is only supported for objects in the Amazon S3
|
2767
|
+
# Express One Zone storage class in directory buckets.
|
2768
|
+
#
|
2769
|
+
# </note>
|
1376
2770
|
# @option options [Hash<String,String>] :metadata
|
1377
2771
|
# A map of metadata to store with the object in S3.
|
1378
2772
|
# @option options [String] :server_side_encryption
|
1379
|
-
# The server-side encryption algorithm used when
|
1380
|
-
# Amazon S3
|
2773
|
+
# The server-side encryption algorithm that was used when you store this
|
2774
|
+
# object in Amazon S3 or Amazon FSx.
|
2775
|
+
#
|
2776
|
+
# * <b>General purpose buckets </b> - You have four mutually exclusive
|
2777
|
+
# options to protect data using server-side encryption in Amazon S3,
|
2778
|
+
# depending on how you choose to manage the encryption keys.
|
2779
|
+
# Specifically, the encryption key options are Amazon S3 managed keys
|
2780
|
+
# (SSE-S3), Amazon Web Services KMS keys (SSE-KMS or DSSE-KMS), and
|
2781
|
+
# customer-provided keys (SSE-C). Amazon S3 encrypts data with
|
2782
|
+
# server-side encryption by using Amazon S3 managed keys (SSE-S3) by
|
2783
|
+
# default. You can optionally tell Amazon S3 to encrypt data at rest
|
2784
|
+
# by using server-side encryption with other key options. For more
|
2785
|
+
# information, see [Using Server-Side Encryption][1] in the *Amazon S3
|
2786
|
+
# User Guide*.
|
2787
|
+
#
|
2788
|
+
# * <b>Directory buckets </b> - For directory buckets, there are only
|
2789
|
+
# two supported options for server-side encryption: server-side
|
2790
|
+
# encryption with Amazon S3 managed keys (SSE-S3) (`AES256`) and
|
2791
|
+
# server-side encryption with KMS keys (SSE-KMS) (`aws:kms`). We
|
2792
|
+
# recommend that the bucket's default encryption uses the desired
|
2793
|
+
# encryption configuration and you don't override the bucket default
|
2794
|
+
# encryption in your `CreateSession` requests or `PUT` object
|
2795
|
+
# requests. Then, new objects are automatically encrypted with the
|
2796
|
+
# desired encryption settings. For more information, see [Protecting
|
2797
|
+
# data with server-side encryption][2] in the *Amazon S3 User Guide*.
|
2798
|
+
# For more information about the encryption overriding behaviors in
|
2799
|
+
# directory buckets, see [Specifying server-side encryption with KMS
|
2800
|
+
# for new object uploads][3].
|
2801
|
+
#
|
2802
|
+
# In the Zonal endpoint API calls (except [CopyObject][4] and
|
2803
|
+
# [UploadPartCopy][5]) using the REST API, the encryption request
|
2804
|
+
# headers must match the encryption settings that are specified in the
|
2805
|
+
# `CreateSession` request. You can't override the values of the
|
2806
|
+
# encryption settings (`x-amz-server-side-encryption`,
|
2807
|
+
# `x-amz-server-side-encryption-aws-kms-key-id`,
|
2808
|
+
# `x-amz-server-side-encryption-context`, and
|
2809
|
+
# `x-amz-server-side-encryption-bucket-key-enabled`) that are
|
2810
|
+
# specified in the `CreateSession` request. You don't need to
|
2811
|
+
# explicitly specify these encryption settings values in Zonal
|
2812
|
+
# endpoint API calls, and Amazon S3 will use the encryption settings
|
2813
|
+
# values from the `CreateSession` request to protect new objects in
|
2814
|
+
# the directory bucket.
|
2815
|
+
#
|
2816
|
+
# <note markdown="1"> When you use the CLI or the Amazon Web Services SDKs, for
|
2817
|
+
# `CreateSession`, the session token refreshes automatically to avoid
|
2818
|
+
# service interruptions when a session expires. The CLI or the Amazon
|
2819
|
+
# Web Services SDKs use the bucket's default encryption configuration
|
2820
|
+
# for the `CreateSession` request. It's not supported to override the
|
2821
|
+
# encryption settings values in the `CreateSession` request. So in the
|
2822
|
+
# Zonal endpoint API calls (except [CopyObject][4] and
|
2823
|
+
# [UploadPartCopy][5]), the encryption request headers must match the
|
2824
|
+
# default encryption configuration of the directory bucket.
|
2825
|
+
#
|
2826
|
+
# </note>
|
2827
|
+
#
|
2828
|
+
# * <b>S3 access points for Amazon FSx </b> - When accessing data stored
|
2829
|
+
# in Amazon FSx file systems using S3 access points, the only valid
|
2830
|
+
# server side encryption option is `aws:fsx`. All Amazon FSx file
|
2831
|
+
# systems have encryption configured by default and are encrypted at
|
2832
|
+
# rest. Data is automatically encrypted before being written to the
|
2833
|
+
# file system, and automatically decrypted as it is read. These
|
2834
|
+
# processes are handled transparently by Amazon FSx.
|
2835
|
+
#
|
2836
|
+
#
|
2837
|
+
#
|
2838
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingServerSideEncryption.html
|
2839
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-serv-side-encryption.html
|
2840
|
+
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-specifying-kms-encryption.html
|
2841
|
+
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html
|
2842
|
+
# [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html
|
1381
2843
|
# @option options [String] :storage_class
|
1382
2844
|
# By default, Amazon S3 uses the STANDARD Storage Class to store newly
|
1383
2845
|
# created objects. The STANDARD storage class provides high durability
|
1384
2846
|
# and high availability. Depending on performance needs, you can specify
|
1385
|
-
# a different Storage Class.
|
1386
|
-
#
|
1387
|
-
#
|
2847
|
+
# a different Storage Class. For more information, see [Storage
|
2848
|
+
# Classes][1] in the *Amazon S3 User Guide*.
|
2849
|
+
#
|
2850
|
+
# <note markdown="1"> * Directory buckets only support `EXPRESS_ONEZONE` (the S3 Express One
|
2851
|
+
# Zone storage class) in Availability Zones and `ONEZONE_IA` (the S3
|
2852
|
+
# One Zone-Infrequent Access storage class) in Dedicated Local Zones.
|
2853
|
+
#
|
2854
|
+
# * Amazon S3 on Outposts only uses the OUTPOSTS Storage Class.
|
2855
|
+
#
|
2856
|
+
# </note>
|
1388
2857
|
#
|
1389
2858
|
#
|
1390
2859
|
#
|
@@ -1393,7 +2862,8 @@ module Aws::S3
|
|
1393
2862
|
# If the bucket is configured as a website, redirects requests for this
|
1394
2863
|
# object to another object in the same bucket or to an external URL.
|
1395
2864
|
# Amazon S3 stores the value of this header in the object metadata. For
|
1396
|
-
# information about object metadata, see [Object Key and Metadata][1]
|
2865
|
+
# information about object metadata, see [Object Key and Metadata][1] in
|
2866
|
+
# the *Amazon S3 User Guide*.
|
1397
2867
|
#
|
1398
2868
|
# In the following example, the request header sets the redirect to an
|
1399
2869
|
# object (anotherPage.html) in the same bucket:
|
@@ -1407,7 +2877,11 @@ module Aws::S3
|
|
1407
2877
|
#
|
1408
2878
|
# For more information about website hosting in Amazon S3, see [Hosting
|
1409
2879
|
# Websites on Amazon S3][2] and [How to Configure Website Page
|
1410
|
-
# Redirects][3]
|
2880
|
+
# Redirects][3] in the *Amazon S3 User Guide*.
|
2881
|
+
#
|
2882
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
2883
|
+
#
|
2884
|
+
# </note>
|
1411
2885
|
#
|
1412
2886
|
#
|
1413
2887
|
#
|
@@ -1415,79 +2889,167 @@ module Aws::S3
|
|
1415
2889
|
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/WebsiteHosting.html
|
1416
2890
|
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/how-to-page-redirect.html
|
1417
2891
|
# @option options [String] :sse_customer_algorithm
|
1418
|
-
# Specifies the algorithm to use
|
1419
|
-
# example, AES256).
|
2892
|
+
# Specifies the algorithm to use when encrypting the object (for
|
2893
|
+
# example, `AES256`).
|
2894
|
+
#
|
2895
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
2896
|
+
#
|
2897
|
+
# </note>
|
1420
2898
|
# @option options [String] :sse_customer_key
|
1421
2899
|
# Specifies the customer-provided encryption key for Amazon S3 to use in
|
1422
2900
|
# encrypting data. This value is used to store the object and then it is
|
1423
2901
|
# discarded; Amazon S3 does not store the encryption key. The key must
|
1424
2902
|
# be appropriate for use with the algorithm specified in the
|
1425
2903
|
# `x-amz-server-side-encryption-customer-algorithm` header.
|
2904
|
+
#
|
2905
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
2906
|
+
#
|
2907
|
+
# </note>
|
1426
2908
|
# @option options [String] :sse_customer_key_md5
|
1427
2909
|
# Specifies the 128-bit MD5 digest of the encryption key according to
|
1428
2910
|
# RFC 1321. Amazon S3 uses this header for a message integrity check to
|
1429
2911
|
# ensure that the encryption key was transmitted without error.
|
2912
|
+
#
|
2913
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
2914
|
+
#
|
2915
|
+
# </note>
|
1430
2916
|
# @option options [String] :ssekms_key_id
|
1431
|
-
#
|
1432
|
-
#
|
1433
|
-
#
|
1434
|
-
#
|
1435
|
-
#
|
1436
|
-
#
|
1437
|
-
#
|
1438
|
-
#
|
1439
|
-
#
|
2917
|
+
# Specifies the KMS key ID (Key ID, Key ARN, or Key Alias) to use for
|
2918
|
+
# object encryption. If the KMS key doesn't exist in the same account
|
2919
|
+
# that's issuing the command, you must use the full Key ARN not the Key
|
2920
|
+
# ID.
|
2921
|
+
#
|
2922
|
+
# **General purpose buckets** - If you specify
|
2923
|
+
# `x-amz-server-side-encryption` with `aws:kms` or `aws:kms:dsse`, this
|
2924
|
+
# header specifies the ID (Key ID, Key ARN, or Key Alias) of the KMS key
|
2925
|
+
# to use. If you specify `x-amz-server-side-encryption:aws:kms` or
|
2926
|
+
# `x-amz-server-side-encryption:aws:kms:dsse`, but do not provide
|
2927
|
+
# `x-amz-server-side-encryption-aws-kms-key-id`, Amazon S3 uses the
|
2928
|
+
# Amazon Web Services managed key (`aws/s3`) to protect the data.
|
2929
|
+
#
|
2930
|
+
# **Directory buckets** - To encrypt data using SSE-KMS, it's
|
2931
|
+
# recommended to specify the `x-amz-server-side-encryption` header to
|
2932
|
+
# `aws:kms`. Then, the `x-amz-server-side-encryption-aws-kms-key-id`
|
2933
|
+
# header implicitly uses the bucket's default KMS customer managed key
|
2934
|
+
# ID. If you want to explicitly set the `
|
2935
|
+
# x-amz-server-side-encryption-aws-kms-key-id` header, it must match the
|
2936
|
+
# bucket's default customer managed key (using key ID or ARN, not
|
2937
|
+
# alias). Your SSE-KMS configuration can only support 1 [customer
|
2938
|
+
# managed key][1] per directory bucket's lifetime. The [Amazon Web
|
2939
|
+
# Services managed key][2] (`aws/s3`) isn't supported. Incorrect key
|
2940
|
+
# specification results in an HTTP `400 Bad Request` error.
|
2941
|
+
#
|
2942
|
+
#
|
2943
|
+
#
|
2944
|
+
# [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk
|
2945
|
+
# [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk
|
1440
2946
|
# @option options [String] :ssekms_encryption_context
|
1441
|
-
# Specifies the Amazon Web Services KMS Encryption Context
|
1442
|
-
#
|
1443
|
-
#
|
1444
|
-
#
|
1445
|
-
#
|
1446
|
-
# operations on this
|
2947
|
+
# Specifies the Amazon Web Services KMS Encryption Context as an
|
2948
|
+
# additional encryption context to use for object encryption. The value
|
2949
|
+
# of this header is a Base64 encoded string of a UTF-8 encoded JSON,
|
2950
|
+
# which contains the encryption context as key-value pairs. This value
|
2951
|
+
# is stored as object metadata and automatically gets passed on to
|
2952
|
+
# Amazon Web Services KMS for future `GetObject` operations on this
|
2953
|
+
# object.
|
2954
|
+
#
|
2955
|
+
# **General purpose buckets** - This value must be explicitly added
|
2956
|
+
# during `CopyObject` operations if you want an additional encryption
|
2957
|
+
# context for your object. For more information, see [Encryption
|
2958
|
+
# context][1] in the *Amazon S3 User Guide*.
|
2959
|
+
#
|
2960
|
+
# **Directory buckets** - You can optionally provide an explicit
|
2961
|
+
# encryption context value. The value must match the default encryption
|
2962
|
+
# context - the bucket Amazon Resource Name (ARN). An additional
|
2963
|
+
# encryption context value is not supported.
|
2964
|
+
#
|
2965
|
+
#
|
2966
|
+
#
|
2967
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/UsingKMSEncryption.html#encryption-context
|
1447
2968
|
# @option options [Boolean] :bucket_key_enabled
|
1448
2969
|
# Specifies whether Amazon S3 should use an S3 Bucket Key for object
|
1449
2970
|
# encryption with server-side encryption using Key Management Service
|
1450
|
-
# (KMS) keys (SSE-KMS).
|
1451
|
-
# to use an S3 Bucket Key for object encryption with SSE-KMS.
|
2971
|
+
# (KMS) keys (SSE-KMS).
|
1452
2972
|
#
|
1453
|
-
#
|
1454
|
-
#
|
2973
|
+
# **General purpose buckets** - Setting this header to `true` causes
|
2974
|
+
# Amazon S3 to use an S3 Bucket Key for object encryption with SSE-KMS.
|
2975
|
+
# Also, specifying this header with a PUT action doesn't affect
|
2976
|
+
# bucket-level settings for S3 Bucket Key.
|
2977
|
+
#
|
2978
|
+
# **Directory buckets** - S3 Bucket Keys are always enabled for `GET`
|
2979
|
+
# and `PUT` operations in a directory bucket and can’t be disabled. S3
|
2980
|
+
# Bucket Keys aren't supported, when you copy SSE-KMS encrypted objects
|
2981
|
+
# from general purpose buckets to directory buckets, from directory
|
2982
|
+
# buckets to general purpose buckets, or between directory buckets,
|
2983
|
+
# through [CopyObject][1], [UploadPartCopy][2], [the Copy operation in
|
2984
|
+
# Batch Operations][3], or [the import jobs][4]. In this case, Amazon S3
|
2985
|
+
# makes a call to KMS every time a copy request is made for a
|
2986
|
+
# KMS-encrypted object.
|
2987
|
+
#
|
2988
|
+
#
|
2989
|
+
#
|
2990
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html
|
2991
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html
|
2992
|
+
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-objects-Batch-Ops
|
2993
|
+
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/create-import-job
|
1455
2994
|
# @option options [String] :request_payer
|
1456
2995
|
# Confirms that the requester knows that they will be charged for the
|
1457
2996
|
# request. Bucket owners need not specify this parameter in their
|
1458
|
-
# requests.
|
2997
|
+
# requests. If either the source or destination S3 bucket has Requester
|
2998
|
+
# Pays enabled, the requester will pay for corresponding charges to copy
|
2999
|
+
# the object. For information about downloading objects from Requester
|
1459
3000
|
# Pays buckets, see [Downloading Objects in Requester Pays Buckets][1]
|
1460
3001
|
# in the *Amazon S3 User Guide*.
|
1461
3002
|
#
|
3003
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
3004
|
+
#
|
3005
|
+
# </note>
|
3006
|
+
#
|
1462
3007
|
#
|
1463
3008
|
#
|
1464
3009
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
|
1465
3010
|
# @option options [String] :tagging
|
1466
3011
|
# The tag-set for the object. The tag-set must be encoded as URL Query
|
1467
3012
|
# parameters. (For example, "Key1=Value1")
|
3013
|
+
#
|
3014
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
3015
|
+
#
|
3016
|
+
# </note>
|
1468
3017
|
# @option options [String] :object_lock_mode
|
1469
3018
|
# The Object Lock mode that you want to apply to this object.
|
3019
|
+
#
|
3020
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
3021
|
+
#
|
3022
|
+
# </note>
|
1470
3023
|
# @option options [Time,DateTime,Date,Integer,String] :object_lock_retain_until_date
|
1471
3024
|
# The date and time when you want this object's Object Lock to expire.
|
1472
3025
|
# Must be formatted as a timestamp parameter.
|
3026
|
+
#
|
3027
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
3028
|
+
#
|
3029
|
+
# </note>
|
1473
3030
|
# @option options [String] :object_lock_legal_hold_status
|
1474
3031
|
# Specifies whether a legal hold will be applied to this object. For
|
1475
|
-
# more information about S3 Object Lock, see [Object Lock][1]
|
3032
|
+
# more information about S3 Object Lock, see [Object Lock][1] in the
|
3033
|
+
# *Amazon S3 User Guide*.
|
3034
|
+
#
|
3035
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
3036
|
+
#
|
3037
|
+
# </note>
|
1476
3038
|
#
|
1477
3039
|
#
|
1478
3040
|
#
|
1479
3041
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lock.html
|
1480
3042
|
# @option options [String] :expected_bucket_owner
|
1481
|
-
# The account ID of the expected bucket owner. If the
|
1482
|
-
#
|
1483
|
-
# Forbidden` (access denied).
|
3043
|
+
# The account ID of the expected bucket owner. If the account ID that
|
3044
|
+
# you provide does not match the actual owner of the bucket, the request
|
3045
|
+
# fails with the HTTP status code `403 Forbidden` (access denied).
|
1484
3046
|
# @return [Types::PutObjectOutput]
|
1485
3047
|
def put(options = {})
|
1486
3048
|
options = options.merge(
|
1487
3049
|
bucket: @bucket_name,
|
1488
3050
|
key: @key
|
1489
3051
|
)
|
1490
|
-
resp = Aws::Plugins::UserAgent.
|
3052
|
+
resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
|
1491
3053
|
@client.put_object(options)
|
1492
3054
|
end
|
1493
3055
|
resp.data
|
@@ -1543,7 +3105,7 @@ module Aws::S3
|
|
1543
3105
|
# bucket_name: "BucketName", # required
|
1544
3106
|
# prefix: "LocationPrefix", # required
|
1545
3107
|
# encryption: {
|
1546
|
-
# encryption_type: "AES256", # required, accepts AES256, aws:kms, aws:kms:dsse
|
3108
|
+
# encryption_type: "AES256", # required, accepts AES256, aws:fsx, aws:kms, aws:kms:dsse
|
1547
3109
|
# kms_key_id: "SSEKMSKeyId",
|
1548
3110
|
# kms_context: "KMSContext",
|
1549
3111
|
# },
|
@@ -1574,12 +3136,12 @@ module Aws::S3
|
|
1574
3136
|
# value: "MetadataValue",
|
1575
3137
|
# },
|
1576
3138
|
# ],
|
1577
|
-
# storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW
|
3139
|
+
# storage_class: "STANDARD", # accepts STANDARD, REDUCED_REDUNDANCY, STANDARD_IA, ONEZONE_IA, INTELLIGENT_TIERING, GLACIER, DEEP_ARCHIVE, OUTPOSTS, GLACIER_IR, SNOW, EXPRESS_ONEZONE, FSX_OPENZFS
|
1578
3140
|
# },
|
1579
3141
|
# },
|
1580
3142
|
# },
|
1581
3143
|
# request_payer: "requester", # accepts requester
|
1582
|
-
# checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256
|
3144
|
+
# checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256, CRC64NVME
|
1583
3145
|
# expected_bucket_owner: "AccountId",
|
1584
3146
|
# })
|
1585
3147
|
# @param [Hash] options ({})
|
@@ -1590,21 +3152,27 @@ module Aws::S3
|
|
1590
3152
|
# @option options [String] :request_payer
|
1591
3153
|
# Confirms that the requester knows that they will be charged for the
|
1592
3154
|
# request. Bucket owners need not specify this parameter in their
|
1593
|
-
# requests.
|
3155
|
+
# requests. If either the source or destination S3 bucket has Requester
|
3156
|
+
# Pays enabled, the requester will pay for corresponding charges to copy
|
3157
|
+
# the object. For information about downloading objects from Requester
|
1594
3158
|
# Pays buckets, see [Downloading Objects in Requester Pays Buckets][1]
|
1595
3159
|
# in the *Amazon S3 User Guide*.
|
1596
3160
|
#
|
3161
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
3162
|
+
#
|
3163
|
+
# </note>
|
3164
|
+
#
|
1597
3165
|
#
|
1598
3166
|
#
|
1599
3167
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
|
1600
3168
|
# @option options [String] :checksum_algorithm
|
1601
3169
|
# Indicates the algorithm used to create the checksum for the object
|
1602
|
-
# when
|
1603
|
-
# functionality if
|
1604
|
-
# must be a corresponding `x-amz-checksum` or `x-amz-trailer`
|
1605
|
-
# sent. Otherwise, Amazon S3 fails the request with the HTTP
|
1606
|
-
# `400 Bad Request`. For more information, see [Checking
|
1607
|
-
# integrity][1] in the *Amazon S3 User Guide*.
|
3170
|
+
# when you use the SDK. This header will not provide any additional
|
3171
|
+
# functionality if you don't use the SDK. When you send this header,
|
3172
|
+
# there must be a corresponding `x-amz-checksum` or `x-amz-trailer`
|
3173
|
+
# header sent. Otherwise, Amazon S3 fails the request with the HTTP
|
3174
|
+
# status code `400 Bad Request`. For more information, see [Checking
|
3175
|
+
# object integrity][1] in the *Amazon S3 User Guide*.
|
1608
3176
|
#
|
1609
3177
|
# If you provide an individual checksum, Amazon S3 ignores any provided
|
1610
3178
|
# `ChecksumAlgorithm` parameter.
|
@@ -1613,16 +3181,16 @@ module Aws::S3
|
|
1613
3181
|
#
|
1614
3182
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html
|
1615
3183
|
# @option options [String] :expected_bucket_owner
|
1616
|
-
# The account ID of the expected bucket owner. If the
|
1617
|
-
#
|
1618
|
-
# Forbidden` (access denied).
|
3184
|
+
# The account ID of the expected bucket owner. If the account ID that
|
3185
|
+
# you provide does not match the actual owner of the bucket, the request
|
3186
|
+
# fails with the HTTP status code `403 Forbidden` (access denied).
|
1619
3187
|
# @return [Types::RestoreObjectOutput]
|
1620
3188
|
def restore_object(options = {})
|
1621
3189
|
options = options.merge(
|
1622
3190
|
bucket: @bucket_name,
|
1623
3191
|
key: @key
|
1624
3192
|
)
|
1625
|
-
resp = Aws::Plugins::UserAgent.
|
3193
|
+
resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
|
1626
3194
|
@client.restore_object(options)
|
1627
3195
|
end
|
1628
3196
|
resp.data
|
@@ -1636,6 +3204,12 @@ module Aws::S3
|
|
1636
3204
|
# if_none_match: "IfNoneMatch",
|
1637
3205
|
# if_unmodified_since: Time.now,
|
1638
3206
|
# range: "Range",
|
3207
|
+
# response_cache_control: "ResponseCacheControl",
|
3208
|
+
# response_content_disposition: "ResponseContentDisposition",
|
3209
|
+
# response_content_encoding: "ResponseContentEncoding",
|
3210
|
+
# response_content_language: "ResponseContentLanguage",
|
3211
|
+
# response_content_type: "ResponseContentType",
|
3212
|
+
# response_expires: Time.now,
|
1639
3213
|
# version_id: "ObjectVersionId",
|
1640
3214
|
# sse_customer_algorithm: "SSECustomerAlgorithm",
|
1641
3215
|
# sse_customer_key: "SSECustomerKey",
|
@@ -1649,42 +3223,137 @@ module Aws::S3
|
|
1649
3223
|
# @option options [String] :if_match
|
1650
3224
|
# Return the object only if its entity tag (ETag) is the same as the one
|
1651
3225
|
# specified; otherwise, return a 412 (precondition failed) error.
|
3226
|
+
#
|
3227
|
+
# If both of the `If-Match` and `If-Unmodified-Since` headers are
|
3228
|
+
# present in the request as follows:
|
3229
|
+
#
|
3230
|
+
# * `If-Match` condition evaluates to `true`, and;
|
3231
|
+
#
|
3232
|
+
# * `If-Unmodified-Since` condition evaluates to `false`;
|
3233
|
+
#
|
3234
|
+
# Then Amazon S3 returns `200 OK` and the data requested.
|
3235
|
+
#
|
3236
|
+
# For more information about conditional requests, see [RFC 7232][1].
|
3237
|
+
#
|
3238
|
+
#
|
3239
|
+
#
|
3240
|
+
# [1]: https://tools.ietf.org/html/rfc7232
|
1652
3241
|
# @option options [Time,DateTime,Date,Integer,String] :if_modified_since
|
1653
3242
|
# Return the object only if it has been modified since the specified
|
1654
3243
|
# time; otherwise, return a 304 (not modified) error.
|
3244
|
+
#
|
3245
|
+
# If both of the `If-None-Match` and `If-Modified-Since` headers are
|
3246
|
+
# present in the request as follows:
|
3247
|
+
#
|
3248
|
+
# * `If-None-Match` condition evaluates to `false`, and;
|
3249
|
+
#
|
3250
|
+
# * `If-Modified-Since` condition evaluates to `true`;
|
3251
|
+
#
|
3252
|
+
# Then Amazon S3 returns the `304 Not Modified` response code.
|
3253
|
+
#
|
3254
|
+
# For more information about conditional requests, see [RFC 7232][1].
|
3255
|
+
#
|
3256
|
+
#
|
3257
|
+
#
|
3258
|
+
# [1]: https://tools.ietf.org/html/rfc7232
|
1655
3259
|
# @option options [String] :if_none_match
|
1656
3260
|
# Return the object only if its entity tag (ETag) is different from the
|
1657
3261
|
# one specified; otherwise, return a 304 (not modified) error.
|
3262
|
+
#
|
3263
|
+
# If both of the `If-None-Match` and `If-Modified-Since` headers are
|
3264
|
+
# present in the request as follows:
|
3265
|
+
#
|
3266
|
+
# * `If-None-Match` condition evaluates to `false`, and;
|
3267
|
+
#
|
3268
|
+
# * `If-Modified-Since` condition evaluates to `true`;
|
3269
|
+
#
|
3270
|
+
# Then Amazon S3 returns the `304 Not Modified` response code.
|
3271
|
+
#
|
3272
|
+
# For more information about conditional requests, see [RFC 7232][1].
|
3273
|
+
#
|
3274
|
+
#
|
3275
|
+
#
|
3276
|
+
# [1]: https://tools.ietf.org/html/rfc7232
|
1658
3277
|
# @option options [Time,DateTime,Date,Integer,String] :if_unmodified_since
|
1659
3278
|
# Return the object only if it has not been modified since the specified
|
1660
3279
|
# time; otherwise, return a 412 (precondition failed) error.
|
3280
|
+
#
|
3281
|
+
# If both of the `If-Match` and `If-Unmodified-Since` headers are
|
3282
|
+
# present in the request as follows:
|
3283
|
+
#
|
3284
|
+
# * `If-Match` condition evaluates to `true`, and;
|
3285
|
+
#
|
3286
|
+
# * `If-Unmodified-Since` condition evaluates to `false`;
|
3287
|
+
#
|
3288
|
+
# Then Amazon S3 returns `200 OK` and the data requested.
|
3289
|
+
#
|
3290
|
+
# For more information about conditional requests, see [RFC 7232][1].
|
3291
|
+
#
|
3292
|
+
#
|
3293
|
+
#
|
3294
|
+
# [1]: https://tools.ietf.org/html/rfc7232
|
1661
3295
|
# @option options [String] :range
|
1662
3296
|
# HeadObject returns only the metadata for an object. If the Range is
|
1663
3297
|
# satisfiable, only the `ContentLength` is affected in the response. If
|
1664
3298
|
# the Range is not satisfiable, S3 returns a `416 - Requested Range Not
|
1665
3299
|
# Satisfiable` error.
|
3300
|
+
# @option options [String] :response_cache_control
|
3301
|
+
# Sets the `Cache-Control` header of the response.
|
3302
|
+
# @option options [String] :response_content_disposition
|
3303
|
+
# Sets the `Content-Disposition` header of the response.
|
3304
|
+
# @option options [String] :response_content_encoding
|
3305
|
+
# Sets the `Content-Encoding` header of the response.
|
3306
|
+
# @option options [String] :response_content_language
|
3307
|
+
# Sets the `Content-Language` header of the response.
|
3308
|
+
# @option options [String] :response_content_type
|
3309
|
+
# Sets the `Content-Type` header of the response.
|
3310
|
+
# @option options [Time,DateTime,Date,Integer,String] :response_expires
|
3311
|
+
# Sets the `Expires` header of the response.
|
1666
3312
|
# @option options [String] :version_id
|
1667
|
-
#
|
3313
|
+
# Version ID used to reference a specific version of the object.
|
3314
|
+
#
|
3315
|
+
# <note markdown="1"> For directory buckets in this API operation, only the `null` value of
|
3316
|
+
# the version ID is supported.
|
3317
|
+
#
|
3318
|
+
# </note>
|
1668
3319
|
# @option options [String] :sse_customer_algorithm
|
1669
|
-
# Specifies the algorithm to use
|
3320
|
+
# Specifies the algorithm to use when encrypting the object (for
|
1670
3321
|
# example, AES256).
|
3322
|
+
#
|
3323
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
3324
|
+
#
|
3325
|
+
# </note>
|
1671
3326
|
# @option options [String] :sse_customer_key
|
1672
3327
|
# Specifies the customer-provided encryption key for Amazon S3 to use in
|
1673
3328
|
# encrypting data. This value is used to store the object and then it is
|
1674
3329
|
# discarded; Amazon S3 does not store the encryption key. The key must
|
1675
3330
|
# be appropriate for use with the algorithm specified in the
|
1676
3331
|
# `x-amz-server-side-encryption-customer-algorithm` header.
|
3332
|
+
#
|
3333
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
3334
|
+
#
|
3335
|
+
# </note>
|
1677
3336
|
# @option options [String] :sse_customer_key_md5
|
1678
3337
|
# Specifies the 128-bit MD5 digest of the encryption key according to
|
1679
3338
|
# RFC 1321. Amazon S3 uses this header for a message integrity check to
|
1680
3339
|
# ensure that the encryption key was transmitted without error.
|
3340
|
+
#
|
3341
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
3342
|
+
#
|
3343
|
+
# </note>
|
1681
3344
|
# @option options [String] :request_payer
|
1682
3345
|
# Confirms that the requester knows that they will be charged for the
|
1683
3346
|
# request. Bucket owners need not specify this parameter in their
|
1684
|
-
# requests.
|
3347
|
+
# requests. If either the source or destination S3 bucket has Requester
|
3348
|
+
# Pays enabled, the requester will pay for corresponding charges to copy
|
3349
|
+
# the object. For information about downloading objects from Requester
|
1685
3350
|
# Pays buckets, see [Downloading Objects in Requester Pays Buckets][1]
|
1686
3351
|
# in the *Amazon S3 User Guide*.
|
1687
3352
|
#
|
3353
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
3354
|
+
#
|
3355
|
+
# </note>
|
3356
|
+
#
|
1688
3357
|
#
|
1689
3358
|
#
|
1690
3359
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
|
@@ -1694,23 +3363,33 @@ module Aws::S3
|
|
1694
3363
|
# for the part specified. Useful querying about the size of the part and
|
1695
3364
|
# the number of parts in this object.
|
1696
3365
|
# @option options [String] :expected_bucket_owner
|
1697
|
-
# The account ID of the expected bucket owner. If the
|
1698
|
-
#
|
1699
|
-
# Forbidden` (access denied).
|
3366
|
+
# The account ID of the expected bucket owner. If the account ID that
|
3367
|
+
# you provide does not match the actual owner of the bucket, the request
|
3368
|
+
# fails with the HTTP status code `403 Forbidden` (access denied).
|
1700
3369
|
# @option options [String] :checksum_mode
|
1701
3370
|
# To retrieve the checksum, this parameter must be enabled.
|
1702
3371
|
#
|
1703
|
-
#
|
1704
|
-
#
|
1705
|
-
# KMS), you must have permission to use the
|
1706
|
-
#
|
3372
|
+
# **General purpose buckets** - If you enable checksum mode and the
|
3373
|
+
# object is uploaded with a [checksum][1] and encrypted with an Key
|
3374
|
+
# Management Service (KMS) key, you must have permission to use the
|
3375
|
+
# `kms:Decrypt` action to retrieve the checksum.
|
3376
|
+
#
|
3377
|
+
# **Directory buckets** - If you enable `ChecksumMode` and the object is
|
3378
|
+
# encrypted with Amazon Web Services Key Management Service (Amazon Web
|
3379
|
+
# Services KMS), you must also have the `kms:GenerateDataKey` and
|
3380
|
+
# `kms:Decrypt` permissions in IAM identity-based policies and KMS key
|
3381
|
+
# policies for the KMS key to retrieve the checksum of the object.
|
3382
|
+
#
|
3383
|
+
#
|
3384
|
+
#
|
3385
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_Checksum.html
|
1707
3386
|
# @return [Types::HeadObjectOutput]
|
1708
3387
|
def head(options = {})
|
1709
3388
|
options = options.merge(
|
1710
3389
|
bucket: @bucket_name,
|
1711
3390
|
key: @key
|
1712
3391
|
)
|
1713
|
-
resp = Aws::Plugins::UserAgent.
|
3392
|
+
resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
|
1714
3393
|
@client.head_object(options)
|
1715
3394
|
end
|
1716
3395
|
resp.data
|
@@ -1829,7 +3508,7 @@ module Aws::S3
|
|
1829
3508
|
# request_payer: "requester", # accepts requester
|
1830
3509
|
# bypass_governance_retention: false,
|
1831
3510
|
# expected_bucket_owner: "AccountId",
|
1832
|
-
# checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256
|
3511
|
+
# checksum_algorithm: "CRC32", # accepts CRC32, CRC32C, SHA1, SHA256, CRC64NVME
|
1833
3512
|
# })
|
1834
3513
|
# @param options ({})
|
1835
3514
|
# @option options [String] :mfa
|
@@ -1837,13 +3516,36 @@ module Aws::S3
|
|
1837
3516
|
# space, and the value that is displayed on your authentication device.
|
1838
3517
|
# Required to permanently delete a versioned object if versioning is
|
1839
3518
|
# configured with MFA delete enabled.
|
3519
|
+
#
|
3520
|
+
# When performing the `DeleteObjects` operation on an MFA delete enabled
|
3521
|
+
# bucket, which attempts to delete the specified versioned objects, you
|
3522
|
+
# must include an MFA token. If you don't provide an MFA token, the
|
3523
|
+
# entire request will fail, even if there are non-versioned objects that
|
3524
|
+
# you are trying to delete. If you provide an invalid token, whether
|
3525
|
+
# there are versioned object keys in the request or not, the entire
|
3526
|
+
# Multi-Object Delete request will fail. For information about MFA
|
3527
|
+
# Delete, see [ MFA Delete][1] in the *Amazon S3 User Guide*.
|
3528
|
+
#
|
3529
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
3530
|
+
#
|
3531
|
+
# </note>
|
3532
|
+
#
|
3533
|
+
#
|
3534
|
+
#
|
3535
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/Versioning.html#MultiFactorAuthenticationDelete
|
1840
3536
|
# @option options [String] :request_payer
|
1841
3537
|
# Confirms that the requester knows that they will be charged for the
|
1842
3538
|
# request. Bucket owners need not specify this parameter in their
|
1843
|
-
# requests.
|
3539
|
+
# requests. If either the source or destination S3 bucket has Requester
|
3540
|
+
# Pays enabled, the requester will pay for corresponding charges to copy
|
3541
|
+
# the object. For information about downloading objects from Requester
|
1844
3542
|
# Pays buckets, see [Downloading Objects in Requester Pays Buckets][1]
|
1845
3543
|
# in the *Amazon S3 User Guide*.
|
1846
3544
|
#
|
3545
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
3546
|
+
#
|
3547
|
+
# </note>
|
3548
|
+
#
|
1847
3549
|
#
|
1848
3550
|
#
|
1849
3551
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html
|
@@ -1851,25 +3553,46 @@ module Aws::S3
|
|
1851
3553
|
# Specifies whether you want to delete this object even if it has a
|
1852
3554
|
# Governance-type Object Lock in place. To use this header, you must
|
1853
3555
|
# have the `s3:BypassGovernanceRetention` permission.
|
3556
|
+
#
|
3557
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
3558
|
+
#
|
3559
|
+
# </note>
|
1854
3560
|
# @option options [String] :expected_bucket_owner
|
1855
|
-
# The account ID of the expected bucket owner. If the
|
1856
|
-
#
|
1857
|
-
# Forbidden` (access denied).
|
3561
|
+
# The account ID of the expected bucket owner. If the account ID that
|
3562
|
+
# you provide does not match the actual owner of the bucket, the request
|
3563
|
+
# fails with the HTTP status code `403 Forbidden` (access denied).
|
1858
3564
|
# @option options [String] :checksum_algorithm
|
1859
3565
|
# Indicates the algorithm used to create the checksum for the object
|
1860
|
-
# when
|
1861
|
-
# functionality if
|
1862
|
-
# must be a corresponding `x-amz-checksum` or
|
1863
|
-
# sent. Otherwise, Amazon S3 fails the request
|
1864
|
-
# `400 Bad Request`.
|
1865
|
-
#
|
3566
|
+
# when you use the SDK. This header will not provide any additional
|
3567
|
+
# functionality if you don't use the SDK. When you send this header,
|
3568
|
+
# there must be a corresponding `x-amz-checksum-algorithm ` or
|
3569
|
+
# `x-amz-trailer` header sent. Otherwise, Amazon S3 fails the request
|
3570
|
+
# with the HTTP status code `400 Bad Request`.
|
3571
|
+
#
|
3572
|
+
# For the `x-amz-checksum-algorithm ` header, replace ` algorithm ` with
|
3573
|
+
# the supported algorithm from the following list:
|
3574
|
+
#
|
3575
|
+
# * `CRC32`
|
3576
|
+
#
|
3577
|
+
# * `CRC32C`
|
3578
|
+
#
|
3579
|
+
# * `CRC64NVME`
|
3580
|
+
#
|
3581
|
+
# * `SHA1`
|
3582
|
+
#
|
3583
|
+
# * `SHA256`
|
3584
|
+
#
|
3585
|
+
# For more information, see [Checking object integrity][1] in the
|
3586
|
+
# *Amazon S3 User Guide*.
|
3587
|
+
#
|
3588
|
+
# If the individual checksum value you provide through
|
3589
|
+
# `x-amz-checksum-algorithm ` doesn't match the checksum algorithm you
|
3590
|
+
# set through `x-amz-sdk-checksum-algorithm`, Amazon S3 fails the
|
3591
|
+
# request with a `BadDigest` error.
|
1866
3592
|
#
|
1867
3593
|
# If you provide an individual checksum, Amazon S3 ignores any provided
|
1868
3594
|
# `ChecksumAlgorithm` parameter.
|
1869
3595
|
#
|
1870
|
-
# This checksum algorithm must be the same for all parts and it match
|
1871
|
-
# the checksum value supplied in the `CreateMultipartUpload` request.
|
1872
|
-
#
|
1873
3596
|
#
|
1874
3597
|
#
|
1875
3598
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html
|
@@ -1885,7 +3608,7 @@ module Aws::S3
|
|
1885
3608
|
key: item.key
|
1886
3609
|
}
|
1887
3610
|
end
|
1888
|
-
Aws::Plugins::UserAgent.
|
3611
|
+
Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
|
1889
3612
|
batch[0].client.delete_objects(params)
|
1890
3613
|
end
|
1891
3614
|
end
|
@@ -1897,3 +3620,6 @@ module Aws::S3
|
|
1897
3620
|
end
|
1898
3621
|
end
|
1899
3622
|
end
|
3623
|
+
|
3624
|
+
# Load customizations if they exist
|
3625
|
+
require 'aws-sdk-s3/customizations/object'
|