Re: [exim] ACL error "for linear search: No such file or dir…

Top Page
Delete this message
Reply to this message
Author: Graeme Fowler
Date:  
To: exim-users@exim.org
Subject: Re: [exim] ACL error "for linear search: No such file or directory"
On 19 Nov 2019, at 11:35, Emanuel Gonzalez via Exim-users <exim-users@???> wrote:
> [@~] # /opt/exim/bin/exim -be 'condition = ${if exists{${lookup{$sender_address}lsearch*@{${perl{getmaildir2}{$local_part@$domain}}/.spamassas
> sin/whitelist{no}{yes}}'
> Failed: failed to open /mail///.spamassassin/whitelist{no for linear search: No such file or directory
>
> any ideas?


Yes; in 'exim -be' the variables pertaining to message data aren't defined. You'll need an example message and 'exim -bem' - see the docs.

You also said earlier in this thread that this is being called in the DATA ACL.

$local_part and $domain are unavailable at this point - a message can have more than one recipient.

If you want to do per-user spamassassin lookups, you need to ensure you've only got one recipient per message (by deferring the second and subsequent RCPT TO commands) and send the data through in an ACL variable such as $acl_m_local_part or $acl_m_domain, which you can set in the RCPT ACL.

If you're asking SpamAssassin to use a whitelist, why not just let SpamAssassin use it? Alternatively, move your condition to be in the RCPT ACL instead.

Graeme