Re: [Exim] condition and exists{}

Página Inicial
Delete this message
Reply to this message
Autor: Nico Erfurth
Data:  
Para: Jan Kriesten
CC: exim-users@exim.org
Assunto: Re: [Exim] condition and exists{}
On Fri, 29 Nov 2002, Jan Kriesten wrote:

>
> hi!
>
> i have the following problem with simple list handling with v4.10:
>
> lists:
> driver = redirect
> condition = ${if exists{/etc/exim/lists/$domain/$local_part.acl} {yes} {no}}
> require_files = /etc/exim/lists/$domain/$local_part
> senders = lsearch;/etc/exim/lists/$domain/$local_part.acl
> file = /etc/exim/lists/$domain/$local_part
> headers_remove = "Sender:From:Envelope-to:Organization:Return-path"
> headers_add = "From: $local_part@$domain\nEnvelope-to: $local_part@$domain"
> no_check_local_user
> forbid_pipe
> forbid_file
> skip_syntax_errors
> errors_to = $local_part@$domain
>
> this should be evaluated only if the condition is true, but exim always
> stumbles into the senders-file and reports an errer, the file doesn't exist!


Check the mailinglist archive, this was discussed some days ago.

senders is checked before condition.

You can do something like this

senders = ${if exists{FILE}{$lookup {$sender_address} {FILE} fail } fail}

ciao