Detecting Adwind using clustered child processes of java.exe


Sample: https://app.any.run/tasks/455f13a6-c615-4969-bbfb-50967760b158/

Here is a nice sample of #adwind using a few child processes (cmd, xcopy, reg, attrib, and javaw) that we can use as a cluster TTP.  In addition, the malware is impatient so it does all this in a few seconds as well, which will help isolate the behavior when searching over long time frames.

Here is the search minus a couple of tunes I needed:



Breakdown:
  • The parent must be java.exe
  • The bucket sets the one minute time frame for the events
  • Command_count gives us the unique event count for command lines
  • Proc_count gives us the distinct count of the process names since we want at least of couple of these. Keep it loose enough to catch other things as well


This sample also does a bunch of taskkills for various processes associated with analysis so lets do a search for that as well in the same fashion.



Breakdown:
  • Here we are looking mainly for high counts of unique command lines from taskkill >25
  • I'll use match with (?i) case insensitivity to make sure at least one of the common ones found in the anyrun is present since there are some processes which legitimately have this activity but are false positives.


References:

https://app.any.run/tasks/455f13a6-c615-4969-bbfb-50967760b158/

Tip on using "match" in "where" conditions: https://twitter.com/ateixei/status/1179692764876955648

Comments

Popular posts from this blog

Misleading extensions Xls.exe Doc.exe Pdf.exe

Netconn from suspicious directories

Powershell DNS C2 Notes