A solutions architect is designing an integration where an application running on Amazon EC2 instances in Account A must read encrypted objects from an Amazon S3 bucket in Account B. The objects are encrypted using Server-Side Encryption with AWS KMS (SSE-KMS). Which key configuration will successfully allow the application in Account A to decrypt the objects?
- Use a Customer Managed Key in Account B, and configure its key policy to grant the IAM role in Account A decrypt permissions.Cevap
- BUse the AWS-managed key for Amazon S3 (aws/s3) in Account B, and configure the S3 bucket policy in Account B to grant decrypt permissions to Account A.
- CUse the AWS-managed key for Amazon S3 (aws/s3) in Account B, and apply a Service Control Policy (SCP) at the Organization root to grant cross-account access.
- DUse a Customer Managed Key in Account B, and configure only the S3 bucket policy in Account B to grant access to Account A without updating the KMS key policy.
Cevap
Use a Customer Managed Key in Account B, and configure its key policy to grant the IAM role in Account A decrypt permissions.
Using a Customer Managed Key (CMK) in Account B allows you to modify its key policy. In a cross-account scenario, the key policy of the CMK in the owning account (Account B) must explicitly grant decrypt permissions to the principal (IAM role) in the reading account (Account A). The role in Account A also needs the corresponding IAM permissions to call the KMS Decrypt action.
Adım Adım Çözüm
Anahtar Kavram
Cross-account KMS key sharing requires a Customer Managed Key with a key policy that delegates access to the external account, along with matching local IAM permissions in the external account.
Tahmini Süre:1m 0s