Re: [Exim] local_part+suffix@domain, where local_part needs …

Kezdőlap
Üzenet törlése
Válasz az üzenetre
Szerző: Nico Erfurth
Dátum:  
Címzett: francisco
CC: exim-users
Tárgy: Re: [Exim] local_part+suffix@domain, where local_part needs a rewrite
Frysco! wrote:
> Hi,
>
> I already have Exim configured so that user1+foo@??? gets delivered
> properly to user1 via procmail. However, the problem that I'm trying to
> deal with at the moment is what to do when you want user2 to rewrite to
> user1, as user2 doesn't exist in any getpwbyname()able format.
>
> The goal is to:
> - accept mail for 'user2+foo@???'
> - rewrite it to 'user1+foo@???'
> - deliver to 'user1' locally via procmail
>
> I've been using the C010 snippet from the Exim 3.x config samples tarball
> for the existing setup.
>
> Any ideas?


I'll assume exim4, because you didn't told us what you use.

alias_with_suffix:
   driver = redirect
   local_part_suffix = +*
   local_part_suffix_optional
   data = ${lookup {$local_part} lsearch \
             {/etc/aliases}}$local_part_suffix


This will lookup an alias from /etc/aliases and append
$local_part_suffix, the suffix is optional, so it will work for
user2@domain too.

Nico