This rule ensures that all S3 buckets are logging S3 data events in CloudTrail.
Rule | All S3 buckets should log S3 data events in CloudTrail |
Framework | NIST 800-53 Revision 5 |
Severity | ✔ Medium |
Rule Description
This rule ensures that all S3 buckets within an AWS account enable logging of S3 data events in CloudTrail, in accordance with the NIST (National Institute of Standards and Technology) 800-53 Revision 5 security guidelines.
Enabling CloudTrail logging for S3 data events provides a comprehensive audit trail of all actions performed on S3 buckets, such as object-level API operations, bucket-level operations, and permission changes. This helps capture key information for security analysis, compliance audits, and incident response.
Troubleshooting Steps
Necessary Codes
There are no specific codes needed to enforce this rule. Instead, the following are the remediation steps to enable S3 bucket logging in CloudTrail.
Remediation Steps
Open the AWS Management Console and navigate to the CloudTrail service.
Click on the specific trail associated with the AWS account where the S3 bucket resides.
Within the trail details page, click on the "Edit" button.
Scroll down to the "Management events" section and ensure that the "Read/Write events" checkbox is selected.
Scroll further down to the "Data events" section and enable logging for S3 by selecting the "All S3 data events" checkbox.
Choose the S3 bucket log file prefix, which is the path in the S3 bucket where the log files are stored. You can use a custom prefix or choose the default option.
Click the "Save" button to save the changes.
Verification
To verify if the S3 bucket is successfully logging data events in CloudTrail, follow these steps:
Open the AWS Management Console and navigate to the CloudTrail service.
Select the specific trail associated with the AWS account where the S3 bucket resides.
In the trail details page, click on the "Event history" tab.
Use the filter option to narrow down the displayed events by selecting the specific S3 bucket and the desired time range.
Review the listed events to ensure that the required S3 data events are being logged.
If there are no events listed or if the required events are missing, review the troubleshooting steps mentioned earlier to identify and resolve any issues.