Hacked Sites, how Google helps
Site Hacked and removed from Google? Now what?
While still very rare in our day to day dealings with many sites and many sectors occasionally various hacking schemes in other sectors (the usual supsects pills, p**n and gambling) come to light. Usually they will add in some text and links through to their own sites in order to get rankings and traffic. And while very unlikley it is worth bearing in mind that if this does happen to your site you may be removed from the search engines even though it is not your fault.
Typically the hacks are usually conducted on out of date blogging platforms so the first thing you really should do is to make sure you are installing updates as they are made available. Or sometimes sites may get modified through insecure directories that has open permissions.
Matt Cutts posted here on why Google removes hacked sites (because they may contain malware and infect other sites) but he also explains what Google wil do to alert site owners of the situation which is to send emails to known contact addresses such as email@example.com, firstname.lastname@example.org email@example.com and so on. Do you monitor those email addresses?
Not only that they will also try to contact you via your Webmaster console so we really do recommend you keep an eye open here for any messages and warnings.
When Google contact you they will outline the known issues, explain why they have removed you and more importantly what you need to do to get back into their index.
Now hopefully this will not happen to you but if it does Google will try to help you through the process which we think is cool.