In late February, CRIL observed a campaign that targets Russian individuals with the information stealer malware known as “SapphireStealer.” The SapphireStealer is an open-source information-stealing tool previously documented by Talos researchers. Since its initial public release in December 2022, it has been increasingly seen across various public malware sources.
Threat Actors (TAs) responsible for this campaign remain unidentified. We suspect the campaign begins with a spam email containing a link that leads to downloading an executable file (disguised with a PDF icon to deceive the recipient into thinking it is a PDF document) from a fake Russian government website URL.
The downloaded executable is identified as SapphireStealer that propagates from a counterfeit Russian government website (govermentu[.]ru) and is downloaded from the following URL:
Figure 1 – Legitimate & Fake Russian government website
The translated name of the downloaded file indicates that it relates to a resolution issued by a federal administration regarding the initiation of executive proceedings.
Upon running the executable file, it drops and opens a PDF document named “Постановлениe.pdf” (translated as: Resolution.pdf) while concurrently doing a covert data stealing operation in the background.
The lure pdf contains a scanned image of the document, which serves as a guideline for the recipient to carry out their duties in enforcing the court order against the debtor, as shown in the figure below.
Figure 2 – Lure PDF document
The following image displays another bait PDF utilized in this campaign named “Повестка.pdf” (translated as: Agenda.pdf), which is dropped and opened upon the execution of the “FederalnoeUpravlenie.exe” file.
This lure PDF also contains a scanned image of the document, which is a subpoena issued by a court in Russia, summoning an individual as a witness in a case involving an administrative violation.
Figure 3 – Lure PDF document
TAs are using deceptive legal documents in this campaign, which are used to implant fear and urgency in recipients, compelling them to take immediate action. These documents often contain threats of legal consequences with the fabricated legal matters. Recipients may be psychologically manipulated into opening attachments or clicking on links, exposing themselves to malware or phishing attempts.
The file “FederalnoeUpravlenie.exe” is a .NET executable, protected and obfuscated using .NET Reactor. It bears a PDF icon and has an approximate size of 1MB, as shown in the figure below.
Figure 4 – Icon of the Stealer file
Upon execution of the exe file, it begins by running the Main() function. This function initially retrieves an embedded PDF content from the .NET resource, saves it with the filename “Повестка.pdf”, and subsequently opens it using Process.Start(). This action displays the deceptive PDF document to the user, creating the illusion that they have opened a genuine PDF file, as shown in the below process tree.
Figure 5 – Process tree
The figure below shows the code snippet of the de-obfuscated Main() function, which drops and executes the lure PDF document for the victims.
Figure 6 – Main() function of the Stealer
The following figure depicts an embedded lure PDF content within the .NET resource named “Повестка_от_390”.
Figure 7 – Embedded lure PDF inside malware file resource section
After dropping and displaying the deceptive PDF, the malware commences its covert stealing operations by using the method, Class1.Log() in the background, unbeknownst to the victim, as shown below.
Figure 8 – Code snippet responsible for Stealer functionalities
The malware incorporates several encrypted strings. Throughout its code, the stealer employs the StringCipher.Decryptasdfasdfasdfs() function to decrypt and access necessary strings such as the name of folders created by the malware, file extensions to target, paths of browsers for stealing sensitive data, etc. This function decrypts ciphertext utilizing AES encryption, employing a specific key derived from a random number and salt, ultimately returning the decrypted plaintext.
The figure below shows the code snippet of the Decryptasdfasdfasdfs() function.
Figure 9 – Code used to decrypt the encrypted strings used by the stealer
When the function Class1.Log() is executed, it primarily invokes another significant method named Log2() within the class named “InstanceOfClass,” as shown in the figure below. This method carries out the core activities of the stealer, including the extraction of sensitive data, which is subsequently sent to the threat actor.
Figure 10 – SapphireStealer Operation code snippet
The steps detail the operations performed by the InstanseOfClass().Log2() method are outlined below.
Figure 11 – Targeted browsers & their paths of the Stealer
Figure 12 – Targeted extension for Grabbing files operation
Figure 13 – SapphireStealer malware directory
Figure 14 – Summary of the stolen details
Figure 15 – Code snippet for Exfiltration
The network traffic depicted in the following figure illustrates the communication between the victim’s system and the remote server, facilitating the exfiltration of the stolen data.
Figure 16 – Network details of Exfiltration to C&C
Threat Actors choose sensitive or official documents as lures due to their ability to manipulate emotions, create an illusion of authenticity, and attract a wide range of targets. This calculated use of social engineering techniques enhances the success of malware campaigns by helping attackers evade detection, as they masquerade as trustworthy and benign entities.
In this malware campaign, TAs are focusing on Russian individuals, utilizing a masqueraded Russian government website to distribute the malware, along with deceptive PDF documents written in Russian to mislead victims. Upon successful execution, the user becomes infected with the SapphireStealer, which then proceeds to extract sensitive information and send it to a remote server.
CRIL meticulously monitors the latest phishing or malware variants circulating, delivering timely analyses with actionable insights. This data aids users in fortifying their defenses against potential threats and attacks.
Tactic | Technique | Procedure |
Execution (TA0002) | Exploitation for Client Execution (T1203) | TAs uses lure PDF document execute the malicious code. |
Defense Evasion (TA0005) | Masquerading (T1036) | TAs uses fake Russian government site to spread malware. Icon mismatch, binary includes an Icon from a different legit application in order to fool users. |
Defense Evasion (TA0005) | Obfuscated Files or Information (T1027) | Binary may include packed or crypted data. |
Defense Evasion (TA0005) | Software Packing (T027.002) | Binary may include packed or crypted data. |
Defense Evasion (TA0005) | Deobfuscate/Decode Files or Information (T1140) | Decode data using Base64 in .NET |
Credential Access (TA0006) | OS Credential Dumping (T1003) | Tries to harvest and steal browser information (cookies, passwords, etc) |
Discovery (TA0007) | System Information Discovery (T1082) | Queries the system information (host name, IP address, etc). |
Discovery (TA0007) | File and Directory Discovery (T1083) | Stealer enumerate files for grabbing. |
Collection (TA0009) | Data from Local System (T1005) | Tries to harvest and steal browser information (cookies, passwords, etc) |
Collection (TA0009) | Archive Collected Data (T1560) | Stealer compress the stolen data with ZIP extension. |
C&C (TA0011) | Application Layer Protocol (T1071) | Malware exe communicate to C&C server. |
Indicators | Indicator Type | Description |
5c025a9e86a125bf2f2ca5c1b29b42a6 6b44ab6c246c077ee0e6f51300654b3eec2fddc7 850a99d2039dadb0c15442b40c90aa4dac16319114455ab5904aa51e062fe6e1 | MD5 SHA1 SHA256 | Sapphire Stealer exe |
55bb772aea4303ca373fd8940663b6bd b396a8d5e30fb179f3139d28b843b57bb8ae3f47 c816d0be8d180573d14d230b438a22d7dda6368b1ef1733754eda9804f295a2f | MD5 SHA1 SHA256 | Sapphire Stealer exe |
govermentu[.]ru | Domain | Phishing site |
hxxp://govermentu[.]ru/media/FederalnoeUpravlenie_postanovlenie_o_vozbuzdenie_ispolnitelnogo_proizvodstava[.]exe | URL | Malware download URL |
193.39.185[.]4 | IP | C&C |
https://blog.talosintelligence.com/sapphirestealer-goes-open-source