An enterprise manages a multi-account environment using AWS Organizations. The transaction workloads run on Amazon ECS on AWS Fargate across several member accounts, with application containers sending log events to local Amazon CloudWatch log groups. To comply with security audits, the enterprise must aggregate all member account AWS CloudTrail trails into a centralized Amazon S3 bucket in a dedicated security account. Additionally, all application logs must be streamed in real-time to an Amazon OpenSearch Service domain located in the security account. Currently, cross-account CloudTrail logs are failing to deliver to the S3 bucket, and application logs remain isolated within their local member accounts. Which combination of actions will securely centralize both the CloudTrail logs and the application logs with the least operational overhead? (Select TWO.)
- In the security account, configure the centralized S3 bucket policy to allow the `s3:PutObject` action for the `cloudtrail.amazonaws.com` service principal, and include a condition that checks `aws:PrincipalOrgID` to match the enterprise's Organization ID.Cevap
- BIn the security account, configure the S3 bucket policy to grant `s3:PutObject` directly to the root IAM ARNs of all member accounts, and enable default bucket encryption using the AWS-managed KMS key `aws/s3` while granting the member accounts cross-account access to the key.
- In the security account, create an Amazon Kinesis Data Stream and a CloudWatch Logs destination pointing to it. Configure the destination's access policy to allow `logs:PutSubscriptionFilter` from the Organization, and create an IAM role trusted by `logs.amazonaws.com` to write to the stream. In the member accounts, create CloudWatch Logs subscription filters targeting the centralized destination.Cevap
- DIn the security account, modify the S3 bucket policy to allow `s3:PutObject` only to the parent AWS Organization's root account ID, and in the member accounts, update the CloudTrail trail configuration to use the S3 bucket's regional endpoint directly without the `cloudtrail.amazonaws.com` service principal in the bucket policy.
- EIn the member accounts, configure the CloudWatch agent on the Fargate tasks to ship logs directly to the security account's S3 bucket by modifying the agent's configuration file to use static log file paths. Associate an IAM role with the task execution role that has a trust relationship allowing the security account's root user to write objects to the S3 bucket.