[Exim] Multiple conditions in filter?

Pàgina inicial
Delete this message
Reply to this message
Autor: j2
Data:  
A: exim-users
Assumpte: [Exim] Multiple conditions in filter?
This is a multi-part message in MIME format.
--
[ Picked text/plain from multipart/alternative ]
I have been banging my head agains the wall, and not being able to figure this one out. Below is a part of my filter.

# Exim filter

if error_message then finish endif
if
        ($h_X-Spam-Score: contains "++"
or
        "${if def:h_X-Spam-Flag {def}{undef}}" is "def")
and not
        ${lookup{$return_path}lsearch{/home/j2/etc/mail/whitelist}{yes}} is "yes"
then
        save $home/Maildir/.Trash/
        finish
endif


Now, i would like to do is add another clause to the "and not" part, i would like to also search /home/j2/etc/mail/sort-Return-Path.conf a file with lines like

exim-users-admin@???:                                      .Listor.Exim


so basically, "if the return path is in the sort-Return-Path OR in the whitelist file, do not trash it wven if spamassassin flags in".

Can someone tell me HOW to do this, as i have now tried dozens of ways NOT to do it? (Exim 4.20)
--