How to block a spam attack?

This is something that comes up a fair bit, I am adding the feature to the 1.8 list