A financial company hosts an application that stores sensitive transaction reports in an Amazon S3 bucket. To comply with data protection regulations, the objects are encrypted using the default AWS-managed KMS key (aws/s3). The company now needs to grant read-only access to these S3 objects to an external auditing team operating in a separate AWS account. The external team is currently blocked when attempting to read the objects, despite having the correct S3 permissions. Which of the following is the most appropriate action to resolve this issue and securely allow cross-account access?
- Create a customer managed KMS key, re-encrypt the S3 objects using this new key, and update its key policy to grant the external AWS account's role permission to use the key.Cevap
- BModify the key policy of the default AWS-managed KMS key (aws/s3) to grant decrypt permissions to the IAM role used by the external auditing team.
- CCreate a Service Control Policy (SCP) at the root level of the AWS Organization that allows the external account's role to access the default AWS-managed KMS key (aws/s3).
- DAdd a statement to the S3 bucket policy in the source account that delegates kms:Decrypt permissions to the external account principal for the default AWS-managed KMS key (aws/s3).
Cevap
Create a customer managed KMS key, re-encrypt the S3 objects using this new key, and update its key policy to grant the external AWS account's role permission to use the key.
For cross-account access to encrypted S3 objects, the external role must have permissions on the S3 bucket and decrypt permissions on the KMS key. Because default AWS-managed KMS keys (aws/s3) cannot be shared across accounts and their key policies cannot be modified, a customer managed key must be used. Re-encrypting the objects with a customer managed KMS key and allowing the external account's IAM role in its key policy successfully solves the issue.
Adım Adım Çözüm
Anahtar Kavram
Cross-account AWS KMS access rules and limitations of default AWS-managed KMS keys.
Tahmini Süre:1m 0s