Detection rules › Panther
Query.EC2.CRUD.Activity.Useragent
This is a threat-hunting query, not an automated detection. It surfaces activity for an analyst to review rather than firing on a match. It is searchable for reference but is excluded from the detection-rule browse and the ATT&CK coverage matrix.
This query searches for CRUD activity in EC2 by userAgent. A low count or previously unseen useragent may indicate that the action was not performed by an automated process.
Rules detecting the same action
Other rules on this platform that filter on the same API call or operation.
- AWS Discovery API Calls via CLI from a Single Resource (Elastic)
- Query.EC2.CRUD.Activity.Role (Panther)
- Sensitive API Calls Via VPC Endpoint (Panther)
Rule body yaml
AnalysisType: scheduled_query
QueryName: "Query.EC2.CRUD.Activity.Useragent"
Enabled: false
Description: >
This query searches for CRUD activity in EC2 by userAgent. A low count or previously unseen useragent may indicate that the action was not performed by an automated process.
Query: |
SELECT
count(*) as num_logs,
recipientAccountId,
userAgent,
eventName,
eventSource
FROM panther_logs.public.aws_cloudtrail
WHERE
eventSource = 'ec2.amazonaws.com'
AND eventName LIKE '%Image%'
AND eventName NOT LIKE '%Describe%'
AND p_occurs_since('3 day')
GROUP BY recipientAccountId, userAgent, eventName, eventSource
ORDER BY recipientAccountId, count(*), userAgent
Schedule:
RateMinutes: 1440
TimeoutMinutes: 20
Detection logic
Stage 1: source
panther_logs.public.aws_cloudtrail
Stage 2: filter
eventSource eq "ec2.amazonaws.com"
eventName wildcard "*Image*"
eventName not wildcard "*Describe*"
Exclusions
Top-level NOT(...) conjuncts: predicates this rule actively suppresses.
| Field | Kind | Excluded values |
|---|---|---|
eventName | match | Describe |
Indicators
Each row is a field, operator, and value that the rule matches. The corpus column counts how many other rules in the catalog look for the same combination: high numbers point to widely-used, community-vetted indicators. Blank or 1 shows that the indicator is specific to this rule.
| Field | Kind | Values |
|---|---|---|
eventName | wildcard |
|
eventSource | eq |
|
Output fields
Fields the rule emits when it matches. Chronicle authors list these in the outcome block; they appear on the detection and $risk_score drives alerting. Sentinel / Defender XDR rules build them up through project / summarize / extend stages. Sentinel maps these into alert fields via entityMappings and customDetails; Defender XDR custom detections surface them as alert fields directly.
| Field | Source |
|---|---|
num_logs | count ( * ) |
recipientAccountId | |
userAgent | |
eventName | |
eventSource |