Stop Forum Spam
I'm impressed with a site that my friend Huw Reddick recently alerted me to called Stop Forum Spam. It's a database of IP's, user name's and emails that have been used to spam forums. If you run a forum or maintain forum software then it's a great resource to query when someone's registering on your forum to try and cut down on spammers joining your forum. You can also submit spammer information to their database (manually) at this link. If, however, you're like me and hate spammers but are also very lazy then you'll want to automate this process as much as possible. Here's some C# code that will submit the spammers info for you:
public bool SubmitForumSpammer(string ip, string username, string email, string apikey)
{
WebRequest req = WebRequest.Create("http://www.stopforumspam.com/add");
string postData = String.Format("username={0}&email={1}&ip_addr={2}&api_key={3}", username, email, ip, apikey);
byte[] send = Encoding.Default.GetBytes(postData);
req.Method = "POST";
req.ContentType = "application/x-www-form-urlencoded";
req.ContentLength = send.Length;
Stream sout = req.GetRequestStream();
sout.Write(send, 0, send.Length);
sout.Flush();
sout.Close();
WebResponse res = req.GetResponse();
StreamReader sr = new StreamReader(res.GetResponseStream());
string returnvalue = sr.ReadToEnd();
return returnvalue.Contains("Data submitted successfully");
}