[exim] Re: Question about Exim macro language

Αρχική Σελίδα
Delete this message
Reply to this message
Συντάκτης: Slavko
Ημερομηνία:  
Προς: exim-users@lists.exim.org
Αντικείμενο: [exim] Re: Question about Exim macro language
Dňa 1. mája 2024 16:52:04 UTC používateľ halbtaxabo-jnq--- via Exim-users <exim-users@???> napísal:

>DKIM_DOMAIN = ${lookup{$domain:$h_from:}lsearch{/etc/exim4/dkim/domainslist}}


lsearch lookup key in fike and returns its value, thus it expects:

   key: value

The value can be empty, i guess that your file has only keys:

    key1
    key2

In this case lsearch returns ťhat empty value and you need to instruct
it to return key itself:

    ... lsearch,ret=key{...}

Now it will return key if found in file or empty string otherwise.

regards


-- 
Slavko
https://www.slavino.sk/


--
## subscription configuration (requires account):
## https://lists.exim.org/mailman3/postorius/lists/exim-users.lists.exim.org/
## unsubscribe (doesn't require an account):
## exim-users-unsubscribe@???
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://wiki.exim.org/