You create a script that checks referrer, user-agent, and IP address then updates .htaccess to ban them. Do you need some help creating one of these? What website are you trying to do this on?
I have no idea how to do all that. Its on my mail server not the http side. Emails, so I figure it'd have to happen on that level right? You can't stop mails from .htaccess can you?
Can't say I have the answer but editing your .htaccess file would be useless since it's a mail server thing, not an apache thing. You're best bet is probably just to use the best spam filters available. The other alternative is probably writing your own scripts to talk to the mail server. I'm not sure if you'd do it on the SMTP side or the POP side, but either way your scripting language would have to have the permissions to fool around with your mail stuff, which likely will not be the case on a virtual server.
You could write a simple filter that looks for words like "viagra" or "online perscriptions", etc. It wouldn't take long to compile a pretty sweet list of words that would drastically reduce spam. What are the odds your friends are going to email you talking about viagra? slim to none, so it works out good
I do that already, but these mails use an image and a bunch of random words/phrases which makes it a lot harder.
have you ever tried to use a blacklist for your mail server? I won't guaranty that it will cut all spam, but will help a lot.