During an incident response engagement for a FinTech startup, the security team detected anomalous compute billing spikes in the AWS us-east-1 region. Several expensive EC2 instances (c5.24xlarge) were deployed outside of standard CI/CD pipelines, strongly indicating a crypto-jacking compromise.
Forensics investigators have acquired the relevant AWS CloudTrail log archives from the organization's dedicated security logging account to trace the origin of the unauthorized API calls and identify the compromised credentials.
userIdentity element contains details about the principal that made the request. In cloud forensics, this is the primary field analyzed to extract the IAM user name, AWS Account ID, access key ID, and ARN responsible for an action.
eventSource field identifies the specific AWS service that the request was made to (e.g., ec2.amazonaws.com). It does not provide any information regarding the identity of the user initiating the action.
responseElements field logs the response provided by the AWS service after executing the API call (such as the generated instanceId of the newly spun-up EC2). It does not contain the identity of the requester.
requestParameters field logs the parameters sent in the API request payload, such as the instanceType or imageId (AMI) requested. It dictates *what* is being built, not *who* is building it.
The CloudTrail log clearly records a RunInstances event executed by an IAM User named dev-admin-jdoe using the access key AKIAIOSFODNN7EXAMPLE. The request originated from an external IP (198.51.100.42) to spin up five heavy-compute (c5.24xlarge) resources.
This task is part of the Analysis phase, specifically focusing on Cloud Environments and Log Correlation.
A. userIdentity: In AWS CloudTrail architecture, identity attribution is strictly maintained within the userIdentity JSON block. Whether the actor is a root user, an IAM user, an assumed role (STS), or an AWS service, this block holds the principal ID, ARN, and credentials utilized, establishing the digital equivalent of a "suspect profile" in cloud investigations.
Upon identifying the compromised identity within userIdentity, a forensic investigator would execute a timeline analysis filtering CloudTrail logs by that specific accessKeyId or arn. The immediate incident response action would be to revoke the access key, attach an explicit "Deny All" policy to the user, and search for potential persistence mechanisms (e.g., creating new IAM users) executed by that identity.
In cloud forensics, investigators cannot physically seize a server. Logs are the primary evidence. To maintain the Chain of Custody and ensure non-repudiation, CloudTrail logs should always be stored in an isolated, restricted S3 bucket in a separate AWS Account, with Multi-Factor Authentication (MFA) Delete enabled and CloudTrail Log File Validation turned on. This proves mathematically (via SHA-256) that the JSON logs have not been tampered with since AWS wrote them.
Enhance your digital forensics expertise with full-length CHFI practice scenarios.
Explore more CHFI simulations