2

I recently was attacked by a ransomware that encrypted files in my computer and turning them into a .CRYSTAL file type. In the ransom note there is a “key id” which resembles a public key of sort, and a computer ID.

I paid - and got a “key” and a decryption program. This decrypts 70% of my server but all the larger files (more than 100MB) remain encrypted. Attacker demands another payment for them to release the “RSA key”. I’m uncertain whether this is a bluff and the file size condition is coded into the decryption program or if they actually used different key for large and small files.

Opening up the decryption exe file in hex editor, I discovered traces of Salsa20 and Chacha. I figured, what if I make the decryption script myself, I wouldn’t run into the file size limitation. The problem lies the initialization vector, how would I know what IV to use?

Thoughts?

40pro
  • 121
  • 2
  • You'd have to reverse engineer the malware to see how it generates the IV. It might be deterministically-generated based on some identifier for each file such as creation date, for example. – forest Jun 29 '21 at 02:14
  • Wouldn't it have to be something that is in the ransom note? Because when I requested for the "key", the asked for the ransom note. Assuming they needed those info to generate the "key". – 40pro Jun 29 '21 at 02:44
  • Asking for the ransom note likely allowed them to get the corresponding decryption key. It's not like they use the same key for everyone. Since it's RSA, it's usually public key cryptography. – forest Jun 29 '21 at 02:45
  • I thought so too. Except the “key” provided to me was a 32-character text. Not a private key. – 40pro Jun 29 '21 at 03:07
  • 2
    Strictly speaking, you can deterministically-generate a private RSA key from a shorter 32-byte key, but it's very possible that their server just stores all the keys used. If you're lucky, they're stupid and are using the same key for small files and big files, as you said. Do you known how to use a debugger? It might be pretty easy to find the key and figure out how it's generating the IV if you can attach a debugger while it's decrypting your smaller files. Then you can try to manually decrypt your larger ones. – forest Jun 29 '21 at 03:09

0 Answers0