procmail
[Top] [All Lists]

chowning messges delivered to specific user through /etc/procmail

2002-10-04 07:31:35
I apologize if this is receied twice - looks like what was in it the first
time may have been filtered & never reached the list...

I've recently set up a few recipes in /etc/procmailrc to drop Klez & other
viruses into a special account & not deliver to the original recepient.
It has worked like a dream come true.

I have created a "virus" users account that receives all these messages.
Whoever reads the account hunts down & kills the propagator if they're
local.  I list the full path to a folder in the virus account's home dir,
and have the recipe delivering fine there, but since it's coming from
/etc/procmailrc. it gets delivered & owned by root.  I would like to chown
it to the virus user, but have had limited success so far.

Here's what I've got:

:0B
* <my pattern(s)>
{
       :0c
       /export/home/faculty/virus/Maildir/.Filtered.Klez-1/

       :0
       | chown -R virus /export/home/faculty/virus/Maildir/.Filtered.Klez-1/
}

When I run nearly the identical recipe for my personal account, I receive
no errors & it works fine, unless I up the LOGABSTRCT level to all - then
it works, but I just get some errors in my personal log.  With the
/etc/procmailrc, depending on what I set LOGABSTRACT to, I get different
errors.

With LOGABSTRACT set to yes, I get this error:

procmail: Error while writing to "chown"
From MAILER-DAEMON(_at_)geneseo(_dot_)edu  Fri Oct  4 08:49:21 2002
 Subject: Warning: could not send message for past 4 hours
  Folder: /home/slr4/Maildir/new/1033735761.3634_1.helios                156978

& it doesn't appear to have delivered the message to the special virus
account.

With LOGABSTRACT set to all, I get this error:

From MAILER-DAEMON(_at_)geneseo(_dot_)edu  Fri Oct  4 08:46:49 2002
 Subject: Returned mail: see transcript for details
  Folder: /export/home/faculty/virus/VMaildir/.Filtered.Klez-1/new/103   135313
procmail: Error while writing to "chown"
From MAILER-DAEMON(_at_)geneseo(_dot_)edu  Fri Oct  4 08:46:49 2002
 Subject: Returned mail: see transcript for details
  Folder: /home/sbn2/Maildir/new/1033735609.3164_1.helios                135313

It's procmail 3.22 in solaris 8, with sendmail using procmail to deliver
to Maildirs.

I've been banging my head off the desk for a couple days now & haven't
found enlightenment in any of the manpages yet.  Is this the correct way
to deliver to my special account & make them own it?  Can I do it with
some type of variable?  Any help is appreciated ahead of time.

-Mark

The rest top of my /etc/procamilrc reads:

LOGFILE=/var/adm/procmail.log
VERBOSE=no
LOGABSTRACT=yes
MAILDIR=$HOME
DEFAULT=$HOME/Maildir/
ORGMAIL=/var/mail/$LOGNAME
SENDMAIL=/usr/lib/sendmail
NORESRETRY=4
SUSPEND=16
COMSAT=no


--))> >--))>
Mark T. Valites
Unix Systems Analyst
1 College Circle - 124b1 South Hall
SUNY Geneseo
Geneseo, NY 14454
585-245-5577
585-259-3471 (Cell)
585-245-5579 (Fax)

_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail