Wannacry doesn't infect Linux machines. It uses CVE-2017-0146 and CVE-2017-0147 which is the NSA leak exploit which was released by Shadow Broker almost 3 weeks ago.
It does affect Linux machines with
It takes advantage of an SMB exploit.
There are 2 paths that can help you protect yourself.
- Make this domain available to your environment.
The wannacry uses this to detect if the environment is running under analysis or not. This domain was a unregistered domain until researchers realized. They made it and purchased to domain to stop the spreading.
On registering the ransomware thinks it is running under sandbox and hence stops
- Download the patch officially release by Microsoft.
Following is the link.
WannaCry is the ransomware affects only Windows systems.