AWS EC2 Full Network Packet Capture Detected

Identifies potential Traffic Mirroring in an Amazon Elastic Compute Cloud (EC2) instance. Traffic Mirroring is an Amazon VPC feature that you can use to copy network traffic from an Elastic network interface. This feature can potentially be abused to exfiltrate sensitive data from unencrypted internal traffic.

Elastic rule (View on GitHub)

 1[metadata]
 2creation_date = "2021/05/05"
 3integration = ["aws"]
 4maturity = "production"
 5min_stack_comments = "New fields added: required_fields, related_integrations, setup"
 6min_stack_version = "8.3.0"
 7updated_date = "2023/03/06"
 8
 9[rule]
10author = ["Elastic", "Austin Songer"]
11description = """
12Identifies potential Traffic Mirroring in an Amazon Elastic Compute Cloud (EC2) instance. Traffic Mirroring is an Amazon
13VPC feature that you can use to copy network traffic from an Elastic network interface. This feature can potentially be
14abused to exfiltrate sensitive data from unencrypted internal traffic.
15"""
16false_positives = [
17    """
18    Traffic Mirroring may be done by a system or network administrator. Verify whether the user identity, user agent,
19    and/or hostname should be making changes in your environment. Traffic Mirroring from unfamiliar users or hosts
20    should be investigated. If known behavior is causing false positives, it can be exempted from the rule.
21    """,
22]
23from = "now-60m"
24index = ["filebeat-*", "logs-aws*"]
25interval = "10m"
26language = "kuery"
27license = "Elastic License v2"
28name = "AWS EC2 Full Network Packet Capture Detected"
29note = """## Setup
30
31The AWS Fleet integration, Filebeat module, or similarly structured data is required to be compatible with this rule."""
32references = [
33    "https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_TrafficMirrorFilter.html",
34    "https://github.com/easttimor/aws-incident-response",
35]
36risk_score = 47
37rule_id = "c1812764-0788-470f-8e74-eb4a14d47573"
38severity = "medium"
39tags = ["Elastic", "Cloud", "AWS", "Amazon Web Services", "Continuous Monitoring", "SecOps", "Network Security"]
40timestamp_override = "event.ingested"
41type = "query"
42
43query = '''
44event.dataset:aws.cloudtrail and event.provider:ec2.amazonaws.com and
45event.action:(CreateTrafficMirrorFilter or CreateTrafficMirrorFilterRule or CreateTrafficMirrorSession or CreateTrafficMirrorTarget) and
46event.outcome:success
47'''
48
49
50[[rule.threat]]
51framework = "MITRE ATT&CK"
52[[rule.threat.technique]]
53id = "T1020"
54name = "Automated Exfiltration"
55reference = "https://attack.mitre.org/techniques/T1020/"
56
57
58[rule.threat.tactic]
59id = "TA0010"
60name = "Exfiltration"
61reference = "https://attack.mitre.org/tactics/TA0010/"
62[[rule.threat]]
63framework = "MITRE ATT&CK"
64[[rule.threat.technique]]
65id = "T1074"
66name = "Data Staged"
67reference = "https://attack.mitre.org/techniques/T1074/"
68
69
70[rule.threat.tactic]
71id = "TA0009"
72name = "Collection"
73reference = "https://attack.mitre.org/tactics/TA0009/"

Setup

The AWS Fleet integration, Filebeat module, or similarly structured data is required to be compatible with this rule.

to-top