Web Design Forums

Software Articles & Tutorials

Read about using Apache, Outlook, and other web design- and Internet-related software.

An easy way to remove large percentages of spam (multi-post tutorial)



Site of the Month Voting - Now Open. CAST YOUR VOTE NOW!

Reply
 
LinkBack Thread Tools
Old November 23 '03, 01:29 AM (#1)
TheGAME1264 is offline
Mod-son Canadian
 
TheGAME1264's Avatar
 
Join Date: December 2002
Location: Toronto, Ontario
Posts: 3,032
TheGAME1264 has disabled reputation
An easy way to remove large percentages of spam (multi-post tutorial)

I've been sitting here for a few hours analyzing the spam that comes in for one of my clients. At least 10 or 15 of those lovely Viagra and porn and gambling emails come in every single day, without fail. After three hours of looking, I finally discovered something that a number of them had in common.

To understand what they all have in common, consider the following email screenshot:
Attached Thumbnails
surfaceappearance_gif  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old November 23 '03, 01:33 AM (#2)
TheGAME1264 is offline
Mod-son Canadian
 
TheGAME1264's Avatar
 
Join Date: December 2002
Location: Toronto, Ontario
Posts: 3,032
TheGAME1264 has disabled reputation
Part 2

On the surface, it appears that you can cue off of many of the words and phrases in the email, such as "Free cash grant", "Never Repay", and other such uncommonly-used phrases.

Doing this will block a few of the emails (mostly the plain text ones). However, it will not block most of the HTML-formatted emails. An examination of the message source code reveals something rather interesting, which I have circled a few times in pinkish circles to make them stand out.
Attached Thumbnails
hiddentag_gif  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old November 23 '03, 01:40 AM (#3)
TheGAME1264 is offline
Mod-son Canadian
 
TheGAME1264's Avatar
 
Join Date: December 2002
Location: Toronto, Ontario
Posts: 3,032
TheGAME1264 has disabled reputation
As you can see, the beginning of the HTML comment tag, <!, is used rather frequently and ubiquitously throughout the document. The purpose of this tag, in the spam context, is to "split up" a potentially blockable word or phrase into a string that reads perfectly normally on the surface, but is really a string of nonsensical gibberish underneath.

Upon inspection of every non-spammy HTML-based email that was sent to my clients, I have found that not one of them has had this tag in it. Nor should these emails, as they would likely have been previewed and developed using a web browser (or multiples) first, and then further tested via different email clients. Based on this, I made the conclusion that it is safe to block the offending <! tag. This is the purpose and motive of this tutorial.

Disclaimer/cautionary note: if you do receive non-spammy HTML email with comment tags in it, this tutorial is not going to work in your particular situation and I assume no responsiblity if you employ this tutorial method and end up losing important email.

Okay, back to business. The following steps have been prepared using IMail, so modify them accordingly to suit your particular email server software.

Step 1: Log into your IMail administrator account (this is the account from which the admin assigns other email accounts and forwards) and select "Domain Processing Rules". This will allow you to select the processing rules for all email addresses within a domain (e.g. a@domain.com, b@domain.com, c@domain.com).
Attached Thumbnails
domainprocessing_gif  

Last edited by TheGAME1264; November 23 '03 at 01:53 AM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old November 23 '03, 01:41 AM (#4)
TheGAME1264 is offline
Mod-son Canadian
 
TheGAME1264's Avatar
 
Join Date: December 2002
Location: Toronto, Ontario
Posts: 3,032
TheGAME1264 has disabled reputation
Go down to the bottom of your domain processing rules list and select "Add" to add your new rule.
Attached Thumbnails
ruleslist_gif  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old November 23 '03, 01:44 AM (#5)
TheGAME1264 is offline
Mod-son Canadian
 
TheGAME1264's Avatar
 
Join Date: December 2002
Location: Toronto, Ontario
Posts: 3,032
TheGAME1264 has disabled reputation
You should now see a screen that allows you to enter in your rule to be added. Select "Body" from the "Field" listbox, "Contains" from the radio box, and type in <! (- the Code part). When you're finished and your screen looks like my screen capture, click "Add Condition".
Attached Thumbnails
addthecondition_gif  

Last edited by TheGAME1264; November 23 '03 at 01:52 AM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old November 23 '03, 01:49 AM (#6)
TheGAME1264 is offline
Mod-son Canadian
 
TheGAME1264's Avatar
 
Join Date: December 2002
Location: Toronto, Ontario
Posts: 3,032
TheGAME1264 has disabled reputation
Scroll down to the bottom of the "Add Condition" screen and you will see something that looks like the attached screen capture. To complete your work, simply select "Delete" from the Destination listbox.

Note: as an alternative, you could create a new user/email in the admin section called "possiblespam@domain.com" or something like that and have all the offending emails you receive to it. To do so, simply leave the listbox alone (by default, "Move the message to this mailbox"

Mind you, this would only be necessary if you think you get HTML email that is non-spammy and contains comment tags, and at least 99% of the time, this is not going to be the case.


When you're done, click "Finish" and your rule will be added. This won't get rid of all of your spam email, but it should get rid of at least 50% of it. Applying this with the common words and phrases that one can associate with spam (e.g. "Viagra", "*****", "Free Porn", "Big Casino Payouts") should keep the spam you actually receive to a minimum.
Attached Thumbnails
conditionadded_gif  

Last edited by TheGAME1264; November 23 '03 at 01:56 AM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old November 23 '03, 01:32 PM (#7)
DanielOliver is offline
Dan the man
 
DanielOliver's Avatar
 
Join Date: June 2003
Location: Cornwall, England.
Posts: 1,202
DanielOliver has disabled reputation
Send a message via AIM to DanielOliver Send a message via MSN to DanielOliver
Nice tutorial, very handy, when I have more time I will deffinatly look further into it despite the fact that I am not recieving to much spam on important e-mail address's, its just my daniboy125 [at] hotmail.com that gets thousands and thousand a day.

I have to go on and delete my junk box everynight, otherwise my account size is over limit.

I hate spam!!!!!!


Nice work, good turorial.
Daniel.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old November 23 '03, 03:46 PM (#8)
TheGAME1264 is offline
Mod-son Canadian
 
TheGAME1264's Avatar
 
Join Date: December 2002
Location: Toronto, Ontario
Posts: 3,032
TheGAME1264 has disabled reputation
Thankya. Anything to stem the increase in cranial trauma that occurs when one bangs one's head off of one's desk after reading "Enlarge your manhood today!" for the 500th time.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old November 23 '03, 03:48 PM (#9)
justlivyalife is offline
Retired
 
justlivyalife's Avatar
 
Join Date: July 2003
Location: Birmingham, UK
Posts: 2,871
justlivyalife is an unknown quantity at this point
I remember going on holiday once and returning home to find my inbox full up of emails of that sort, about 2000 in about 2 weeks if I recall.

Great Tutorial BTW.

Last edited by justlivyalife; November 23 '03 at 03:48 PM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old December 2 '03, 10:07 AM (#10)
sopiaz57 is offline
WDF Member
 
sopiaz57's Avatar
 
Join Date: September 2003
Posts: 41
sopiaz57
Are you running imail on a win2k box?

how do you like imail?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old December 2 '03, 11:41 AM (#11)
TheGAME1264 is offline
Mod-son Canadian
 
TheGAME1264's Avatar
 
Join Date: December 2002
Location: Toronto, Ontario
Posts: 3,032
TheGAME1264 has disabled reputation
My host does that. I don't host my own box. But it is a Win2K box.

Overall, I don't mind it from a strictly admin point of view (adding/deleting/modifying user accounts). I feel that by default, it leaves something to be desired as far as general user-friendliness and aesthetics are concerned. It's not a big issue for me, though, since 99% of my clients and their employees use a POP3 program to check their email anyway. A few use the IMail setup on occasion (myself included if I'm on the road), and I know there's a way to "skin it". I just haven't bothered to do so yet due to time restrictions.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old December 12 '03, 02:05 PM (#12)
actualsize82 is offline
WDF Member
 
actualsize82's Avatar
 
Join Date: November 2003
Location: Chicago, IL
Posts: 41
actualsize82
Send a message via AIM to actualsize82
Great idea...what about those of us who aren't doing are emails in an admin setting (more like...using Microsoft Outlook). Any suggestions/step-by-steps for that program?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old December 12 '03, 02:14 PM (#13)
TheGAME1264 is offline
Mod-son Canadian
 
TheGAME1264's Avatar
 
Join Date: December 2002
Location: Toronto, Ontario
Posts: 3,032
TheGAME1264 has disabled reputation
I know there's a way to do it in Outlook using the Rules Wizard. Mind you, I haven't played with Outlook in years so I couldn't tell you exactly how it's done. Basically, you want the same concept though: you want to make sure that any messages with "<!" in the body are deleted from the server.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old December 12 '03, 05:26 PM (#14)
actualsize82 is offline
WDF Member
 
actualsize82's Avatar
 
Join Date: November 2003
Location: Chicago, IL
Posts: 41
actualsize82
Send a message via AIM to actualsize82
Thank you! I'll look into it and post a tutorial on it once I figure it out.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old December 12 '03, 06:42 PM (#15)
TheGAME1264 is offline
Mod-son Canadian
 
TheGAME1264's Avatar
 
Join Date: December 2002
Location: Toronto, Ontario
Posts: 3,032
TheGAME1264 has disabled reputation
Sweet. Tutorial sequels. It's like Star Wars...only...for...web design...yeah.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply

  Web Design Forums » Web Design Help » Articles & Tutorials » Software Articles & Tutorials

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


 
User Infomation
Your Avatar

Site Of The Month
Nominate Your Site Now!

Advertisement
WolfCMS.org

Latest Articles
- by RickM
- by bfsog

Advertisement

Partner Links



All times are GMT -4. The time now is 01:56 PM.


WebDesignForums.net is Copyright © 2010 RikeMedia.

SEO by vBSEO

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164