home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 35 Internet
/
35-Internet.zip
/
postroad.zip
/
prmblams.doc
< prev
next >
Wrap
Text File
|
1997-10-23
|
8KB
|
148 lines
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
BlamSpam Version 1.0
Adaptation for Use with Post Road Mailer
InnoVal Systems Solutions, Inc.
May 12, 1997
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
BlamSpam is a Spam Filter (or Twit Filter) for use with an InnoVal
product named Hacksaw. BlamSpam will blow away the spam messages,
right on your POP3 server, before your regular email program has to
deal with them. This is an adaptation of BlamSpam, for use with the
Post Road Mailer. The files must be renamed to PRMRECV.CMD and
PRMRECV.CFG, or they won't work. (They're not distributed with those
filenames, because a Post Road Mailer user might already have a
PRMRECV.CMD, and we certainly don't want to overwrite that when you
unzip this program into the directory!) Furthermore, the files must
be in your Post Road Mailer directory (the one with INBASKET.NIX and
PRMSYS.INI in it). The Post Road Mailer executes any file named
PRMRECV.CMD that it finds in that directory, at the end of the Refresh
process. This BlamSpam program, then, renamed to PRMRECV.CMD, will
search all of the messages, as they arrive from the POP3 server, for
the strings specified in the PRMRECV.CFG file, and delete the messages
which contain any of those strings in their applicable portions.
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
The PRMRECV.CFG File
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
A sample PRMRECV.CFG file is included, which contains entries for many
internet addresses that are known to send spam messages.
Blank lines, and lines which begin with /* are ignored.
There are two other types of lines in a PRMRECV.CFG file:
The only required lines in this file are the lines which tell the
program which messages to delete. Each of these lines contains a
single search string, which can be the author's email address, a word
or phrase in the subject line, or even a string of text from the body
of the message. Choose a string which will appear in the messages you
want deleted but which will not ever, under any circumstances, appear
in the applicable part(s) of any other messages.
If you don't tell it otherwise, the program will find these strings in
any message header line (which, by definition, means any line before
the first blank line of the message) but not in any of the message
body text (past the first blank line, which is the divider between the
headers and the body of the message). If you need to make the program
search the message body text as well as (or instead of) the header
lines, or if you need to make it search only certain ones of the
header lines instead of all of them, you can do that, too, using a
HEADERLINES parameter.
To make the program apply a HEADERLINES parameter to one single line
of the PRMRECV.CFG file, you can put it on that same line of the file,
after a <TAB> character. For example:
spamco.com<TAB>From:
This example would kill all the messages with "spamco.com" in the
From: header, but no messages with that string in the Subject: header
or anywhere else in the message.
In order for that to work, you must create the PRMRECV.CFG file with a
text editor which actually places <TAB> characters into the file,
rather than converting them to a certain number of spaces the way so
many text editors do! OS/2's E.EXE is safe for this purpose.
In order to make a HEADERLINES parameter apply to all subsequent lines
of the PRMRECV.CFG file instead of only the one line, you insert a
line such as this one:
<headerlines>=From:
before the first of the lines to which you want it to apply. That is
the third possible type of line in a PRMRECV.CFG file. It will change
the HEADERLINES parameter for all PRMRECV.CFG lines below it, until
the next <headerlines>= line in the file (if any). Except, of course,
for any lines which have their own HEADERLINES parameters (that is, a
<TAB> character and another string, following the search string). A
HEADERLINES parameter on a search string line overrides whatever
global HEADERLINES parameter default is in effect in that part of the
PRMRECV.CFG file.
The reason the default behavior of BlamSpam is to look for matches in
all the header lines and none of the message body text, is because the
default HEADERLINES value is NOBODY. NOBODY means not to search the
body text, just the header lines.
Another valid value for HEADERLINES is ENTIRE. This means that the
entire message will be searched: The header lines and the message
body text.
The other possible values for HEADERLINES are MSGTEXT which means just
the message body text and no header lines; or any valid internet
message header tag such as TO, FROM, SUBJECT, X-MAILER, REPLY-TO,
RECEIVED, etc. These must be spelled the same way as they are spelled
in the headers of the messages, though they're case insensitive and
the colon is optional. That is, the program will treat "FROM:" and
"From:" and "FrOm" and "from" identically.
Except for NOBODY and ENTIRE, all other possible HEADERLINES values
can be combined, using spaces or commas. For example, you can say
"FROM,REPLY-TO" or "REPLY-TO FROM" to have the program search only
both of those header lines in each of the messages.
Remember, when using the ENTIRE or MSGTEXT value for the HEADERLINES
parameter, keep the search string as short as possible. If the string
is more than one word long, it can occur with a carriage return in the
middle of it instead of a space, in which case the program will not
recognize it as a match! If the string is only one word long, then
the only way it can be missed is if it's hyphenated and split across
two lines of the message.
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Example PRMRECV.CFG File
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
spamco@isp.com
Spamco<TAB>Sender: Reply-To:
Spamco, Inc.<TAB>subject,msgtext
<headerlines>=msgtext
Spamco Product Name
111.222.333.444<TAB>Received
foul language<TAB>entire
4letterword
spamco2@elsewhere.com<TAB>NoBody
Since NOBODY is the default HEADERLINES parameter value, the program
will search only the header lines, and not the message body text, for
spamco@isp.com. It will search for Spamco in only the Sender: and
Reply-to: header lines. It will search only the Subject: header line
and all of the message body text for Spamco, Inc. The next line,
<headerlines>=msgtext, causes the default HEADERLINES parameter to be
changed from NOBODY to MSGTEXT for all future entries which don't have
their own HEADERLINES parameter on them. So the phrase "Spamco
Product Name" will be searched for only in the message body text, not
in any header lines. The same will be true for the word 4letterword.
The IP address 111.222.333.444 will be searched in only the Received:
lines, and the phrase "foul language" will be searched for in all
header lines and the message body text as well. Finally,
spamco2@elsewhere.com will be searched for in all the header lines but
not the message body text. The only reason the NOBODY parameter is
needed there is because the global default had been changed from
NOBODY to MSGTEXT by the earlier <headerlines>= line of the file.