Thankfully, it's relatively easy -- and free -- to protect your computer from bad rabbit ransomware. By simply tweaking a couple of files, you can stop the ransomware in its tracks. all you need to do is create two files (c:\windows\infpub.dat and c:\windows\cscc.dat) and remove all permissions from them. This means that even if you come into contact with Bad Rabbit, it will not be able to work its magic.
or you can do disabling the WMI service to prevent the spread of Bad Rabbit over a network.
To do this, use the following steps: