procmail
[Top] [All Lists]

Re: Sendmail reading from address

1997-09-17 11:39:04
Excerpts from mail: (16-Sep-97) Re: your mail by Aaron Dougherty (Sim Master)
Hmmm, this doens't seem to be working. It looks like it is just putting in
a bunch of empty headers.

No, that's not what it is doing. "formail -I headerfield" *removes* the
specified header from the e-mail.

When I tested it, the mail still was sent to me.

In your e-mail, you said you "bounced" the request that was sent to you to
the autoresponder account. I interpreted your "bounce" to actually be the
action of re-sending. (Elm calls it "bounce" and uses the "b" key.) Did I
misinterpret? Assuming that when you "bounce" the e-mail to the
autoresponder, the only change to the e-mail headers of any importance is the
insertion of Resent-* headers, then my receipe will remove those headers, and
the subsequent recipe should respond to the original sender.

Is $MY_ADDR set to the address that you "bounce" the e-mails from?

how would I get your recipe to send the responce to the address in the
From: field?

It should. Why don't you turn on VERBOSE logging and see what it is actually
doing? And you might want to save a copy of the incoming e-mail and examine
the headers.

Excerpts from mail: (12-Sep-97) Sendmail reading from address by Aaron 
Dougherty (Sim Master)
The problem with this, is that the -t tag reads To, Cc, Bcc, etc, for the
recipient of the auto responce. I would like to bounce messages to faq,
but if I do that, I end up getting the mail instead the the appropriate
recipient. Any suggestions?

No problem. Just change your recipe to this:

MY_ADDR = "swsim(_at_)swsim(_dot_)com"

:0
* ^TOfaq
{
    :0 fwh
    * $ ^Resent-From:(.*[^-((_dot_)%(_at_)a-zA-Z0-9])?$\MY_ADDR
    | formail -I Resent-From: -I Resent-To: -I Resent-Date: \
              -I Resent-Sender: -I Resent-Message-Id:

    :0
    | (formail -rA"X-Loop: swsim(_at_)swsim(_dot_)com" ; \
       cat $HOME/www/faq.html; \
       echo ""; \
       cat $HOME/.signature \
      ) | $SENDMAIL -oi -t
}

Note: I changed "sendmail" to $SENDMAIL which is slightly more correctly.

You might want to add some MIME headers to your reply e-mail....

May the Force be with you,
Ed

<Prev in Thread] Current Thread [Next in Thread>