procmail
[Top] [All Lists]

Re: chowning messges delivered to specific user through /etc/procmail

2002-10-07 08:01:03
On Fri, 4 Oct 2002, David W. Tamkin wrote:

Read about the `i' flag in the procmailrc(5) man page.  In short, chown
doesn't read, nor need to read, any of the message text.  When an action line
in a procmail recipe doesn't accept the entire text fed to it (the head if the
`h' flag is present, the body if the `b' flag is in use, or the entire message
if you use neither of the two flags or both of them), procmail believes
something went wrong.  Using the `i' flag tells procmail not to expect the
entire text to be read.

Short answer: add an `i' flag to the call to chown, or put the call to chown
in a dummy backtick assignment, or put the call to chown into a TRAP.

The 'i' flag works well for both of the first two suggested ways, but
still outputs a Folder line into my $LOGFILE.  (see below)  Anyway I can
change the behavior of it to NOT log on the chown part?  Perhaps changing
LOGABSTRACT's value on the fly?  (exmaple would be great...)  I'm not very
familiar with it, but the info for TRAP from the man page looks like it
will log too.

{
        :0c
        /export/home/faculty/virus/VMaildir/.Filtered.Klez-1/

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

Folder: chown -R virus /export/home/faculty/virus/VMaildir/.Filtered/


{
        :0c
        /export/home/faculty/virus/VMaildir/.Filtered.Klez-1/

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

Folder: |

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