Re: [Exim] Envelope-To with smartuser rewrites

Página Principal
Apagar esta mensagem
Responder a esta mensagem
Autor: Philip Hazel
Data:  
Para: Phil Pennock
CC: Exim Users
Assunto: Re: [Exim] Envelope-To with smartuser rewrites
On Mon, 31 Jul 2000, Phil Pennock wrote:

> I have this transport:
> all_groupname:
>   driver        = smartuser
>   domains       = localhost
>   prefix        = all-
>   condition     = ${if ={${originator_uid}}{MY_USERID} {yes}{no}}
>   rewrite       = true
>   headers_add   = "X-List: all-${local_part}.globnix.org (private)"
>   new_address   = ${perl{all_group}{$local_part}}

>
> And the all_group() function will return the usercodes of all members of
> the specified group. For the catch-all real account 'users' this works
> well.
>
> However, I've just done some tests with some minor system groups, where,
> eg, one of the members is me, and one is an alias which rewrites to me.
> So, a mail from me to <all-staff@localhost> expands to 'root' and 'phil'
> and 'root' indirectly (via 'sysadm') maps to 'phil'.
>
> The delivering director uses a transport with 'envelope_to_add' set, so
> I get to see this:
> -----------------------------< cut here >-------------------------------
> Envelope-to: all-staff@localhost,
> all-staff@localhost
> -----------------------------< cut here >-------------------------------
>
> Given that this is all local, I can see that this is perhaps why it
> still says 'all-staff' - there's no SMTP here, for this delivery. It is
> confusing, though, IMHO.


But the envelope to address *was* all-staff@localhost. Why is this
confusing? The point of the header is to record the original address
that provoked this delivery.

The double appearance is an infelicity. When it maps 'root' to 'phil' it
discovers a duplicate address, so it does only a single delivery.
However, it lists the envelope-to fields for both addresses. They just
happen to be the same. If you were to send a message to both root and
phil, you'd get just one delivery, but the envelope-to: header would
list the two envelope addresses.

So that is telling you that all-staff expanded into two different
addresses, both of which eventually turned into deliveries to you.


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