Re: [courier-users] mailbot useage

This is a discussion on Re: [courier-users] mailbot useage within the Courier-Imap forums, part of the Mail Servers and Related category; This is a followup. My .mailfilter file looks like: import HOME if (/^X-DSPAM-Result: Spam/) { to ".Spam/" } ...


Go Back   Usenet Forums > Mail Servers and Related > Courier-Imap

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 06-28-2006
Kyle Johnson
 
Posts: n/a
Default Re: [courier-users] mailbot useage

This is a followup.

My .mailfilter file looks like:
import HOME

if (/^X-DSPAM-Result: Spam/)
{
to ".Spam/"
}

cc "| /usr/local/bin/mailbot -s 'Out-Of-Office Reply' -A 'From:
sodoherty@hanoveruniform.com' -m
'/usr/local/virtual/hanoveruniform.com/sodoherty/message.txt'
/usr/sbin/sendmail -f '' kjohnson@fixertec.net"

I have found that, with the above rule, when email is sent to this user
from a non-local domain, the autoreply does work - it sends to the
message to kjohnson@fixertec.net. There are a few questions:
1: I'd like the mail to go to the sender, not to a static address
(kjohnson@fixertec.net) - how can I do this?
2: The original email does not end up in the users inbox. How can I do
this?
3: Why does #2 happen?

Also, I've done a test, so I know the rule is being read:
mail:/usr/local/virtual/hanoveruniform.com/sodoherty # cat ./message.txt
| /usr/local/bin/maildrop -V 10 -d sodoherty@hanoveruniform.com
maildrop: authlib: groupid=1010
maildrop: authlib: userid=2008
maildrop: authlib: logname=sodoherty@hanoveruniform.com,
home=/usr/local/virtual/hanoveruniform.com/sodoherty/,
mail=/usr/local/virtual/hanoveruniform.com/sodoherty/
maildrop: Changing to /usr/local/virtual/hanoveruniform.com/sodoherty/
Message start at 0 bytes, envelope sender=sodoherty@hanoveruniform.com
maildrop: Attempting .mailfilter
Tokenized import
Tokenized string: "HOME"
Tokenized ;
Tokenized ;
Tokenized if
Tokenized (
Tokenized regexp: /^X-DSPAM-Result: Spam/
Tokenized )
Tokenized ;
Tokenized {
Tokenized ;
Tokenized to
Tokenized string: ".Spam/"
Tokenized ;
Tokenized }
Tokenized ;
Tokenized ;
Tokenized cc
Tokenized string: "| /usr/local/bin/mailbot -s 'Out-Of-Office Reply' -A
'From: sodoherty@hanoveruniform.com' -m
'/usr/local/virtual/hanoveruniform.com/sodoherty/message.txt'
/usr/sbin/sendmail -f '' kjohnson@fixertec.net"
Tokenized ;
Tokenized eof
..mailfilter(1): import "HOME"
..mailfilter(3): Evaluating IF condition.
Matching /^X-DSPAM-Result: Spam/ against Steve O'Doherty will be on
vacation starting Wed. 6/28 - returning Friday July 14th.
Not matched.
Matching /^X-DSPAM-Result: Spam/ against He will respond to your message
at that time - If a Customer Service Rep can
Not matched.
Matching /^X-DSPAM-Result: Spam/ against be of assistance, please call
1-800-541-9709
Not matched.
..mailfilter(3): Search of ^X-DSPAM-Result: Spam = 0
..mailfilter(3): IF evaluated, result=0
maildrop: Delivering to | /usr/local/bin/mailbot -s 'Out-Of-Office
Reply' -A 'From: sodoherty@hanoveruniform.com' -m
'/usr/local/virtual/hanoveruniform.com/sodoherty/message.txt'
/usr/sbin/sendmail -f '' kjohnson@fixertec.net
maildrop: Delivery complete.
maildrop: Delivery complete.

Thanks again,
Kyle

Kyle Johnson wrote:
> Hi everyone,
> I'm trying to use mailbot here, and I'm stuck. I've tried including a
> rule, similar to the one that is provided in the man page, in my
> ..mailfilter file, but with no luck. The rule is:
> if (/^To:.*kjohnson@hanoveruniform.com.*/)
> {
> cc "| /usr/local/bin/mailbot -t
> /usr/local/virtual/fixertec.net/kjohnson/message -A 'From:
> kjohnson@hanoveruniform.com' /usr/bin/mail"
> }
>
> I have also tried:
> if (/^To:.*kjohnson@hanoveruniform.com.*/)
> {
> cc "| /usr/local/bin/mailbot -t /home/admin/message -A 'From:
> kjohnson@hanoveruniform.com' /usr/sbin/sendmail -f ''"
> }
>
>
> Neither of these work, and I don't even know how to debug mailbot. I've
> also tried using mailbot from the command line, like:
> cat file| mailbot -t /home/admin/grepx -A 'From: test@domain.tld' -r
> kjohnson@fixertec.net /usr/bin/mail
>
> and:
> cat file| mailbot -t /home/admin/grepx -A 'From: test@domain.tld' -r
> kjohnson@fixertec.net /usr/sbin/sendmail -f ''
>
>
> I guess I'm looking for some more examples on mailbot usage, as well as
> where my error lies.
>
>
>


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=...057&dat=121642
_______________________________________________
courier-users mailing list
courier-users@lists.sourceforge.net
Unsubscribe: https://lists.sourceforge.net/lists/.../courier-users
Reply With Quote
Reply


Thread Tools
Display Modes

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

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



All times are GMT +1. The time now is 08:15 AM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0