Suspicious MS Office Child Process

Identifies suspicious child processes of frequently targeted Microsoft Office applications (Word, PowerPoint, Excel). These child processes are often launched during exploitation of Office applications or from documents with malicious macros.

Elastic rule (View on GitHub)

  1[metadata]
  2creation_date = "2020/02/18"
  3integration = ["endpoint", "windows", "system", "m365_defender", "sentinel_one_cloud_funnel", "crowdstrike"]
  4maturity = "production"
  5updated_date = "2024/10/31"
  6min_stack_version = "8.14.0"
  7min_stack_comments = "Breaking change at 8.14.0 for the Windows Integration."
  8
  9[rule]
 10author = ["Elastic"]
 11description = """
 12Identifies suspicious child processes of frequently targeted Microsoft Office applications (Word, PowerPoint, Excel).
 13These child processes are often launched during exploitation of Office applications or from documents with malicious
 14macros.
 15"""
 16from = "now-9m"
 17index = [
 18    "winlogbeat-*",
 19    "logs-endpoint.events.process-*",
 20    "logs-windows.forwarded*",
 21    "logs-windows.sysmon_operational-*",
 22    "endgame-*",
 23    "logs-system.security*",
 24    "logs-m365_defender.event-*",
 25    "logs-sentinel_one_cloud_funnel.*",
 26    "logs-crowdstrike.fdr*",
 27]
 28language = "eql"
 29license = "Elastic License v2"
 30name = "Suspicious MS Office Child Process"
 31note = """## Triage and analysis
 32
 33### Investigating Suspicious MS Office Child Process
 34
 35Microsoft Office (MS Office) is a suite of applications designed to help with productivity and completing common tasks on a computer. You can create and edit documents containing text and images, work with data in spreadsheets and databases, and create presentations and posters. As it is some of the most-used software across companies, MS Office is frequently targeted for initial access. It also has a wide variety of capabilities that attackers can take advantage of.
 36
 37This rule looks for suspicious processes spawned by MS Office programs. This is generally the result of the execution of malicious documents.
 38
 39#### Possible investigation steps
 40
 41- Investigate the process execution chain (parent process tree) for unknown processes. Examine their executable files for prevalence, whether they are located in expected locations, and if they are signed with valid digital signatures.
 42- Investigate other alerts associated with the user/host during the past 48 hours.
 43- Retrieve MS Office documents received and opened by the user that could cause this behavior. Common locations include, but are not limited to, the Downloads and Document folders and the folder configured at the email client.
 44- Determine if the collected files are malicious:
 45  - Use a private sandboxed malware analysis system to perform analysis.
 46    - Observe and collect information about the following activities:
 47      - Attempts to contact external domains and addresses.
 48      - File and registry access, modification, and creation activities.
 49      - Service creation and launch activities.
 50      - Scheduled task creation.
 51  - Use the PowerShell Get-FileHash cmdlet to get the files' SHA-256 hash values.
 52    - Search for the existence and reputation of the hashes in resources like VirusTotal, Hybrid-Analysis, CISCO Talos, Any.run, etc.
 53
 54### False positive analysis
 55
 56- This activity is unlikely to happen legitimately. Benign true positives (B-TPs) can be added as exceptions if necessary.
 57
 58### Response and remediation
 59
 60- Initiate the incident response process based on the outcome of the triage.
 61- Isolate the involved host to prevent further post-compromise behavior.
 62- Investigate credential exposure on systems compromised or used by the attacker to ensure all compromised accounts are identified. Reset passwords for these accounts and other potentially compromised credentials, such as email, business systems, and web services.
 63- If the triage identified malware, search the environment for additional compromised hosts.
 64  - Implement temporary network rules, procedures, and segmentation to contain the malware.
 65  - Stop suspicious processes.
 66  - Immediately block the identified indicators of compromise (IoCs).
 67  - Inspect the affected systems for additional malware backdoors like reverse shells, reverse proxies, or droppers that attackers could use to reinfect the system.
 68- Remove and block malicious artifacts identified during triage.
 69- Run a full antimalware scan. This may reveal additional artifacts left in the system, persistence mechanisms, and malware components.
 70- Determine the initial vector abused by the attacker and take action to prevent reinfection through the same vector.
 71  - If the malicious file was delivered via phishing:
 72    - Block the email sender from sending future emails.
 73    - Block the malicious web pages.
 74    - Remove emails from the sender from mailboxes.
 75    - Consider improvements to the security awareness program.
 76- Using the incident response data, update logging and audit policies to improve the mean time to detect (MTTD) and the mean time to respond (MTTR).
 77"""
 78references = ["https://www.elastic.co/blog/vulnerability-summary-follina"]
 79risk_score = 47
 80rule_id = "a624863f-a70d-417f-a7d2-7a404638d47f"
 81severity = "medium"
 82tags = [
 83    "Domain: Endpoint",
 84    "OS: Windows",
 85    "Use Case: Threat Detection",
 86    "Tactic: Initial Access",
 87    "Tactic: Defense Evasion",
 88    "Tactic: Execution",
 89    "Resources: Investigation Guide",
 90    "Data Source: Elastic Endgame",
 91    "Data Source: Elastic Defend",
 92    "Data Source: System",
 93    "Data Source: Microsoft Defender for Endpoint",
 94    "Data Source: Sysmon",
 95    "Data Source: SentinelOne",
 96    "Data Source: Crowdstrike",
 97]
 98timestamp_override = "event.ingested"
 99type = "eql"
100
101query = '''
102process where host.os.type == "windows" and event.type == "start" and
103  process.parent.name : (
104      "eqnedt32.exe", "excel.exe", "fltldr.exe", "msaccess.exe",
105      "mspub.exe", "powerpnt.exe", "winword.exe", "outlook.exe"
106  ) and
107  process.name : (
108      "Microsoft.Workflow.Compiler.exe", "arp.exe", "atbroker.exe", "bginfo.exe", "bitsadmin.exe", "cdb.exe",
109      "certutil.exe", "cmd.exe", "cmstp.exe", "control.exe", "cscript.exe", "csi.exe", "dnx.exe", "dsget.exe",
110      "dsquery.exe", "forfiles.exe", "fsi.exe", "ftp.exe", "gpresult.exe", "hostname.exe", "ieexec.exe", "iexpress.exe",
111      "installutil.exe", "ipconfig.exe", "mshta.exe", "msxsl.exe", "nbtstat.exe", "net.exe", "net1.exe", "netsh.exe",
112      "netstat.exe", "nltest.exe", "odbcconf.exe", "ping.exe", "powershell.exe", "pwsh.exe", "qprocess.exe",
113      "quser.exe", "qwinsta.exe", "rcsi.exe", "reg.exe", "regasm.exe", "regsvcs.exe", "regsvr32.exe", "sc.exe",
114      "schtasks.exe", "systeminfo.exe", "tasklist.exe", "tracert.exe", "whoami.exe", "wmic.exe", "wscript.exe",
115      "xwizard.exe", "explorer.exe", "rundll32.exe", "hh.exe", "msdt.exe"
116  ) and
117  not (
118    process.parent.name : "outlook.exe" and
119    process.name : "rundll32.exe" and
120    process.args : "shell32.dll,Control_RunDLL" and
121    process.args : "srchadmin.dll"
122  )
123'''
124
125
126[[rule.threat]]
127framework = "MITRE ATT&CK"
128[[rule.threat.technique]]
129id = "T1566"
130name = "Phishing"
131reference = "https://attack.mitre.org/techniques/T1566/"
132[[rule.threat.technique.subtechnique]]
133id = "T1566.001"
134name = "Spearphishing Attachment"
135reference = "https://attack.mitre.org/techniques/T1566/001/"
136
137
138
139[rule.threat.tactic]
140id = "TA0001"
141name = "Initial Access"
142reference = "https://attack.mitre.org/tactics/TA0001/"
143[[rule.threat]]
144framework = "MITRE ATT&CK"
145[[rule.threat.technique]]
146id = "T1059"
147name = "Command and Scripting Interpreter"
148reference = "https://attack.mitre.org/techniques/T1059/"
149[[rule.threat.technique.subtechnique]]
150id = "T1059.001"
151name = "PowerShell"
152reference = "https://attack.mitre.org/techniques/T1059/001/"
153
154[[rule.threat.technique.subtechnique]]
155id = "T1059.003"
156name = "Windows Command Shell"
157reference = "https://attack.mitre.org/techniques/T1059/003/"
158
159
160
161[rule.threat.tactic]
162id = "TA0002"
163name = "Execution"
164reference = "https://attack.mitre.org/tactics/TA0002/"
165[[rule.threat]]
166framework = "MITRE ATT&CK"
167[[rule.threat.technique]]
168id = "T1218"
169name = "System Binary Proxy Execution"
170reference = "https://attack.mitre.org/techniques/T1218/"
171
172
173[rule.threat.tactic]
174id = "TA0005"
175name = "Defense Evasion"
176reference = "https://attack.mitre.org/tactics/TA0005/"

Triage and analysis

Investigating Suspicious MS Office Child Process

Microsoft Office (MS Office) is a suite of applications designed to help with productivity and completing common tasks on a computer. You can create and edit documents containing text and images, work with data in spreadsheets and databases, and create presentations and posters. As it is some of the most-used software across companies, MS Office is frequently targeted for initial access. It also has a wide variety of capabilities that attackers can take advantage of.

This rule looks for suspicious processes spawned by MS Office programs. This is generally the result of the execution of malicious documents.

Possible investigation steps

  • Investigate the process execution chain (parent process tree) for unknown processes. Examine their executable files for prevalence, whether they are located in expected locations, and if they are signed with valid digital signatures.
  • Investigate other alerts associated with the user/host during the past 48 hours.
  • Retrieve MS Office documents received and opened by the user that could cause this behavior. Common locations include, but are not limited to, the Downloads and Document folders and the folder configured at the email client.
  • Determine if the collected files are malicious:
    • Use a private sandboxed malware analysis system to perform analysis.
      • Observe and collect information about the following activities:
        • Attempts to contact external domains and addresses.
        • File and registry access, modification, and creation activities.
        • Service creation and launch activities.
        • Scheduled task creation.
    • Use the PowerShell Get-FileHash cmdlet to get the files' SHA-256 hash values.
      • Search for the existence and reputation of the hashes in resources like VirusTotal, Hybrid-Analysis, CISCO Talos, Any.run, etc.

False positive analysis

  • This activity is unlikely to happen legitimately. Benign true positives (B-TPs) can be added as exceptions if necessary.

Response and remediation

  • Initiate the incident response process based on the outcome of the triage.
  • Isolate the involved host to prevent further post-compromise behavior.
  • Investigate credential exposure on systems compromised or used by the attacker to ensure all compromised accounts are identified. Reset passwords for these accounts and other potentially compromised credentials, such as email, business systems, and web services.
  • If the triage identified malware, search the environment for additional compromised hosts.
    • Implement temporary network rules, procedures, and segmentation to contain the malware.
    • Stop suspicious processes.
    • Immediately block the identified indicators of compromise (IoCs).
    • Inspect the affected systems for additional malware backdoors like reverse shells, reverse proxies, or droppers that attackers could use to reinfect the system.
  • Remove and block malicious artifacts identified during triage.
  • Run a full antimalware scan. This may reveal additional artifacts left in the system, persistence mechanisms, and malware components.
  • Determine the initial vector abused by the attacker and take action to prevent reinfection through the same vector.
    • If the malicious file was delivered via phishing:
      • Block the email sender from sending future emails.
      • Block the malicious web pages.
      • Remove emails from the sender from mailboxes.
      • Consider improvements to the security awareness program.
  • Using the incident response data, update logging and audit policies to improve the mean time to detect (MTTD) and the mean time to respond (MTTR).

References

Related rules

to-top