The original creator of the malware has released a decryption key so that victims can get their files back.
Graham Cluley explains:
The original developer of the Petya ransomware has released a master decryption key that works for all prevision versions of its enciphering creation.
On 5 July, a person or group by the name "Janus Cybercrime Solutions" tweeted out a link to an encrypted and password-protected file on Mega.nz, a cloud hosting service.
Cracking this file revealed a decryption key that works for previous versions of Petya, a form of ransomware which replaces an infected computer's Master Boot Record before encrypting the Master File Table. Petya has undergone several modifications since its detection in the spring of 2016.