[Exim] Nested if conditions

トップ ページ
このメッセージを削除
このメッセージに返信
著者: JP Kelly
日付:  
To: exim-users
古いトピック: [Exim] Deny sender where from or reply-to is "*@*.kr"
題目: [Exim] Nested if conditions
I can't seem to get this to work:

spam_tag_router:
check_local_user
# - bypass bounce in system filter if spam flag is set to tag
condition = ${if and{eq{tag} {${lookup mysql {SELECT spam FROM passwd
WHERE id='${local_part}@${domain}'}}} {!d
ef:h_X-Spam-Flag:}} {yes}{no}}
driver = accept
transport = spamtag

The nested conditions in my if statement keep giving me an error.

2002-12-21 20:54:21 H7I8AJ-0002BR-00 <jpkelly@???>: spamcheck
transport output: 2002-12-21 20:54:21 H7I8AJ-0002BV-00 failed to expand
condition "${if and{eq{tag} {${lookup mysql {SELECT spam FROM passwd
WHERE id='${local_part}@${domain}'}}} {!def:h_X-Spam-Flag:}}
{yes}{no}}" for spam_tag_router router: subcondition in {} expected
inside "and{...}" condition

What is the syntax to properly nest conditions?