Courseiva

Real-Time Monitoring of CloudTrail Events

A security analyst needs to detect and alert on suspicious API calls in real time. Which combination of AWS services should be used?

Quick Answer

The correct combination is AWS CloudTrail, Amazon CloudWatch Logs, and Amazon EventBridge. This pipeline works because CloudTrail captures every API call made within your AWS account and streams those events to CloudWatch Logs, where you can define metric filters that match suspicious patterns—such as unauthorized access attempts or changes to security group rules. EventBridge then consumes those filtered log events as a rule target, enabling real-time alerts via SNS or automated remediation through Lambda functions. On the SCS-C02 exam, this scenario tests your understanding of building a real-time monitoring of CloudTrail events pipeline without relying on third-party tools; a common trap is choosing CloudTrail alone with S3, which introduces latency and cannot trigger immediate actions. Remember the mnemonic “CLE” for Capture, Log, and Event—CloudTrail captures, CloudWatch Logs filters, and EventBridge executes.

⚠ Common exam trap

A common mix-up: candidates assume GuardDuty alone can provide real-time API call alerts, but GuardDuty findings are based on aggregated threat intelligence and behavioral analysis, not real-time per-API-call filtering, whereas CloudTrail plus CloudWatch Logs plus EventBridge gives you precise, real-time control over specific API actions.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

✓

AWS CloudTrail, Amazon CloudWatch Logs, and Amazon EventBridge.

AWS CloudTrail captures API calls and delivers log files to Amazon CloudWatch Logs, where you can define metric filters to detect suspicious patterns. Amazon EventBridge then consumes those filtered log events to trigger real-time alerts or automated remediation actions. This combination provides the end-to-end pipeline needed for real-time detection and alerting on API activity.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • ✓

    AWS CloudTrail, Amazon CloudWatch Logs, and Amazon EventBridge.

    Why this is correct

    CloudTrail records API activity, CloudWatch Logs stores those events, and EventBridge filters them in near real time to trigger alerts. This satisfies the requirement to detect suspicious API calls as they occur, rather than relying on periodic batch analysis or delayed log review.

  • ✗

    Amazon Inspector and AWS CloudTrail.

    Why it's wrong here

    Amazon Inspector assesses EC2, ECR images and Lambda for vulnerabilities; it does not analyse API activity, and CloudTrail alone only records events without generating the required real-time alerts. It is tempting because both services are security-related, and CloudTrail would be correct if paired with a detection service such as Amazon GuardDuty.

  • ✗

    Amazon GuardDuty and AWS Lambda.

    Why it's wrong here

    GuardDuty generates findings from CloudTrail management events, but its detection latency is minutes, not real time, and it cannot inspect data-plane API calls. Lambda only reacts to those findings. CloudWatch Logs metric filters with alarms on CloudTrail deliver the near-real-time alerting the scenario demands.

  • ✗

    AWS Config and Amazon SNS.

    Why it's wrong here

    AWS Config records resource configuration changes and evaluates compliance rules; it does not analyse API call patterns or detect malicious activity, so no suspicious-call finding is ever produced. Config with SNS suits alerting on configuration drift or non-compliant resources, not real-time threat detection.

About these practice questions

Courseiva writes every SCS-C02 question from scratch — 1,205 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

Same concept, more angles

4 more ways this is tested on SCS-C02

These questions test the same concept from different angles. Work through them to make sure you can recognise it however the exam phrases it.

Variation 1. A company uses AWS CloudTrail to log all API activity. The security team wants to detect when an IAM user creates an access key for another user, which is a potential privilege escalation. Which TWO actions should the team take to set up this detection?

hard
  • A.Create an AWS Config managed rule to detect CreateAccessKey calls.
  • ✓ B.Create a CloudWatch alarm based on the metric filter.
  • ✓ C.Create a CloudWatch Logs metric filter that matches the event CreateAccessKey.
  • D.Use Amazon EventBridge to create a rule that matches the CloudTrail event and triggers an AWS Lambda function.
  • E.Enable Amazon GuardDuty and create a custom threat list.

Why B: Option C is correct because CloudTrail delivers API activity to a CloudWatch Logs log group, and a metric filter with a filter pattern matching the eventName "CreateAccessKey" converts those log events into a numeric CloudWatch metric that can be alarmed on. Option B is correct because a CloudWatch alarm on that metric filter's metric fires when the metric crosses the threshold, which is the standard way to detect and notify on the specific CreateAccessKey activity. Option A is not appropriate because AWS Config managed rules evaluate resource configuration compliance, not individual API calls. Option D is not correct for this two-action pair because an EventBridge rule that triggers a Lambda function is a separate single-step alternative, not one of the two actions needed in the CloudWatch Logs metric filter and alarm setup. Option E is wrong because GuardDuty custom threat lists are for IP addresses and domains, not for detecting specific IAM API calls.

Variation 2. A security analyst notices an IAM role 'AdminRole' is being assumed from an IP address outside the company's allowed network. The analyst wants to receive real-time alerts when this role is assumed from unauthorized locations. Which combination of services should be used?

hard
  • A.AWS CloudTrail, Amazon S3, and Amazon Athena
  • B.AWS Config, Amazon SNS, and AWS Lambda
  • C.Amazon GuardDuty and AWS Lambda
  • ✓ D.AWS CloudTrail, Amazon CloudWatch Events, and Amazon SNS

Why D: AWS CloudTrail logs IAM role assumption events (sts:AssumeRole) as CloudTrail events, which can be sent to Amazon CloudWatch Events (now Amazon EventBridge) as a real-time event stream. CloudWatch Events rules can then match specific patterns (e.g., source IP outside allowed ranges) and trigger an Amazon SNS notification to alert the security analyst immediately. This combination provides the real-time alerting required without additional polling or storage.

Variation 3. A security team wants to detect and alert on API calls that create or modify IAM roles in their AWS account. Which AWS service can be used to create a metric filter and alarm for these specific CloudTrail events?

easy
  • A.Amazon GuardDuty
  • B.AWS CloudTrail
  • ✓ C.Amazon CloudWatch Logs
  • D.AWS Config

Why C: Amazon CloudWatch Logs can create metric filters on CloudTrail log data to detect specific API calls, such as CreateRole or UpdateAssumeRolePolicy. These metric filters can then trigger CloudWatch alarms for real-time notification. CloudTrail delivers logs to CloudWatch Logs, but the metric filter and alarm capabilities reside in CloudWatch Logs, not in CloudTrail itself.

Variation 4. A security engineer needs to detect and alert on suspicious API calls made from a compromised EC2 instance. The instance is associated with an IAM role that has permissions to call various AWS APIs. Which AWS service should the engineer use to monitor API calls and trigger alerts?

medium
  • A.Amazon GuardDuty
  • ✓ B.AWS CloudTrail combined with Amazon CloudWatch Events
  • C.AWS Config
  • D.VPC Flow Logs

Why B: AWS CloudTrail records all API calls made by or on behalf of the EC2 instance's IAM role. By sending these logs to Amazon CloudWatch Events (now Amazon EventBridge), you can create rules that match specific API actions (e.g., 'ec2:TerminateInstances') and trigger alerts via SNS, Lambda, or other targets. This combination provides real-time monitoring and alerting for suspicious API activity from a compromised instance.

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This SCS-C02 practice question is part of Courseiva's free Amazon Web Services certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the SCS-C02 exam.