Suspicious macOS MS Office Child Process
Identifies suspicious child processes of frequently targeted Microsoft Office applications (Word, PowerPoint, and Excel). These child processes are often launched during exploitation of Office applications or by documents with malicious macros.
Elastic rule (View on GitHub)
1[metadata]
2creation_date = "2021/01/04"
3integration = ["endpoint"]
4maturity = "production"
5updated_date = "2024/11/07"
6
7[rule]
8author = ["Elastic"]
9description = """
10Identifies suspicious child processes of frequently targeted Microsoft Office applications (Word, PowerPoint, and
11Excel). These child processes are often launched during exploitation of Office applications or by documents with
12malicious macros.
13"""
14from = "now-9m"
15index = ["logs-endpoint.events.*"]
16language = "eql"
17license = "Elastic License v2"
18name = "Suspicious macOS MS Office Child Process"
19references = ["https://blog.malwarebytes.com/cybercrime/2017/02/microsoft-office-macro-malware-targets-macs/"]
20risk_score = 47
21rule_id = "66da12b1-ac83-40eb-814c-07ed1d82b7b9"
22setup = """## Setup
23
24This rule requires data coming in from Elastic Defend.
25
26### Elastic Defend Integration Setup
27Elastic Defend is integrated into the Elastic Agent using Fleet. Upon configuration, the integration allows the Elastic Agent to monitor events on your host and send data to the Elastic Security app.
28
29#### Prerequisite Requirements:
30- Fleet is required for Elastic Defend.
31- To configure Fleet Server refer to the [documentation](https://www.elastic.co/guide/en/fleet/current/fleet-server.html).
32
33#### The following steps should be executed in order to add the Elastic Defend integration on a macOS System:
34- Go to the Kibana home page and click "Add integrations".
35- In the query bar, search for "Elastic Defend" and select the integration to see more details about it.
36- Click "Add Elastic Defend".
37- Configure the integration name and optionally add a description.
38- Select the type of environment you want to protect, for MacOS it is recommended to select "Traditional Endpoints".
39- Select a configuration preset. Each preset comes with different default settings for Elastic Agent, you can further customize these later by configuring the Elastic Defend integration policy. [Helper guide](https://www.elastic.co/guide/en/security/current/configure-endpoint-integration-policy.html).
40- We suggest selecting "Complete EDR (Endpoint Detection and Response)" as a configuration setting, that provides "All events; all preventions"
41- Enter a name for the agent policy in "New agent policy name". If other agent policies already exist, you can click the "Existing hosts" tab and select an existing policy instead.
42For more details on Elastic Agent configuration settings, refer to the [helper guide](https://www.elastic.co/guide/en/fleet/current/agent-policy.html).
43- Click "Save and Continue".
44- To complete the integration, select "Add Elastic Agent to your hosts" and continue to the next section to install the Elastic Agent on your hosts.
45For more details on Elastic Defend refer to the [helper guide](https://www.elastic.co/guide/en/security/current/install-endpoint.html).
46"""
47severity = "medium"
48tags = [
49 "Domain: Endpoint",
50 "OS: macOS",
51 "Use Case: Threat Detection",
52 "Tactic: Initial Access",
53 "Data Source: Elastic Defend",
54]
55timestamp_override = "event.ingested"
56type = "eql"
57
58query = '''
59process where event.action == "exec" and host.os.type == "macos" and
60 process.parent.name: (
61 "Microsoft Word",
62 "Microsoft Outlook",
63 "Microsoft Excel",
64 "Microsoft PowerPoint",
65 "Microsoft OneNote"
66 ) and
67 process.name : (
68 "curl",
69 "nscurl",
70 "bash",
71 "sh",
72 "osascript",
73 "python*",
74 "perl*",
75 "mktemp",
76 "chmod",
77 "php",
78 "nohup",
79 "openssl",
80 "plutil",
81 "PlistBuddy",
82 "xattr",
83 "mktemp",
84 "sqlite3",
85 "funzip",
86 "popen"
87 ) and
88
89 // Filter FPs related to product version discovery and Office error reporting behavior
90 not process.args:
91 (
92 "ProductVersion",
93 "hw.model",
94 "ioreg",
95 "ProductName",
96 "ProductUserVisibleVersion",
97 "ProductBuildVersion",
98 "/Library/Application Support/Microsoft/MERP*/Microsoft Error Reporting.app/Contents/MacOS/Microsoft Error Reporting",
99 "open -a Safari *",
100 "defaults read *",
101 "sysctl hw.model*",
102 "ioreg -d2 -c IOPlatformExpertDevice *",
103 "ps aux | grep 'ToDesk_Desktop' | grep -v grep",
104 "PIPE=\"$CFFIXED_USER_HOME/.zoteroIntegrationPipe*"
105 ) and
106
107 not process.parent.executable :
108 (
109 "/Applications/ToDesk.app/Contents/MacOS/ToDesk_Service",
110 "/usr/local/Privacy-i/PISupervisor",
111 "/Library/Addigy/lan-cache",
112 "/Library/Elastic/Agent/*",
113 "/opt/jc/bin/jumpcloud-agent",
114 "/usr/sbin/networksetup"
115 ) and
116 not (process.name : "sh" and process.command_line : "*$CFFIXED_USER_HOME/.zoteroIntegrationPipe*") and
117
118 not process.Ext.effective_parent.executable : (
119 "/Applications/ToDesk.app/Contents/MacOS/ToDesk_Service",
120 "/usr/local/Privacy-i/PISupervisor",
121 "/Library/Addigy/auditor",
122 "/Library/Elastic/Agent/*",
123 "/opt/jc/bin/jumpcloud-agent",
124 "/usr/sbin/networksetup"
125 )
126'''
127
128
129[[rule.threat]]
130framework = "MITRE ATT&CK"
131[[rule.threat.technique]]
132id = "T1566"
133name = "Phishing"
134reference = "https://attack.mitre.org/techniques/T1566/"
135[[rule.threat.technique.subtechnique]]
136id = "T1566.001"
137name = "Spearphishing Attachment"
138reference = "https://attack.mitre.org/techniques/T1566/001/"
139
140
141
142[rule.threat.tactic]
143id = "TA0001"
144name = "Initial Access"
145reference = "https://attack.mitre.org/tactics/TA0001/"
References
Related rules
- Suspicious Browser Child Process
- Apple Scripting Execution with Administrator Privileges
- Finder Sync Plugin Registered and Enabled
- Modification of Environment Variable via Unsigned or Untrusted Parent
- Potential Admin Group Account Addition