Blogs & Stories

SpiderLabs Blog

Attracting more than a half-million annual readers, this is the security community's go-to destination for technical breakdowns of the latest threats, critical vulnerability disclosures and cutting-edge research.

Necurs Unleashed “Locky diablo” from Hell

Over two days in early August (the 8th and 9th), amidst of the active distribution of Trickbot malware, a new Locky ransomware variant called "diablo" has emerged from hell. The Trustwave SpiderLabs Spam Research Database has picked up a large amount Necurs spam emails and given a 36-hour period, we have gathered a total of 4,814,159 email samples and with an average influx of 133,727 pieces of spam per hour. Most of the spam we gathered came from India, Vietnam, and Iran.


Figure 1: Hourly volume of Locky related spam

Locky ransomware began its rise to fame last 2016, and has a track record of using email templates about invoice payments with a JS file or a malicious Word document as an attachment. The latest email uses a simple template wherein an office document or an image has been attached.

The subject could vary from the following:

E 2017-08-09 ({random number}).[doc|docx|xls|xlsx|pdf|jpg|tiff]

Each email has a zip attachment and uses the same subject details as its filename. Inside the zip file is a VBscript file.


Figure 2: Locky email sample - E 2017-08-09 (00).jpg


Figure 3: Locky email sample - E 2017-08-09 (00).doc

The attached VBS file is not totally obfuscated, it uses confusing variable names and adds some garbage codes. It also uses some string obfuscation techniques to avoid detection, for example it requires the construction of the "User-Agent" from different variables.

The script also initializes a lot of objects and retrieves the user's temp folder from the environment variables for later use.


Figure 4: VBS File – Initialization

From the URL array list, the script will try to connect to each site and check if the site it is still active.


Figure 5: VBS File – Connect to download sites

The script gets the HTTP response and saves it as a file in the temp folder.

MD5: 544BC1C6ECD95D89D96B5E75C3121FEA
SHA1: B4DC5F5D47B87BAA0BE87AFDA5CCEE1F00497984


Figure 6: TCP Stream – Shows a binary has been downloaded


Figure 7: VBS File – Save to File

Lastly, the script will execute the downloaded binary file.


Figure 8: VBS File – Execute binary file


Since the conception of the first Locky variant it has been recorded that it has used different extension names for the encrypted files from:


The current variant uses a different filename format and uses an extension name: ".diablo6"

Encrypted files

Figure 8: Locky – Encrypted Files

The typical Locky ransomware still has the html based ransom note placed on each folder and changes the wallpaper with a BMP based ransom note.


Figure 9: Locky – Ransom Note

This variant also still uses the same payment method where the decryption tool can be only accessible thru the TOR browser.


Figure 10: Locky – Onion Site – Payment for Decryption Tool


It has been a little while since Locky has hit the doors of email gateways. Even though this 'diablo' variant is just the same old Locky, the threat actors know how to make sure it is properly delivered. With the use of simple email contents and a very reliable methodology of downloading the binaries using an obfuscated VBS, this is just enough for an unsuspecting user to, indeed, experience hell.

Locky has done a lot of damage in the past and now appears to be reclaiming the limelight. This could be a start of a new sequence of Necurs/Locky mal-spam campaigns. In the future it is likely to utilize other means of delivery like macro embedded documents, PDFs, and JS files – all of which we will be on the look out for so stay tuned.