[Exim] ${if help

Página superior
Eliminar este mensaje
Responder a este mensaje
Autor: Dan Egli
Fecha:  
A: exim-users
Asunto: [Exim] ${if help
Ok.. I'm trying to put together a multi-compound condition for
SpamAssasin. Since SA-Exim uses Exim's expansion routines I'm trying to
follow the specs but it keeps goofing up.

Here's the condition I'm trying to check:

sender_host_address <> 127.0.0.1 *AND*
sender_host_address <> [ a friend's IP ] *AND*
X-(sa_header) not present in message.

Here's the condition I have setup so far, but it always fails the
expansion: (of course I changed the strings, for this message since I
don't want to broadcast my spam-assassin bypass header or my friend's mail
server IP)

${if and ${if and {{def:sender_host_address} {!eq
{$sender_host_address}{127.0.0.1}} {!eq {$h_X-SA-Header-Cleared:}\{Yes}}}
{1}{0}} {!eq {$sender_host_address}{1.2.3.4}} {1}{0}}

I thought that would be ok. If I read it left to right I get:

if sender_host_address is defined, and sender_host_address is not
127.0.0.1 and the header X-SA-Header-Cleared is present and the
sender_host_address is not 1.2.3.4.


What am I doing wrong? These expansions have never made much sense to me
so I'm quite lost here.

Thanks for the help! Quick responses are always appreciated!

--- Dan