Re: [exim] - Need help on ACL statement (subcondition)

Top Page
Delete this message
Reply to this message
Author: Dan_Mitton
Date:  
To: Laurent RISSE
CC: exim-users
Subject: Re: [exim] - Need help on ACL statement (subcondition)
Have you tried...

${if or {
        {
        and {{eq {${lc:$sender_helo_name}}{string2}} 
{eq{$sender_host_address}{XX.XX.XX.XX}}}
        }
        {
        and {{eq {${lc:$sender_helo_name}}{string2}} {eq 
{$sender_host_address}{XX.XX.XX.XX}}}
        }
        {
        and {{eq {${lc:$sender_helo_name}}{string3}} {eq 
{$sender_host_address}{XX.XX.XX.XX}}}
        }
        }
        {true}{false}
}




Sent by:        exim-users-bounces@???
To:     exim-users@???
cc:      (bcc: Dan Mitton/YD/RWDOE)
Subject:        [exim]  - Need help on ACL statement (subcondition)
LSN: Not Relevant
User Filed as: Not a Record


Hi all,

hope everybody is OK.

I try to make an ACL working with a series of statements...

Well, it consist of two "OR" tests, like that:

(
$a == "string1" AND $b == "IP1"
OR
$c == "string2" AND $d == "IP2"
OR
$e == "string3" AND $f == "IP3"
)

I write a test ACL like this:

${if or {
        {
        ${if and {{eq {${lc:$sender_helo_name}}{string2}} 
{eq{$sender_host_address}{XX.XX.XX.XX}}} {true}{false}
        }
        }
        {
        ${if and {{eq {${lc:$sender_helo_name}}{string2}} {eq 
{$sender_host_address}{XX.XX.XX.XX}}} {true}{false}
        }
        }
        {
        ${if and {{eq {${lc:$sender_helo_name}}{string3}} {eq 
{$sender_host_address}{XX.XX.XX.XX}}} {true}{false}
        }
        }
        }
        {true}{false}
}


My goal is to make a check on an peer consisting of a HELO string given
by the remote host with a combination of a certain incoming IP address...

After some tests, EXIM don't want this syntax, and I don't know if
"condition inside condition" concept is working (subconditioning !) ?

I hope that someone could help me on that topic :)

Thanks to all

Regards

Laurent
-------

--
## List details at http://www.exim.org/mailman/listinfo/exim-users
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://www.exim.org/eximwiki/