thousands-gold-60287
11/17/2022, 2:41 PMaws s3 cp hi.txt <s3://bucket-name/hi.txt> --sse aws:kms --sse-kms-key-id alias/my-key
And an example for boto3 to give you the idea:
s3.Object(BUCKET_NAME, "tmp/hi.txt").put(Body=b"Hi!", ServerSideEncryption="aws:kms", SSEKMSKeyId=KMS_KEY_ID)
My use case: I’m using Metaflow with AWS and my company’s policy requires all S3 buckets to have object-level encryption via a customer managed KMS key.average-beach-28850
11/17/2022, 4:24 PMaverage-beach-28850
11/17/2022, 4:25 PMthousands-gold-60287
11/21/2022, 9:03 AMaverage-beach-28850
11/22/2022, 11:51 PM