Creates a session that establishes temporary security credentials to support fast authentication and authorization for the Zonal endpoint API operations on directory buckets
Source:R/s3_operations.R
s3_create_session.RdCreates a session that establishes temporary security credentials to support fast authentication and authorization for the Zonal endpoint API operations on directory buckets. For more information about Zonal endpoint API operations that include the Availability Zone in the request endpoint, see S3 Express One Zone APIs in the Amazon S3 User Guide.
See https://www.paws-r-sdk.com/docs/s3_create_session/ for full documentation.
Usage
s3_create_session(
SessionMode = NULL,
Bucket,
ServerSideEncryption = NULL,
SSEKMSKeyId = NULL,
SSEKMSEncryptionContext = NULL,
BucketKeyEnabled = NULL
)Arguments
- SessionMode
Specifies the mode of the session that will be created, either
ReadWriteorReadOnly. If no session mode is specified, the default behavior attempts to create a session with the maximum allowable privilege. It will first attempt to create aReadWritesession, and if that is not allowed by permissions, it will attempt to create aReadOnlysession. If neither session type is allowed, the request will return an Access Denied error. AReadWritesession is capable of executing all the Zonal endpoint API operations on a directory bucket. AReadOnlysession is constrained to execute the following Zonal endpoint API operations:get_object,head_object,list_objects_v2,get_object_attributes,list_parts, andlist_multipart_uploads.- Bucket
[required] The name of the bucket that you create a session for.
- ServerSideEncryption
The server-side encryption algorithm to use when you store objects in the directory bucket.
For directory buckets, there are only two supported options for server-side encryption: server-side encryption with Amazon S3 managed keys (SSE-S3) (
AES256) and server-side encryption with KMS keys (SSE-KMS) (aws:kms). By default, Amazon S3 encrypts data with SSE-S3. For more information, see Protecting data with server-side encryption in the Amazon S3 User Guide.S3 access points for Amazon FSx - When accessing data stored in Amazon FSx file systems using S3 access points, the only valid server side encryption option is
aws:fsx. All Amazon FSx file systems have encryption configured by default and are encrypted at rest. Data is automatically encrypted before being written to the file system, and automatically decrypted as it is read. These processes are handled transparently by Amazon FSx.- SSEKMSKeyId
If you specify
x-amz-server-side-encryptionwithaws:kms, you must specify thex-amz-server-side-encryption-aws-kms-key-idheader with the ID (Key ID or Key ARN) of the KMS symmetric encryption customer managed key to use. Otherwise, you get an HTTP400 Bad Requesterror. Only use the key ID or key ARN. The key alias format of the KMS key isn't supported. Also, if the KMS key doesn't exist in the same account that't issuing the command, you must use the full Key ARN not the Key ID.Your SSE-KMS configuration can only support 1 customer managed key per directory bucket's lifetime. The Amazon Web Services managed key (
aws/s3) isn't supported.- SSEKMSEncryptionContext
Specifies the Amazon Web Services KMS Encryption Context as an additional encryption context to use for object encryption. The value of this header is a Base64 encoded string of a UTF-8 encoded JSON, which contains the encryption context as key-value pairs. This value is stored as object metadata and automatically gets passed on to Amazon Web Services KMS for future
get_objectoperations on this object.General purpose buckets - This value must be explicitly added during
copy_objectoperations if you want an additional encryption context for your object. For more information, see Encryption context in the Amazon S3 User Guide.Directory buckets - You can optionally provide an explicit encryption context value. The value must match the default encryption context - the bucket Amazon Resource Name (ARN). An additional encryption context value is not supported.
- BucketKeyEnabled
Specifies whether Amazon S3 should use an S3 Bucket Key for object encryption with server-side encryption using KMS keys (SSE-KMS).
S3 Bucket Keys are always enabled for
GETandPUToperations in a directory bucket and can’t be disabled. S3 Bucket Keys aren't supported, when you copy SSE-KMS encrypted objects from general purpose buckets to directory buckets, from directory buckets to general purpose buckets, or between directory buckets, throughcopy_object,upload_part_copy, the Copy operation in Batch Operations, or the import jobs. In this case, Amazon S3 makes a call to KMS every time a copy request is made for a KMS-encrypted object.