Re: [exim] reject mails via .forward not bounce

Página Principal
Apagar esta mensagem
Responder a esta mensagem
Autor: Phil Pennock
Data:  
Para: exim-users
CC: Sebastian Siewior
Assunto: Re: [exim] reject mails via .forward not bounce
On 2006-11-22 at 14:46 +0800, Sebastian Siewior wrote:
> What I'm trying to do is, to setup an account "usenet" which is an alias
> to my local account. The suffix should be like 1106 for November 2006.
> Therefore the user should decide which emails he wants to have in his
> local .forward file. I don't want to accept usenet+whatever or
> username+spam and a blackhole is not very friendly (in case of a few
> *real* mails / mistypes). Also I want something like user+bla where bla
> is an alias for $homepage where I have to signup in order to do
> anything. Since most of those pages tend to send "newsletters" and *I*
> prefer just to remove bla from my .forward and reject those mails
> (and not giving them the pleasure that I maybe read them) instead of
> clicking through the whole page trying to remove myself from the
> "newsletter". It should also be a nice thing for mailing lists. I thing
> you got the point :)


(The problematic newsletters accept +addressing? I find that the more
likely I am to want to use a +ext, the less likely the site is to
accept it because the "programmer" never bothered checking what's
actually valid in an email address; that said, I use +ext quite a lot).

How about letting users create a .emailext-blacklist or
.emailext-whitelist file in their home directory, one item per line?
Easier to make changes, can even use tools to make it easier for people
to maintain if they're not so clued.

Just before the userforward router, put in something like (untested):

userextblacklist:
  driver = redirect
  domains = +WHATEVER
  check_local_user
  local_part_suffix = +*
  condition = ${if and {\
      {exists {$home/.emailext-blacklist}}\
    {${lookup{$local_part_suffix} lsearch {$home/.emailext-blacklist}\
     {yes}{no} }} {yes}{no}}
  verify_only
  no_expn
  allow_fail
  data = :fail: address no longer valid


If you want to let people use
extension: reject reason
then change the last line to be:

  data = :fail: ${lookup{$local_part_suffix} lsearch \
          {$home/.emailext-blacklist} \
        {${if def:value {$value}{address no longer valid}}}\
        {address no longer valid}}



Does this help?
-Phil