Re: [Exim] envelope_to_add, pipes, and multiple recipients

Páxina inicial
Borrar esta mensaxe
Responder a esta mensaxe
Autor: Philip Hazel
Data:  
Para: WJCarpenter
CC: exim-users
Asunto: Re: [Exim] envelope_to_add, pipes, and multiple recipients
On Mon, 21 Jan 2002, WJCarpenter wrote:

> 1. If the message goes straight to the mailbox, then the ENVELOPE-TO:
> header mentions all the envelope addressees. Exactly one copy of the
> message gets delivered. This seems like the correct and desired
> behavior.
>
> 2. If a ".forward" file is created for that local user and directs
> the message to a pipe (e.g., "|/usr/bin/procmail"), then the
> ENVELOPE-TO: only mentions one of the envelope addressees. In every
> case so far, it has been the addressee mentioned first as a RCPT TO:
> in the SMTP conversation. The message is still delivered exactly
> once. So, filtering based on examination of ENVELOPE-TO: would
> incorrectly conclude there was a single recipient.


I will investigate this in the context of Exim 4 to see if there is
something going on that is not correct. Meanwhile, here are some
comments:

Exim discards duplicate addresses, including those generated during
aliasing etc, though the Envelope-To: header should still refer to all
the original recpients. This is what is happening in (1) above, where
you have A=>X and B=>X and X is a local mailbox.

This gets tricker when you have A=>|something and B=>|something because
the two new addresses are *not* the same, though textually they are
identical. For this reason, Exim has to behave differently for pipes. I
presume that what you actually have is A=>X and B=>X and X=>|something.
The special pipe code may be tripping up in this case.

> 3. If the ".forward" file is instead an exim filter, then the
> expansion variable "$original_local_part" only mentions one of the
> envelope addressees (it so happens it's the same one that shows up in
> the ENVELOPE-TO:.


$original_local_part will only ever contain one local part, that is
certainly true. If A is aliased to X, then the filter will be run for X
with A as the original. Then when Exim looks at B and finds it is also
aliased to X, it will just discard X because it has already dealt with
it.

> So, does any of the above sound familiar to anyone? Does anyone have
> a configuration where sending the message to a pipe still gets all the
> addressees mentioned on the ENVELOPE-TO:? (We have exim 3.02, but I
> wanted to sniff around a bit for clues before putting the local
> sysadmin to the trouble of upgrading.)


Aha! Looks like I might not need to do anything after all. The ChangeLog for
Exim 3.21 contains this:

-----------------------------------------------------------------------
7. When an Envelope-To: header was added to a delivery, more than one instance
of the same envelope address could appear if there were discarded duplicates
that had the same original address. In other cases, different originals might
not appear when they should.
-----------------------------------------------------------------------

So, please upgrade to Exim 3.34 and then repost if you still have problems.

Philip


--
Philip Hazel            University of Cambridge Computing Service,
ph10@???      Cambridge, England. Phone: +44 1223 334714.