Security wants to know who deleted a production S3 bucket yesterday. How do you find out?
BeginnerScenarioIAM, Organizations and Multi-Account
Answer
Situation read → This is a CloudTrail question; bucket deletion is a management event, recorded by default for 90 days.
What I'd do →
- Open CloudTrail Event history and filter on Event name
DeleteBucket - Or CLI:
aws cloudtrail lookup-events --lookup-attributes AttributeKey=EventName,AttributeValue=DeleteBucket - Read
userIdentity,sourceIPAddressanduserAgentto identify the principal - For longer history query the trail's S3 logs with Athena
Why → Event history only covers 90 days of management events in one region view, so an organization trail to S3 is what actually keeps the evidence.
Interview tip → Distinguish management events from data events (object-level), which are off by default.
More on IAM, Organizations and Multi-Account
A developer needs read-only access to one S3 bucket from their laptop. How do you grant it without creating long-lived access keys?BeginnerAn EC2 application needs to write to DynamoDB. Where do the credentials come from?BeginnerYou must stop anyone in a member account from disabling CloudTrail, even account admins. What do you use?BeginnerA cross-account role assumption fails with AccessDenied even though the target role trusts the source account. What do you check?IntermediateDesign access for a CI pipeline in GitHub Actions to deploy to AWS without storing AWS keys in GitHub.IntermediateHow would you let developers create IAM roles for their apps without letting them escalate to admin?Intermediate