Newly Observed FortiGate Alert

This rule detects FortiGate alerts that are observed for the first time in the previous 5 days of alert history. Analysts can use this to prioritize triage and response.

Elastic rule (View on GitHub)

 1[metadata]
 2creation_date = "2026/01/21"
 3integration = ["fortinet_fortigate"]
 4maturity = "production"
 5updated_date = "2026/09/18"
 6
 7[rule]
 8author = ["Elastic"]
 9description = """
10This rule detects FortiGate alerts that are observed for the first time in the previous 5 days of alert history.
11Analysts can use this to prioritize triage and response.
12"""
13from = "now-7205m"
14interval = "5m"
15language = "esql"
16license = "Elastic License v2"
17name = "Newly Observed FortiGate Alert"
18risk_score = 99
19rule_id = "2c40dfe2-c13e-48a8-8eff-fb9bfb2a7854"
20severity = "critical"
21tags = [
22    "Use Case: Threat Detection",
23    "Rule Type: Higher-Order Rule",
24    "Resources: Investigation Guide",
25    "Domain: Network",
26    "Data Source: Fortinet",
27    "Noise: Medium",
28    "Performance: Normal",
29    "Rule Type: ES|QL",
30]
31timestamp_override = "event.ingested"
32type = "esql"
33
34query = '''
35FROM logs-fortinet_fortigate.*, filebeat-* metadata _id
36
37| WHERE event.module == "fortinet_fortigate" and event.action in ("signature", "ssl-anomaly") and
38  message is not null and event.category != "authentication" and
39  message != "Connection Failed" and not message like "Web.Client: *" and
40  not message like "Network.Service: *" and not message like "General.Interest*" and not message like "Update: *" and
41  not message like "tcp_reassembler*" and not message like "a-ipdf*" and not message like "Video*" and not message like "nbss_decode*" and
42  not message like "name_server*" and not message like "misc*" and not message like "Collaboration*" and not message like "Business*" and
43  not message like "Cloud.IT*" and not message like "Mobile*"
44
45| STATS Esql.alerts_count = count(*),
46        Esql.first_time_seen = MIN(@timestamp),
47        Esql.distinct_count_src_ip = COUNT_DISTINCT(source.ip),
48        Esql.distinct_count_dst_ip = COUNT_DISTINCT(destination.ip),
49        src_ip = VALUES(source.ip),
50        dst_ip = VALUES(destination.ip),
51        url_domain = VALUES(url.domain),
52        url_path = VALUES(url.path) by message, event.category, event.outcome
53
54// first time seen is within 10m of the rule execution time
55| eval Esql.recent = DATE_DIFF("minute", Esql.first_time_seen, now())
56| where Esql.recent <= 10 and Esql.alerts_count <= 5 and Esql.distinct_count_src_ip <= 2 and Esql.distinct_count_dst_ip <= 2
57
58// move dynamic fields to ECS equivalent for rule exceptions
59| eval source.ip = MV_FIRST(src_ip),
60       destination.ip = MV_FIRST(dst_ip),
61       url.domain = MV_FIRST(url_domain),
62       url.path = MV_FIRST(url_path)
63
64| keep message, event.category, event.outcome, Esql.*, source.ip, destination.ip, url.domain, url.path
65'''
66note = """## Triage and analysis
67
68### Investigating Newly Observed Fortigate Alert
69
70This rule surfaces newly observed, low-frequency high severity FortiGate alerts within the last 5 days.
71
72Because the alert has not been seen previously, it should be prioritized for validation to determine whether it represents a true compromise or rare benign activity.
73
74### Investigation Steps
75
76- Identify the source address, affected host and review the associated message to understand the alert.
77- Validate the source address under which the activity occurred and assess whether it aligns with normal behavior.
78- Refer to the specific alert details like event.original to get more context.
79
80### False Positive Considerations
81
82- Vulnerability scanners and pentesting.
83- Administrative scripts or automation tools can trigger detections when first introduced.
84- Development or testing environments may produce one-off behaviors that resemble malicious techniques.
85
86### Response and Remediation
87
88- If the activity is confirmed malicious, isolate the affected host to prevent further execution or lateral movement.
89- Terminate malicious processes and remove any dropped files or persistence mechanisms.
90- Collect forensic artifacts to understand initial access and execution flow.
91- Patch or remediate any vulnerabilities or misconfigurations that enabled the behavior.
92- If benign, document the finding and consider tuning or exception handling to reduce future noise.
93- Continue monitoring the host and environment for recurrence of the behavior or related alerts."""
94references = ["https://www.elastic.co/docs/reference/integrations/fortinet_fortigate"]

Triage and analysis

Investigating Newly Observed Fortigate Alert

This rule surfaces newly observed, low-frequency high severity FortiGate alerts within the last 5 days.

Because the alert has not been seen previously, it should be prioritized for validation to determine whether it represents a true compromise or rare benign activity.

Investigation Steps

  • Identify the source address, affected host and review the associated message to understand the alert.
  • Validate the source address under which the activity occurred and assess whether it aligns with normal behavior.
  • Refer to the specific alert details like event.original to get more context.

False Positive Considerations

  • Vulnerability scanners and pentesting.
  • Administrative scripts or automation tools can trigger detections when first introduced.
  • Development or testing environments may produce one-off behaviors that resemble malicious techniques.

Response and Remediation

  • If the activity is confirmed malicious, isolate the affected host to prevent further execution or lateral movement.
  • Terminate malicious processes and remove any dropped files or persistence mechanisms.
  • Collect forensic artifacts to understand initial access and execution flow.
  • Patch or remediate any vulnerabilities or misconfigurations that enabled the behavior.
  • If benign, document the finding and consider tuning or exception handling to reduce future noise.
  • Continue monitoring the host and environment for recurrence of the behavior or related alerts.

References

Related rules

to-top