The Fidelis Threat Research team is comprised of expert security researchers whose sole focus is generating accurate and actionable intelligence to better secure customers. Together, they represent over... Read More
Comments
May 1, 2018
Emotet Update
Last year Fidelis Cybersecurity posted an update to our previous research on the Emotet spreader module(7). Our analysts continue to monitor this threat however, due to ongoing Emotet activity recently, the Fidelis Threat Research Team recently dedicated some time to check out an updated sample.
We decided to do the full break down on the malware and its modules to verify whether the C2 protocols were the same and also release updated technical data to the community. While in the process of reversing the modules, we noticed the spreader module looked different and this blog will cover the modifications we uncovered during our analysis of the updated Emotet malware.
Emotet Network Spreader
For starters, the new sample was larger than it was when last analyzed. Change in size does typically indicate alteration. Once we dug in we realized the new version is identical to the previous version except for two key differences:
Emotet now comes with NetPass.exe onboard
Strings have been obfuscated instead of encoded
While the spreader still comes with an onboard password list (10), it also now comes with two embedded and XOR encoded EXE files. After decoding the files we can see that they are the 32bit and 64bit version of NetPass.exe(8) which will be executed with the argument ‘/stab’ in order to dump any stored network passwords onto the system. This is a crude addition similar to their usage of other NirSoft utilities as modules which allow additional passwords to be utilized as the malware spreads around the network. This technique also capitalizes on any potential password reuse across accounts.
Most of the strings for this spreader module are obfuscated instead of encoded as the other modules have encoded strings –similar to how Emotet encodes its strings[11]. The exception being that the onboard password list is still stored encoded.
The above is an example where we can see the string ‘Administrator’ loaded in chunks.
Strings used to create file names and service names are similarly obfuscated.
Instead of manually typing this we can utilize a similar technique to deobfuscate H1N1 strings which use a similar method for hiding its strings. This involves using the unicorn emulator(10) in python.
A quick way to decode out every potential file embedded in this sample is to simply XOR encode the entire file and then dump out all the PE files from it, this works as the data is stored on an even offset within the file. Doing this provides us with two PE files, a 32bit and a 64bit version of NetPass from NirSoft.
Now that we’ve found this little addition we can take a look at its usage in the overall setup phase of the spreader module.
As can be seen in this overview of the setup phase of the spreader module, it is much the same as the previously documented version except for an addition involving the executing of NetPass. After this initial setup, the DLL moves into the actual spreading portion:
The spreading portion is similar to our last post. Upon a successful connection to the remote machine the Emotet sample on disk is copied using a random name based on the tick count and then a server is created to execute it which also uses a random name based on the tick count.
Conclusion
Network spreading appears to continue to be a development priority for malware authors, this trend isn’t looking to stop anytime soon. The research community appears to have answered this trend with researchers from many fields in cyber security adjusting their focus to lateral movement and pivoting in enterprise environments. Attacks such as the one being utilized by Emotet for spreading however are related to old problems in our field; password policies. There’s nothing like an ever-evolving current threat to help us remember why these old principals are still important to this day. Fidelis threat research team will continue to monitor threats such as these to help the community and our customers stay ahead of our adversaries.