procmail
[Top] [All Lists]

Re: Picking Off Sender's Address

1997-06-30 20:44:00
Paul O Bartlett <pobart(_at_)access(_dot_)digex(_dot_)net> writes:
   This is something that was never clear to me from man procmailrc(5)
as to how ! as a "delivery" works.  I first thought about doing exactly
as era suggested with ! `cat $USERLIST`.  However, I was afraid that
everybody's copy would get everybody else's address stacked up in the
received To: header.  That is clumsy, and some people find it
irritating.

An action of

        ! foo bar baz

is internally treated as if you had written

        |$SENDMAIL $SENDMAILFLAGS foo bar baz

(Well, almost.  The '!' version will leave out a leading "From " line when
it feed the message into the pipe, as if you had written:

        |formail -I'From ' | $SENDMAIL $SENDMAILFLAGS foo bar baz

but with the formail part done inside procmail.  Modern sendmails make note
of the date in the header and then delete it, but some other MTAs barf on
such a non-rfc822 line, thus the extra work on procmail's part.  If you
haven't run into the problem yourself I wouldn't worry about it.)

Anyway, sendmail won't modify the destination headers (To:, Cc:, Bcc:)
unless they're missing.


Philip Guenther