Skip to content

Commit 1217a23

Browse files
committed
Merge branch 'main' into ET_SURIC
2 parents 7a316a2 + 6ac69db commit 1217a23

File tree

148 files changed

+778
-515
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

148 files changed

+778
-515
lines changed

.github/stale.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ onlyLabels: []
1212
exemptLabels:
1313
- bug
1414
- backlog
15+
- "Rule: Tuning"
16+
- "Rule: New"
1517

1618
# Set to true to ignore issues in a project (defaults to false)
1719
exemptProjects: false
114 Bytes
Binary file not shown.
332 Bytes
Binary file not shown.

rules/cross-platform/defense_evasion_agent_spoofing_multiple_hosts.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
creation_date = "2021/07/14"
33
integration = ["endpoint"]
44
maturity = "production"
5-
updated_date = "2025/11/13"
5+
updated_date = "2025/12/10"
66

77
[rule]
88
author = ["Elastic"]
@@ -30,7 +30,7 @@ type = "esql"
3030

3131
query = '''
3232
from logs-endpoint.* metadata _id
33-
| where event.agent_id_status is not null
33+
| where event.agent_id_status is not null and agent.id is not null
3434
| stats Esql.count_distinct_host_ids = count_distinct(host.id), Esql.host_id_values = values(host.id), Esql.user_id_values_user_id = values(user.id) by agent.id
3535
| where Esql.count_distinct_host_ids >= 2
3636
| keep Esql.count_distinct_host_ids, Esql.host_id_values, Esql.user_id_values_user_id, agent.id

rules/cross-platform/defense_evasion_whitespace_padding_command_line.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
creation_date = "2025/06/30"
33
integration = ["endpoint", "system", "windows", "auditd_manager", "m365_defender", "crowdstrike", "sentinel_one_cloud_funnel"]
44
maturity = "production"
5-
updated_date = "2025/06/30"
5+
updated_date = "2025/12/09"
66

77
[rule]
88
author = ["Elastic"]
@@ -90,7 +90,7 @@ FROM logs-* metadata _id, _version, _index
9090
// more than 100 spaces in process.command_line
9191
| eval multi_spaces = LOCATE(process.command_line, space(100))
9292
| where multi_spaces > 0
93-
| keep user.name, host.id, host.name, process.command_line, process.executable, process.parent.executable
93+
| keep user.name, host.id, host.name, process.command_line, process.executable, process.parent.executable, _id, _version, _index
9494
'''
9595

9696

rules/cross-platform/impact_hosts_file_modified.toml

Lines changed: 20 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
creation_date = "2020/07/07"
33
integration = ["endpoint", "windows"]
44
maturity = "production"
5-
updated_date = "2025/03/20"
5+
updated_date = "2025/12/11"
66

77
[rule]
88
author = ["Elastic"]
@@ -78,23 +78,37 @@ timestamp_override = "event.ingested"
7878
type = "eql"
7979

8080
query = '''
81-
any where
81+
any where process.executable != null and
8282
8383
/* file events for creation; file change events are not captured by some of the included sources for linux and so may
8484
miss this, which is the purpose of the process + command line args logic below */
8585
(
86-
event.category == "file" and event.type in ("change", "creation") and
86+
event.category == "file" and event.type in ("change", "creation") and event.action != "rename" and
8787
file.path : ("/private/etc/hosts", "/etc/hosts", "?:\\Windows\\System32\\drivers\\etc\\hosts") and
88-
not process.name in ("dockerd", "rootlesskit", "podman", "crio")
88+
not process.name in ("dockerd", "rootlesskit", "podman", "crio") and
89+
not process.executable : ("C:\\Program Files\\Fortinet\\FortiClient\\FCDBLog.exe",
90+
"C:\\Program Files\\Seqrite\\Seqrite\\SCANNER.EXE",
91+
"C:\\Windows\\Temp\\*.ins\\inst.exe",
92+
"C:\\Windows\\System32\\svchost.exe",
93+
"C:\\Program Files\\NordVPN\\nordvpn-service.exe",
94+
"C:\\Program Files\\Tailscale\\tailscaled.exe",
95+
"C:\\Program Files\\Docker\\Docker\\com.docker.service",
96+
"C:\\Program Files\\Quick Heal\\Quick Heal AntiVirus Pro\\scanner.exe",
97+
"C:\\Program Files (x86)\\Quick Heal AntiVirus Pro\\SCANNER.EXE",
98+
"C:\\Program Files\\Quick Heal\\Quick Heal Internet Security\\scanner.exe",
99+
"C:\\Program Files (x86)\\Cisco\\Cisco AnyConnect Secure Mobility Client\\vpnagent.exe",
100+
"/opt/IBM/InformationServer/Server/DSEngine/bin/uvsh",
101+
"/usr/local/demisto/server")
89102
)
90103
or
91104
92105
/* process events for change targeting linux only */
93106
(
94107
event.category == "process" and event.type in ("start") and
95108
process.name in ("nano", "vim", "vi", "emacs", "echo", "sed") and
96-
process.args : ("/etc/hosts") and
97-
not process.parent.name in ("dhclient-script", "google_set_hostname")
109+
(process.args : ("/etc/hosts") or (process.working_directory == "/etc" and process.args == "hosts")) and
110+
not process.parent.name in ("dhclient-script", "google_set_hostname") and
111+
not process.command_line == "sed -i /Added by Google/d /etc/hosts"
98112
)
99113
'''
100114

rules/cross-platform/initial_access_azure_o365_with_network_alert.toml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22
creation_date = "2025/04/29"
33
integration = ["azure", "o365"]
44
maturity = "production"
5-
updated_date = "2025/07/30"
5+
updated_date = "2025/12/10"
66

77
[rule]
88
author = ["Elastic"]
99
description = """
10-
This rule correlate Azure or Office 356 mail successful sign-in events with network security alerts by source.ip.
10+
This rule correlate Entra-ID or Microsoft 365 mail successful sign-in events with network security alerts by source address.
1111
Adversaries may trigger some network security alerts such as reputation or other anomalies before accessing cloud
1212
resources.
1313
"""
@@ -19,10 +19,10 @@ false_positives = [
1919
from = "now-60m"
2020
language = "esql"
2121
license = "Elastic License v2"
22-
name = "Microsoft 365 or Entra ID Sign-in from a Suspicious Source"
22+
name = "M365 or Entra ID Identity Sign-in from a Suspicious Source"
2323
note = """## Triage and analysis
2424
25-
### Investigating Microsoft 365 or Entra ID Sign-in from a Suspicious Source
25+
### Investigating M365 or Entra ID Identity Sign-in from a Suspicious Source
2626
2727
#### Possible investigation steps
2828
@@ -82,7 +82,7 @@ from logs-o365.audit-*, logs-azure.signinlogs-*, .alerts-security.*
8282
| where @timestamp > now() - 8 hours
8383
// filter for azure or m365 sign-in and external alerts with source.ip not null
8484
| where to_ip(source.ip) is not null
85-
and (event.dataset in ("o365.audit", "azure.signinlogs") or kibana.alert.rule.name == "External Alerts")
85+
and (event.dataset in ("o365.audit", "azure.signinlogs") or kibana.alert.rule.rule_id == "eb079c62-4481-4d6e-9643-3ca499df7aaa")
8686
and not cidr_match(
8787
to_ip(source.ip),
8888
"10.0.0.0/8", "127.0.0.0/8", "169.254.0.0/16", "172.16.0.0/12", "192.0.0.0/24", "192.0.0.0/29",
@@ -93,13 +93,13 @@ from logs-o365.audit-*, logs-azure.signinlogs-*, .alerts-security.*
9393
)
9494
9595
// capture relevant raw fields
96-
| keep source.ip, event.action, event.outcome, event.dataset, kibana.alert.rule.name, event.category
96+
| keep source.ip, event.action, event.outcome, event.dataset, kibana.alert.rule.rule_id, event.category
9797
9898
// classify each source ip based on alert type
9999
| eval
100100
Esql.source_ip_mail_access_case = case(event.dataset == "o365.audit" and event.action == "MailItemsAccessed" and event.outcome == "success", to_ip(source.ip), null),
101101
Esql.source_ip_azure_signin_case = case(event.dataset == "azure.signinlogs" and event.outcome == "success", to_ip(source.ip), null),
102-
Esql.source_ip_network_alert_case = case(kibana.alert.rule.name == "external alerts" and not event.dataset in ("o365.audit", "azure.signinlogs"), to_ip(source.ip), null)
102+
Esql.source_ip_network_alert_case = case(kibana.alert.rule.rule_id == "eb079c62-4481-4d6e-9643-3ca499df7aaa" and not event.dataset in ("o365.audit", "azure.signinlogs"), to_ip(source.ip), null)
103103
104104
// aggregate by source ip
105105
| stats
@@ -109,7 +109,7 @@ from logs-o365.audit-*, logs-azure.signinlogs-*, .alerts-security.*
109109
Esql.source_ip_network_alert_case_count_distinct = count_distinct(Esql.source_ip_network_alert_case),
110110
Esql.event_dataset_count_distinct = count_distinct(event.dataset),
111111
Esql.event_dataset_values = values(event.dataset),
112-
Esql.kibana_alert_rule_name_values = values(kibana.alert.rule.name),
112+
Esql.kibana_alert_rule_id_values = values(kibana.alert.rule.rule_id),
113113
Esql.event_category_values = values(event.category)
114114
by Esql.source_ip = to_ip(source.ip)
115115

rules/cross-platform/initial_access_execution_susp_react_serv_child.toml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
creation_date = "2025/12/04"
33
integration = ["endpoint", "windows", "auditd_manager", "sentinel_one_cloud_funnel"]
44
maturity = "production"
5-
updated_date = "2025/12/08"
5+
updated_date = "2025/12/10"
66

77
[rule]
88
author = ["Elastic"]
@@ -101,12 +101,11 @@ process where event.type == "start" and event.action in ("exec", "executed", "st
101101
)
102102
and (
103103
?process.working_directory : (
104-
"*react-dom*", "*.next*", "*node_modules/next*", "*react-server*", "*bin/next*", "*--experimental-https*", "*app/server*",
105-
"*.pnpm/next*", "*/app/*", "*next/dist/server*", "*react-scripts*") or
104+
"*react-dom*", "*.next*", "*node_modules/next*", "*react-server*", "*bin/next*", "*.pnpm/next*", "*next/dist/server*", "*react-scripts*") or
106105
(
107106
process.parent.name in ("node", "bun", "node.exe", "bun.exe") and
108107
process.parent.command_line : (
109-
"*react-dom*", "*.next*", "*node_modules/next*", "*react-server*", "*next-server*", "*server.js*", "*bin/next*",
108+
"*react-dom*", "*.next*", "*node_modules/next*", "*react-server*", "*next-server*", "* server.js*", "*start-server.js*", "*bin/next*",
110109
"*--experimental-https*", "*app/server*", "*.pnpm/next*", "*next start*", "*next dev*", "*react-scripts start*", "*next/dist/server*"
111110
)
112111
)

rules/cross-platform/multiple_alerts_email_elastic_defend_correlation.toml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
[metadata]
22
creation_date = "2025/11/19"
3+
integration = ["endpoint", "checkpoint_email"]
34
maturity = "production"
4-
updated_date = "2025/11/19"
5+
updated_date = "2025/12/15"
56

67
[rule]
78
author = ["Elastic"]
@@ -22,14 +23,15 @@ tags = [
2223
"Rule Type: Higher-Order Rule",
2324
"Resources: Investigation Guide",
2425
"Data Source: Elastic Defend",
26+
"Data Source: Check Point Harmony Email & Collaboration",
2527
"Domain: Email",
2628
"Domain: Endpoint"
2729
]
2830
timestamp_override = "event.ingested"
2931
type = "esql"
3032

3133
query = '''
32-
from logs-* metadata _id
34+
from logs-endpoint.alerts-*, logs-checkpoint_email.event-* metadata _id
3335
// Email or Elastic Defend alerts where user name is populated
3436
| where
3537
(event.category == "email" and event.kind == "alert" and destination.user.name is not null) or

rules/integrations/aws/credential_access_new_terms_secretsmanager_getsecretvalue.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
creation_date = "2020/07/06"
33
integration = ["aws"]
44
maturity = "production"
5-
updated_date = "2025/08/18"
5+
updated_date = "2025/12/12"
66

77
[rule]
88
author = ["Nick Jones", "Elastic"]
@@ -97,7 +97,7 @@ type = "new_terms"
9797
query = '''
9898
event.dataset:aws.cloudtrail and event.provider:secretsmanager.amazonaws.com and
9999
event.action: (GetSecretValue or BatchGetSecretValue) and event.outcome:success and
100-
not user_agent.name: ("Chrome" or "Firefox" or "Safari" or "Edge" or "Brave" or "Opera")
100+
not user_agent.name: ("Chrome" or "Firefox" or "Safari" or "Edge" or "Brave" or "Opera" or "Boto3")
101101
'''
102102

103103
[rule.investigation_fields]

0 commit comments

Comments
 (0)