On Thu, Apr 01, 1999 at 04:04:25PM +0300, era eriksson wrote:
Try this:
:0h
TCPREMOTEIP=| origip.pl
:0
* TCPREMOTEIP ?? .
* ? rblcheck -q "$TCPREMOTEIP"
{
LOGABSTRACT=all
LOG="Filter: RBL-filtered address: \"$TPCREMOTEIP\"
"
:0:
| formail -i "X-RBL-Filtered-Address: $TCPREMOTEIP" >>$FILTER_FOLDER
}
The below log entries shows what happens when an RBL listed IP mail is
recieved. It is being invoked like so on the command line:
cat rbltest | env - TCPREMOTEIP=127.0.0.2 \
/usr/local/bin/procmail -m .jfrc
The second piece of log file is just a normal GOOD piece of EMAIL from
my WS at home. The seond piece of email is going to my $FILTER_FOLDER as
well. Why is it not going to $DEFAULT??
<begin log (Should goto junkmail)>
procmail: [20272] Thu Apr 1 08:22:37 1999
procmail: Assigning "LOCKFILE=/home/insane/.lockmail"
procmail: Locking "/home/insane/.lockmail"
procmail: Assigning "FILTER_FOLDER=/home/insane/Mail/junkmail"
procmail: Assigning "TCPREMOTEIP="
procmail: Executing "origip.pl"
procmail: Match on "."
procmail: Executing "rblcheck,-q,207.113.133.228"
checking 207.113.133.228
procmail: Assigning "LASTFOLDER=rblcheck -q 207.113.133.228"
procmail: Match on "rblcheck -q 207.113.133.228"
procmail: Assigning "LOGABSTRACT=all"
procmail: Assigning "LOG=Filter: RBL-filtered address: "207.113.133.228"
"
Filter: RBL-filtered address: "207.113.133.228"
procmail: Locking "/home/insane/Mail/junkmail.lock"
procmail: [20272] Thu Apr 1 08:22:38 1999
procmail: Executing "formail -i "X-RBL-Filtered-Address: $TCPREMOTEIP" >>
$FILTER_FOLDER"
procmail: [20272] Thu Apr 1 08:22:38 1999
procmail: Assigning "LASTFOLDER=formail -i "X-RBL-Filtered-Address:
$TCPREMOTEIP" >> $FILTER_FOLDER"
procmail: Unlocking "/home/insane/Mail/junkmail.lock"
From insane(_at_)the(_dot_)oneinsane(_dot_)net Wed Mar 31 11:22:10 1999
Subject: Test
Folder: formail -i "X-RBL-Filtered-Address: $TCPREMOTEIP" >> $FILTER_ 1470
procmail: Unlocking "/home/insane/.lockmail"
<end log (Should goto junkmail)>
<begin log (Should goto DEFAULT)>
procmail: [20357] Thu Apr 1 08:23:03 1999
procmail: Assigning "LOCKFILE=/home/insane/.lockmail"
procmail: Locking "/home/insane/.lockmail"
procmail: Assigning "FILTER_FOLDER=/home/insane/Mail/junkmail"
procmail: Assigning "TCPREMOTEIP="
procmail: Executing "origip.pl"
procmail: Match on "."
procmail: Executing "rblcheck,-q,207.113.133.231"
checking 207.113.133.231
procmail: Assigning "LASTFOLDER=rblcheck -q 207.113.133.231"
procmail: Match on "rblcheck -q 207.113.133.231"
procmail: Assigning "LOGABSTRACT=all"
procmail: Assigning "LOG=Filter: RBL-filtered address: "207.113.133.231"
"
Filter: RBL-filtered address: "207.113.133.231"
procmail: Locking "/home/insane/Mail/junkmail.lock"
procmail: [20357] Thu Apr 1 08:23:04 1999
procmail: Executing "formail -i "X-RBL-Filtered-Address: $TCPREMOTEIP" >>
$FILTER_FOLDER"
procmail: [20357] Thu Apr 1 08:23:04 1999
procmail: Assigning "LASTFOLDER=formail -i "X-RBL-Filtered-Address:
$TCPREMOTEIP" >> $FILTER_FOLDER"
procmail: Unlocking "/home/insane/Mail/junkmail.lock"
From insane(_at_)lunatic(_dot_)oneinsane(_dot_)net Thu Apr 1 08:23:03 1999
Subject: Test
Folder: formail -i "X-RBL-Filtered-Address: $TCPREMOTEIP" >> $FILTER_ 637
procmail: Unlocking "/home/insane/.lockmail"
<end log (Should goto DEFAULT)>
TIA
--
-------------------------------------------------------------------
Ron Rosson ... and a UNIX user said ...
The InSaNe One rm -rf *
insane(_at_)oneinsane(_dot_)net and all was null and void
-------------------------------------------------------------------
"Where am I, and what am I doing in this handbasket?"