More Info:

All AWS CloudTrail configuration changes should be monitored using CloudWatch alarms.

Risk Level

Medium

Address

Security

Compliance Standards

CISAWSF, PCI, GDPR, APRA, MAS, NIST4, SOC2, HIPAA, ISO27001, NISTCSF

Triage and Remediation

Remediation

Here are the step-by-step instructions to remediate the CloudTrail Changes Alarm misconfiguration in AWS using the AWS console:

  1. Sign in to your AWS account and navigate to the CloudWatch service.

  2. In the left-hand menu, select “Logs”.

  3. Select the log group created for your CloudTrail trail event logs and click on the “Create Metric Filter” button.

  4. On the Define Logs Metric Filter page, in the Filter Pattern box, enter the following pattern:

{ ($.eventName = CreateTrail) || ($.eventName = UpdateTrail) || ($.eventName = DeleteTrail) || ($.eventName = StartLogging) || ($.eventName = StopLogging) }

This pattern monitors CloudTrail for changes like creating, updating, or deleting trails.

  1. Review the metric filter details and click Assign Metric.

  2. On the next page, provide the following details:

    • Filter Name: Enter a name like AWSCloudTrailChanges.
    • Metric Namespace: Enter CloudTrailMetrics.
    • Metric Name: Enter CloudTrailEventCount.
    • Click Show advanced metric settings, and in the Metric Value box, enter 1.
  3. Review the details and click Create Filter.

  4. Now, click Create Alarm for the filter created in the previous step.

  5. In the Create Alarm dialog, configure the following:

    • Alarm Name: Enter CloudTrail Changes.
    • Threshold: Set the threshold value to 1 (greater than or equal to 1).
    • Actions: Click the + Notification button, select State is ALARM, and choose an SNS topic for notifications.
    • Period: Select 5 Minutes from the dropdown.
    • Statistic: Set to Sum.
  6. Review the configuration and click Create Alarm to finalize.

That’s it! You have successfully remediated the CloudTrail Changes Alarm misconfiguration in AWS using the AWS console.

Additional Reading: