Creation or Modification of a new GPO Scheduled Task or Service
Detects the creation or modification of a new Group Policy based scheduled task or service. These methods are used for legitimate system administration, but can also be abused by an attacker with domain admin permissions to execute a malicious payload remotely on all or a subset of the domain joined machines.
Elastic rule (View on GitHub)
1[metadata]
2creation_date = "2020/08/13"
3integration = ["endpoint", "windows", "m365_defender", "sentinel_one_cloud_funnel"]
4maturity = "production"
5updated_date = "2024/10/10"
6min_stack_version = "8.13.0"
7min_stack_comments = "Breaking change at 8.13.0 for SentinelOne Integration."
8
9[rule]
10author = ["Elastic"]
11description = """
12Detects the creation or modification of a new Group Policy based scheduled task or service. These methods are used for
13legitimate system administration, but can also be abused by an attacker with domain admin permissions to execute a
14malicious payload remotely on all or a subset of the domain joined machines.
15"""
16from = "now-9m"
17index = ["winlogbeat-*", "logs-endpoint.events.file-*", "logs-windows.sysmon_operational-*", "endgame-*", "logs-m365_defender.event-*", "logs-sentinel_one_cloud_funnel.*"]
18language = "eql"
19license = "Elastic License v2"
20name = "Creation or Modification of a new GPO Scheduled Task or Service"
21risk_score = 21
22rule_id = "c0429aa8-9974-42da-bfb6-53a0a515a145"
23severity = "low"
24tags = [
25 "Domain: Endpoint",
26 "OS: Windows",
27 "Use Case: Threat Detection",
28 "Tactic: Privilege Escalation",
29 "Tactic: Persistence",
30 "Data Source: Elastic Endgame",
31 "Data Source: Elastic Defend",
32 "Data Source: Sysmon",
33 "Data Source: Microsoft Defender for Endpoint",
34 "Data Source: SentinelOne",
35]
36timestamp_override = "event.ingested"
37type = "eql"
38
39query = '''
40file where host.os.type == "windows" and event.type != "deletion" and file.name : "ScheduledTasks.xml" and
41 file.path : (
42 "?:\\Windows\\SYSVOL\\domain\\Policies\\*\\MACHINE\\Preferences\\ScheduledTasks\\ScheduledTasks.xml",
43 "?:\\Windows\\SYSVOL\\domain\\Policies\\*\\MACHINE\\Preferences\\Services\\Services.xml"
44 ) and
45 not process.name : "dfsrs.exe"
46'''
47
48
49[[rule.threat]]
50framework = "MITRE ATT&CK"
51[[rule.threat.technique]]
52id = "T1484"
53name = "Domain or Tenant Policy Modification"
54reference = "https://attack.mitre.org/techniques/T1484/"
55[[rule.threat.technique.subtechnique]]
56id = "T1484.001"
57name = "Group Policy Modification"
58reference = "https://attack.mitre.org/techniques/T1484/001/"
59
60
61
62[rule.threat.tactic]
63id = "TA0004"
64name = "Privilege Escalation"
65reference = "https://attack.mitre.org/tactics/TA0004/"
66[[rule.threat]]
67framework = "MITRE ATT&CK"
68[[rule.threat.technique]]
69id = "T1053"
70name = "Scheduled Task/Job"
71reference = "https://attack.mitre.org/techniques/T1053/"
72[[rule.threat.technique.subtechnique]]
73id = "T1053.005"
74name = "Scheduled Task"
75reference = "https://attack.mitre.org/techniques/T1053/005/"
76
77
78
79[rule.threat.tactic]
80id = "TA0003"
81name = "Persistence"
82reference = "https://attack.mitre.org/tactics/TA0003/"
Related rules
- Persistence via TelemetryController Scheduled Task Hijack
- Persistence via Update Orchestrator Service Hijack
- Potential Persistence via Time Provider Modification
- Persistence via PowerShell profile
- Suspicious WerFault Child Process