Remove Dharma Ransomware Virus and Restore .onion Encrypted Files

New Dharma Ransomware – Remove and Restore .onion Files

An article created to display how to remove the .onion variant of Dharma ransomware and how to restore files encrypted by this virus.

Dharma ransomware infection has been reported to be spread in a new ransomware variant that is using the .onion file extension and the e-mail address []. The ransomware virus is believed to be extremely similar to the latest CrySiS Globe ransomware infection, using the file extension .[].onion. The relation between the two ransomware viruses may be due to them both being part of the CrySiS ransomware family. In case you have become a victim of the Dharma .onion ransomware, we recommend you to read this article thoroughly.

Threat Summary


Dharma .onion

Short Description.Onion virus, also calling itself Dharma encrypts user files and leaves as contact e-mail addresses to contact the criminals behind it and pay a ransom fee to restore encrypted files.
SymptomsChanges file extension of encrypted files to .onion. Changes wallpaper to one with ransom instructions that have ransom e-mail.
Distribution MethodVia an Exploit kit, Dll file attack, malicious JavaScript or a drive-by download of the malware itself in an obfuscated manner.
Detection Tool See If Your System Has Been Affected by Dharma .onion


Malware Removal Tool

User ExperienceJoin our forum to Discuss Dharma .onion.
Data Recovery ToolWindows Data Recovery by Stellar Phoenix Notice! This product scans your drive sectors to recover lost files and it may not recover 100% of the encrypted files, but only few of them, depending on the situation and whether or not you have reformatted your drive.

Update June 2017 – New Data Recovery Method

It has been brought to our attention that victims of the latest Dharma .onion ransomware infection variants have managed to restore a very high percentage (over 90%) of their files using a very unique method – converting files into virtual drives and then using partition recovery option on data recovery programs. This method takes advantage of the converting the files into a .VHD file type which is a virtual drive. Since there are new data recovery programs specifically designed to recover partitions, one approach is to restore files encrypted by Dharma ransomware is to convert the encrypted files into .VHD files and then try to recover them using partition recovery software. Since the algorithm that encrypts files actually alters only a small portion of the file, you have a much higher chance of recovering the files if you change them into .VHD type.

The methods have been reported to not be a full guarantee to recover all the files, but if you haven’t reinstalled your operating system yet, we advise you to follow them. But first, make sure to remove Dharma’s malicious files from the instructions at the bottom of these article. Here are the instructions:

.onion Recovery Instructions 2017

Step 1: Make sure to make copies of the .onion encrypted files on another drive or PC:

Step 2: After creating the copies, download a tool that converts files in .VHD format. One good tool is Microsoft’s VHD conversion software. You can download it, by clicking on the button below:



Step 3: Now, make sure to rename a file that you want to recover in the .VHD file extension. For example, if the file is test.onion, it should be test.vhd

Step 4: Now you need to run the VHDTOOL you previously downloaded from Windows Command Prompt. To do this, run Windows Command Prompt as an administrator by typing “cmd” in Windows Search and right-clicking after which choosing “Run as administrator”.

Then type the following commands exactly as it they are:

→ cd {The location of the file, for example C:\Users\Lenovo\Desktop}
vhdtool.exe /convert “{the location of your file and the name goes here}

The final result should look like the following image:

Step 5: After you convert the drive into VHD, make sure to mount it on your computer. To do this:

Right-click on My Computer or This PC and then click on “Manage”

Then right-click on Disk Management after which click on Attach VHD

Then click on the Browse button in order to locate and open the .vhd file

After this, to initialize the disk, right-click on it and click New Simple Volume. After this click on Next and set it up:

At the end, the volume should appear like the following:

Step 6: Download and recover the .VHD image using data recovery software. The data recovery software you should download has to support the option “Partition Recovery”. Here is a comprehensive list of multiple data recovery programs that are able to recover partitions:

Another scenario with which we have reports of over 90% of recovered files includes the usage of a program for Virtual Drive Recovery, since .VHD is essentially a virtual drive. Such programs are created with the sole purpose of recovering .VHD files. One of those programs is called BitRecover Virtual Drive Recovery Wizard.

Dharma .onion File Virus – More Information

Dharma ransomware is a file-encrypting type of infection that aims for one thing only – to render important documents and other files on the infected computer corrupt and ask a ransom to be paid for their decryption.

Dharma .onion Virus Files – Distribution

The distribution of the .onion virus files is conducted in more than one way. For the distribution, different tools and programs may be utilized, like:

  • Exploit kit.
  • File Joiners.
  • Executable files that are obfuscated.
  • Droppers.
  • Downloaders.
  • Online hosts for distribution where the malicious files are stored.
  • Websites for the command and control server.
  • Spam services or spamming software.

The combination of these tools may result in the infection of Dharma ransomware’s .onion variant on multiple different locations:

  • Spammed as e-mail messages that contain malicious e-mail attachments or web links.
  • Sent via online chat programs.
  • Spammed via social media.

The most often used technique for the distribution of malicious files is via spammed e-mail messages that contain deceptive information, such as fake invoice of a purchase the victim has not made or other scamming claims. One example of such e-mail containing malicious attachment can be seen below:

Dharma .onion Ransomware – Malicious Activity

Once a malicious file or script has been activated, Dharma .onion ransomware’s payload may be dropped via a loader, dropper or a downloader malware which self-deletes afterwards. The malicious files off the virus may exist in the key Windows folders under different names:

As soon as this variant of Dharma ransomware has dropped it’s malicious files on the compromised computer, the virus could modify the Run and RunOnce Windows registry sub-keys. In those keys, values may be added that modify the wallpaper and automatically open files on system startup. One of those files may be the malicious file of Dharma .onion virus which causes the encryption process.

In addition to this process, Dharma ransomware may also execute multiple different iterations of the vssadmin command as an administrator. The command is for Windows Command Prompt and looks like the following:

Usually the delete-shadows part of the command, means that Dharma .onion ransomware may delete volume shadow copies to make file restoration via Windows backup impossible.

Other suspicious activity of the .onion Dharma ransomware include the creating of a folder, named “data” in %System Drive%.

.onion Dharma – Encryption Activity

The process of encoding files by Dharma is similar to the one used by the older variant of the virus. At the start, the virus begins to scan whether or not it is ran on a virtual drive and if so, it may shut down and self-delete. If not, the ransomware begins to scan your computer for important files, such as:

  • Microsoft Office documents.
  • Adobe .PDF documents.
  • Virtual drive images.
  • Photos and other image files.
  • Music and other audio data.
  • Videos.
  • System image files.
  • Files related to often used software.

As soon as these pre-configured set of files Dharma .onion is programmed to scan are detected, the virus may append the Advanced Encryption Algorithm on them, otherwise known as AES. The AES cipher replaces blocks of data on the files with symbols from the algorithm. This renders the files no longer openable and they seem corrupt. After the encryption process has completed, Dharma ransomware leaves the files with the .onion file extension, making them look like the following:

After the encryption process has completed, Dharma .onion ransomware generates unique keys and may leave a ransom note with clear demands to make a ransom payoff in BitCoin in order to restore the encrypted files. Upon payment from the victim, he or she receives via the mail in the extension a message with the software which scans for the key. After the key is scanned and copied and sent back to the cyber-crooks, they send back a unique decrypter with the embedded decryption key corresponding to the public one sent by the victim wo scanned it.

Remove Dharma Ransomware and Restore .onion Encrypted Files

Viruses like Dharma have previously been decrypted as it happened with the first variant using the .dharma file extension. This is why it is strongly recommended to backup your encrypted files before removing the virus.

For the removal process of Dharma ransomware, recommendations are to focus on following the removal instructions below. They will help isolate this variant of Dharma ransomware after which remove the malicious files. In case manual removal may represent difficulty to you, security experts always give recommendations to download and install an advanced anti-malware program on your computer. It will ensure that Dharma .onion ransomware is permanently removed automatically and will protect your computer in real-time as well.

Regarding the situation with the encrypted files, malware researchers advise not to pay any ransom to the virus. They keep monitoring the virus and hopefully should come up with decryption instructions soon. In the meantime, we advise you to perform the actions the following steps:

1. Backup the encrypted files and create several copies of them.
2. Remove Dharma, preferably by following the instructions below.
3. Focus on trying to restore the files using alternative methods, like the ones we have suggested below in step “2. Restore files encrypted by Dharma .onion”.


Ventsislav Krastev

Ventsislav has been covering the latest malware, software and newest tech developments at SensorsTechForum for 3 years now. He started out as a network administrator. Having graduated Marketing as well, Ventsislav also has passion for discovery of new shifts and innovations in cybersecurity that become game changers. After studying Value Chain Management and then Network Administration, he found his passion within cybersecrurity and is a strong believer in basic education of every user towards online safety.

More Posts - Website

Follow Me:

Leave a Comment

Your email address will not be published. Required fields are marked *

Time limit is exhausted. Please reload CAPTCHA.

Share on Facebook Share
Share on Twitter Tweet
Share on Google Plus Share
Share on Linkedin Share
Share on Digg Share
Share on Reddit Share
Share on Stumbleupon Share