Overview
CloudTrail records every API call made in your AWS account. Atatus reads those records directly from the S3 bucket your trail already writes to, so there is nothing to change about how CloudTrail itself is configured. Once flowing, CloudTrail events are analysed by the built-in AWS detection rules, such as console logins without MFA, IAM policy changes, S3 bucket policy modifications, access-denied bursts, root account activity, and more.Collection starts from the moment you set it up. Objects already in the
bucket are not ingested, so a trail holding years of history costs
you nothing.
Requirements
Run the agent on one machine only. An EC2 instance is easiest, because it
can use an instance role instead of long-lived access keys.
Collection modes
Choose one.
With SQS, a notification only exists for objects created after you set it
up, so old logs are unreachable rather than filtered out.
Step 1: Create the SQS queue (Mode A only)
Skip this section if you are using bucket polling.queue-policy.json:
notification.json:
S3 sends a single
s3:TestEvent message when the notification
is created. The agent consumes and discards it, so no action is needed.Step 2: Create the IAM policy
The agent needs read access to the bucket, plus queue access in Mode A.Mode A: SQS notifications
Mode B: bucket polling
Attaching the policy
On EC2 (recommended): attach the policy to the instance role of the machine running the agent. Nothing else to configure; the agent picks the role up automatically. Anywhere else: create an IAM user, attach the policy, and generate an access key:AccessKeyId and SecretAccessKey from the output. You will need
them in the next step.
Step 3: Configure the agent
Create/etc/atatus-infra-agent/conf.d/s3.d/s3.yml.
One file covers every AWS log family delivered to S3, and source: picks the
family. CloudTrail is shown here; VPC Flow Logs
use the same file with source: vpc_flow.
The file must end in
.yml. Files with any other extension are
ignored without warning.Mode A: SQS notifications
Mode B: bucket polling
Using access keys
If the machine has no instance role, add the credentials to the stanza:Omit both keys entirely to use the standard AWS credential chain:
environment variables, shared config, then the EC2/ECS instance role. Where
the agent runs inside AWS this is the better option, because it keeps
long-lived keys off disk.
Reading a bucket in another AWS account
If the bucket belongs to a different AWS account than the credentials above, add a role instead of asking that account for a user key:sts:AssumeRole), and
everything else is read with the temporary credentials the role returns.
See Reading an S3 bucket in another AWS account
for the role, the two IAM policies, and how to verify it before restarting the
agent.
Same account? You do not need a role. Attach the policy from Step 2 to your
user or instance role and skip this.
Step 4: Restart and verify
dataSource: cloudtrail.
Configuration reference
queue_url and bucket_arn are mutually exclusive, so set one, not both.
Send to Logs instead of SIEM
By default CloudTrail records become security events and run through the detection rules. To keep them as ordinary searchable logs instead:How it behaves
- Only new logs are collected. Collection begins when the agent first
starts with this configuration. To deliberately backfill a known window, set
start_timestamp: "2026-08-01T00:00:00Z". - Restarts are safe. The agent records which objects it has already sent, so restarting the agent or rebooting the machine never re-sends them.
- Multiple accounts and regions in a single bucket are picked up automatically, so you do not list them.
- Digest files (
CloudTrail-Digest/) are skipped; they hold integrity metadata, not events.
Troubleshooting
Errors appear in the agent log at/var/log/atatus-infra-agent/.
The agent logs
first successful delivery once per endpoint
when data first reaches Atatus. If you never see that line, the problem is
upstream of the network, so check the listing and filter messages above.