Question 1
SDLC AutomationA CodePipeline pipeline in a tools account deploys a CloudFormation stack to a production account through a cross-account role. The artifact bucket uses the AWS managed aws/s3 key, and the deploy action fails because the production role cannot read the input artifact. Which change fixes this?
Show the answer
Correct answerB. Use a customer managed KMS key for the artifact store whose key policy lets the production role decrypt, and allow that role in the bucket policy.
AWhy not this: The bucket policy alone is not enough: the aws/s3 key's policy cannot grant the production role permission to decrypt.
BWhy this is right: A customer managed key's policy can let the production role decrypt artifacts, and the bucket policy lets it read them.
CWhy not this: The deploy action reads artifacts from the pipeline's artifact store, so a replica in another bucket does not supply them.
DWhy not this: The pipeline's service role assumes the production role; the trust must be on the production role, and it does not fix decryption.
Cross-account pipeline actions need a customer managed KMS key for the artifact store, because an AWS managed key's policy cannot be changed to let another account decrypt. The key policy and the bucket policy must both allow the production role.