Skip to content

Commit 31f6170

Browse files
imays11Mikaayenson
andauthored
Apply suggestions from code review
Co-authored-by: Mika Ayenson, PhD <[email protected]>
1 parent a2bee33 commit 31f6170

File tree

1 file changed

+12
-3
lines changed

1 file changed

+12
-3
lines changed

rules/integrations/aws/discovery_multiple_discovery_api_calls_via_cli.toml

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,15 @@ tags = [
116116
"Data Source: AWS EC2",
117117
"Data Source: AWS IAM",
118118
"Data Source: AWS S3",
119+
"Data Source: AWS Cloudtrail",
120+
"Data Source: AWS RDS",
121+
"Data Source: AWS Lambda",
122+
"Data Source: AWS STS",
123+
"Data Source: AWS KMS",
124+
"Data Source: AWS SES",
125+
"Data Source: AWS Cloudfront",
126+
"Data Source: AWS DynamoDB",
127+
"Data Source: AWS Elastic Load Balancing",
119128
"Use Case: Threat Detection",
120129
"Tactic: Discovery",
121130
"Resources: Investigation Guide",
@@ -124,7 +133,7 @@ timestamp_override = "event.ingested"
124133
type = "esql"
125134

126135
query = '''
127-
from logs-aws.cloudtrail* metadata _id, _version, _index
136+
from logs-aws.cloudtrail-* metadata _id, _version, _index
128137
// create time window buckets of 10 seconds
129138
| eval Esql.time_window_date_trunc = date_trunc(10 seconds, @timestamp)
130139
@@ -150,7 +159,7 @@ from logs-aws.cloudtrail* metadata _id, _version, _index
150159
// filter for aws-cli specifically
151160
and user_agent.name == "aws-cli"
152161
// exclude DescribeCapacityReservations events related to AWS Config
153-
and not event.action in ("DescribeCapacityReservations")
162+
and event.action != "DescribeCapacityReservations"
154163
155164
// filter for Describe, Get, List, and Generate API calls
156165
| where true in (
@@ -220,7 +229,7 @@ field_names = [
220229
"Esql.event_action_count_distinct",
221230
"Esql.time_window_date_trunc",
222231
"aws.cloudtrail.user_identity.arn",
223-
"Esql.aws_cloudtrail_user_identity_arn_type_values",
232+
"Esql.aws_cloudtrail_user_identity_type_values",
224233
"Esql.aws_cloudtrail_user_identity_access_key_id_values",
225234
"Esql.source_ip_values",
226235
"Esql.source_as_organization_name_values",

0 commit comments

Comments
 (0)