The 3 Line Bot Revealer.

Publicated on : 1185270783
This is probably the smallest and useful script I ever wrote. It is designed to trace email harvesters. Normally those bots will scrape websites and looking for "mailto" tags and such. Now I figured that while they scrape an email address they need to store it. And probably use different IP's to spam from. It's tough to correlate them together. This is where these 3 lines of code make a difference.

The idea is trivial, set up a catch-all email account somewhere and use this script. The script will take the IP and hostname from the bot and constructs his own signature as a new email address like: 255.222.2.2_lousyISP@thiswebsite.com. So that it e-mails me his own fingerprint. Of course this mailto tag is hidden. it's even better to randomize it and use different styles. I use IP and host because most bots won't reveal their hostname, in case you wondered about that also.

I wrote it just for fun, not to win prizes with.