Twice in the space of six weeks, the world has suffered major attacks of ransomware — malicious software that locks up photos and other files