A global logistics corporation uses AWS Organizations with multiple member accounts. Security analysts must authenticate using the company's on-premises SAML 2.0 Identity Provider (IdP) to assume an IAM role named SecurityAuditorRole in a centralized Identity account (). From this role, the analysts run query analyses using Amazon Athena on regulatory compliance logs stored in an Amazon S3 bucket within a separate Security Logging account (). The S3 bucket requires all objects to be encrypted at rest using server-side encryption with AWS KMS (SSE-KMS). Which combination of configurations must a solutions architect implement to securely grant the security analysts the access required to retrieve and decrypt the logs?
- AIn the Identity account, configure the trust policy of SecurityAuditorRole to allow the sts:AssumeRole action from the SAML provider. Attach an IAM policy to SecurityAuditorRole that allows s3:GetObject on the S3 bucket and kms:Decrypt on a Customer Managed Key (CMK) in the Security Logging account. In the Security Logging account, configure the S3 bucket policy to allow s3:GetObject for the SecurityAuditorRole ARN, and configure the CMK's key policy to allow kms:Decrypt for the SecurityAuditorRole ARN.
- BIn the Identity account, configure the trust policy of SecurityAuditorRole to allow the sts:AssumeRoleWithSAML action from the SAML provider. Attach an IAM policy to SecurityAuditorRole that allows s3:GetObject on the S3 bucket and kms:Decrypt on the AWS managed key (aws/s3) in the Security Logging account. In the Security Logging account, configure the S3 bucket policy to allow s3:GetObject for the SecurityAuditorRole ARN.
- In the Identity account, configure the trust policy of SecurityAuditorRole to allow the sts:AssumeRoleWithSAML action from the SAML provider. Attach an IAM policy to SecurityAuditorRole that allows s3:GetObject on the S3 bucket and kms:Decrypt on a Customer Managed Key (CMK) in the Security Logging account. In the Security Logging account, configure the S3 bucket policy to allow s3:GetObject for the SecurityAuditorRole ARN, and configure the CMK's key policy to allow kms:Decrypt for the SecurityAuditorRole ARN.Answer
- DIn the Identity account, configure the trust policy of SecurityAuditorRole to allow the sts:AssumeRoleWithSAML action from the SAML provider. In the AWS Organizations management account, attach a Service Control Policy (SCP) to the Organizational Unit (OU) containing both accounts that explicitly permits the SecurityAuditorRole ARN to perform s3:GetObject on the S3 bucket and kms:Decrypt on the KMS key in the Security Logging account.
Answer
In the Identity account, configure the trust policy of SecurityAuditorRole to allow the sts:AssumeRoleWithSAML action from the SAML provider. Attach an IAM policy to SecurityAuditorRole that allows s3:GetObject on the S3 bucket and kms:Decrypt on a Customer Managed Key (CMK) in the Security Logging account. In the Security Logging account, configure the S3 bucket policy to allow s3:GetObject for the SecurityAuditorRole ARN, and configure the CMK's key policy to allow kms:Decrypt for the SecurityAuditorRole ARN.
The correct configuration uses the sts:AssumeRoleWithSAML action in the IAM role's trust policy to support federation from the SAML IdP. It encrypts the target S3 bucket with a Customer Managed Key (CMK) to allow modification of its key policy. It then configures cross-account access by granting outbound permissions in the source IAM role policy and inbound permissions in both the target S3 bucket policy and the target KMS key policy.
Step-by-Step Solution
Key Concept
Cross-account access delegation with SAML federation and custom KMS key policies