Any input please on how to configure a mailhub (smapd,
procmail & sendmail) to filter incoming emails.
DM
--- D M <kfupm111(_at_)yahoo(_dot_)com> wrote:
Date: Thu, 28 Apr 2005 00:13:32 -0700 (PDT)
From: D M <kfupm111(_at_)yahoo(_dot_)com>
Subject: filtering & forwarding incoming email
To: procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
I inherated mialhup setup (smap, sendmail &
procmail).
Mail domain name is mydomain.com in sendmail.cf
"Cxmydomain.com". It is forwarding smtp to 10.1.1.1
,
which is the internal email server.
sendmail.cf contains "R$+ <@$=x.> $#smtp
$(_at_)[10(_dot_)1(_dot_)1(_dot_)1] $:$1<@$2>"
sendmail.cw has mydomain.com.
netperm-table contains the following:-
# smap rules:
# -------------------
smap, smapd: userid 5
smap, smapd: groupid 5
smap, smapd: directory /var/spool/smap
smapd: executable
/opt/TISfwtk/bin/smapd
smapd: sendmail
/etc/mail/procmail/sendmail.filter
smapd: maxchildren 30
smap: timeout 600
smap: maxbytes 15728640
smap: domains mydomain.com.
sendmail.filter file contains the following:-
#! /usr/bin/sh
procmailConfig=/etc/mail/procmail/procmail.rc
errorLog=/dev/null
umask 177
sendmail=/usr/lib/sendmail
procmail=/usr/local/bin/procmail
if test -x $procmail ; then
exec $procmail -m $procmailConfig $* 1>>$errorLog
2>&1
else
exec $sendmail -d6,11,13,20,28,48.2 -v $*
1>>$errorLog 2>&1
fi
I have a requirement to filter emails
user1(_at_)mydomain(_dot_)com and forward them
user1(_at_)yourdomain(_dot_)com, which is an external email
server. I added "user1(_at_)mydoamin(_dot_)com
user1(_at_)yourdomain(_dot_)com" in virtusertable.map. Run
makemap command to create virtusertable.dir & pag.
Tested the filtering and did not work.
In procmail.rc file added
:0 cw
* ^(To|Cc|Bcc) user1(_at_)mydomian\(_dot_)com
{
:0
! user1(_at_)yourdomain\(_dot_)com
}
And still does not forward the emails
yourdomian.com.
How to make email filtering & forwarding work?
D.M.
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam
protection around
http://mail.yahoo.com
__________________________________
Do you Yahoo!?
Yahoo! Small Business - Try our new resources site!
http://smallbusiness.yahoo.com/resources/
____________________________________________________________
procmail mailing list Procmail homepage: http://www.procmail.org/
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail