text
stringlengths
1
38.9k
We also believe the tasking to have been temporary , because we have not observed any further similar targeting from the Dukes after the spring of 2014 .
While MiniDuke activity decreased significantly during the rest of 2013 following the attention it garnered from researchers , the beginning of 2014 saw the toolset back in full force .
All MiniDuke components , from the loader and downloader to the backdoor , had been slightly updated and modified during the downtime .
Interestingly , the nature of these modifications suggests that their primary purpose was to regain the element of stealth and undetectability that had been lost almost a year earlier .
Of these modifications , arguably the most important were the ones done to the loader .
These resulted in a loader version that would later become known as the β€œ Nemesis Gemina loader ” due to PDB strings found in many of the samples .
It is however still only an iteration on earlier versions of the MiniDuke loader .
The first observed samples of the Nemesis Gemina loader ( compiled on 14th December 2013 ) were used to load the updated MiniDuke backdoor , but by the spring of 2014 the Nemesis Gemina loader was also observed in use with CosmicDuke .
Following the MiniDuke expose , CosmicDuke in turn got its moment of fame when F-Secure published a whitepaper about it on 2nd July 2014 .
The next day , Kaspersky also published their own research on the malware .
It should be noted that until this point , even though CosmicDuke had been in active use for over 4 years , and had undergone minor modifications and updates during that time , even the most recent CosmicDuke samples would often embed persistence components that date back to 2012 .
These samples would also contain artefacts of functionality from the earliest CosmicDuke samples from 2010 .
It is therefore valuable to observe how the Dukes reacted to CosmicDuke ’s outing at the beginning of July .
By the end of that month , CosmicDuke samples we found that had been compiled on the 30th of July had shed unused parts of their code that had essentially just been relics of the past .
Similarly , some of the hardcoded values that had remained unaltered in CosmicDuke samples for many years had been changed .
We believe these edits were an attempt at evading detection by modifying or removing parts of the toolset that the authors believed might be helpful in identifying and detecting it .
Concurrently with the alterations to CosmicDuke , the Dukes were also hard at work modifying their trusted loader .
Much like the CosmicDuke toolset , the loader used by both MiniDuke and CosmicDuke had previously only undergone one major update ( the Nemesis Gemina upgrade ) since the first known samples from 2010 .
Again , much of the modification work focused on removing redundant code in an attempt to appear different from earlier versions of the loader .
Interestingly however , another apparent evasion trick was also attempted - forging of the loaders ’ compilation timestamps .
The first CosmicDuke sample we observed after the initial research on CosmicDuke was a sample compiled on the 30th of July 2014 .
The loader used by the sample purported to have been compiled on the 25th of March 2010 .
Due to artefacts left in the loader during compilation time however , we know that it used a specific version of the Boost library , 1.54.0 , that was only published on the 1st of July 2013 .
The compilation timestamp therefore had to have been faked .
F-Secure ’s whitepaper on CosmicDuke includes a timeline of the loader ’s usage , based on compilation timestamps .
Perhaps the Dukes group thought that by faking a timestamp from before the earliest one cited in the whitepaper , they might be able to confuse researchers .
During the rest of 2014 and the spring of 2015 , the Dukes continued making similar evasionfocused modifications to CosmicDuke , as well as experimenting with ways to obfuscate the loader .
In the latter case however , the group appear to have also simultaneously developed an entirely new loader , which we first observed being used in conjunction with CosmicDuke during the spring of 2015 .
While it is not surprising that the Dukes reacted to multiple companies publishing extensive reports on one of their key toolsets , it is valuable to note the manner in which they responded .
Much like the MiniDuke expose in February 2013 , the Dukes again appeared to prioritize continuing operations over staying hidden .
They could have ceased all use of CosmicDuke ( at least until they had developed a new loader ) or retired it entirely , since they still had other toolsets available .
Instead , they opted for minimal downtime and attempted to continue operations , with only minor modifications to the toolset .
While we now know that CozyDuke had been under development since at least the end of 2011 , it was not until the early days of July 2014 that the first large-scale CozyDuke campaign that we are aware of took place .
This campaign , like later CozyDuke campaigns , began with spear-phishing emails that tried to impersonate commonly seen spam emails .
These spear-phishing emails would contain links that eventually lead the victim to becoming infected with CozyDuke .
Some of the CozyDuke spear-phishing emails from early July posed as e-fax arrival notifications , a popular theme for spam emails , and used the same β€œ US letter fax test page ” decoy document that was used a year later by CloudDuke .
In at least one case however , the email instead contained a link to a zip archive file named β€œ Office Monkeys LOL Video.zip ” , which was hosted on the DropBox cloud storage service .
What made this particular case interesting was that instead of the usual dull PDF file , the decoy was a Flash video file , more specifically a Super Bowl advertisement from 2007 purporting to show monkeys at an office .
THE DUKES 7 YEARS OF RUSSIAN CYBERESPIONAGE .
Release_Time : 2015-09Report_URL : https://blog-assets.f-secure.com/wp-content/uploads/2020/03/18122307/F-Secure_Dukes_Whitepaper.pdf2014 : OnionDuke gets caught using a malicious Tor node .
On the 23rd of October 2014 , Leviathan Security Group published a blog post describing a malicious Tor exit node they had found .
They noted that this node appeared to be maliciously modifying any executables that were downloaded through it over a HTTP connection .
Executing the modified applications obtained this way would result in the victim being infected with unidentified malware .
On the 14th of November , F-Secure published a blog post naming the malware OnionDuke and associating it with MiniDuke and CosmicDuke , the other Duke toolsets known at the time .
Based on our investigations into OnionDuke , we believe that for about 7 months , from April 2014 to when Leviathan published their blog post in October 2014 , the Tor exit node identified by the researchers was being used to wrap executables on-the-fly with OnionDuke ( image 7 , page 13 ) .
This is similar to the way in which the toolset was being spread via trojanized applications in torrent files during the summer of 2013 .
While investigating the OnionDuke variant being spread by the malicious Tor node , we also identified another OnionDuke variant that appeared to have successfully compromised multiple victims in the ministry of foreign affairs of an Eastern European country during the spring of 2014 .
This variant differed significantly in functionality from the one being spread via the Tor node , further suggesting that different OnionDuke variants are intended for different kinds of victims .
We believe that , unusually , the purpose of the OnionDuke variant spread via the Tor node was not to pursue targeted attacks but instead to form a small botnet for later use .
This OnionDuke variant is related to the one seen during the summer of 2013 being spread via torrent files .
Both of these infection vectors are highly indiscriminate and untargeted when compared to spearphishing , the usual infection vector of choice for the Dukes .
Further , the functionality of the OnionDuke variant is derived from a number of modules .
While one of these modules gathers system information and another attempts to steal the victim ’s usernames and passwords , as one would expect from a malware used for a targeted attack , the other two known OnionDuke modules are quite the opposite ; one is designed for use inattacks and the other for posting predetermined messages to the Russian VKontakte social media site .
This sort of functionality is more common in criminality-oriented botnets , not statesponsored targeted attacks .
We have since been able to identify at least two separate OnionDuke botnets .
We believe the formation of the first of these botnets began in January 2014 , using both unidentified infection vectors and the known malicious Tor node , and continued until our blogpost was published in November .
We believe the formation of the second botnet began in August 2014 and continued until January 2015 .
We have been unable to identify the infection vectors used for this second botnet , but the C&C servers it used had open directory listings , allowing us to retrieve files containing listings of victim IP addresses .
The geographic distribution of these IP addresses ( image 8 , page 13 ) further supports our theory that the purpose of this OnionDuke variant was not targeted attacks against high-profile targets .
One theory is that the botnets were a criminal side business for the Dukes group .
The size of the botnet however ( about 1400 bots ) is very small if its intended use is for commercial DoS attacks or spam-sending .
Alternatively , OnionDuke also steals user credentials from its victims , providing another potential revenue source .
The counter to that argument however is that the value of stolen credentials from users in the countries with the highest percentage of OnionDuke bots ( Mongolia and India ) are among the lowest on underground markets .
2015 : The Dukes up the ante .
The end of January 2015 saw the start of the most high- volume Duke campaign seen thus far , with thousands of recipients being sent spear-phishing emails that contained links to compromised websites hosting CozyDuke .
Curiously , the spear-phishing emails were strikingly similar to the e-fax themed spam usually seen spreading ransomware and other common crimeware .
Due to the sheer number of recipients , it may not have been possible to customize the emails in the same way as was possible with lower-volume campaigns .
The similarity to common spam may however also serve a more devious purpose .
It is easy to imagine a security analyst , burdened by the amount of attacks against their network , dismissing such common-looking spam as β€œ just another crimeware spam run ” , allowing the campaign to , in essence , hide in the masses .
The CozyDuke activity continues one of the long-running trends of the Dukes operations , the use of multiple malware toolsets against a single target .
In this case , the Dukes first attempted to infect large numbers of potential targets with CozyDuke ( and in a more obvious manner than previously seen ) .
They would then use the toolset to gather initial information on the victims , before deciding which ones to pursue further .
For the victims deemed interesting enough , the Dukes would then deploy a different toolset .
We believe the primary purpose of this tactic is an attempt at evading detection in the targeted network .
Even if the noisy initial CozyDuke campaign is noticed by the victim organization , or by someone else who then makes it publicly known , defenders will begin by first looking for indicators of compromise ( IOCs ) related to the CozyDuke toolset .
If however by that time the Dukes are already operating within the victim ’s network , using an another toolset with different IOCs , then it is reasonable to assume that it will take much longer for the victim organization to notice the infiltration .
In previous cases , the group used their malware toolsets interchangeably , as either the initial or a later-stage toolset in a campaign .
For these CozyDuke campaigns however , the Dukes appear to have employed two particular later-stage toolsets , SeaDuke and HammerDuke , that were purposely designed to leave a persistent backdoor on the compromised network .
HammerDuke is a set of backdoors that was first seen in the wild in February 2015 , while SeaDuke is a crossplatform backdoor that was , according to Symantec , first spotted in the wild in October 2014 .
Both toolsets were originally spotted being deployed by CozyDuke to its victims .
What makes SeaDuke special is that it was written in Python and designed to work on both Windows and Linux systems ; it is the first cross-platform tool we have seen from the Dukes .
One plausible reason for developing such a flexible malware might be that the group were increasingly encountering victim environments where users were using Linux as their desktop operating system .
Meanwhile , HammerDuke is a Windows only malware ( written in .NET ) and comes in two variants .
The simpler one will connect to a hardcoded C&C server over HTTP or HTTPS to download commands to execute .
The more advanced variant , on the other hand , will use an algorithm to generate a periodically-changing Twitter account name and will then attempt to find tweets from that account containing links to the actual download location of the commands to execute .
In this way , the advanced HammerDuke variant attempts to hide its network traffic in more legitimate use of Twitter .
This method is not unique to HammerDuke , as MiniDuke , OnionDuke , and CozyDuke all support similar use of Twitter ( image 9 , page 18 ) to retrieve links to additional payloads or commands .
2015 : CloudDuke .
In the beginning of July 2015 , the Dukes embarked on yet another large-scale phishing campaign .
The malware toolset used for this campaign was the previously unseen CloudDuke and we believe that the July campaign marks the first time that this toolset was deployed by the Dukes , other than possible small-scale testing .
The CloudDuke toolset consists of at least a loader , a downloader , and two backdoor variants .
Both backdoors ( internally referred to by their authors as β€œ BastionSolution ” and β€œ OneDriveSolution ” ) essentially allow the operator to remotely execute commands on the compromised machine .
The way in which each backdoor does so however is significantly different .
While the BastionSolution variant simply retrieves commands from a hard-coded C&C server controlled by the Dukes , the OneDriveSolution utilizes Microsoft ’s OneDrive cloud storage service for communicating with its masters , making it significantly harder for defenders to notice the traffic and block the communication channel .
What is most significant about the July 2015 CloudDuke campaign is the timeline .
The campaign appeared to consist of two distinct waves of spear-phishing , one during the first days of July and the other starting from the 20th of the month .
Details of the first wave , including a thorough technical analysis of CloudDuke , was published by Palo Alto Networks on 14th July .
This was followed by additional details from Kaspersky in a blog post published on 16th July .
Both publications happened before the second wave took place and received notable publicity .
Despite the attention and public exposure of the toolset ’s technical details ( including IOCs ) to defenders , the Dukes still continued with their second wave of spear-phishing , including the continued use of CloudDuke .