aws-sdk-s3 1.162.0 → 1.163.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -0
- data/VERSION +1 -1
- data/lib/aws-sdk-s3/bucket.rb +120 -43
- data/lib/aws-sdk-s3/client.rb +1081 -388
- data/lib/aws-sdk-s3/client_api.rb +8 -0
- data/lib/aws-sdk-s3/object.rb +336 -129
- data/lib/aws-sdk-s3/object_summary.rb +324 -109
- data/lib/aws-sdk-s3/object_version.rb +14 -8
- data/lib/aws-sdk-s3/types.rb +644 -306
- data/lib/aws-sdk-s3.rb +1 -1
- data/sig/client.rbs +9 -1
- data/sig/types.rbs +10 -2
- metadata +2 -2
data/lib/aws-sdk-s3/client.rb
CHANGED
@@ -800,9 +800,15 @@ module Aws::S3
|
|
800
800
|
# [Multipart Upload and Permissions][6] in the *Amazon S3 User
|
801
801
|
# Guide*.
|
802
802
|
#
|
803
|
+
# If you provide an [additional checksum value][7] in your
|
804
|
+
# `MultipartUpload` requests and the object is encrypted with Key
|
805
|
+
# Management Service, you must have permission to use the
|
806
|
+
# `kms:Decrypt` action for the `CompleteMultipartUpload` request to
|
807
|
+
# succeed.
|
808
|
+
#
|
803
809
|
# * **Directory bucket permissions** - To grant access to this API
|
804
810
|
# operation on a directory bucket, we recommend that you use the [
|
805
|
-
# `CreateSession` ][
|
811
|
+
# `CreateSession` ][8] API operation for session-based
|
806
812
|
# authorization. Specifically, you grant the
|
807
813
|
# `s3express:CreateSession` permission to the directory bucket in a
|
808
814
|
# bucket policy or an IAM identity-based policy. Then, you make the
|
@@ -813,13 +819,11 @@ module Aws::S3
|
|
813
819
|
# token for use. Amazon Web Services CLI or SDKs create session and
|
814
820
|
# refresh the session token automatically to avoid service
|
815
821
|
# interruptions when a session expires. For more information about
|
816
|
-
# authorization, see [ `CreateSession` ][
|
822
|
+
# authorization, see [ `CreateSession` ][8].
|
817
823
|
#
|
818
|
-
#
|
819
|
-
# `
|
820
|
-
#
|
821
|
-
# `kms:Decrypt` action for the `CompleteMultipartUpload` request to
|
822
|
-
# succeed.
|
824
|
+
# If the object is encrypted with SSE-KMS, you must also have the
|
825
|
+
# `kms:GenerateDataKey` and `kms:Decrypt` permissions in IAM
|
826
|
+
# identity-based policies and KMS key policies for the KMS key.
|
823
827
|
#
|
824
828
|
# Special errors
|
825
829
|
# : * Error Code: `EntityTooSmall`
|
@@ -878,8 +882,8 @@ module Aws::S3
|
|
878
882
|
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/dev/uploadobjusingmpu.html
|
879
883
|
# [5]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html
|
880
884
|
# [6]: https://docs.aws.amazon.com/AmazonS3/latest/dev/mpuAndPermissions.html
|
881
|
-
# [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/
|
882
|
-
# [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/
|
885
|
+
# [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_Checksum.html
|
886
|
+
# [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html
|
883
887
|
# [9]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateMultipartUpload.html
|
884
888
|
# [10]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_AbortMultipartUpload.html
|
885
889
|
# [11]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListParts.html
|
@@ -1265,6 +1269,10 @@ module Aws::S3
|
|
1265
1269
|
# destination. The `s3express:SessionMode` condition key can't be
|
1266
1270
|
# set to `ReadOnly` on the copy destination bucket.
|
1267
1271
|
#
|
1272
|
+
# If the object is encrypted with SSE-KMS, you must also have the
|
1273
|
+
# `kms:GenerateDataKey` and `kms:Decrypt` permissions in IAM
|
1274
|
+
# identity-based policies and KMS key policies for the KMS key.
|
1275
|
+
#
|
1268
1276
|
# For example policies, see [Example bucket policies for S3 Express
|
1269
1277
|
# One Zone][6] and [Amazon Web Services Identity and Access
|
1270
1278
|
# Management (IAM) identity-based policies for S3 Express One
|
@@ -1711,9 +1719,8 @@ module Aws::S3
|
|
1711
1719
|
#
|
1712
1720
|
# @option params [String] :server_side_encryption
|
1713
1721
|
# The server-side encryption algorithm used when storing this object in
|
1714
|
-
# Amazon S3
|
1715
|
-
#
|
1716
|
-
# and will receive a `400 Bad Request` response.
|
1722
|
+
# Amazon S3. Unrecognized or unsupported values won’t write a
|
1723
|
+
# destination object and will receive a `400 Bad Request` response.
|
1717
1724
|
#
|
1718
1725
|
# Amazon S3 automatically encrypts all new objects that are copied to an
|
1719
1726
|
# S3 bucket. When copying an object, if you don't specify encryption
|
@@ -1721,35 +1728,72 @@ module Aws::S3
|
|
1721
1728
|
# object is set to the default encryption configuration of the
|
1722
1729
|
# destination bucket. By default, all buckets have a base level of
|
1723
1730
|
# encryption configuration that uses server-side encryption with Amazon
|
1724
|
-
# S3 managed keys (SSE-S3). If the destination bucket has a
|
1725
|
-
# encryption configuration
|
1726
|
-
#
|
1727
|
-
# encryption with Amazon Web Services KMS keys (DSSE-KMS), or
|
1728
|
-
# server-side encryption with customer-provided encryption keys (SSE-C),
|
1729
|
-
# Amazon S3 uses the corresponding KMS key, or a customer-provided key
|
1730
|
-
# to encrypt the target object copy.
|
1731
|
-
#
|
1732
|
-
# When you perform a `CopyObject` operation, if you want to use a
|
1733
|
-
# different type of encryption setting for the target object, you can
|
1734
|
-
# specify appropriate encryption-related headers to encrypt the target
|
1735
|
-
# object with an Amazon S3 managed key, a KMS key, or a
|
1736
|
-
# customer-provided key. If the encryption setting in your request is
|
1737
|
-
# different from the default encryption configuration of the destination
|
1738
|
-
# bucket, the encryption setting in your request takes precedence.
|
1731
|
+
# S3 managed keys (SSE-S3). If the destination bucket has a different
|
1732
|
+
# default encryption configuration, Amazon S3 uses the corresponding
|
1733
|
+
# encryption key to encrypt the target object copy.
|
1739
1734
|
#
|
1740
1735
|
# With server-side encryption, Amazon S3 encrypts your data as it writes
|
1741
1736
|
# your data to disks in its data centers and decrypts the data when you
|
1742
1737
|
# access it. For more information about server-side encryption, see
|
1743
1738
|
# [Using Server-Side Encryption][1] in the *Amazon S3 User Guide*.
|
1744
1739
|
#
|
1745
|
-
# <
|
1746
|
-
#
|
1747
|
-
#
|
1748
|
-
#
|
1740
|
+
# <b>General purpose buckets </b>
|
1741
|
+
#
|
1742
|
+
# * For general purpose buckets, there are the following supported
|
1743
|
+
# options for server-side encryption: server-side encryption with Key
|
1744
|
+
# Management Service (KMS) keys (SSE-KMS), dual-layer server-side
|
1745
|
+
# encryption with Amazon Web Services KMS keys (DSSE-KMS), and
|
1746
|
+
# server-side encryption with customer-provided encryption keys
|
1747
|
+
# (SSE-C). Amazon S3 uses the corresponding KMS key, or a
|
1748
|
+
# customer-provided key to encrypt the target object copy.
|
1749
|
+
#
|
1750
|
+
# * When you perform a `CopyObject` operation, if you want to use a
|
1751
|
+
# different type of encryption setting for the target object, you can
|
1752
|
+
# specify appropriate encryption-related headers to encrypt the target
|
1753
|
+
# object with an Amazon S3 managed key, a KMS key, or a
|
1754
|
+
# customer-provided key. If the encryption setting in your request is
|
1755
|
+
# different from the default encryption configuration of the
|
1756
|
+
# destination bucket, the encryption setting in your request takes
|
1757
|
+
# precedence.
|
1758
|
+
#
|
1759
|
+
# <b>Directory buckets </b>
|
1760
|
+
#
|
1761
|
+
# * For directory buckets, there are only two supported options for
|
1762
|
+
# server-side encryption: server-side encryption with Amazon S3
|
1763
|
+
# managed keys (SSE-S3) (`AES256`) and server-side encryption with KMS
|
1764
|
+
# keys (SSE-KMS) (`aws:kms`). We recommend that the bucket's default
|
1765
|
+
# encryption uses the desired encryption configuration and you don't
|
1766
|
+
# override the bucket default encryption in your `CreateSession`
|
1767
|
+
# requests or `PUT` object requests. Then, new objects are
|
1768
|
+
# automatically encrypted with the desired encryption settings. For
|
1769
|
+
# more information, see [Protecting data with server-side
|
1770
|
+
# encryption][2] in the *Amazon S3 User Guide*. For more information
|
1771
|
+
# about the encryption overriding behaviors in directory buckets, see
|
1772
|
+
# [Specifying server-side encryption with KMS for new object
|
1773
|
+
# uploads][3].
|
1774
|
+
#
|
1775
|
+
# * To encrypt new object copies to a directory bucket with SSE-KMS, we
|
1776
|
+
# recommend you specify SSE-KMS as the directory bucket's default
|
1777
|
+
# encryption configuration with a KMS key (specifically, a [customer
|
1778
|
+
# managed key][4]). [Amazon Web Services managed key][5] (`aws/s3`)
|
1779
|
+
# isn't supported. Your SSE-KMS configuration can only support 1
|
1780
|
+
# [customer managed key][4] per directory bucket for the lifetime of
|
1781
|
+
# the bucket. After you specify a customer managed key for SSE-KMS,
|
1782
|
+
# you can't override the customer managed key for the bucket's
|
1783
|
+
# SSE-KMS configuration. Then, when you perform a `CopyObject`
|
1784
|
+
# operation and want to specify server-side encryption settings for
|
1785
|
+
# new object copies with SSE-KMS in the encryption-related request
|
1786
|
+
# headers, you must ensure the encryption key is the same customer
|
1787
|
+
# managed key that you specified for the directory bucket's default
|
1788
|
+
# encryption configuration.
|
1749
1789
|
#
|
1750
1790
|
#
|
1751
1791
|
#
|
1752
1792
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/serv-side-encryption.html
|
1793
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-serv-side-encryption.html
|
1794
|
+
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-specifying-kms-encryption.html
|
1795
|
+
# [4]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk
|
1796
|
+
# [5]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk
|
1753
1797
|
#
|
1754
1798
|
# @option params [String] :storage_class
|
1755
1799
|
# If the `x-amz-storage-class` header is not used, the copied object
|
@@ -1846,33 +1890,51 @@ module Aws::S3
|
|
1846
1890
|
# </note>
|
1847
1891
|
#
|
1848
1892
|
# @option params [String] :ssekms_key_id
|
1849
|
-
# Specifies the KMS ID (Key ID, Key ARN, or Key Alias) to use for
|
1850
|
-
# encryption. All GET and PUT requests for an object protected by
|
1851
|
-
# will fail if they're not made via SSL or using SigV4. For
|
1852
|
-
# about configuring any of the officially supported Amazon
|
1853
|
-
# SDKs and Amazon Web Services CLI, see [Specifying the
|
1854
|
-
# Version in Request Authentication][1] in the *Amazon S3 User
|
1855
|
-
#
|
1856
|
-
# <note markdown="1"> This functionality is not supported when the destination bucket is a
|
1857
|
-
# directory bucket.
|
1893
|
+
# Specifies the KMS key ID (Key ID, Key ARN, or Key Alias) to use for
|
1894
|
+
# object encryption. All GET and PUT requests for an object protected by
|
1895
|
+
# KMS will fail if they're not made via SSL or using SigV4. For
|
1896
|
+
# information about configuring any of the officially supported Amazon
|
1897
|
+
# Web Services SDKs and Amazon Web Services CLI, see [Specifying the
|
1898
|
+
# Signature Version in Request Authentication][1] in the *Amazon S3 User
|
1899
|
+
# Guide*.
|
1858
1900
|
#
|
1859
|
-
#
|
1901
|
+
# **Directory buckets** - If you specify `x-amz-server-side-encryption`
|
1902
|
+
# with `aws:kms`, you must specify the `
|
1903
|
+
# x-amz-server-side-encryption-aws-kms-key-id` header with the ID (Key
|
1904
|
+
# ID or Key ARN) of the KMS symmetric encryption customer managed key to
|
1905
|
+
# use. Otherwise, you get an HTTP `400 Bad Request` error. Only use the
|
1906
|
+
# key ID or key ARN. The key alias format of the KMS key isn't
|
1907
|
+
# supported. Your SSE-KMS configuration can only support 1 [customer
|
1908
|
+
# managed key][2] per directory bucket for the lifetime of the bucket.
|
1909
|
+
# [Amazon Web Services managed key][3] (`aws/s3`) isn't supported.
|
1860
1910
|
#
|
1861
1911
|
#
|
1862
1912
|
#
|
1863
1913
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingAWSSDK.html#specify-signature-version
|
1914
|
+
# [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk
|
1915
|
+
# [3]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk
|
1864
1916
|
#
|
1865
1917
|
# @option params [String] :ssekms_encryption_context
|
1866
|
-
# Specifies the Amazon Web Services KMS Encryption Context
|
1867
|
-
#
|
1868
|
-
#
|
1869
|
-
#
|
1870
|
-
# `CopyObject` requests.
|
1918
|
+
# Specifies the Amazon Web Services KMS Encryption Context as an
|
1919
|
+
# additional encryption context to use for the destination object
|
1920
|
+
# encryption. The value of this header is a base64-encoded UTF-8 string
|
1921
|
+
# holding JSON with the encryption context key-value pairs.
|
1871
1922
|
#
|
1872
|
-
#
|
1873
|
-
#
|
1923
|
+
# **General purpose buckets** - This value must be explicitly added to
|
1924
|
+
# specify encryption context for `CopyObject` requests if you want an
|
1925
|
+
# additional encryption context for your destination object. The
|
1926
|
+
# additional encryption context of the source object won't be copied to
|
1927
|
+
# the destination object. For more information, see [Encryption
|
1928
|
+
# context][1] in the *Amazon S3 User Guide*.
|
1874
1929
|
#
|
1875
|
-
#
|
1930
|
+
# **Directory buckets** - You can optionally provide an explicit
|
1931
|
+
# encryption context value. The value must match the default encryption
|
1932
|
+
# context - the bucket Amazon Resource Name (ARN). An additional
|
1933
|
+
# encryption context value is not supported.
|
1934
|
+
#
|
1935
|
+
#
|
1936
|
+
#
|
1937
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/UsingKMSEncryption.html#encryption-context
|
1876
1938
|
#
|
1877
1939
|
# @option params [Boolean] :bucket_key_enabled
|
1878
1940
|
# Specifies whether Amazon S3 should use an S3 Bucket Key for object
|
@@ -1887,14 +1949,19 @@ module Aws::S3
|
|
1887
1949
|
# For more information, see [Amazon S3 Bucket Keys][1] in the *Amazon S3
|
1888
1950
|
# User Guide*.
|
1889
1951
|
#
|
1890
|
-
# <note markdown="1">
|
1891
|
-
#
|
1952
|
+
# <note markdown="1"> **Directory buckets** - S3 Bucket Keys aren't supported, when you
|
1953
|
+
# copy SSE-KMS encrypted objects from general purpose buckets to
|
1954
|
+
# directory buckets, from directory buckets to general purpose buckets,
|
1955
|
+
# or between directory buckets, through [CopyObject][2]. In this case,
|
1956
|
+
# Amazon S3 makes a call to KMS every time a copy request is made for a
|
1957
|
+
# KMS-encrypted object.
|
1892
1958
|
#
|
1893
1959
|
# </note>
|
1894
1960
|
#
|
1895
1961
|
#
|
1896
1962
|
#
|
1897
1963
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/bucket-key.html
|
1964
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html
|
1898
1965
|
#
|
1899
1966
|
# @option params [String] :copy_source_sse_customer_algorithm
|
1900
1967
|
# Specifies the algorithm to use when decrypting the source object (for
|
@@ -2636,9 +2703,53 @@ module Aws::S3
|
|
2636
2703
|
# using server-side encryption with customer-provided encryption
|
2637
2704
|
# keys (SSE-C)][11] in the *Amazon S3 User Guide*.
|
2638
2705
|
#
|
2639
|
-
# * **Directory buckets** -For directory buckets, only
|
2640
|
-
#
|
2641
|
-
#
|
2706
|
+
# * **Directory buckets** - For directory buckets, there are only two
|
2707
|
+
# supported options for server-side encryption: server-side
|
2708
|
+
# encryption with Amazon S3 managed keys (SSE-S3) (`AES256`) and
|
2709
|
+
# server-side encryption with KMS keys (SSE-KMS) (`aws:kms`). We
|
2710
|
+
# recommend that the bucket's default encryption uses the desired
|
2711
|
+
# encryption configuration and you don't override the bucket
|
2712
|
+
# default encryption in your `CreateSession` requests or `PUT`
|
2713
|
+
# object requests. Then, new objects are automatically encrypted
|
2714
|
+
# with the desired encryption settings. For more information, see
|
2715
|
+
# [Protecting data with server-side encryption][12] in the *Amazon
|
2716
|
+
# S3 User Guide*. For more information about the encryption
|
2717
|
+
# overriding behaviors in directory buckets, see [Specifying
|
2718
|
+
# server-side encryption with KMS for new object uploads][13].
|
2719
|
+
#
|
2720
|
+
# In the Zonal endpoint API calls (except [CopyObject][14] and
|
2721
|
+
# [UploadPartCopy][9]) using the REST API, the encryption request
|
2722
|
+
# headers must match the encryption settings that are specified in
|
2723
|
+
# the `CreateSession` request. You can't override the values of the
|
2724
|
+
# encryption settings (`x-amz-server-side-encryption`,
|
2725
|
+
# `x-amz-server-side-encryption-aws-kms-key-id`,
|
2726
|
+
# `x-amz-server-side-encryption-context`, and
|
2727
|
+
# `x-amz-server-side-encryption-bucket-key-enabled`) that are
|
2728
|
+
# specified in the `CreateSession` request. You don't need to
|
2729
|
+
# explicitly specify these encryption settings values in Zonal
|
2730
|
+
# endpoint API calls, and Amazon S3 will use the encryption settings
|
2731
|
+
# values from the `CreateSession` request to protect new objects in
|
2732
|
+
# the directory bucket.
|
2733
|
+
#
|
2734
|
+
# <note markdown="1"> When you use the CLI or the Amazon Web Services SDKs, for
|
2735
|
+
# `CreateSession`, the session token refreshes automatically to
|
2736
|
+
# avoid service interruptions when a session expires. The CLI or the
|
2737
|
+
# Amazon Web Services SDKs use the bucket's default encryption
|
2738
|
+
# configuration for the `CreateSession` request. It's not supported
|
2739
|
+
# to override the encryption settings values in the `CreateSession`
|
2740
|
+
# request. So in the Zonal endpoint API calls (except
|
2741
|
+
# [CopyObject][14] and [UploadPartCopy][9]), the encryption request
|
2742
|
+
# headers must match the default encryption configuration of the
|
2743
|
+
# directory bucket.
|
2744
|
+
#
|
2745
|
+
# </note>
|
2746
|
+
#
|
2747
|
+
# <note markdown="1"> For directory buckets, when you perform a `CreateMultipartUpload`
|
2748
|
+
# operation and an `UploadPartCopy` operation, the request headers
|
2749
|
+
# you provide in the `CreateMultipartUpload` request must match the
|
2750
|
+
# default encryption configuration of the destination bucket.
|
2751
|
+
#
|
2752
|
+
# </note>
|
2642
2753
|
#
|
2643
2754
|
# HTTP Host header syntax
|
2644
2755
|
#
|
@@ -2649,13 +2760,13 @@ module Aws::S3
|
|
2649
2760
|
#
|
2650
2761
|
# * [UploadPart][1]
|
2651
2762
|
#
|
2652
|
-
# * [CompleteMultipartUpload][
|
2763
|
+
# * [CompleteMultipartUpload][15]
|
2653
2764
|
#
|
2654
|
-
# * [AbortMultipartUpload][
|
2765
|
+
# * [AbortMultipartUpload][16]
|
2655
2766
|
#
|
2656
|
-
# * [ListParts][
|
2767
|
+
# * [ListParts][17]
|
2657
2768
|
#
|
2658
|
-
# * [ListMultipartUploads][
|
2769
|
+
# * [ListMultipartUploads][18]
|
2659
2770
|
#
|
2660
2771
|
#
|
2661
2772
|
#
|
@@ -2670,10 +2781,13 @@ module Aws::S3
|
|
2670
2781
|
# [9]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html
|
2671
2782
|
# [10]: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingAWSSDK.html#specify-signature-version
|
2672
2783
|
# [11]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/ServerSideEncryptionCustomerKeys.html
|
2673
|
-
# [12]: https://docs.aws.amazon.com/AmazonS3/latest/
|
2674
|
-
# [13]: https://docs.aws.amazon.com/AmazonS3/latest/
|
2675
|
-
# [14]: https://docs.aws.amazon.com/AmazonS3/latest/API/
|
2676
|
-
# [15]: https://docs.aws.amazon.com/AmazonS3/latest/API/
|
2784
|
+
# [12]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-serv-side-encryption.html
|
2785
|
+
# [13]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-specifying-kms-encryption.html
|
2786
|
+
# [14]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html
|
2787
|
+
# [15]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CompleteMultipartUpload.html
|
2788
|
+
# [16]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_AbortMultipartUpload.html
|
2789
|
+
# [17]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListParts.html
|
2790
|
+
# [18]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListMultipartUploads.html
|
2677
2791
|
#
|
2678
2792
|
# @option params [String] :acl
|
2679
2793
|
# The canned ACL to apply to the object. Amazon S3 supports a set of
|
@@ -3036,10 +3150,52 @@ module Aws::S3
|
|
3036
3150
|
# The server-side encryption algorithm used when you store this object
|
3037
3151
|
# in Amazon S3 (for example, `AES256`, `aws:kms`).
|
3038
3152
|
#
|
3039
|
-
# <
|
3040
|
-
#
|
3153
|
+
# * <b>Directory buckets </b> - For directory buckets, there are only
|
3154
|
+
# two supported options for server-side encryption: server-side
|
3155
|
+
# encryption with Amazon S3 managed keys (SSE-S3) (`AES256`) and
|
3156
|
+
# server-side encryption with KMS keys (SSE-KMS) (`aws:kms`). We
|
3157
|
+
# recommend that the bucket's default encryption uses the desired
|
3158
|
+
# encryption configuration and you don't override the bucket default
|
3159
|
+
# encryption in your `CreateSession` requests or `PUT` object
|
3160
|
+
# requests. Then, new objects are automatically encrypted with the
|
3161
|
+
# desired encryption settings. For more information, see [Protecting
|
3162
|
+
# data with server-side encryption][1] in the *Amazon S3 User Guide*.
|
3163
|
+
# For more information about the encryption overriding behaviors in
|
3164
|
+
# directory buckets, see [Specifying server-side encryption with KMS
|
3165
|
+
# for new object uploads][2].
|
3166
|
+
#
|
3167
|
+
# In the Zonal endpoint API calls (except [CopyObject][3] and
|
3168
|
+
# [UploadPartCopy][4]) using the REST API, the encryption request
|
3169
|
+
# headers must match the encryption settings that are specified in the
|
3170
|
+
# `CreateSession` request. You can't override the values of the
|
3171
|
+
# encryption settings (`x-amz-server-side-encryption`,
|
3172
|
+
# `x-amz-server-side-encryption-aws-kms-key-id`,
|
3173
|
+
# `x-amz-server-side-encryption-context`, and
|
3174
|
+
# `x-amz-server-side-encryption-bucket-key-enabled`) that are
|
3175
|
+
# specified in the `CreateSession` request. You don't need to
|
3176
|
+
# explicitly specify these encryption settings values in Zonal
|
3177
|
+
# endpoint API calls, and Amazon S3 will use the encryption settings
|
3178
|
+
# values from the `CreateSession` request to protect new objects in
|
3179
|
+
# the directory bucket.
|
3180
|
+
#
|
3181
|
+
# <note markdown="1"> When you use the CLI or the Amazon Web Services SDKs, for
|
3182
|
+
# `CreateSession`, the session token refreshes automatically to avoid
|
3183
|
+
# service interruptions when a session expires. The CLI or the Amazon
|
3184
|
+
# Web Services SDKs use the bucket's default encryption configuration
|
3185
|
+
# for the `CreateSession` request. It's not supported to override the
|
3186
|
+
# encryption settings values in the `CreateSession` request. So in the
|
3187
|
+
# Zonal endpoint API calls (except [CopyObject][3] and
|
3188
|
+
# [UploadPartCopy][4]), the encryption request headers must match the
|
3189
|
+
# default encryption configuration of the directory bucket.
|
3041
3190
|
#
|
3042
|
-
#
|
3191
|
+
# </note>
|
3192
|
+
#
|
3193
|
+
#
|
3194
|
+
#
|
3195
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-serv-side-encryption.html
|
3196
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-specifying-kms-encryption.html
|
3197
|
+
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html
|
3198
|
+
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html
|
3043
3199
|
#
|
3044
3200
|
# @option params [String] :storage_class
|
3045
3201
|
# By default, Amazon S3 uses the STANDARD Storage Class to store newly
|
@@ -3098,34 +3254,71 @@ module Aws::S3
|
|
3098
3254
|
# </note>
|
3099
3255
|
#
|
3100
3256
|
# @option params [String] :ssekms_key_id
|
3101
|
-
# Specifies the ID (Key ID, Key ARN, or Key Alias)
|
3102
|
-
# encryption
|
3103
|
-
#
|
3104
|
-
#
|
3105
|
-
#
|
3106
|
-
#
|
3257
|
+
# Specifies the KMS key ID (Key ID, Key ARN, or Key Alias) to use for
|
3258
|
+
# object encryption. If the KMS key doesn't exist in the same account
|
3259
|
+
# that's issuing the command, you must use the full Key ARN not the Key
|
3260
|
+
# ID.
|
3261
|
+
#
|
3262
|
+
# **General purpose buckets** - If you specify
|
3263
|
+
# `x-amz-server-side-encryption` with `aws:kms` or `aws:kms:dsse`, this
|
3264
|
+
# header specifies the ID (Key ID, Key ARN, or Key Alias) of the KMS key
|
3265
|
+
# to use. If you specify `x-amz-server-side-encryption:aws:kms` or
|
3266
|
+
# `x-amz-server-side-encryption:aws:kms:dsse`, but do not provide
|
3267
|
+
# `x-amz-server-side-encryption-aws-kms-key-id`, Amazon S3 uses the
|
3268
|
+
# Amazon Web Services managed key (`aws/s3`) to protect the data.
|
3269
|
+
#
|
3270
|
+
# **Directory buckets** - If you specify `x-amz-server-side-encryption`
|
3271
|
+
# with `aws:kms`, you must specify the `
|
3272
|
+
# x-amz-server-side-encryption-aws-kms-key-id` header with the ID (Key
|
3273
|
+
# ID or Key ARN) of the KMS symmetric encryption customer managed key to
|
3274
|
+
# use. Otherwise, you get an HTTP `400 Bad Request` error. Only use the
|
3275
|
+
# key ID or key ARN. The key alias format of the KMS key isn't
|
3276
|
+
# supported. Your SSE-KMS configuration can only support 1 [customer
|
3277
|
+
# managed key][1] per directory bucket for the lifetime of the bucket.
|
3278
|
+
# [Amazon Web Services managed key][2] (`aws/s3`) isn't supported.
|
3279
|
+
#
|
3280
|
+
#
|
3281
|
+
#
|
3282
|
+
# [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk
|
3283
|
+
# [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk
|
3107
3284
|
#
|
3108
3285
|
# @option params [String] :ssekms_encryption_context
|
3109
3286
|
# Specifies the Amazon Web Services KMS Encryption Context to use for
|
3110
|
-
# object encryption. The value of this header is a
|
3111
|
-
#
|
3287
|
+
# object encryption. The value of this header is a Base64-encoded string
|
3288
|
+
# of a UTF-8 encoded JSON, which contains the encryption context as
|
3289
|
+
# key-value pairs.
|
3112
3290
|
#
|
3113
|
-
#
|
3114
|
-
#
|
3115
|
-
#
|
3291
|
+
# **Directory buckets** - You can optionally provide an explicit
|
3292
|
+
# encryption context value. The value must match the default encryption
|
3293
|
+
# context - the bucket Amazon Resource Name (ARN). An additional
|
3294
|
+
# encryption context value is not supported.
|
3116
3295
|
#
|
3117
3296
|
# @option params [Boolean] :bucket_key_enabled
|
3118
3297
|
# Specifies whether Amazon S3 should use an S3 Bucket Key for object
|
3119
3298
|
# encryption with server-side encryption using Key Management Service
|
3120
|
-
# (KMS) keys (SSE-KMS).
|
3121
|
-
# to use an S3 Bucket Key for object encryption with SSE-KMS.
|
3299
|
+
# (KMS) keys (SSE-KMS).
|
3122
3300
|
#
|
3123
|
-
#
|
3301
|
+
# **General purpose buckets** - Setting this header to `true` causes
|
3302
|
+
# Amazon S3 to use an S3 Bucket Key for object encryption with SSE-KMS.
|
3303
|
+
# Also, specifying this header with a PUT action doesn't affect
|
3124
3304
|
# bucket-level settings for S3 Bucket Key.
|
3125
3305
|
#
|
3126
|
-
#
|
3306
|
+
# **Directory buckets** - S3 Bucket Keys are always enabled for `GET`
|
3307
|
+
# and `PUT` operations in a directory bucket and can’t be disabled. S3
|
3308
|
+
# Bucket Keys aren't supported, when you copy SSE-KMS encrypted objects
|
3309
|
+
# from general purpose buckets to directory buckets, from directory
|
3310
|
+
# buckets to general purpose buckets, or between directory buckets,
|
3311
|
+
# through [CopyObject][1], [UploadPartCopy][2], [the Copy operation in
|
3312
|
+
# Batch Operations][3], or [the import jobs][4]. In this case, Amazon S3
|
3313
|
+
# makes a call to KMS every time a copy request is made for a
|
3314
|
+
# KMS-encrypted object.
|
3127
3315
|
#
|
3128
|
-
#
|
3316
|
+
#
|
3317
|
+
#
|
3318
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html
|
3319
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html
|
3320
|
+
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-objects-Batch-Ops
|
3321
|
+
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/create-import-job
|
3129
3322
|
#
|
3130
3323
|
# @option params [String] :request_payer
|
3131
3324
|
# Confirms that the requester knows that they will be charged for the
|
@@ -3286,9 +3479,10 @@ module Aws::S3
|
|
3286
3479
|
|
3287
3480
|
# Creates a session that establishes temporary security credentials to
|
3288
3481
|
# support fast authentication and authorization for the Zonal endpoint
|
3289
|
-
#
|
3290
|
-
#
|
3291
|
-
# [S3 Express One Zone APIs][1] in the *Amazon S3
|
3482
|
+
# API operations on directory buckets. For more information about Zonal
|
3483
|
+
# endpoint API operations that include the Availability Zone in the
|
3484
|
+
# request endpoint, see [S3 Express One Zone APIs][1] in the *Amazon S3
|
3485
|
+
# User Guide*.
|
3292
3486
|
#
|
3293
3487
|
# To make Zonal endpoint API requests on a directory bucket, use the
|
3294
3488
|
# `CreateSession` API operation. Specifically, you grant
|
@@ -3297,13 +3491,13 @@ module Aws::S3
|
|
3297
3491
|
# the `CreateSession` API request on the bucket, which returns temporary
|
3298
3492
|
# security credentials that include the access key ID, secret access
|
3299
3493
|
# key, session token, and expiration. These credentials have associated
|
3300
|
-
# permissions to access the Zonal endpoint
|
3301
|
-
# created, you don’t need to use other policies to grant
|
3302
|
-
# each Zonal endpoint API individually. Instead, in your
|
3303
|
-
# API requests, you sign your requests by applying the
|
3304
|
-
# security credentials of the session to the request headers
|
3305
|
-
# following the SigV4 protocol for authentication. You also apply
|
3306
|
-
# session token to the `x-amz-s3session-token` request header for
|
3494
|
+
# permissions to access the Zonal endpoint API operations. After the
|
3495
|
+
# session is created, you don’t need to use other policies to grant
|
3496
|
+
# permissions to each Zonal endpoint API individually. Instead, in your
|
3497
|
+
# Zonal endpoint API requests, you sign your requests by applying the
|
3498
|
+
# temporary security credentials of the session to the request headers
|
3499
|
+
# and following the SigV4 protocol for authentication. You also apply
|
3500
|
+
# the session token to the `x-amz-s3session-token` request header for
|
3307
3501
|
# authorization. Temporary security credentials are scoped to the bucket
|
3308
3502
|
# and expire after 5 minutes. After the expiration time, any calls that
|
3309
3503
|
# you make with those credentials will fail. You must use IAM
|
@@ -3326,16 +3520,16 @@ module Aws::S3
|
|
3326
3520
|
# [Regional and Zonal endpoints][3] in the *Amazon S3 User Guide*.
|
3327
3521
|
#
|
3328
3522
|
# * <b> <code>CopyObject</code> API operation</b> - Unlike other Zonal
|
3329
|
-
# endpoint
|
3330
|
-
# temporary security credentials returned from the `CreateSession`
|
3331
|
-
# operation for authentication and authorization. For information
|
3523
|
+
# endpoint API operations, the `CopyObject` API operation doesn't use
|
3524
|
+
# the temporary security credentials returned from the `CreateSession`
|
3525
|
+
# API operation for authentication and authorization. For information
|
3332
3526
|
# about authentication and authorization of the `CopyObject` API
|
3333
3527
|
# operation on directory buckets, see [CopyObject][4].
|
3334
3528
|
#
|
3335
3529
|
# * <b> <code>HeadBucket</code> API operation</b> - Unlike other Zonal
|
3336
|
-
# endpoint
|
3337
|
-
# temporary security credentials returned from the `CreateSession`
|
3338
|
-
# operation for authentication and authorization. For information
|
3530
|
+
# endpoint API operations, the `HeadBucket` API operation doesn't use
|
3531
|
+
# the temporary security credentials returned from the `CreateSession`
|
3532
|
+
# API operation for authentication and authorization. For information
|
3339
3533
|
# about authentication and authorization of the `HeadBucket` API
|
3340
3534
|
# operation on directory buckets, see [HeadBucket][5].
|
3341
3535
|
#
|
@@ -3354,9 +3548,71 @@ module Aws::S3
|
|
3354
3548
|
# Identity and Access Management (IAM) identity-based policies for S3
|
3355
3549
|
# Express One Zone][8] in the *Amazon S3 User Guide*.
|
3356
3550
|
#
|
3357
|
-
# To grant cross-account access to Zonal endpoint
|
3358
|
-
# policy should also grant both accounts the
|
3359
|
-
# permission.
|
3551
|
+
# To grant cross-account access to Zonal endpoint API operations, the
|
3552
|
+
# bucket policy should also grant both accounts the
|
3553
|
+
# `s3express:CreateSession` permission.
|
3554
|
+
#
|
3555
|
+
# If you want to encrypt objects with SSE-KMS, you must also have the
|
3556
|
+
# `kms:GenerateDataKey` and the `kms:Decrypt` permissions in IAM
|
3557
|
+
# identity-based policies and KMS key policies for the target KMS key.
|
3558
|
+
#
|
3559
|
+
# Encryption
|
3560
|
+
#
|
3561
|
+
# : For directory buckets, there are only two supported options for
|
3562
|
+
# server-side encryption: server-side encryption with Amazon S3
|
3563
|
+
# managed keys (SSE-S3) (`AES256`) and server-side encryption with KMS
|
3564
|
+
# keys (SSE-KMS) (`aws:kms`). We recommend that the bucket's default
|
3565
|
+
# encryption uses the desired encryption configuration and you don't
|
3566
|
+
# override the bucket default encryption in your `CreateSession`
|
3567
|
+
# requests or `PUT` object requests. Then, new objects are
|
3568
|
+
# automatically encrypted with the desired encryption settings. For
|
3569
|
+
# more information, see [Protecting data with server-side
|
3570
|
+
# encryption][9] in the *Amazon S3 User Guide*. For more information
|
3571
|
+
# about the encryption overriding behaviors in directory buckets, see
|
3572
|
+
# [Specifying server-side encryption with KMS for new object
|
3573
|
+
# uploads][10].
|
3574
|
+
#
|
3575
|
+
# For [Zonal endpoint (object-level) API operations][11] except
|
3576
|
+
# [CopyObject][4] and [UploadPartCopy][12], you authenticate and
|
3577
|
+
# authorize requests through [CreateSession][13] for low latency. To
|
3578
|
+
# encrypt new objects in a directory bucket with SSE-KMS, you must
|
3579
|
+
# specify SSE-KMS as the directory bucket's default encryption
|
3580
|
+
# configuration with a KMS key (specifically, a [customer managed
|
3581
|
+
# key][14]). Then, when a session is created for Zonal endpoint API
|
3582
|
+
# operations, new objects are automatically encrypted and decrypted
|
3583
|
+
# with SSE-KMS and S3 Bucket Keys during the session.
|
3584
|
+
#
|
3585
|
+
# <note markdown="1"> Only 1 [customer managed key][14] is supported per directory bucket
|
3586
|
+
# for the lifetime of the bucket. [Amazon Web Services managed
|
3587
|
+
# key][15] (`aws/s3`) isn't supported. After you specify SSE-KMS as
|
3588
|
+
# your bucket's default encryption configuration with a customer
|
3589
|
+
# managed key, you can't change the customer managed key for the
|
3590
|
+
# bucket's SSE-KMS configuration.
|
3591
|
+
#
|
3592
|
+
# </note>
|
3593
|
+
#
|
3594
|
+
# In the Zonal endpoint API calls (except [CopyObject][4] and
|
3595
|
+
# [UploadPartCopy][12]) using the REST API, you can't override the
|
3596
|
+
# values of the encryption settings (`x-amz-server-side-encryption`,
|
3597
|
+
# `x-amz-server-side-encryption-aws-kms-key-id`,
|
3598
|
+
# `x-amz-server-side-encryption-context`, and
|
3599
|
+
# `x-amz-server-side-encryption-bucket-key-enabled`) from the
|
3600
|
+
# `CreateSession` request. You don't need to explicitly specify these
|
3601
|
+
# encryption settings values in Zonal endpoint API calls, and Amazon
|
3602
|
+
# S3 will use the encryption settings values from the `CreateSession`
|
3603
|
+
# request to protect new objects in the directory bucket.
|
3604
|
+
#
|
3605
|
+
# <note markdown="1"> When you use the CLI or the Amazon Web Services SDKs, for
|
3606
|
+
# `CreateSession`, the session token refreshes automatically to avoid
|
3607
|
+
# service interruptions when a session expires. The CLI or the Amazon
|
3608
|
+
# Web Services SDKs use the bucket's default encryption configuration
|
3609
|
+
# for the `CreateSession` request. It's not supported to override the
|
3610
|
+
# encryption settings values in the `CreateSession` request. Also, in
|
3611
|
+
# the Zonal endpoint API calls (except [CopyObject][4] and
|
3612
|
+
# [UploadPartCopy][12]), it's not supported to override the values of
|
3613
|
+
# the encryption settings from the `CreateSession` request.
|
3614
|
+
#
|
3615
|
+
# </note>
|
3360
3616
|
#
|
3361
3617
|
# HTTP Host header syntax
|
3362
3618
|
#
|
@@ -3373,21 +3629,110 @@ module Aws::S3
|
|
3373
3629
|
# [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html#API_CreateSession_RequestParameters
|
3374
3630
|
# [7]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam-example-bucket-policies.html
|
3375
3631
|
# [8]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam-identity-policies.html
|
3632
|
+
# [9]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-serv-side-encryption.html
|
3633
|
+
# [10]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-specifying-kms-encryption.html
|
3634
|
+
# [11]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-differences.html#s3-express-differences-api-operations
|
3635
|
+
# [12]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html
|
3636
|
+
# [13]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html
|
3637
|
+
# [14]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk
|
3638
|
+
# [15]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk
|
3376
3639
|
#
|
3377
3640
|
# @option params [String] :session_mode
|
3378
3641
|
# Specifies the mode of the session that will be created, either
|
3379
3642
|
# `ReadWrite` or `ReadOnly`. By default, a `ReadWrite` session is
|
3380
3643
|
# created. A `ReadWrite` session is capable of executing all the Zonal
|
3381
|
-
# endpoint
|
3382
|
-
# constrained to execute the following Zonal endpoint
|
3383
|
-
# `HeadObject`, `ListObjectsV2`, `GetObjectAttributes`,
|
3384
|
-
# `ListMultipartUploads`.
|
3644
|
+
# endpoint API operations on a directory bucket. A `ReadOnly` session is
|
3645
|
+
# constrained to execute the following Zonal endpoint API operations:
|
3646
|
+
# `GetObject`, `HeadObject`, `ListObjectsV2`, `GetObjectAttributes`,
|
3647
|
+
# `ListParts`, and `ListMultipartUploads`.
|
3385
3648
|
#
|
3386
3649
|
# @option params [required, String] :bucket
|
3387
3650
|
# The name of the bucket that you create a session for.
|
3388
3651
|
#
|
3652
|
+
# @option params [String] :server_side_encryption
|
3653
|
+
# The server-side encryption algorithm to use when you store objects in
|
3654
|
+
# the directory bucket.
|
3655
|
+
#
|
3656
|
+
# For directory buckets, there are only two supported options for
|
3657
|
+
# server-side encryption: server-side encryption with Amazon S3 managed
|
3658
|
+
# keys (SSE-S3) (`AES256`) and server-side encryption with KMS keys
|
3659
|
+
# (SSE-KMS) (`aws:kms`). By default, Amazon S3 encrypts data with
|
3660
|
+
# SSE-S3. For more information, see [Protecting data with server-side
|
3661
|
+
# encryption][1] in the *Amazon S3 User Guide*.
|
3662
|
+
#
|
3663
|
+
#
|
3664
|
+
#
|
3665
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-serv-side-encryption.html
|
3666
|
+
#
|
3667
|
+
# @option params [String] :ssekms_key_id
|
3668
|
+
# If you specify `x-amz-server-side-encryption` with `aws:kms`, you must
|
3669
|
+
# specify the ` x-amz-server-side-encryption-aws-kms-key-id` header with
|
3670
|
+
# the ID (Key ID or Key ARN) of the KMS symmetric encryption customer
|
3671
|
+
# managed key to use. Otherwise, you get an HTTP `400 Bad Request`
|
3672
|
+
# error. Only use the key ID or key ARN. The key alias format of the KMS
|
3673
|
+
# key isn't supported. Also, if the KMS key doesn't exist in the same
|
3674
|
+
# account that't issuing the command, you must use the full Key ARN not
|
3675
|
+
# the Key ID.
|
3676
|
+
#
|
3677
|
+
# Your SSE-KMS configuration can only support 1 [customer managed
|
3678
|
+
# key][1] per directory bucket for the lifetime of the bucket. [Amazon
|
3679
|
+
# Web Services managed key][2] (`aws/s3`) isn't supported.
|
3680
|
+
#
|
3681
|
+
#
|
3682
|
+
#
|
3683
|
+
# [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk
|
3684
|
+
# [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk
|
3685
|
+
#
|
3686
|
+
# @option params [String] :ssekms_encryption_context
|
3687
|
+
# Specifies the Amazon Web Services KMS Encryption Context as an
|
3688
|
+
# additional encryption context to use for object encryption. The value
|
3689
|
+
# of this header is a Base64-encoded string of a UTF-8 encoded JSON,
|
3690
|
+
# which contains the encryption context as key-value pairs. This value
|
3691
|
+
# is stored as object metadata and automatically gets passed on to
|
3692
|
+
# Amazon Web Services KMS for future `GetObject` operations on this
|
3693
|
+
# object.
|
3694
|
+
#
|
3695
|
+
# **General purpose buckets** - This value must be explicitly added
|
3696
|
+
# during `CopyObject` operations if you want an additional encryption
|
3697
|
+
# context for your object. For more information, see [Encryption
|
3698
|
+
# context][1] in the *Amazon S3 User Guide*.
|
3699
|
+
#
|
3700
|
+
# **Directory buckets** - You can optionally provide an explicit
|
3701
|
+
# encryption context value. The value must match the default encryption
|
3702
|
+
# context - the bucket Amazon Resource Name (ARN). An additional
|
3703
|
+
# encryption context value is not supported.
|
3704
|
+
#
|
3705
|
+
#
|
3706
|
+
#
|
3707
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/UsingKMSEncryption.html#encryption-context
|
3708
|
+
#
|
3709
|
+
# @option params [Boolean] :bucket_key_enabled
|
3710
|
+
# Specifies whether Amazon S3 should use an S3 Bucket Key for object
|
3711
|
+
# encryption with server-side encryption using KMS keys (SSE-KMS).
|
3712
|
+
#
|
3713
|
+
# S3 Bucket Keys are always enabled for `GET` and `PUT` operations in a
|
3714
|
+
# directory bucket and can’t be disabled. S3 Bucket Keys aren't
|
3715
|
+
# supported, when you copy SSE-KMS encrypted objects from general
|
3716
|
+
# purpose buckets to directory buckets, from directory buckets to
|
3717
|
+
# general purpose buckets, or between directory buckets, through
|
3718
|
+
# [CopyObject][1], [UploadPartCopy][2], [the Copy operation in Batch
|
3719
|
+
# Operations][3], or [the import jobs][4]. In this case, Amazon S3 makes
|
3720
|
+
# a call to KMS every time a copy request is made for a KMS-encrypted
|
3721
|
+
# object.
|
3722
|
+
#
|
3723
|
+
#
|
3724
|
+
#
|
3725
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html
|
3726
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html
|
3727
|
+
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-objects-Batch-Ops
|
3728
|
+
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/create-import-job
|
3729
|
+
#
|
3389
3730
|
# @return [Types::CreateSessionOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
3390
3731
|
#
|
3732
|
+
# * {Types::CreateSessionOutput#server_side_encryption #server_side_encryption} => String
|
3733
|
+
# * {Types::CreateSessionOutput#ssekms_key_id #ssekms_key_id} => String
|
3734
|
+
# * {Types::CreateSessionOutput#ssekms_encryption_context #ssekms_encryption_context} => String
|
3735
|
+
# * {Types::CreateSessionOutput#bucket_key_enabled #bucket_key_enabled} => Boolean
|
3391
3736
|
# * {Types::CreateSessionOutput#credentials #credentials} => Types::SessionCredentials
|
3392
3737
|
#
|
3393
3738
|
# @example Request syntax with placeholder values
|
@@ -3395,10 +3740,18 @@ module Aws::S3
|
|
3395
3740
|
# resp = client.create_session({
|
3396
3741
|
# session_mode: "ReadOnly", # accepts ReadOnly, ReadWrite
|
3397
3742
|
# bucket: "BucketName", # required
|
3743
|
+
# server_side_encryption: "AES256", # accepts AES256, aws:kms, aws:kms:dsse
|
3744
|
+
# ssekms_key_id: "SSEKMSKeyId",
|
3745
|
+
# ssekms_encryption_context: "SSEKMSEncryptionContext",
|
3746
|
+
# bucket_key_enabled: false,
|
3398
3747
|
# })
|
3399
3748
|
#
|
3400
3749
|
# @example Response structure
|
3401
3750
|
#
|
3751
|
+
# resp.server_side_encryption #=> String, one of "AES256", "aws:kms", "aws:kms:dsse"
|
3752
|
+
# resp.ssekms_key_id #=> String
|
3753
|
+
# resp.ssekms_encryption_context #=> String
|
3754
|
+
# resp.bucket_key_enabled #=> Boolean
|
3402
3755
|
# resp.credentials.access_key_id #=> String
|
3403
3756
|
# resp.credentials.secret_access_key #=> String
|
3404
3757
|
# resp.credentials.session_token #=> String
|
@@ -3644,47 +3997,92 @@ module Aws::S3
|
|
3644
3997
|
req.send_request(options)
|
3645
3998
|
end
|
3646
3999
|
|
3647
|
-
#
|
4000
|
+
# This implementation of the DELETE action resets the default encryption
|
4001
|
+
# for the bucket as server-side encryption with Amazon S3 managed keys
|
4002
|
+
# (SSE-S3).
|
4003
|
+
#
|
4004
|
+
# <note markdown="1"> * **General purpose buckets** - For information about the bucket
|
4005
|
+
# default encryption feature, see [Amazon S3 Bucket Default
|
4006
|
+
# Encryption][1] in the *Amazon S3 User Guide*.
|
4007
|
+
#
|
4008
|
+
# * **Directory buckets** - For directory buckets, there are only two
|
4009
|
+
# supported options for server-side encryption: SSE-S3 and SSE-KMS.
|
4010
|
+
# For information about the default encryption configuration in
|
4011
|
+
# directory buckets, see [Setting default server-side encryption
|
4012
|
+
# behavior for directory buckets][2].
|
3648
4013
|
#
|
3649
4014
|
# </note>
|
3650
4015
|
#
|
3651
|
-
#
|
3652
|
-
#
|
3653
|
-
#
|
3654
|
-
#
|
3655
|
-
#
|
4016
|
+
# Permissions
|
4017
|
+
# : * **General purpose bucket permissions** - The
|
4018
|
+
# `s3:PutEncryptionConfiguration` permission is required in a
|
4019
|
+
# policy. The bucket owner has this permission by default. The
|
4020
|
+
# bucket owner can grant this permission to others. For more
|
4021
|
+
# information about permissions, see [Permissions Related to Bucket
|
4022
|
+
# Operations][3] and [Managing Access Permissions to Your Amazon S3
|
4023
|
+
# Resources][4].
|
3656
4024
|
#
|
3657
|
-
#
|
3658
|
-
#
|
3659
|
-
# permission
|
3660
|
-
#
|
3661
|
-
#
|
3662
|
-
#
|
3663
|
-
#
|
4025
|
+
# * **Directory bucket permissions** - To grant access to this API
|
4026
|
+
# operation, you must have the
|
4027
|
+
# `s3express:PutEncryptionConfiguration` permission in an IAM
|
4028
|
+
# identity-based policy instead of a bucket policy. Cross-account
|
4029
|
+
# access to this API operation isn't supported. This operation can
|
4030
|
+
# only be performed by the Amazon Web Services account that owns the
|
4031
|
+
# resource. For more information about directory bucket policies and
|
4032
|
+
# permissions, see [Amazon Web Services Identity and Access
|
4033
|
+
# Management (IAM) for S3 Express One Zone][5] in the *Amazon S3
|
4034
|
+
# User Guide*.
|
4035
|
+
#
|
4036
|
+
# HTTP Host header syntax
|
4037
|
+
#
|
4038
|
+
# : <b>Directory buckets </b> - The HTTP Host header syntax is
|
4039
|
+
# `s3express-control.region.amazonaws.com`.
|
3664
4040
|
#
|
3665
4041
|
# The following operations are related to `DeleteBucketEncryption`:
|
3666
4042
|
#
|
3667
|
-
# * [PutBucketEncryption][
|
4043
|
+
# * [PutBucketEncryption][6]
|
3668
4044
|
#
|
3669
|
-
# * [GetBucketEncryption][
|
4045
|
+
# * [GetBucketEncryption][7]
|
3670
4046
|
#
|
3671
4047
|
#
|
3672
4048
|
#
|
3673
4049
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/bucket-encryption.html
|
3674
|
-
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/
|
3675
|
-
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-
|
3676
|
-
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/
|
3677
|
-
# [5]: https://docs.aws.amazon.com/AmazonS3/latest/
|
4050
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-bucket-encryption.html
|
4051
|
+
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources
|
4052
|
+
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html
|
4053
|
+
# [5]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam.html
|
4054
|
+
# [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketEncryption.html
|
4055
|
+
# [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketEncryption.html
|
3678
4056
|
#
|
3679
4057
|
# @option params [required, String] :bucket
|
3680
4058
|
# The name of the bucket containing the server-side encryption
|
3681
4059
|
# configuration to delete.
|
3682
4060
|
#
|
4061
|
+
# <b>Directory buckets </b> - When you use this operation with a
|
4062
|
+
# directory bucket, you must use path-style requests in the format
|
4063
|
+
# `https://s3express-control.region_code.amazonaws.com/bucket-name `.
|
4064
|
+
# Virtual-hosted-style requests aren't supported. Directory bucket
|
4065
|
+
# names must be unique in the chosen Availability Zone. Bucket names
|
4066
|
+
# must also follow the format ` bucket_base_name--az_id--x-s3` (for
|
4067
|
+
# example, ` DOC-EXAMPLE-BUCKET--usw2-az1--x-s3`). For information about
|
4068
|
+
# bucket naming restrictions, see [Directory bucket naming rules][1] in
|
4069
|
+
# the *Amazon S3 User Guide*
|
4070
|
+
#
|
4071
|
+
#
|
4072
|
+
#
|
4073
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-bucket-naming-rules.html
|
4074
|
+
#
|
3683
4075
|
# @option params [String] :expected_bucket_owner
|
3684
4076
|
# The account ID of the expected bucket owner. If the account ID that
|
3685
4077
|
# you provide does not match the actual owner of the bucket, the request
|
3686
4078
|
# fails with the HTTP status code `403 Forbidden` (access denied).
|
3687
4079
|
#
|
4080
|
+
# <note markdown="1"> For directory buckets, this header is not supported in this API
|
4081
|
+
# operation. If you specify this header, the request fails with the HTTP
|
4082
|
+
# status code `501 Not Implemented`.
|
4083
|
+
#
|
4084
|
+
# </note>
|
4085
|
+
#
|
3688
4086
|
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
3689
4087
|
#
|
3690
4088
|
# @example Request syntax with placeholder values
|
@@ -4678,35 +5076,35 @@ module Aws::S3
|
|
4678
5076
|
# * {Types::DeleteObjectTaggingOutput#version_id #version_id} => String
|
4679
5077
|
#
|
4680
5078
|
#
|
4681
|
-
# @example Example: To remove tag set from an object
|
5079
|
+
# @example Example: To remove tag set from an object
|
4682
5080
|
#
|
4683
|
-
# # The following example removes tag set associated with the specified object
|
4684
|
-
# #
|
5081
|
+
# # The following example removes tag set associated with the specified object. If the bucket is versioning enabled, the
|
5082
|
+
# # operation removes tag set from the latest object version.
|
4685
5083
|
#
|
4686
5084
|
# resp = client.delete_object_tagging({
|
4687
5085
|
# bucket: "examplebucket",
|
4688
5086
|
# key: "HappyFace.jpg",
|
4689
|
-
# version_id: "ydlaNkwWm0SfKJR.T1b1fIdPRbldTYRI",
|
4690
5087
|
# })
|
4691
5088
|
#
|
4692
5089
|
# resp.to_h outputs the following:
|
4693
5090
|
# {
|
4694
|
-
# version_id: "
|
5091
|
+
# version_id: "null",
|
4695
5092
|
# }
|
4696
5093
|
#
|
4697
|
-
# @example Example: To remove tag set from an object
|
5094
|
+
# @example Example: To remove tag set from an object version
|
4698
5095
|
#
|
4699
|
-
# # The following example removes tag set associated with the specified object.
|
4700
|
-
# #
|
5096
|
+
# # The following example removes tag set associated with the specified object version. The request specifies both the
|
5097
|
+
# # object key and object version.
|
4701
5098
|
#
|
4702
5099
|
# resp = client.delete_object_tagging({
|
4703
5100
|
# bucket: "examplebucket",
|
4704
5101
|
# key: "HappyFace.jpg",
|
5102
|
+
# version_id: "ydlaNkwWm0SfKJR.T1b1fIdPRbldTYRI",
|
4705
5103
|
# })
|
4706
5104
|
#
|
4707
5105
|
# resp.to_h outputs the following:
|
4708
5106
|
# {
|
4709
|
-
# version_id: "
|
5107
|
+
# version_id: "ydlaNkwWm0SfKJR.T1b1fIdPRbldTYRI",
|
4710
5108
|
# }
|
4711
5109
|
#
|
4712
5110
|
# @example Request syntax with placeholder values
|
@@ -4989,20 +5387,22 @@ module Aws::S3
|
|
4989
5387
|
# * {Types::DeleteObjectsOutput#errors #errors} => Array<Types::Error>
|
4990
5388
|
#
|
4991
5389
|
#
|
4992
|
-
# @example Example: To delete multiple
|
5390
|
+
# @example Example: To delete multiple object versions from a versioned bucket
|
4993
5391
|
#
|
4994
|
-
# # The following example deletes objects from a bucket. The
|
4995
|
-
# #
|
5392
|
+
# # The following example deletes objects from a bucket. The request specifies object versions. S3 deletes specific object
|
5393
|
+
# # versions and returns the key and versions of deleted objects in the response.
|
4996
5394
|
#
|
4997
5395
|
# resp = client.delete_objects({
|
4998
5396
|
# bucket: "examplebucket",
|
4999
5397
|
# delete: {
|
5000
5398
|
# objects: [
|
5001
5399
|
# {
|
5002
|
-
# key: "
|
5400
|
+
# key: "HappyFace.jpg",
|
5401
|
+
# version_id: "2LWg7lQLnY41.maGB5Z6SWW.dcq0vx7b",
|
5003
5402
|
# },
|
5004
5403
|
# {
|
5005
|
-
# key: "
|
5404
|
+
# key: "HappyFace.jpg",
|
5405
|
+
# version_id: "yoz3HB.ZhCS_tKVEmIOr7qYyyAaZSKVd",
|
5006
5406
|
# },
|
5007
5407
|
# ],
|
5008
5408
|
# quiet: false,
|
@@ -5013,34 +5413,30 @@ module Aws::S3
|
|
5013
5413
|
# {
|
5014
5414
|
# deleted: [
|
5015
5415
|
# {
|
5016
|
-
#
|
5017
|
-
#
|
5018
|
-
# key: "objectkey1",
|
5416
|
+
# key: "HappyFace.jpg",
|
5417
|
+
# version_id: "yoz3HB.ZhCS_tKVEmIOr7qYyyAaZSKVd",
|
5019
5418
|
# },
|
5020
5419
|
# {
|
5021
|
-
#
|
5022
|
-
#
|
5023
|
-
# key: "objectkey2",
|
5420
|
+
# key: "HappyFace.jpg",
|
5421
|
+
# version_id: "2LWg7lQLnY41.maGB5Z6SWW.dcq0vx7b",
|
5024
5422
|
# },
|
5025
5423
|
# ],
|
5026
5424
|
# }
|
5027
5425
|
#
|
5028
|
-
# @example Example: To delete multiple
|
5426
|
+
# @example Example: To delete multiple objects from a versioned bucket
|
5029
5427
|
#
|
5030
|
-
# # The following example deletes objects from a bucket. The
|
5031
|
-
# #
|
5428
|
+
# # The following example deletes objects from a bucket. The bucket is versioned, and the request does not specify the
|
5429
|
+
# # object version to delete. In this case, all versions remain in the bucket and S3 adds a delete marker.
|
5032
5430
|
#
|
5033
5431
|
# resp = client.delete_objects({
|
5034
5432
|
# bucket: "examplebucket",
|
5035
5433
|
# delete: {
|
5036
5434
|
# objects: [
|
5037
5435
|
# {
|
5038
|
-
# key: "
|
5039
|
-
# version_id: "2LWg7lQLnY41.maGB5Z6SWW.dcq0vx7b",
|
5436
|
+
# key: "objectkey1",
|
5040
5437
|
# },
|
5041
5438
|
# {
|
5042
|
-
# key: "
|
5043
|
-
# version_id: "yoz3HB.ZhCS_tKVEmIOr7qYyyAaZSKVd",
|
5439
|
+
# key: "objectkey2",
|
5044
5440
|
# },
|
5045
5441
|
# ],
|
5046
5442
|
# quiet: false,
|
@@ -5051,12 +5447,14 @@ module Aws::S3
|
|
5051
5447
|
# {
|
5052
5448
|
# deleted: [
|
5053
5449
|
# {
|
5054
|
-
#
|
5055
|
-
#
|
5450
|
+
# delete_marker: true,
|
5451
|
+
# delete_marker_version_id: "A._w1z6EFiCF5uhtQMDal9JDkID9tQ7F",
|
5452
|
+
# key: "objectkey1",
|
5056
5453
|
# },
|
5057
5454
|
# {
|
5058
|
-
#
|
5059
|
-
#
|
5455
|
+
# delete_marker: true,
|
5456
|
+
# delete_marker_version_id: "iOd_ORxhkKe_e8G8_oSGxt2PjsCZKlkt",
|
5457
|
+
# key: "objectkey2",
|
5060
5458
|
# },
|
5061
5459
|
# ],
|
5062
5460
|
# }
|
@@ -5559,46 +5957,92 @@ module Aws::S3
|
|
5559
5957
|
req.send_request(options)
|
5560
5958
|
end
|
5561
5959
|
|
5562
|
-
#
|
5960
|
+
# Returns the default encryption configuration for an Amazon S3 bucket.
|
5961
|
+
# By default, all buckets have a default encryption configuration that
|
5962
|
+
# uses server-side encryption with Amazon S3 managed keys (SSE-S3).
|
5963
|
+
#
|
5964
|
+
# <note markdown="1"> * **General purpose buckets** - For information about the bucket
|
5965
|
+
# default encryption feature, see [Amazon S3 Bucket Default
|
5966
|
+
# Encryption][1] in the *Amazon S3 User Guide*.
|
5967
|
+
#
|
5968
|
+
# * **Directory buckets** - For directory buckets, there are only two
|
5969
|
+
# supported options for server-side encryption: SSE-S3 and SSE-KMS.
|
5970
|
+
# For information about the default encryption configuration in
|
5971
|
+
# directory buckets, see [Setting default server-side encryption
|
5972
|
+
# behavior for directory buckets][2].
|
5563
5973
|
#
|
5564
5974
|
# </note>
|
5565
5975
|
#
|
5566
|
-
#
|
5567
|
-
#
|
5568
|
-
#
|
5569
|
-
#
|
5570
|
-
#
|
5976
|
+
# Permissions
|
5977
|
+
# : * **General purpose bucket permissions** - The
|
5978
|
+
# `s3:GetEncryptionConfiguration` permission is required in a
|
5979
|
+
# policy. The bucket owner has this permission by default. The
|
5980
|
+
# bucket owner can grant this permission to others. For more
|
5981
|
+
# information about permissions, see [Permissions Related to Bucket
|
5982
|
+
# Operations][3] and [Managing Access Permissions to Your Amazon S3
|
5983
|
+
# Resources][4].
|
5571
5984
|
#
|
5572
|
-
#
|
5573
|
-
#
|
5574
|
-
# permission
|
5575
|
-
#
|
5576
|
-
#
|
5577
|
-
#
|
5985
|
+
# * **Directory bucket permissions** - To grant access to this API
|
5986
|
+
# operation, you must have the
|
5987
|
+
# `s3express:GetEncryptionConfiguration` permission in an IAM
|
5988
|
+
# identity-based policy instead of a bucket policy. Cross-account
|
5989
|
+
# access to this API operation isn't supported. This operation can
|
5990
|
+
# only be performed by the Amazon Web Services account that owns the
|
5991
|
+
# resource. For more information about directory bucket policies and
|
5992
|
+
# permissions, see [Amazon Web Services Identity and Access
|
5993
|
+
# Management (IAM) for S3 Express One Zone][5] in the *Amazon S3
|
5994
|
+
# User Guide*.
|
5995
|
+
#
|
5996
|
+
# HTTP Host header syntax
|
5997
|
+
#
|
5998
|
+
# : <b>Directory buckets </b> - The HTTP Host header syntax is
|
5999
|
+
# `s3express-control.region.amazonaws.com`.
|
5578
6000
|
#
|
5579
6001
|
# The following operations are related to `GetBucketEncryption`:
|
5580
6002
|
#
|
5581
|
-
# * [PutBucketEncryption][
|
6003
|
+
# * [PutBucketEncryption][6]
|
5582
6004
|
#
|
5583
|
-
# * [DeleteBucketEncryption][
|
6005
|
+
# * [DeleteBucketEncryption][7]
|
5584
6006
|
#
|
5585
6007
|
#
|
5586
6008
|
#
|
5587
6009
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/bucket-encryption.html
|
5588
|
-
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/
|
5589
|
-
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-
|
5590
|
-
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/
|
5591
|
-
# [5]: https://docs.aws.amazon.com/AmazonS3/latest/
|
6010
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-bucket-encryption.html
|
6011
|
+
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources
|
6012
|
+
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html
|
6013
|
+
# [5]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam.html
|
6014
|
+
# [6]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketEncryption.html
|
6015
|
+
# [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketEncryption.html
|
6016
|
+
#
|
6017
|
+
# @option params [required, String] :bucket
|
6018
|
+
# The name of the bucket from which the server-side encryption
|
6019
|
+
# configuration is retrieved.
|
6020
|
+
#
|
6021
|
+
# <b>Directory buckets </b> - When you use this operation with a
|
6022
|
+
# directory bucket, you must use path-style requests in the format
|
6023
|
+
# `https://s3express-control.region_code.amazonaws.com/bucket-name `.
|
6024
|
+
# Virtual-hosted-style requests aren't supported. Directory bucket
|
6025
|
+
# names must be unique in the chosen Availability Zone. Bucket names
|
6026
|
+
# must also follow the format ` bucket_base_name--az_id--x-s3` (for
|
6027
|
+
# example, ` DOC-EXAMPLE-BUCKET--usw2-az1--x-s3`). For information about
|
6028
|
+
# bucket naming restrictions, see [Directory bucket naming rules][1] in
|
6029
|
+
# the *Amazon S3 User Guide*
|
6030
|
+
#
|
5592
6031
|
#
|
5593
|
-
#
|
5594
|
-
#
|
5595
|
-
# configuration is retrieved.
|
6032
|
+
#
|
6033
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-bucket-naming-rules.html
|
5596
6034
|
#
|
5597
6035
|
# @option params [String] :expected_bucket_owner
|
5598
6036
|
# The account ID of the expected bucket owner. If the account ID that
|
5599
6037
|
# you provide does not match the actual owner of the bucket, the request
|
5600
6038
|
# fails with the HTTP status code `403 Forbidden` (access denied).
|
5601
6039
|
#
|
6040
|
+
# <note markdown="1"> For directory buckets, this header is not supported in this API
|
6041
|
+
# operation. If you specify this header, the request fails with the HTTP
|
6042
|
+
# status code `501 Not Implemented`.
|
6043
|
+
#
|
6044
|
+
# </note>
|
6045
|
+
#
|
5602
6046
|
# @return [Types::GetBucketEncryptionOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
5603
6047
|
#
|
5604
6048
|
# * {Types::GetBucketEncryptionOutput#server_side_encryption_configuration #server_side_encryption_configuration} => Types::ServerSideEncryptionConfiguration
|
@@ -7338,6 +7782,10 @@ module Aws::S3
|
|
7338
7782
|
# interruptions when a session expires. For more information about
|
7339
7783
|
# authorization, see [ `CreateSession` ][4].
|
7340
7784
|
#
|
7785
|
+
# If the object is encrypted using SSE-KMS, you must also have the
|
7786
|
+
# `kms:GenerateDataKey` and `kms:Decrypt` permissions in IAM
|
7787
|
+
# identity-based policies and KMS key policies for the KMS key.
|
7788
|
+
#
|
7341
7789
|
# Storage classes
|
7342
7790
|
#
|
7343
7791
|
# : If the object you are retrieving is stored in the S3 Glacier
|
@@ -7366,6 +7814,11 @@ module Aws::S3
|
|
7366
7814
|
# `GetObject` requests for the object that uses these types of keys,
|
7367
7815
|
# you’ll get an HTTP `400 Bad Request` error.
|
7368
7816
|
#
|
7817
|
+
# **Directory buckets** - For directory buckets, there are only two
|
7818
|
+
# supported options for server-side encryption: SSE-S3 and SSE-KMS.
|
7819
|
+
# SSE-C isn't supported. For more information, see [Protecting data
|
7820
|
+
# with server-side encryption][7] in the *Amazon S3 User Guide*.
|
7821
|
+
#
|
7369
7822
|
# Overriding response header values through the request
|
7370
7823
|
#
|
7371
7824
|
# : There are times when you want to override certain response header
|
@@ -7413,9 +7866,9 @@ module Aws::S3
|
|
7413
7866
|
#
|
7414
7867
|
# The following operations are related to `GetObject`:
|
7415
7868
|
#
|
7416
|
-
# * [ListBuckets][
|
7869
|
+
# * [ListBuckets][8]
|
7417
7870
|
#
|
7418
|
-
# * [GetObjectAcl][
|
7871
|
+
# * [GetObjectAcl][9]
|
7419
7872
|
#
|
7420
7873
|
#
|
7421
7874
|
#
|
@@ -7425,8 +7878,9 @@ module Aws::S3
|
|
7425
7878
|
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html
|
7426
7879
|
# [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_RestoreObject.html
|
7427
7880
|
# [6]: https://docs.aws.amazon.com/AmazonS3/latest/dev/restoring-objects.html
|
7428
|
-
# [7]: https://docs.aws.amazon.com/AmazonS3/latest/
|
7429
|
-
# [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/
|
7881
|
+
# [7]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-serv-side-encryption.html
|
7882
|
+
# [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListBuckets.html
|
7883
|
+
# [9]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectAcl.html
|
7430
7884
|
#
|
7431
7885
|
# @option params [String, IO] :response_target
|
7432
7886
|
# Where to write response data, file path, or IO object.
|
@@ -7723,10 +8177,10 @@ module Aws::S3
|
|
7723
8177
|
# @option params [String] :checksum_mode
|
7724
8178
|
# To retrieve the checksum, this mode must be enabled.
|
7725
8179
|
#
|
7726
|
-
# In addition, if you enable checksum mode
|
7727
|
-
# with a [checksum][1] and encrypted with an
|
7728
|
-
# (KMS) key, you must have permission to use the
|
7729
|
-
# retrieve the checksum.
|
8180
|
+
# **General purpose buckets** - In addition, if you enable checksum mode
|
8181
|
+
# and the object is uploaded with a [checksum][1] and encrypted with an
|
8182
|
+
# Key Management Service (KMS) key, you must have permission to use the
|
8183
|
+
# `kms:Decrypt` action to retrieve the checksum.
|
7730
8184
|
#
|
7731
8185
|
#
|
7732
8186
|
#
|
@@ -8128,7 +8582,7 @@ module Aws::S3
|
|
8128
8582
|
# Permissions
|
8129
8583
|
# : * **General purpose bucket permissions** - To use
|
8130
8584
|
# `GetObjectAttributes`, you must have READ access to the object.
|
8131
|
-
# The permissions that you need to use this operation
|
8585
|
+
# The permissions that you need to use this operation depend on
|
8132
8586
|
# whether the bucket is versioned. If the bucket is versioned, you
|
8133
8587
|
# need both the `s3:GetObjectVersion` and
|
8134
8588
|
# `s3:GetObjectVersionAttributes` permissions for this operation. If
|
@@ -8162,6 +8616,10 @@ module Aws::S3
|
|
8162
8616
|
# interruptions when a session expires. For more information about
|
8163
8617
|
# authorization, see [ `CreateSession` ][3].
|
8164
8618
|
#
|
8619
|
+
# If the object is encrypted with SSE-KMS, you must also have the
|
8620
|
+
# `kms:GenerateDataKey` and `kms:Decrypt` permissions in IAM
|
8621
|
+
# identity-based policies and KMS key policies for the KMS key.
|
8622
|
+
#
|
8165
8623
|
# Encryption
|
8166
8624
|
# : <note markdown="1"> Encryption request headers, like `x-amz-server-side-encryption`,
|
8167
8625
|
# should not be sent for `HEAD` requests if your object uses
|
@@ -8195,9 +8653,19 @@ module Aws::S3
|
|
8195
8653
|
# Customer-Provided Encryption Keys)][4] in the *Amazon S3 User
|
8196
8654
|
# Guide*.
|
8197
8655
|
#
|
8198
|
-
# <note markdown="1"> **Directory bucket permissions** - For directory buckets,
|
8199
|
-
#
|
8200
|
-
# (`AES256`)
|
8656
|
+
# <note markdown="1"> **Directory bucket permissions** - For directory buckets, there are
|
8657
|
+
# only two supported options for server-side encryption: server-side
|
8658
|
+
# encryption with Amazon S3 managed keys (SSE-S3) (`AES256`) and
|
8659
|
+
# server-side encryption with KMS keys (SSE-KMS) (`aws:kms`). We
|
8660
|
+
# recommend that the bucket's default encryption uses the desired
|
8661
|
+
# encryption configuration and you don't override the bucket default
|
8662
|
+
# encryption in your `CreateSession` requests or `PUT` object
|
8663
|
+
# requests. Then, new objects are automatically encrypted with the
|
8664
|
+
# desired encryption settings. For more information, see [Protecting
|
8665
|
+
# data with server-side encryption][5] in the *Amazon S3 User Guide*.
|
8666
|
+
# For more information about the encryption overriding behaviors in
|
8667
|
+
# directory buckets, see [Specifying server-side encryption with KMS
|
8668
|
+
# for new object uploads][6].
|
8201
8669
|
#
|
8202
8670
|
# </note>
|
8203
8671
|
#
|
@@ -8221,7 +8689,7 @@ module Aws::S3
|
|
8221
8689
|
# * `If-Unmodified-Since` condition evaluates to `false`.
|
8222
8690
|
#
|
8223
8691
|
# For more information about conditional requests, see [RFC
|
8224
|
-
# 7232][
|
8692
|
+
# 7232][7].
|
8225
8693
|
#
|
8226
8694
|
# * If both of the `If-None-Match` and `If-Modified-Since` headers are
|
8227
8695
|
# present in the request as follows, then Amazon S3 returns the HTTP
|
@@ -8232,7 +8700,7 @@ module Aws::S3
|
|
8232
8700
|
# * `If-Modified-Since` condition evaluates to `true`.
|
8233
8701
|
#
|
8234
8702
|
# For more information about conditional requests, see [RFC
|
8235
|
-
# 7232][
|
8703
|
+
# 7232][7].
|
8236
8704
|
#
|
8237
8705
|
# HTTP Host header syntax
|
8238
8706
|
#
|
@@ -8241,21 +8709,21 @@ module Aws::S3
|
|
8241
8709
|
#
|
8242
8710
|
# The following actions are related to `GetObjectAttributes`:
|
8243
8711
|
#
|
8244
|
-
# * [GetObject][
|
8712
|
+
# * [GetObject][8]
|
8245
8713
|
#
|
8246
|
-
# * [GetObjectAcl][
|
8714
|
+
# * [GetObjectAcl][9]
|
8247
8715
|
#
|
8248
|
-
# * [GetObjectLegalHold][
|
8716
|
+
# * [GetObjectLegalHold][10]
|
8249
8717
|
#
|
8250
|
-
# * [GetObjectLockConfiguration][
|
8718
|
+
# * [GetObjectLockConfiguration][11]
|
8251
8719
|
#
|
8252
|
-
# * [GetObjectRetention][
|
8720
|
+
# * [GetObjectRetention][12]
|
8253
8721
|
#
|
8254
|
-
# * [GetObjectTagging][
|
8722
|
+
# * [GetObjectTagging][13]
|
8255
8723
|
#
|
8256
|
-
# * [HeadObject][
|
8724
|
+
# * [HeadObject][14]
|
8257
8725
|
#
|
8258
|
-
# * [ListParts][
|
8726
|
+
# * [ListParts][15]
|
8259
8727
|
#
|
8260
8728
|
#
|
8261
8729
|
#
|
@@ -8263,15 +8731,17 @@ module Aws::S3
|
|
8263
8731
|
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/using-with-s3-actions.html
|
8264
8732
|
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html
|
8265
8733
|
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/dev/ServerSideEncryptionCustomerKeys.html
|
8266
|
-
# [5]: https://
|
8267
|
-
# [6]: https://docs.aws.amazon.com/AmazonS3/latest/
|
8268
|
-
# [7]: https://
|
8269
|
-
# [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/
|
8270
|
-
# [9]: https://docs.aws.amazon.com/AmazonS3/latest/API/
|
8271
|
-
# [10]: https://docs.aws.amazon.com/AmazonS3/latest/API/
|
8272
|
-
# [11]: https://docs.aws.amazon.com/AmazonS3/latest/API/
|
8273
|
-
# [12]: https://docs.aws.amazon.com/AmazonS3/latest/API/
|
8274
|
-
# [13]: https://docs.aws.amazon.com/AmazonS3/latest/API/
|
8734
|
+
# [5]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-serv-side-encryption.html
|
8735
|
+
# [6]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-specifying-kms-encryption.html
|
8736
|
+
# [7]: https://tools.ietf.org/html/rfc7232
|
8737
|
+
# [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObject.html
|
8738
|
+
# [9]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectAcl.html
|
8739
|
+
# [10]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectLegalHold.html
|
8740
|
+
# [11]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectLockConfiguration.html
|
8741
|
+
# [12]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectRetention.html
|
8742
|
+
# [13]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectTagging.html
|
8743
|
+
# [14]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_HeadObject.html
|
8744
|
+
# [15]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListParts.html
|
8275
8745
|
#
|
8276
8746
|
# @option params [required, String] :bucket
|
8277
8747
|
# The name of the bucket that contains the object.
|
@@ -8815,49 +9285,49 @@ module Aws::S3
|
|
8815
9285
|
# * {Types::GetObjectTaggingOutput#tag_set #tag_set} => Array<Types::Tag>
|
8816
9286
|
#
|
8817
9287
|
#
|
8818
|
-
# @example Example: To retrieve tag set of
|
9288
|
+
# @example Example: To retrieve tag set of a specific object version
|
8819
9289
|
#
|
8820
|
-
# # The following example retrieves tag set of an object.
|
9290
|
+
# # The following example retrieves tag set of an object. The request specifies object version.
|
8821
9291
|
#
|
8822
9292
|
# resp = client.get_object_tagging({
|
8823
9293
|
# bucket: "examplebucket",
|
8824
|
-
# key: "
|
9294
|
+
# key: "exampleobject",
|
9295
|
+
# version_id: "ydlaNkwWm0SfKJR.T1b1fIdPRbldTYRI",
|
8825
9296
|
# })
|
8826
9297
|
#
|
8827
9298
|
# resp.to_h outputs the following:
|
8828
9299
|
# {
|
8829
9300
|
# tag_set: [
|
8830
9301
|
# {
|
8831
|
-
# key: "
|
8832
|
-
# value: "
|
8833
|
-
# },
|
8834
|
-
# {
|
8835
|
-
# key: "Key3",
|
8836
|
-
# value: "Value3",
|
9302
|
+
# key: "Key1",
|
9303
|
+
# value: "Value1",
|
8837
9304
|
# },
|
8838
9305
|
# ],
|
8839
|
-
# version_id: "
|
9306
|
+
# version_id: "ydlaNkwWm0SfKJR.T1b1fIdPRbldTYRI",
|
8840
9307
|
# }
|
8841
9308
|
#
|
8842
|
-
# @example Example: To retrieve tag set of
|
9309
|
+
# @example Example: To retrieve tag set of an object
|
8843
9310
|
#
|
8844
|
-
# # The following example retrieves tag set of an object.
|
9311
|
+
# # The following example retrieves tag set of an object.
|
8845
9312
|
#
|
8846
9313
|
# resp = client.get_object_tagging({
|
8847
9314
|
# bucket: "examplebucket",
|
8848
|
-
# key: "
|
8849
|
-
# version_id: "ydlaNkwWm0SfKJR.T1b1fIdPRbldTYRI",
|
9315
|
+
# key: "HappyFace.jpg",
|
8850
9316
|
# })
|
8851
9317
|
#
|
8852
9318
|
# resp.to_h outputs the following:
|
8853
9319
|
# {
|
8854
9320
|
# tag_set: [
|
8855
9321
|
# {
|
8856
|
-
# key: "
|
8857
|
-
# value: "
|
9322
|
+
# key: "Key4",
|
9323
|
+
# value: "Value4",
|
9324
|
+
# },
|
9325
|
+
# {
|
9326
|
+
# key: "Key3",
|
9327
|
+
# value: "Value3",
|
8858
9328
|
# },
|
8859
9329
|
# ],
|
8860
|
-
# version_id: "
|
9330
|
+
# version_id: "null",
|
8861
9331
|
# }
|
8862
9332
|
#
|
8863
9333
|
# @example Request syntax with placeholder values
|
@@ -9290,6 +9760,13 @@ module Aws::S3
|
|
9290
9760
|
# interruptions when a session expires. For more information about
|
9291
9761
|
# authorization, see [ `CreateSession` ][3].
|
9292
9762
|
#
|
9763
|
+
# If you enable `x-amz-checksum-mode` in the request and the object
|
9764
|
+
# is encrypted with Amazon Web Services Key Management Service
|
9765
|
+
# (Amazon Web Services KMS), you must also have the
|
9766
|
+
# `kms:GenerateDataKey` and `kms:Decrypt` permissions in IAM
|
9767
|
+
# identity-based policies and KMS key policies for the KMS key to
|
9768
|
+
# retrieve the checksum of the object.
|
9769
|
+
#
|
9293
9770
|
# Encryption
|
9294
9771
|
# : <note markdown="1"> Encryption request headers, like `x-amz-server-side-encryption`,
|
9295
9772
|
# should not be sent for `HEAD` requests if your object uses
|
@@ -9323,9 +9800,10 @@ module Aws::S3
|
|
9323
9800
|
# Customer-Provided Encryption Keys)][4] in the *Amazon S3 User
|
9324
9801
|
# Guide*.
|
9325
9802
|
#
|
9326
|
-
# <note markdown="1">
|
9327
|
-
# server-side encryption
|
9328
|
-
#
|
9803
|
+
# <note markdown="1"> <b>Directory bucket </b> - For directory buckets, there are only two
|
9804
|
+
# supported options for server-side encryption: SSE-S3 and SSE-KMS.
|
9805
|
+
# SSE-C isn't supported. For more information, see [Protecting data
|
9806
|
+
# with server-side encryption][5] in the *Amazon S3 User Guide*.
|
9329
9807
|
#
|
9330
9808
|
# </note>
|
9331
9809
|
#
|
@@ -9359,15 +9837,15 @@ module Aws::S3
|
|
9359
9837
|
# requests in the format
|
9360
9838
|
# `https://bucket_name.s3express-az_id.region.amazonaws.com/key-name
|
9361
9839
|
# `. Path-style requests are not supported. For more information, see
|
9362
|
-
# [Regional and Zonal endpoints][
|
9840
|
+
# [Regional and Zonal endpoints][6] in the *Amazon S3 User Guide*.
|
9363
9841
|
#
|
9364
9842
|
# </note>
|
9365
9843
|
#
|
9366
9844
|
# The following actions are related to `HeadObject`:
|
9367
9845
|
#
|
9368
|
-
# * [GetObject][
|
9846
|
+
# * [GetObject][7]
|
9369
9847
|
#
|
9370
|
-
# * [GetObjectAttributes][
|
9848
|
+
# * [GetObjectAttributes][8]
|
9371
9849
|
#
|
9372
9850
|
#
|
9373
9851
|
#
|
@@ -9375,9 +9853,10 @@ module Aws::S3
|
|
9375
9853
|
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/list_amazons3.html
|
9376
9854
|
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html
|
9377
9855
|
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/dev/ServerSideEncryptionCustomerKeys.html
|
9378
|
-
# [5]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-
|
9379
|
-
# [6]: https://docs.aws.amazon.com/AmazonS3/latest/
|
9380
|
-
# [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/
|
9856
|
+
# [5]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-serv-side-encryption.html
|
9857
|
+
# [6]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html
|
9858
|
+
# [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObject.html
|
9859
|
+
# [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectAttributes.html
|
9381
9860
|
#
|
9382
9861
|
# @option params [required, String] :bucket
|
9383
9862
|
# The name of the bucket that contains the object.
|
@@ -9593,10 +10072,16 @@ module Aws::S3
|
|
9593
10072
|
# @option params [String] :checksum_mode
|
9594
10073
|
# To retrieve the checksum, this parameter must be enabled.
|
9595
10074
|
#
|
9596
|
-
#
|
9597
|
-
# with a [checksum][1] and encrypted with an Key
|
9598
|
-
# (KMS) key, you must have permission to use the
|
9599
|
-
# retrieve the checksum.
|
10075
|
+
# **General purpose buckets** - If you enable checksum mode and the
|
10076
|
+
# object is uploaded with a [checksum][1] and encrypted with an Key
|
10077
|
+
# Management Service (KMS) key, you must have permission to use the
|
10078
|
+
# `kms:Decrypt` action to retrieve the checksum.
|
10079
|
+
#
|
10080
|
+
# **Directory buckets** - If you enable `ChecksumMode` and the object is
|
10081
|
+
# encrypted with Amazon Web Services Key Management Service (Amazon Web
|
10082
|
+
# Services KMS), you must also have the `kms:GenerateDataKey` and
|
10083
|
+
# `kms:Decrypt` permissions in IAM identity-based policies and KMS key
|
10084
|
+
# policies for the KMS key to retrieve the checksum of the object.
|
9600
10085
|
#
|
9601
10086
|
#
|
9602
10087
|
#
|
@@ -12592,24 +13077,73 @@ module Aws::S3
|
|
12592
13077
|
req.send_request(options)
|
12593
13078
|
end
|
12594
13079
|
|
12595
|
-
#
|
13080
|
+
# This operation configures default encryption and Amazon S3 Bucket Keys
|
13081
|
+
# for an existing bucket.
|
12596
13082
|
#
|
12597
|
-
#
|
13083
|
+
# <note markdown="1"> <b>Directory buckets </b> - For directory buckets, you must make
|
13084
|
+
# requests for this API operation to the Regional endpoint. These
|
13085
|
+
# endpoints support path-style requests in the format
|
13086
|
+
# `https://s3express-control.region_code.amazonaws.com/bucket-name `.
|
13087
|
+
# Virtual-hosted-style requests aren't supported. For more information,
|
13088
|
+
# see [Regional and Zonal endpoints][1] in the *Amazon S3 User Guide*.
|
12598
13089
|
#
|
12599
|
-
#
|
12600
|
-
# encryption and Amazon S3 Bucket Keys for an existing bucket.
|
13090
|
+
# </note>
|
12601
13091
|
#
|
12602
13092
|
# By default, all buckets have a default encryption configuration that
|
12603
|
-
# uses server-side encryption with Amazon S3 managed keys (SSE-S3).
|
12604
|
-
#
|
12605
|
-
#
|
12606
|
-
#
|
12607
|
-
#
|
12608
|
-
#
|
12609
|
-
#
|
12610
|
-
#
|
12611
|
-
#
|
12612
|
-
#
|
13093
|
+
# uses server-side encryption with Amazon S3 managed keys (SSE-S3).
|
13094
|
+
#
|
13095
|
+
# <note markdown="1"> * **General purpose buckets**
|
13096
|
+
#
|
13097
|
+
# * You can optionally configure default encryption for a bucket by
|
13098
|
+
# using server-side encryption with Key Management Service (KMS)
|
13099
|
+
# keys (SSE-KMS) or dual-layer server-side encryption with Amazon
|
13100
|
+
# Web Services KMS keys (DSSE-KMS). If you specify default
|
13101
|
+
# encryption by using SSE-KMS, you can also configure [Amazon S3
|
13102
|
+
# Bucket Keys][2]. For information about the bucket default
|
13103
|
+
# encryption feature, see [Amazon S3 Bucket Default Encryption][3]
|
13104
|
+
# in the *Amazon S3 User Guide*.
|
13105
|
+
#
|
13106
|
+
# * If you use PutBucketEncryption to set your [default bucket
|
13107
|
+
# encryption][3] to SSE-KMS, you should verify that your KMS key ID
|
13108
|
+
# is correct. Amazon S3 doesn't validate the KMS key ID provided in
|
13109
|
+
# PutBucketEncryption requests.
|
13110
|
+
#
|
13111
|
+
# * <b>Directory buckets </b> - You can optionally configure default
|
13112
|
+
# encryption for a bucket by using server-side encryption with Key
|
13113
|
+
# Management Service (KMS) keys (SSE-KMS).
|
13114
|
+
#
|
13115
|
+
# * We recommend that the bucket's default encryption uses the
|
13116
|
+
# desired encryption configuration and you don't override the
|
13117
|
+
# bucket default encryption in your `CreateSession` requests or
|
13118
|
+
# `PUT` object requests. Then, new objects are automatically
|
13119
|
+
# encrypted with the desired encryption settings. For more
|
13120
|
+
# information about the encryption overriding behaviors in directory
|
13121
|
+
# buckets, see [Specifying server-side encryption with KMS for new
|
13122
|
+
# object uploads][4].
|
13123
|
+
#
|
13124
|
+
# * Your SSE-KMS configuration can only support 1 [customer managed
|
13125
|
+
# key][5] per directory bucket for the lifetime of the bucket.
|
13126
|
+
# [Amazon Web Services managed key][6] (`aws/s3`) isn't supported.
|
13127
|
+
#
|
13128
|
+
# * S3 Bucket Keys are always enabled for `GET` and `PUT` operations
|
13129
|
+
# in a directory bucket and can’t be disabled. S3 Bucket Keys
|
13130
|
+
# aren't supported, when you copy SSE-KMS encrypted objects from
|
13131
|
+
# general purpose buckets to directory buckets, from directory
|
13132
|
+
# buckets to general purpose buckets, or between directory buckets,
|
13133
|
+
# through [CopyObject][7], [UploadPartCopy][8], [the Copy operation
|
13134
|
+
# in Batch Operations][9], or [the import jobs][10]. In this case,
|
13135
|
+
# Amazon S3 makes a call to KMS every time a copy request is made
|
13136
|
+
# for a KMS-encrypted object.
|
13137
|
+
#
|
13138
|
+
# * When you specify an [KMS customer managed key][5] for encryption
|
13139
|
+
# in your directory bucket, only use the key ID or key ARN. The key
|
13140
|
+
# alias format of the KMS key isn't supported.
|
13141
|
+
#
|
13142
|
+
# * For directory buckets, if you use PutBucketEncryption to set your
|
13143
|
+
# [default bucket encryption][3] to SSE-KMS, Amazon S3 validates the
|
13144
|
+
# KMS key ID provided in PutBucketEncryption requests.
|
13145
|
+
#
|
13146
|
+
# </note>
|
12613
13147
|
#
|
12614
13148
|
# If you're specifying a customer managed KMS key, we recommend using a
|
12615
13149
|
# fully qualified KMS key ARN. If you use a KMS key alias instead, then
|
@@ -12619,45 +13153,80 @@ module Aws::S3
|
|
12619
13153
|
#
|
12620
13154
|
# Also, this action requires Amazon Web Services Signature Version 4.
|
12621
13155
|
# For more information, see [ Authenticating Requests (Amazon Web
|
12622
|
-
# Services Signature Version 4)][
|
13156
|
+
# Services Signature Version 4)][11].
|
12623
13157
|
#
|
12624
|
-
#
|
12625
|
-
#
|
12626
|
-
# permission
|
12627
|
-
#
|
12628
|
-
#
|
12629
|
-
#
|
12630
|
-
#
|
13158
|
+
# Permissions
|
13159
|
+
# : * **General purpose bucket permissions** - The
|
13160
|
+
# `s3:PutEncryptionConfiguration` permission is required in a
|
13161
|
+
# policy. The bucket owner has this permission by default. The
|
13162
|
+
# bucket owner can grant this permission to others. For more
|
13163
|
+
# information about permissions, see [Permissions Related to Bucket
|
13164
|
+
# Operations][12] and [Managing Access Permissions to Your Amazon S3
|
13165
|
+
# Resources][13] in the *Amazon S3 User Guide*.
|
13166
|
+
#
|
13167
|
+
# * **Directory bucket permissions** - To grant access to this API
|
13168
|
+
# operation, you must have the
|
13169
|
+
# `s3express:PutEncryptionConfiguration` permission in an IAM
|
13170
|
+
# identity-based policy instead of a bucket policy. Cross-account
|
13171
|
+
# access to this API operation isn't supported. This operation can
|
13172
|
+
# only be performed by the Amazon Web Services account that owns the
|
13173
|
+
# resource. For more information about directory bucket policies and
|
13174
|
+
# permissions, see [Amazon Web Services Identity and Access
|
13175
|
+
# Management (IAM) for S3 Express One Zone][14] in the *Amazon S3
|
13176
|
+
# User Guide*.
|
13177
|
+
#
|
13178
|
+
# To set a directory bucket default encryption with SSE-KMS, you
|
13179
|
+
# must also have the `kms:GenerateDataKey` and the `kms:Decrypt`
|
13180
|
+
# permissions in IAM identity-based policies and KMS key policies
|
13181
|
+
# for the target KMS key.
|
13182
|
+
#
|
13183
|
+
# HTTP Host header syntax
|
13184
|
+
#
|
13185
|
+
# : <b>Directory buckets </b> - The HTTP Host header syntax is
|
13186
|
+
# `s3express-control.region.amazonaws.com`.
|
12631
13187
|
#
|
12632
13188
|
# The following operations are related to `PutBucketEncryption`:
|
12633
13189
|
#
|
12634
|
-
# * [GetBucketEncryption][
|
13190
|
+
# * [GetBucketEncryption][15]
|
12635
13191
|
#
|
12636
|
-
# * [DeleteBucketEncryption][
|
13192
|
+
# * [DeleteBucketEncryption][16]
|
12637
13193
|
#
|
12638
13194
|
#
|
12639
13195
|
#
|
12640
|
-
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/
|
12641
|
-
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/bucket-
|
12642
|
-
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/
|
12643
|
-
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/
|
12644
|
-
# [5]: https://docs.aws.amazon.com/
|
12645
|
-
# [6]: https://docs.aws.amazon.com/
|
12646
|
-
# [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/
|
13196
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html
|
13197
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/dev/bucket-key.html
|
13198
|
+
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/dev/bucket-encryption.html
|
13199
|
+
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-specifying-kms-encryption.html
|
13200
|
+
# [5]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk
|
13201
|
+
# [6]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk
|
13202
|
+
# [7]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html
|
13203
|
+
# [8]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html
|
13204
|
+
# [9]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-objects-Batch-Ops
|
13205
|
+
# [10]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/create-import-job
|
13206
|
+
# [11]: https://docs.aws.amazon.com/AmazonS3/latest/API/sig-v4-authenticating-requests.html
|
13207
|
+
# [12]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-with-s3-actions.html#using-with-s3-actions-related-to-bucket-subresources
|
13208
|
+
# [13]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-access-control.html
|
13209
|
+
# [14]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam.html
|
13210
|
+
# [15]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketEncryption.html
|
13211
|
+
# [16]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketEncryption.html
|
12647
13212
|
#
|
12648
13213
|
# @option params [required, String] :bucket
|
12649
13214
|
# Specifies default encryption for a bucket using server-side encryption
|
12650
|
-
# with different key options.
|
12651
|
-
#
|
12652
|
-
#
|
12653
|
-
#
|
12654
|
-
#
|
12655
|
-
#
|
12656
|
-
#
|
13215
|
+
# with different key options.
|
13216
|
+
#
|
13217
|
+
# <b>Directory buckets </b> - When you use this operation with a
|
13218
|
+
# directory bucket, you must use path-style requests in the format
|
13219
|
+
# `https://s3express-control.region_code.amazonaws.com/bucket-name `.
|
13220
|
+
# Virtual-hosted-style requests aren't supported. Directory bucket
|
13221
|
+
# names must be unique in the chosen Availability Zone. Bucket names
|
13222
|
+
# must also follow the format ` bucket_base_name--az_id--x-s3` (for
|
13223
|
+
# example, ` DOC-EXAMPLE-BUCKET--usw2-az1--x-s3`). For information about
|
13224
|
+
# bucket naming restrictions, see [Directory bucket naming rules][1] in
|
13225
|
+
# the *Amazon S3 User Guide*
|
12657
13226
|
#
|
12658
13227
|
#
|
12659
13228
|
#
|
12660
|
-
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/
|
13229
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-bucket-naming-rules.html
|
12661
13230
|
#
|
12662
13231
|
# @option params [String] :content_md5
|
12663
13232
|
# The base64-encoded 128-bit MD5 digest of the server-side encryption
|
@@ -12667,6 +13236,10 @@ module Aws::S3
|
|
12667
13236
|
# (CLI) or Amazon Web Services SDKs, this field is calculated
|
12668
13237
|
# automatically.
|
12669
13238
|
#
|
13239
|
+
# <note markdown="1"> This functionality is not supported for directory buckets.
|
13240
|
+
#
|
13241
|
+
# </note>
|
13242
|
+
#
|
12670
13243
|
# @option params [String] :checksum_algorithm
|
12671
13244
|
# Indicates the algorithm used to create the checksum for the object
|
12672
13245
|
# when you use the SDK. This header will not provide any additional
|
@@ -12679,6 +13252,11 @@ module Aws::S3
|
|
12679
13252
|
# If you provide an individual checksum, Amazon S3 ignores any provided
|
12680
13253
|
# `ChecksumAlgorithm` parameter.
|
12681
13254
|
#
|
13255
|
+
# <note markdown="1"> For directory buckets, when you use Amazon Web Services SDKs, `CRC32`
|
13256
|
+
# is the default checksum algorithm that's used for performance.
|
13257
|
+
#
|
13258
|
+
# </note>
|
13259
|
+
#
|
12682
13260
|
#
|
12683
13261
|
#
|
12684
13262
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html
|
@@ -12691,6 +13269,12 @@ module Aws::S3
|
|
12691
13269
|
# you provide does not match the actual owner of the bucket, the request
|
12692
13270
|
# fails with the HTTP status code `403 Forbidden` (access denied).
|
12693
13271
|
#
|
13272
|
+
# <note markdown="1"> For directory buckets, this header is not supported in this API
|
13273
|
+
# operation. If you specify this header, the request fails with the HTTP
|
13274
|
+
# status code `501 Not Implemented`.
|
13275
|
+
#
|
13276
|
+
# </note>
|
13277
|
+
#
|
12694
13278
|
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
12695
13279
|
#
|
12696
13280
|
# @example Request syntax with placeholder values
|
@@ -15088,6 +15672,10 @@ module Aws::S3
|
|
15088
15672
|
# interruptions when a session expires. For more information about
|
15089
15673
|
# authorization, see [ `CreateSession` ][5].
|
15090
15674
|
#
|
15675
|
+
# If the object is encrypted with SSE-KMS, you must also have the
|
15676
|
+
# `kms:GenerateDataKey` and `kms:Decrypt` permissions in IAM
|
15677
|
+
# identity-based policies and KMS key policies for the KMS key.
|
15678
|
+
#
|
15091
15679
|
# Data integrity with Content-MD5
|
15092
15680
|
# : * **General purpose bucket** - To ensure that data is not corrupted
|
15093
15681
|
# traversing the network, use the `Content-MD5` header. When you use
|
@@ -15437,25 +16025,65 @@ module Aws::S3
|
|
15437
16025
|
# object in Amazon S3 (for example, `AES256`, `aws:kms`,
|
15438
16026
|
# `aws:kms:dsse`).
|
15439
16027
|
#
|
15440
|
-
# <b>General purpose buckets </b> - You have four mutually exclusive
|
15441
|
-
#
|
15442
|
-
#
|
15443
|
-
#
|
15444
|
-
#
|
15445
|
-
#
|
15446
|
-
#
|
15447
|
-
#
|
15448
|
-
#
|
15449
|
-
#
|
15450
|
-
#
|
16028
|
+
# * <b>General purpose buckets </b> - You have four mutually exclusive
|
16029
|
+
# options to protect data using server-side encryption in Amazon S3,
|
16030
|
+
# depending on how you choose to manage the encryption keys.
|
16031
|
+
# Specifically, the encryption key options are Amazon S3 managed keys
|
16032
|
+
# (SSE-S3), Amazon Web Services KMS keys (SSE-KMS or DSSE-KMS), and
|
16033
|
+
# customer-provided keys (SSE-C). Amazon S3 encrypts data with
|
16034
|
+
# server-side encryption by using Amazon S3 managed keys (SSE-S3) by
|
16035
|
+
# default. You can optionally tell Amazon S3 to encrypt data at rest
|
16036
|
+
# by using server-side encryption with other key options. For more
|
16037
|
+
# information, see [Using Server-Side Encryption][1] in the *Amazon S3
|
16038
|
+
# User Guide*.
|
15451
16039
|
#
|
15452
|
-
# <b>Directory buckets </b> - For directory buckets, only
|
15453
|
-
#
|
15454
|
-
#
|
16040
|
+
# * <b>Directory buckets </b> - For directory buckets, there are only
|
16041
|
+
# two supported options for server-side encryption: server-side
|
16042
|
+
# encryption with Amazon S3 managed keys (SSE-S3) (`AES256`) and
|
16043
|
+
# server-side encryption with KMS keys (SSE-KMS) (`aws:kms`). We
|
16044
|
+
# recommend that the bucket's default encryption uses the desired
|
16045
|
+
# encryption configuration and you don't override the bucket default
|
16046
|
+
# encryption in your `CreateSession` requests or `PUT` object
|
16047
|
+
# requests. Then, new objects are automatically encrypted with the
|
16048
|
+
# desired encryption settings. For more information, see [Protecting
|
16049
|
+
# data with server-side encryption][2] in the *Amazon S3 User Guide*.
|
16050
|
+
# For more information about the encryption overriding behaviors in
|
16051
|
+
# directory buckets, see [Specifying server-side encryption with KMS
|
16052
|
+
# for new object uploads][3].
|
16053
|
+
#
|
16054
|
+
# In the Zonal endpoint API calls (except [CopyObject][4] and
|
16055
|
+
# [UploadPartCopy][5]) using the REST API, the encryption request
|
16056
|
+
# headers must match the encryption settings that are specified in the
|
16057
|
+
# `CreateSession` request. You can't override the values of the
|
16058
|
+
# encryption settings (`x-amz-server-side-encryption`,
|
16059
|
+
# `x-amz-server-side-encryption-aws-kms-key-id`,
|
16060
|
+
# `x-amz-server-side-encryption-context`, and
|
16061
|
+
# `x-amz-server-side-encryption-bucket-key-enabled`) that are
|
16062
|
+
# specified in the `CreateSession` request. You don't need to
|
16063
|
+
# explicitly specify these encryption settings values in Zonal
|
16064
|
+
# endpoint API calls, and Amazon S3 will use the encryption settings
|
16065
|
+
# values from the `CreateSession` request to protect new objects in
|
16066
|
+
# the directory bucket.
|
16067
|
+
#
|
16068
|
+
# <note markdown="1"> When you use the CLI or the Amazon Web Services SDKs, for
|
16069
|
+
# `CreateSession`, the session token refreshes automatically to avoid
|
16070
|
+
# service interruptions when a session expires. The CLI or the Amazon
|
16071
|
+
# Web Services SDKs use the bucket's default encryption configuration
|
16072
|
+
# for the `CreateSession` request. It's not supported to override the
|
16073
|
+
# encryption settings values in the `CreateSession` request. So in the
|
16074
|
+
# Zonal endpoint API calls (except [CopyObject][4] and
|
16075
|
+
# [UploadPartCopy][5]), the encryption request headers must match the
|
16076
|
+
# default encryption configuration of the directory bucket.
|
16077
|
+
#
|
16078
|
+
# </note>
|
15455
16079
|
#
|
15456
16080
|
#
|
15457
16081
|
#
|
15458
16082
|
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingServerSideEncryption.html
|
16083
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-serv-side-encryption.html
|
16084
|
+
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-specifying-kms-encryption.html
|
16085
|
+
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html
|
16086
|
+
# [5]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html
|
15459
16087
|
#
|
15460
16088
|
# @option params [String] :storage_class
|
15461
16089
|
# By default, Amazon S3 uses the STANDARD Storage Class to store newly
|
@@ -15535,46 +16163,83 @@ module Aws::S3
|
|
15535
16163
|
# </note>
|
15536
16164
|
#
|
15537
16165
|
# @option params [String] :ssekms_key_id
|
15538
|
-
#
|
15539
|
-
#
|
15540
|
-
#
|
15541
|
-
#
|
15542
|
-
#
|
15543
|
-
#
|
15544
|
-
# x-amz-server-side-encryption
|
15545
|
-
#
|
15546
|
-
#
|
15547
|
-
#
|
16166
|
+
# Specifies the KMS key ID (Key ID, Key ARN, or Key Alias) to use for
|
16167
|
+
# object encryption. If the KMS key doesn't exist in the same account
|
16168
|
+
# that's issuing the command, you must use the full Key ARN not the Key
|
16169
|
+
# ID.
|
16170
|
+
#
|
16171
|
+
# **General purpose buckets** - If you specify
|
16172
|
+
# `x-amz-server-side-encryption` with `aws:kms` or `aws:kms:dsse`, this
|
16173
|
+
# header specifies the ID (Key ID, Key ARN, or Key Alias) of the KMS key
|
16174
|
+
# to use. If you specify `x-amz-server-side-encryption:aws:kms` or
|
16175
|
+
# `x-amz-server-side-encryption:aws:kms:dsse`, but do not provide
|
16176
|
+
# `x-amz-server-side-encryption-aws-kms-key-id`, Amazon S3 uses the
|
16177
|
+
# Amazon Web Services managed key (`aws/s3`) to protect the data.
|
16178
|
+
#
|
16179
|
+
# **Directory buckets** - If you specify `x-amz-server-side-encryption`
|
16180
|
+
# with `aws:kms`, you must specify the `
|
16181
|
+
# x-amz-server-side-encryption-aws-kms-key-id` header with the ID (Key
|
16182
|
+
# ID or Key ARN) of the KMS symmetric encryption customer managed key to
|
16183
|
+
# use. Otherwise, you get an HTTP `400 Bad Request` error. Only use the
|
16184
|
+
# key ID or key ARN. The key alias format of the KMS key isn't
|
16185
|
+
# supported. Your SSE-KMS configuration can only support 1 [customer
|
16186
|
+
# managed key][1] per directory bucket for the lifetime of the bucket.
|
16187
|
+
# [Amazon Web Services managed key][2] (`aws/s3`) isn't supported.
|
16188
|
+
#
|
16189
|
+
#
|
16190
|
+
#
|
16191
|
+
# [1]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk
|
16192
|
+
# [2]: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk
|
15548
16193
|
#
|
15549
|
-
#
|
16194
|
+
# @option params [String] :ssekms_encryption_context
|
16195
|
+
# Specifies the Amazon Web Services KMS Encryption Context as an
|
16196
|
+
# additional encryption context to use for object encryption. The value
|
16197
|
+
# of this header is a Base64-encoded string of a UTF-8 encoded JSON,
|
16198
|
+
# which contains the encryption context as key-value pairs. This value
|
16199
|
+
# is stored as object metadata and automatically gets passed on to
|
16200
|
+
# Amazon Web Services KMS for future `GetObject` operations on this
|
16201
|
+
# object.
|
15550
16202
|
#
|
15551
|
-
#
|
16203
|
+
# **General purpose buckets** - This value must be explicitly added
|
16204
|
+
# during `CopyObject` operations if you want an additional encryption
|
16205
|
+
# context for your object. For more information, see [Encryption
|
16206
|
+
# context][1] in the *Amazon S3 User Guide*.
|
15552
16207
|
#
|
15553
|
-
#
|
15554
|
-
#
|
15555
|
-
#
|
15556
|
-
#
|
15557
|
-
# value is stored as object metadata and automatically gets passed on to
|
15558
|
-
# Amazon Web Services KMS for future `GetObject` or `CopyObject`
|
15559
|
-
# operations on this object. This value must be explicitly added during
|
15560
|
-
# `CopyObject` operations.
|
16208
|
+
# **Directory buckets** - You can optionally provide an explicit
|
16209
|
+
# encryption context value. The value must match the default encryption
|
16210
|
+
# context - the bucket Amazon Resource Name (ARN). An additional
|
16211
|
+
# encryption context value is not supported.
|
15561
16212
|
#
|
15562
|
-
# <note markdown="1"> This functionality is not supported for directory buckets.
|
15563
16213
|
#
|
15564
|
-
#
|
16214
|
+
#
|
16215
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/UsingKMSEncryption.html#encryption-context
|
15565
16216
|
#
|
15566
16217
|
# @option params [Boolean] :bucket_key_enabled
|
15567
16218
|
# Specifies whether Amazon S3 should use an S3 Bucket Key for object
|
15568
16219
|
# encryption with server-side encryption using Key Management Service
|
15569
|
-
# (KMS) keys (SSE-KMS).
|
15570
|
-
#
|
16220
|
+
# (KMS) keys (SSE-KMS).
|
16221
|
+
#
|
16222
|
+
# **General purpose buckets** - Setting this header to `true` causes
|
16223
|
+
# Amazon S3 to use an S3 Bucket Key for object encryption with SSE-KMS.
|
16224
|
+
# Also, specifying this header with a PUT action doesn't affect
|
16225
|
+
# bucket-level settings for S3 Bucket Key.
|
15571
16226
|
#
|
15572
|
-
#
|
15573
|
-
#
|
16227
|
+
# **Directory buckets** - S3 Bucket Keys are always enabled for `GET`
|
16228
|
+
# and `PUT` operations in a directory bucket and can’t be disabled. S3
|
16229
|
+
# Bucket Keys aren't supported, when you copy SSE-KMS encrypted objects
|
16230
|
+
# from general purpose buckets to directory buckets, from directory
|
16231
|
+
# buckets to general purpose buckets, or between directory buckets,
|
16232
|
+
# through [CopyObject][1], [UploadPartCopy][2], [the Copy operation in
|
16233
|
+
# Batch Operations][3], or [the import jobs][4]. In this case, Amazon S3
|
16234
|
+
# makes a call to KMS every time a copy request is made for a
|
16235
|
+
# KMS-encrypted object.
|
15574
16236
|
#
|
15575
|
-
# <note markdown="1"> This functionality is not supported for directory buckets.
|
15576
16237
|
#
|
15577
|
-
#
|
16238
|
+
#
|
16239
|
+
# [1]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html
|
16240
|
+
# [2]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html
|
16241
|
+
# [3]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-objects-Batch-Ops
|
16242
|
+
# [4]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/create-import-job
|
15578
16243
|
#
|
15579
16244
|
# @option params [String] :request_payer
|
15580
16245
|
# Confirms that the requester knows that they will be charged for the
|
@@ -15652,24 +16317,22 @@ module Aws::S3
|
|
15652
16317
|
# * {Types::PutObjectOutput#request_charged #request_charged} => String
|
15653
16318
|
#
|
15654
16319
|
#
|
15655
|
-
# @example Example: To upload an object
|
16320
|
+
# @example Example: To upload an object and specify optional tags
|
15656
16321
|
#
|
15657
|
-
# # The following example uploads an object. The request specifies optional
|
15658
|
-
# #
|
16322
|
+
# # The following example uploads an object. The request specifies optional object tags. The bucket is versioned, therefore
|
16323
|
+
# # S3 returns version ID of the newly created object.
|
15659
16324
|
#
|
15660
16325
|
# resp = client.put_object({
|
15661
|
-
# body: "HappyFace.jpg",
|
16326
|
+
# body: "c:\\HappyFace.jpg",
|
15662
16327
|
# bucket: "examplebucket",
|
15663
16328
|
# key: "HappyFace.jpg",
|
15664
|
-
#
|
15665
|
-
# storage_class: "STANDARD_IA",
|
16329
|
+
# tagging: "key1=value1&key2=value2",
|
15666
16330
|
# })
|
15667
16331
|
#
|
15668
16332
|
# resp.to_h outputs the following:
|
15669
16333
|
# {
|
15670
16334
|
# etag: "\"6805f2cfc46c0f04559748bb039d69ae\"",
|
15671
|
-
#
|
15672
|
-
# version_id: "CG612hodqujkf8FaaNfp8U..FIhLROcp",
|
16335
|
+
# version_id: "psM2sYY4.o1501dSx8wMvnkOzSBB.V4a",
|
15673
16336
|
# }
|
15674
16337
|
#
|
15675
16338
|
# @example Example: To create an object.
|
@@ -15688,98 +16351,100 @@ module Aws::S3
|
|
15688
16351
|
# version_id: "Bvq0EDKxOcXLJXNo_Lkz37eM3R4pfzyQ",
|
15689
16352
|
# }
|
15690
16353
|
#
|
15691
|
-
# @example Example: To upload
|
16354
|
+
# @example Example: To upload object and specify user-defined metadata
|
15692
16355
|
#
|
15693
|
-
# # The following example
|
15694
|
-
# #
|
16356
|
+
# # The following example creates an object. The request also specifies optional metadata. If the bucket is versioning
|
16357
|
+
# # enabled, S3 returns version ID in response.
|
15695
16358
|
#
|
15696
16359
|
# resp = client.put_object({
|
15697
|
-
# body: "
|
16360
|
+
# body: "filetoupload",
|
15698
16361
|
# bucket: "examplebucket",
|
15699
|
-
# key: "
|
16362
|
+
# key: "exampleobject",
|
16363
|
+
# metadata: {
|
16364
|
+
# "metadata1" => "value1",
|
16365
|
+
# "metadata2" => "value2",
|
16366
|
+
# },
|
15700
16367
|
# })
|
15701
16368
|
#
|
15702
16369
|
# resp.to_h outputs the following:
|
15703
16370
|
# {
|
15704
16371
|
# etag: "\"6805f2cfc46c0f04559748bb039d69ae\"",
|
15705
|
-
# version_id: "
|
16372
|
+
# version_id: "pSKidl4pHBiNwukdbcPXAIs.sshFFOc0",
|
15706
16373
|
# }
|
15707
16374
|
#
|
15708
|
-
# @example Example: To upload an object
|
16375
|
+
# @example Example: To upload an object
|
15709
16376
|
#
|
15710
|
-
# # The following example uploads an object
|
15711
|
-
# # S3 returns
|
16377
|
+
# # The following example uploads an object to a versioning-enabled bucket. The source file is specified using Windows file
|
16378
|
+
# # syntax. S3 returns VersionId of the newly created object.
|
15712
16379
|
#
|
15713
16380
|
# resp = client.put_object({
|
15714
|
-
# body: "
|
16381
|
+
# body: "HappyFace.jpg",
|
15715
16382
|
# bucket: "examplebucket",
|
15716
16383
|
# key: "HappyFace.jpg",
|
15717
|
-
# tagging: "key1=value1&key2=value2",
|
15718
16384
|
# })
|
15719
16385
|
#
|
15720
16386
|
# resp.to_h outputs the following:
|
15721
16387
|
# {
|
15722
16388
|
# etag: "\"6805f2cfc46c0f04559748bb039d69ae\"",
|
15723
|
-
# version_id: "
|
16389
|
+
# version_id: "tpf3zF08nBplQK1XLOefGskR7mGDwcDk",
|
15724
16390
|
# }
|
15725
16391
|
#
|
15726
|
-
# @example Example: To upload an object and specify
|
16392
|
+
# @example Example: To upload an object and specify server-side encryption and object tags
|
15727
16393
|
#
|
15728
|
-
# # The following example uploads
|
15729
|
-
# #
|
16394
|
+
# # The following example uploads an object. The request specifies the optional server-side encryption option. The request
|
16395
|
+
# # also specifies optional object tags. If the bucket is versioning enabled, S3 returns version ID in response.
|
15730
16396
|
#
|
15731
16397
|
# resp = client.put_object({
|
15732
|
-
# acl: "authenticated-read",
|
15733
16398
|
# body: "filetoupload",
|
15734
16399
|
# bucket: "examplebucket",
|
15735
16400
|
# key: "exampleobject",
|
16401
|
+
# server_side_encryption: "AES256",
|
16402
|
+
# tagging: "key1=value1&key2=value2",
|
15736
16403
|
# })
|
15737
16404
|
#
|
15738
16405
|
# resp.to_h outputs the following:
|
15739
16406
|
# {
|
15740
16407
|
# etag: "\"6805f2cfc46c0f04559748bb039d69ae\"",
|
15741
|
-
#
|
16408
|
+
# server_side_encryption: "AES256",
|
16409
|
+
# version_id: "Ri.vC6qVlA4dEnjgRV4ZHsHoFIjqEMNt",
|
15742
16410
|
# }
|
15743
16411
|
#
|
15744
|
-
# @example Example: To upload object and specify
|
16412
|
+
# @example Example: To upload an object and specify canned ACL.
|
15745
16413
|
#
|
15746
|
-
# # The following example
|
15747
|
-
# # enabled, S3 returns version ID in response.
|
16414
|
+
# # The following example uploads and object. The request specifies optional canned ACL (access control list) to all READ
|
16415
|
+
# # access to authenticated users. If the bucket is versioning enabled, S3 returns version ID in response.
|
15748
16416
|
#
|
15749
16417
|
# resp = client.put_object({
|
16418
|
+
# acl: "authenticated-read",
|
15750
16419
|
# body: "filetoupload",
|
15751
16420
|
# bucket: "examplebucket",
|
15752
16421
|
# key: "exampleobject",
|
15753
|
-
# metadata: {
|
15754
|
-
# "metadata1" => "value1",
|
15755
|
-
# "metadata2" => "value2",
|
15756
|
-
# },
|
15757
16422
|
# })
|
15758
16423
|
#
|
15759
16424
|
# resp.to_h outputs the following:
|
15760
16425
|
# {
|
15761
16426
|
# etag: "\"6805f2cfc46c0f04559748bb039d69ae\"",
|
15762
|
-
# version_id: "
|
16427
|
+
# version_id: "Kirh.unyZwjQ69YxcQLA8z4F5j3kJJKr",
|
15763
16428
|
# }
|
15764
16429
|
#
|
15765
|
-
# @example Example: To upload an object
|
16430
|
+
# @example Example: To upload an object (specify optional headers)
|
15766
16431
|
#
|
15767
|
-
# # The following example uploads an object. The request specifies
|
15768
|
-
# #
|
16432
|
+
# # The following example uploads an object. The request specifies optional request headers to directs S3 to use specific
|
16433
|
+
# # storage class and use server-side encryption.
|
15769
16434
|
#
|
15770
16435
|
# resp = client.put_object({
|
15771
|
-
# body: "
|
16436
|
+
# body: "HappyFace.jpg",
|
15772
16437
|
# bucket: "examplebucket",
|
15773
|
-
# key: "
|
16438
|
+
# key: "HappyFace.jpg",
|
15774
16439
|
# server_side_encryption: "AES256",
|
15775
|
-
#
|
16440
|
+
# storage_class: "STANDARD_IA",
|
15776
16441
|
# })
|
15777
16442
|
#
|
15778
16443
|
# resp.to_h outputs the following:
|
15779
16444
|
# {
|
15780
16445
|
# etag: "\"6805f2cfc46c0f04559748bb039d69ae\"",
|
15781
16446
|
# server_side_encryption: "AES256",
|
15782
|
-
# version_id: "
|
16447
|
+
# version_id: "CG612hodqujkf8FaaNfp8U..FIhLROcp",
|
15783
16448
|
# }
|
15784
16449
|
#
|
15785
16450
|
# @example Streaming a file from disk
|
@@ -17792,6 +18457,10 @@ module Aws::S3
|
|
17792
18457
|
# interruptions when a session expires. For more information about
|
17793
18458
|
# authorization, see [ `CreateSession` ][9].
|
17794
18459
|
#
|
18460
|
+
# If the object is encrypted with SSE-KMS, you must also have the
|
18461
|
+
# `kms:GenerateDataKey` and `kms:Decrypt` permissions in IAM
|
18462
|
+
# identity-based policies and KMS key policies for the KMS key.
|
18463
|
+
#
|
17795
18464
|
# Data integrity
|
17796
18465
|
#
|
17797
18466
|
# : **General purpose bucket** - To ensure that data is not corrupted
|
@@ -17843,12 +18512,13 @@ module Aws::S3
|
|
17843
18512
|
#
|
17844
18513
|
# * x-amz-server-side-encryption-customer-key-MD5
|
17845
18514
|
#
|
17846
|
-
#
|
17847
|
-
#
|
17848
|
-
# supported.
|
18515
|
+
# For more information, see [Using Server-Side Encryption][11] in
|
18516
|
+
# the *Amazon S3 User Guide*.
|
17849
18517
|
#
|
17850
|
-
#
|
17851
|
-
#
|
18518
|
+
# * <b>Directory buckets </b> - For directory buckets, there are only
|
18519
|
+
# two supported options for server-side encryption: server-side
|
18520
|
+
# encryption with Amazon S3 managed keys (SSE-S3) (`AES256`) and
|
18521
|
+
# server-side encryption with KMS keys (SSE-KMS) (`aws:kms`).
|
17852
18522
|
#
|
17853
18523
|
# Special errors
|
17854
18524
|
# : * Error Code: `NoSuchUpload`
|
@@ -18261,6 +18931,10 @@ module Aws::S3
|
|
18261
18931
|
# destination. The `s3express:SessionMode` condition key cannot be
|
18262
18932
|
# set to `ReadOnly` on the copy destination.
|
18263
18933
|
#
|
18934
|
+
# If the object is encrypted with SSE-KMS, you must also have the
|
18935
|
+
# `kms:GenerateDataKey` and `kms:Decrypt` permissions in IAM
|
18936
|
+
# identity-based policies and KMS key policies for the KMS key.
|
18937
|
+
#
|
18264
18938
|
# For example policies, see [Example bucket policies for S3 Express
|
18265
18939
|
# One Zone][10] and [Amazon Web Services Identity and Access
|
18266
18940
|
# Management (IAM) identity-based policies for S3 Express One
|
@@ -18272,9 +18946,26 @@ module Aws::S3
|
|
18272
18946
|
# the `UploadPartCopy` operation, see [CopyObject][12] and
|
18273
18947
|
# [UploadPart][2].
|
18274
18948
|
#
|
18275
|
-
# * <b>Directory buckets </b> - For directory buckets, only
|
18276
|
-
# server-side encryption
|
18277
|
-
# (`AES256`)
|
18949
|
+
# * <b>Directory buckets </b> - For directory buckets, there are only
|
18950
|
+
# two supported options for server-side encryption: server-side
|
18951
|
+
# encryption with Amazon S3 managed keys (SSE-S3) (`AES256`) and
|
18952
|
+
# server-side encryption with KMS keys (SSE-KMS) (`aws:kms`). For
|
18953
|
+
# more information, see [Protecting data with server-side
|
18954
|
+
# encryption][13] in the *Amazon S3 User Guide*.
|
18955
|
+
#
|
18956
|
+
# <note markdown="1"> For directory buckets, when you perform a `CreateMultipartUpload`
|
18957
|
+
# operation and an `UploadPartCopy` operation, the request headers
|
18958
|
+
# you provide in the `CreateMultipartUpload` request must match the
|
18959
|
+
# default encryption configuration of the destination bucket.
|
18960
|
+
#
|
18961
|
+
# </note>
|
18962
|
+
#
|
18963
|
+
# S3 Bucket Keys aren't supported, when you copy SSE-KMS encrypted
|
18964
|
+
# objects from general purpose buckets to directory buckets, from
|
18965
|
+
# directory buckets to general purpose buckets, or between directory
|
18966
|
+
# buckets, through [UploadPartCopy][14]. In this case, Amazon S3
|
18967
|
+
# makes a call to KMS every time a copy request is made for a
|
18968
|
+
# KMS-encrypted object.
|
18278
18969
|
#
|
18279
18970
|
# Special errors
|
18280
18971
|
# : * Error Code: `NoSuchUpload`
|
@@ -18299,17 +18990,17 @@ module Aws::S3
|
|
18299
18990
|
#
|
18300
18991
|
# The following operations are related to `UploadPartCopy`:
|
18301
18992
|
#
|
18302
|
-
# * [CreateMultipartUpload][
|
18993
|
+
# * [CreateMultipartUpload][15]
|
18303
18994
|
#
|
18304
18995
|
# * [UploadPart][2]
|
18305
18996
|
#
|
18306
|
-
# * [CompleteMultipartUpload][
|
18997
|
+
# * [CompleteMultipartUpload][16]
|
18307
18998
|
#
|
18308
|
-
# * [AbortMultipartUpload][
|
18999
|
+
# * [AbortMultipartUpload][17]
|
18309
19000
|
#
|
18310
|
-
# * [ListParts][
|
19001
|
+
# * [ListParts][18]
|
18311
19002
|
#
|
18312
|
-
# * [ListMultipartUploads][
|
19003
|
+
# * [ListMultipartUploads][19]
|
18313
19004
|
#
|
18314
19005
|
#
|
18315
19006
|
#
|
@@ -18325,11 +19016,13 @@ module Aws::S3
|
|
18325
19016
|
# [10]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam-example-bucket-policies.html
|
18326
19017
|
# [11]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam-identity-policies.html
|
18327
19018
|
# [12]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html
|
18328
|
-
# [13]: https://docs.aws.amazon.com/AmazonS3/latest/
|
18329
|
-
# [14]: https://docs.aws.amazon.com/AmazonS3/latest/API/
|
18330
|
-
# [15]: https://docs.aws.amazon.com/AmazonS3/latest/API/
|
18331
|
-
# [16]: https://docs.aws.amazon.com/AmazonS3/latest/API/
|
18332
|
-
# [17]: https://docs.aws.amazon.com/AmazonS3/latest/API/
|
19019
|
+
# [13]: https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-serv-side-encryption.html
|
19020
|
+
# [14]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html
|
19021
|
+
# [15]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateMultipartUpload.html
|
19022
|
+
# [16]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_CompleteMultipartUpload.html
|
19023
|
+
# [17]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_AbortMultipartUpload.html
|
19024
|
+
# [18]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListParts.html
|
19025
|
+
# [19]: https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListMultipartUploads.html
|
18333
19026
|
#
|
18334
19027
|
# @option params [required, String] :bucket
|
18335
19028
|
# The bucket name.
|
@@ -18615,45 +19308,45 @@ module Aws::S3
|
|
18615
19308
|
# * {Types::UploadPartCopyOutput#request_charged #request_charged} => String
|
18616
19309
|
#
|
18617
19310
|
#
|
18618
|
-
# @example Example: To upload a part by copying
|
19311
|
+
# @example Example: To upload a part by copying byte range from an existing object as data source
|
18619
19312
|
#
|
18620
|
-
# # The following example uploads a part of a multipart upload by copying
|
19313
|
+
# # The following example uploads a part of a multipart upload by copying a specified byte range from an existing object as
|
19314
|
+
# # data source.
|
18621
19315
|
#
|
18622
19316
|
# resp = client.upload_part_copy({
|
18623
19317
|
# bucket: "examplebucket",
|
18624
19318
|
# copy_source: "/bucketname/sourceobjectkey",
|
19319
|
+
# copy_source_range: "bytes=1-100000",
|
18625
19320
|
# key: "examplelargeobject",
|
18626
|
-
# part_number:
|
19321
|
+
# part_number: 2,
|
18627
19322
|
# upload_id: "exampleuoh_10OhKhT7YukE9bjzTPRiuaCotmZM_pFngJFir9OZNrSr5cWa3cq3LZSUsfjI4FI7PkP91We7Nrw--",
|
18628
19323
|
# })
|
18629
19324
|
#
|
18630
19325
|
# resp.to_h outputs the following:
|
18631
19326
|
# {
|
18632
19327
|
# copy_part_result: {
|
18633
|
-
# etag: "\"
|
18634
|
-
# last_modified: Time.parse("2016-12-29T21:
|
19328
|
+
# etag: "\"65d16d19e65a7508a51f043180edcc36\"",
|
19329
|
+
# last_modified: Time.parse("2016-12-29T21:44:28.000Z"),
|
18635
19330
|
# },
|
18636
19331
|
# }
|
18637
19332
|
#
|
18638
|
-
# @example Example: To upload a part by copying
|
19333
|
+
# @example Example: To upload a part by copying data from an existing object as data source
|
18639
19334
|
#
|
18640
|
-
# # The following example uploads a part of a multipart upload by copying
|
18641
|
-
# # data source.
|
19335
|
+
# # The following example uploads a part of a multipart upload by copying data from an existing object as data source.
|
18642
19336
|
#
|
18643
19337
|
# resp = client.upload_part_copy({
|
18644
19338
|
# bucket: "examplebucket",
|
18645
19339
|
# copy_source: "/bucketname/sourceobjectkey",
|
18646
|
-
# copy_source_range: "bytes=1-100000",
|
18647
19340
|
# key: "examplelargeobject",
|
18648
|
-
# part_number:
|
19341
|
+
# part_number: 1,
|
18649
19342
|
# upload_id: "exampleuoh_10OhKhT7YukE9bjzTPRiuaCotmZM_pFngJFir9OZNrSr5cWa3cq3LZSUsfjI4FI7PkP91We7Nrw--",
|
18650
19343
|
# })
|
18651
19344
|
#
|
18652
19345
|
# resp.to_h outputs the following:
|
18653
19346
|
# {
|
18654
19347
|
# copy_part_result: {
|
18655
|
-
# etag: "\"
|
18656
|
-
# last_modified: Time.parse("2016-12-29T21:
|
19348
|
+
# etag: "\"b0c6f0e7e054ab8fa2536a2677f8734d\"",
|
19349
|
+
# last_modified: Time.parse("2016-12-29T21:24:43.000Z"),
|
18657
19350
|
# },
|
18658
19351
|
# }
|
18659
19352
|
#
|
@@ -19115,7 +19808,7 @@ module Aws::S3
|
|
19115
19808
|
tracer: tracer
|
19116
19809
|
)
|
19117
19810
|
context[:gem_name] = 'aws-sdk-s3'
|
19118
|
-
context[:gem_version] = '1.
|
19811
|
+
context[:gem_version] = '1.163.0'
|
19119
19812
|
Seahorse::Client::Request.new(handlers, context)
|
19120
19813
|
end
|
19121
19814
|
|