TSPY_EMOTET.XXRK

 Analysis by: David John Agni
 Modified by: RonJay Kristoffer Caragay

 ALIASES:

W32/Emotet.AD!tr (Fortinet), Win32/Emotet.AD (ESET-NOD32), Trojan.Win32.Emotet (Ikarus), Trojan:Win32/Emotet.G (Microsoft)

 PLATFORM:

Windows

 OVERALL RISK RATING:
 DAMAGE POTENTIAL:
 DISTRIBUTION POTENTIAL:
 REPORTED INFECTION:
 INFORMATION EXPOSURE:

  • Threat Type: Spyware

  • Destructiveness: No

  • Encrypted: Yes

  • In the wild: Yes

  OVERVIEW

Infection Channel:

Downloaded from the Internet, Dropped by other malware

This spyware arrives on a system as a file dropped by other malware or as a file downloaded unknowingly by users when visiting malicious sites.

However, as of this writing, the said sites are inaccessible.

  TECHNICAL DETAILS

File Size:

174,213 bytes

File Type:

EXE

Memory Resident:

Yes

Initial Samples Received Date:

13 May 2015

Payload:

Connects to URLs/IPs

Arrival Details

This spyware arrives on a system as a file dropped by other malware or as a file downloaded unknowingly by users when visiting malicious sites.

Installation

This spyware drops the following copies of itself into the affected system:

  • %AppDataLocal%\{random filename}.exe

(Note: %AppDataLocal% is the Application Data folder found in Local Settings, where it is usually C:\Documents and Settings\{user name}\Local Settings\Application Data on Windows 2000, Windows Server 2003, and Windows XP (32- and 64-bit); C:\Users\{user name}\AppData\Local on Windows Vista (32- and 64-bit), Windows 7 (32- and 64-bit), Windows 8 (32- and 64-bit), Windows 8.1 (32- and 64-bit), Windows Server 2008, and Windows Server 2012.)

It adds the following mutexes to ensure that only one of its copies runs at any one time:

  • _{Process ID in hex}{random letter}

It injects codes into the following process(es):

  • explorer.exe

Autostart Technique

This spyware adds the following registry entries to enable its automatic execution at every system startup:

HKEY_CURRENT_USER\Software\Microsoft\
Windows\CurrentVersion\Run
{random filename} = "%AppDataLocal%\{random filename}.exe"

Other System Modifications

This spyware adds the following registry keys:

HKEY_CURRENT_USER\Software\Classes\
.{random 1}\E

HKEY_CURRENT_USER\Software\Classes\
.{random 1}\Q

HKEY_CURRENT_USER\Software\Classes\
.{random 1}\W

It adds the following registry entries:

HKEY_CURRENT_USER\Software\Classes\
.{random 1}\E
T = "{hex values}"

HKEY_CURRENT_USER\Software\Classes\
.{random 1}\E
Y = "{hex values}"

Download Routine

This spyware downloads updated copies of itself from the following websites:

  • http://blog.{BLOCKED}ech.it/sQHNEPSj7M4eIt/9049b.exe
  • http://{BLOCKED}swiecie.pl/syuNA4Kf1PlW/9049b.exe
  • http://{BLOCKED}j.com/G4g1QuqwSi/9049b.exe
  • http://{BLOCKED}ntec.com.br/mHyfKnlBOL407/9049.exe
  • http://www.{BLOCKED}ik.com/3vOor1GYLynw/9049b.exe

It saves the files it downloads using the following names:

  • %User Temp%\{random filename}.tmp

(Note: %User Temp% is the user's temporary folder, where it usually is C:\Documents and Settings\{user name}\Local Settings\Temp on Windows 2000, Windows Server 2003, and Windows XP (32- and 64-bit); C:\Users\{user name}\AppData\Local\Temp on Windows Vista (32- and 64-bit), Windows 7 (32- and 64-bit), Windows 8 (32- and 64-bit), Windows 8.1 (32- and 64-bit), Windows Server 2008, and Windows Server 2012.)

Information Theft

This spyware gathers the following data:

  • Computer name
  • Country
  • Volume information
  • OS Version

Other Details

This spyware connects to the following possibly malicious URL:

  • http://{BLOCKED}.{BLOCKED}.26.36:8080/{random}/{random}.php
  • http://{BLOCKED}.{BLOCKED}.26.36:8080/{random}/{random}/
  • http://{BLOCKED}.{BLOCKED}.7.92:8080/{random}/{random}.php
  • http://{BLOCKED}.{BLOCKED}.7.92:8080/{random}/{random}/
  • http://{BLOCKED}.{BLOCKED}.0.141:8080/{random}/{random}.php
  • http://{BLOCKED}.{BLOCKED}.0.141:8080/{random}/{random}/
  • http://{BLOCKED}.{BLOCKED}.40.103:8080/{random}/{random}.php
  • http://{BLOCKED}.{BLOCKED}.40.103:8080/{random}/{random}/
  • http://{BLOCKED}.{BLOCKED}.233.226:8080/{random}/{random}.php
  • http://{BLOCKED}.{BLOCKED}.233.226:8080/{random}/{random}/
  • http://{BLOCKED}.{BLOCKED}.252.88:8080/{random}/{random}.php
  • http://{BLOCKED}.{BLOCKED}.252.88:8080/{random}/{random}/
  • http://{BLOCKED}.{BLOCKED}.171.84:8080/{random}/{random}.php
  • http://{BLOCKED}.{BLOCKED}.171.84:8080/{random}/{random}/
  • http://{BLOCKED}.{BLOCKED}.171.85:8080/{random}/{random}.php
  • http://{BLOCKED}.{BLOCKED}.171.85:8080/{random}/{random}/
  • http://{BLOCKED}.{BLOCKED}.2.168:8080/{random}/{random}.php
  • http://{BLOCKED}.{BLOCKED}.2.168:8080/{random}/{random}/
  • http://{BLOCKED}.{BLOCKED}.191.195:8080/{random}/{random}.php
  • http://{BLOCKED}.{BLOCKED}.191.195:8080/{random}/{random}/

However, as of this writing, the said sites are inaccessible.

NOTES:

This spyware accesses the sites to post gathered information and download arbitrary files to be executed. The download sites of its updated copy depends on the response from the server. The response changes with every connection.

  SOLUTION

Minimum Scan Engine:

9.750

FIRST VSAPI PATTERN FILE:

11.666.06

FIRST VSAPI PATTERN DATE:

13 May 2015

VSAPI OPR PATTERN File:

11.667.00

VSAPI OPR PATTERN Date:

14 May 2015

Step 1

Before doing any scans, Windows XP, Windows Vista, and Windows 7 users must disable System Restore to allow full scanning of their computers.

Step 2

Note that not all files, folders, and registry keys and entries are installed on your computer during this malware's/spyware's/grayware's execution. This may be due to incomplete installation or other operating system conditions. If you do not find the same files/folders/registry information, please proceed to the next step.

Step 3

Restart in Safe Mode

[ Learn More ]

Step 4

Delete this registry value

[ Learn More ]

Important: Editing the Windows Registry incorrectly can lead to irreversible system malfunction. Please do this step only if you know how or you can ask assistance from your system administrator. Else, check this Microsoft article first before modifying your computer's registry.

  • In HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run
    • {random filename} = "%AppDataLocal%\{random filename}.exe"

Step 5

Delete this registry key

[ Learn More ]

Important: Editing the Windows Registry incorrectly can lead to irreversible system malfunction. Please do this step only if you know how or you can ask assistance from your system administrator. Else, check this Microsoft article first before modifying your computer's registry.

 
  • In HKEY_CURRENT_USER\Software\Classes
    • .{random 1}
  • In HKEY_CURRENT_USER\Software\Classes\.{random 1}
    • E
  • In HKEY_CURRENT_USER\Software\Classes\.{random 1}
    • Q
  • In HKEY_CURRENT_USER\Software\Classes\.{random 1}
    • W

Step 6

Search and delete these files

[ Learn More ]
There may be some files that are hidden. Please make sure you check the Search Hidden Files and Folders checkbox in the "More advanced options" option to include all hidden files and folders in the search result.
  • %User Temp%\{random filename}.tmp

Step 7

Restart in normal mode and scan your computer with your Trend Micro product for files detected as TSPY_EMOTET.XXRK. If the detected files have already been cleaned, deleted, or quarantined by your Trend Micro product, no further step is required. You may opt to simply delete the quarantined files. Please check this Knowledge Base page for more information.


Did this description help? Tell us how we did.