When foraying online prevention is the best cure. I take the following measures:1) Keep your Operating System up to date with the latest updates.2) keep your browser up to date with the latest updates.3) Avoid clicking on advertisements.4) Never believe unbelievable offers arriving through email. Be ware of magic cures arriving through email. Be suspicious of everything until you are convinced otherwise. Never click on links in email unless you are100% sure they are genuine.5) Don't trust your friends. Always keep in mind that if their accounts get hacked it is possible that you might also receive malicious emails appearing that they are genuine.6) Use a strong password in all you accounts. Never repeat the same password in two online services. Strong password guidelines: http://en.wikipedia.org/wiki/Password_strength#Common_guidelines7) There is no free lunch. Always avoid websites that offer "free" software or "free" anything unless you understand their business model. E.g. Free email from Google, Microsoft, Yahoo, etc. is genuine because you understand that they sell you ads in return for the service they provide.