Concerned about system data due to ransomware attacks

Concerned about system data due to ransomware attacks

What will happen to my data if the system is corrupted by ransomware attacks?