[exim] What is the easiest way to block email based on body …

Top Page
Delete this message
Reply to this message
Author: jori.hamalainen
Date:  
To: exim-users
Subject: [exim] What is the easiest way to block email based on body text?
Hi,

I am using standard Exim 4.10 and I must stop messages with some text in message body from entering the system.

Is this the best way?

split_spool_directory=true

acl_data:
    deny message = Your message contains illegal text
        condition = ${run{grep -q "illegal text" $spool_directory/input/[how to get subdir?]/$messageid-D}{yes}{no}}


or better ideas?