Re: [Exim] Question about Exim 4 FAQ 0423

Páxina inicial
Borrar esta mensaxe
Responder a esta mensaxe
Autor: Philip Hazel
Data:  
Para: Jason L Tibbitts III
CC: exim-users
Asunto: Re: [Exim] Question about Exim 4 FAQ 0423
On 11 May 2002, Jason L Tibbitts III wrote:

> condition = ${if match {$home}{^/dead/}{no}{yes}}
>
> And it sort-of works; userforward doesn't complain any longer, but
> the local_delivery transport takes its place:
>
>   == xxx@??? R=localuser T=local_delivery defer (2): No
>     such file or directory: failed to chdir to /dead/2000.12.05

>
> I'm having a hard time figuring out why it even tries to chdir to the
> user's home directory in order to put mail in the mail spool (which
> isn't in $home). Is A0423 incomplete, or did I screw something up
> along the way?


By default, Exim chdir's to the user's home directory when deliverying
mail. You can configure it to use something else if you want.

> I guess what I'd really like to do is bounce any message sent to such
> an address with a notice that the account has been terminated.


That's what we do.

> tried putting this in acl_check_rcpt:


No good. Doesn't work for messages arriving not by SMTP.

You need a router to do this job. Our configuration is somewhat
out-of-date. We use this router:

cancelled_users:
driver = accept
check_local_user
condition = ${if eq{$home}{/home/CANCELLED}{yes}{no}}
fail_verify
local_part_prefix = real-
local_part_prefix_optional
transport = cancelleduser_pipe

... and the pipe generates the message. However, it would be neater
nowadays to use a "redirect" router that generates the message using
:fail: (our usage goes back to Exims that didn't have :fail:). If you
did that, you wouldn't want the fail_verify.

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