Dansie Anti Spam 3.05 ReadMe
By Dansie Website Design
Version 3.0 Copyright  July 1, 2006
Version 1.0 Copyright  December 17, 2001
http://www.dansie.net


##############################################################
DISCLAIMER AND LEGAL STUFF:
##############################################################

# COPYRIGHT NOTICE AND SOFTWARE LICENSE AGREEMENT
# This script may only be used under license from www.dansie.net. If you
# feel you may have received an unlicensed or pirated copy, please contact
# piracy@dansie.net. 
# Use of the Dansie Anti Spam software is subject to the terms of the license
# agreement. By using this software you signify that you have read the license
# agreement and accept its terms. Your purchase of a Dansie Anti Spam software
# license entitles you to one (1) working copy of the script per license. You
# may NOT copy, reproduce, resell, or give away copies of the script in any way
# shape or form. A license is nontransferable from person to person. You may
# make one back up copy should something happen to the working copy on your
# host. You may not make any modifications to the Dansie Anti Spam script
# except as instructed in the ReadMe. The text links, graphic links, logos and
# copyright credit to http://www.dansie.net must remain in the script free of
# modification and appear on the various pages of Dansie Anti Spam script.
# Violation of this license agreement may void your right to technical support
# and subject you to legal action.

Do not modify the script except for the $vars variable near the top of the
script.

Modifying the script is a violation of the software license agreement and
copyrights and may subject you to legal action.

If you believe you may have received an unlicensed copy of this script or you
have information about someone conducting piracy, please contact us at:
piracy@dansie.net or http://www.dansie.net/question.html

Dansie Website Design will not be held responsible for any type of damage or
loss of time that may occur as a result of using this script. This includes but
is not limited to the corruption or loss of data on your server. (Not that we
intentionally put anything in it that will cause any problems on your server, we
just have to say this to cover ourselves.) Customer assumes full responsibility
for any damages or loss of time that may occur.

Refund Policy:

Make sure that your web host allows you to run CGI Perl scripts on your website
before you order. 30 day money back guarantee from the date of purchase if the
Dansie Anti Spam does not run on your website as advertised. For any and all
other reasons, all software license sales are final and are non-refundable. If
necessary, we will FTP in and get it running for you.

Please read all instructions below carefully.


##############################################################
CONTENTS OF ZIP FILE:
##############################################################

anti_spam.pl (The script)
ReadMe.txt   (Instructions)


##############################################################
IMPORTANT RULES OF THUMB:
##############################################################

You must know how to use an FTP (File Transfer Protocol) program to install this
script. You don't have to know anything about Perl or HTML. Always upload the
Perl script in ASCII format and chmod 755.

Cookies must be enabled in your browser. This program utilizes JavaScript. For
best results, be sure to use a late version of either Netscape or Microsoft
Internet Explorer. Other browsers may not be supported.

When teaching your filters, it's important to understand how YOU want to define
spam. Spam is bulk (or automated) unsolicited commercial email (BUCE). A
newsletter that you subscribed to may be automated, but it's not unsolicited. A
chain letter may be unsolicited, but not commercial. Your neighbor may email you
a sales pitch about cutting your lawn for you, but it's not bulk (automated),
it's personal. An email from your ex-wife would hardly be considered spam. Maybe
you should put her on your black list, but it's not spam. At dansie.net we get a
few legitimate emails each day asking for more information about some product
that we don't sell. Those aren't spam, just "wrong address". What you consider
to be spam may differ from what other people think. You may want to consider
chain letters and viruses as spam. Others may like to read chain letters and
some hackers like to play with the viruses. DAS will define and quarantine spam
the way YOU want it to, so it's completely up to you. Your filters will be
customized just for you. Just remember, you have other options besides the
"Quarantine & Learn: Spam" button, there is also the White List, Black List and
the "Trash" button. And hey, if you want to classify an email from your ex-wife
as spam, go right ahead! One more recommendation... if you want to get any
technical support, it's a good idea to put "@dansie.net" in your White List.


##############################################################
INSTALLATION INSTRUCTIONS:
##############################################################

1. UPLOAD: Upload the anti_spam.pl script in ASCII format (not binary) to your
cgi-bin and chmod it 755. What is chmod? See: http://wsftp.stormerhosting.com.
The script will make a subdirectory named "anti_spam" in your cgi-bin and store
all it's data files there. No data files will be made or stored in your cgi-bin
directory.

2. SET ADMIN PASSWORD: Point your browser at it like so:
http://www.YourName.com/cgi-bin/anti_spam.pl?login
and set your admin password! This is very important that you do it quickly
(before anyone else does). Bookmark this URL with the ?login query string. This
is how you will access the Admin Control Panel.

3. SET VARIABLES: After you have set your password you will be in the Admin
Control Panel: Main Menu. Click on "Change Variable Settings". You will notice
many variables are already set for you. Set each variable according to the
instructions for each variable. Of particular importance is the
"pop_accounts_TEXTAREA" variable. Set that as instructed with the system paths
and nicknames of all the POP accounts you want DAS to filter and manage for you.
Set write permissions on your POP accounts so DAS can write to them. Chmod 666
or 777.

4. WHITE/BLACK LISTS: From the Admin Control Panel: Main Menu, click "Email
Lists". Set your family, friends and colleagues email address in the White List
textarea. This will ensure their emails always get to you and never get
quarantined.

5. (a) TEACH/LEARN: Login and click on "All POP Accounts Summary", then select a
POP account to view. Checkmark all spams and then click "Quarantine & Learn:
Spam". Not only will the spam be transferred from your POP account to the
quarantine, DAS will also automatically "learn" what spam is at the same time.
The more spam you have, the better. Make sure no spams are remaining in the POP
account summary, click "Check All" and "Learn: Good". Now select "quarantine"
from the top drop-down menu, click "GO" and look for any possible good emails
there. Checkmark them, select a POP account from the drop-down menu above and
then click "Restore & Learn: Good". Checkmarking "Whitelist" will add the
sender's email address to your White List automatically. If you accidentally
click "Learn: Good" while a spam email was selected, or vice versa, just click
the "Undo last learn" button and it will restore the filters to their prior
state. Repeat this every day. Over the first few days you will see the filters
getting more and more accurate. The program simply "learns" from you as you sort
your mail and after a while, it will sort your mail better than you can. Well,
almost.

5. (b) TEACH/LEARN FASTER: If you happen to have a couple hundred spams and a
couple hundred good emails lying around up on your server, you can make your
filters accurate really quick. Put them in a POP account or misc directory and
follow the instructions above.

5. (c) REDIRECTING SPAM FROM YOUR PC: Another way to teach your filters is to
redirect spam email on your personal computer back to a special pop account on
your server such as "spam_learn@YourDomain.com". DAS can automatically find and
learn from that spam. Set the "spam_redirect_pop_account" variable in your
variable settings and then turn "spam_redirect_pop_account_auto_learn_SELECT" to
"on". Now, the next time a spam sneaks onto your personal computer, click
"redirect" in your personal computer's email client, and send. That's all you
need to do to inoculate yourself from receiving a spam like that again. No need
to login to DAS and adjust any filters- just click "redirect" and send. DAS will
take care of the filter adjusting for you automatically. Be sure you use
"redirect" and not "forward" as forwarding will change the body of the email. If
necessary, configure the email client on your PC so redirecting preserves the
body of the email as closely to the original as possible.

6. CRONJOB: Set a cronjob to execute the script every minute of every hour like
so:
* * * * * /home/yourname/public_html/cgi-bin/anti_spam.pl
This will keep the spam out of your POP account. If you aren't sure how to set a
cronjob, ask your host for assistance. Since the cronjob activates DAS to do the
filtering once every minute, be aware that if you check your email from your
personal computer's email client too frequently, you may download some spam that
DAS didn't get a chance to filter. You may redirect that spam back to the
"spam_redirect_pop_account" on your server to ensure future inoculation.


##############################################################
TROUBLE SHOOTING INSTALLATION:
##############################################################

Most common problems:

1. You didn't upload the script in ASCII format.
2. You didn't chmod the script 755.
3. Your host doesn't have your site properly configured to run Perl scripts.
4. Your server may not have all the required Perl modules required for this
script to run.
5. If the script executes, but it yields an error message about not being able
to find the system path, you may need to set the $vars variable near the top of
the script.

If you still can't get it working, send us your FTP address, login name and
password. We will be happy to go in and get it running for you. Send it to us
securely here:
https://secure.stormer.us/~dansie/ftp_secure.html


##############################################################
TROUBLE SHOOTING OTHER COMMON PROBLEMS:
##############################################################

1. From the "All POP Accounts Summary" page, if you don't see any email in your
POP accounts (and you suspect there should be), you may not have the correct
system paths to the POP accounts set in the "pop_accounts_TEXTAREA" variable.
Accurate system paths are VERY important.

2. If you don't seem to be able to move a message from one POP account to
another, make sure to select a POP account to move the message to in the "Move
message to..." drop-down menu near the top of the page. If you still can't move
a message from one POP account to another, be sure write permissions are set on
the POP email files or directories. Chmod 666 or 777.

3. If you have problems logging in, be sure cookies are enabled in your web
browser.

4. If you can't see the text on the pages, check your "font_color" and "bgcolor"
variables in your Language, Look & Feel Settings. Make sure they contrast.

5. If the "Check All" and "Clear All" links don't work, or your stationery and
signature features wont work, be sure to enable JavaScript in your browser.

6. If you forgot your password, FTP into your website and download the
"anti_spam_vars.txt" file from /cgi-bin/anti_spam/anti_spam_vars.txt. Open the
file in a plain text editor such as Notepad. At the bottom locate the password
variable. Make it blank like so: "password=". Then, immediately visit:
https://www.YourName.com/cgi-bin/anti_spam.pl?login and set your password. 
Note: If you are currently logged in via an expiring password, you will not be
able to change your master password in the variable settings.

If a problem persists, send us an email with a description of the problem and
the URL to the script and your login password if necessary. We'd be happy to
help.
http://www.dansie.net/question.html
Or https:
https://secure.stormer.us/~dansie/ftp_secure.html


##############################################################
HOW DANSIE ANTI SPAM BAYESIAN STYLE FILTERS WORK:
##############################################################

Bayesian email filters take advantage of Bayes' theorem. Bayes' theorem, in the
context of spam, says that the probability that an email is spam, given that it
has certain words in it, is equal to the probability of finding those certain
words in spam email, times the probability that any email is spam, divided by
the probability of finding those words in any email.

Dansie Anti Spam slides the probability scale over so it's from between -50 to
+50, zero being neutral. An email with a probability rating of +30 would
indicative that it's a good email while an email rating -40 would be sure to be
spam.

An email coming from an email address that is in your White List will receive
100 additional points so it will never possibly be quarantined.

Any emails with a probability rating higher than zero remain in your POP
account. You can, however, augment the demarcation point (by default it's set to
zero) by setting the "spam_demarcation_point" variable plus or minus a few
points. From the "Admin Control Panel: Main Menu", click on "Change Variable
Settings".

DAS indexes all word pairs found in the To, From, Subject and Body headers and
attachment filenames. Other headers such as Cc, Reply-to, Date, etc. are ignored
for purposes of filtering and filter learning.


##############################################################
TELL A FRIEND AND RECEIVE A FREE UPGRADE:
##############################################################

We are always upgrading our scripts to make them easier to install, easier for
your customers to use, and to give you more customizing abilities. If you refer
someone else who purchases Dansie Anti Spam, we will send you an upgrade...
free. To receive the upgrade, have the person you referred send us an email
after they purchase telling us it was you that referred them to us. Your free
upgrade can be collected anytime within one year of the referral. So tell a
fellow webmaster about Dansie Anti Spam.


##############################################################
UPGRADE INSTRUCTIONS:
##############################################################

You can purchase an upgrade here:
http://www.dansie.net/upgrade_payment.html

If you are upgrading from DAS version 1.0 or 2.0:
Get your @pop_accounts_to_filter system paths settings from your 2.0 vars.lib
file. Follow the installation instructions above and install this as a separate
program. Later you can delete your older version.

If upgrading from DAS 3.0:
1. If you had to set the "$vars" variable near the top of the script before, you
will need to do so again. If not, don't set it.
2. Upload the new anti_spam.pl script in ASCII format to the cgi-bin on your
website overwriting the old one.
3. Login to your Admin Control Panel and go to the Main Menu:
http://www.YourName.com/cgi-bin/anti_spam.pl?login
4. Click on "Change Variable Settings". You may customize the settings of any
new variables you find.
