On 9 Dec 2004 at 14:22, Richard Hopkins wrote about
"[exim] Discarding a message without":
|...
| # Discard virus infested messages.
| warn log_message = Discarding message with virus $malware_name
| malware = *
| discard malware = *
|
|
| # Discard spam messages with score over 25
| warn log_message = Message rejected as spam (scored $spam_score points)
| condition = ${if <{$message_size}{100k}{1}{0}}
| spam = nobody:true
| condition = ${if >{$spam_score_int}{250}{1}{0}}
| discard condition = ${if >{$spam_score_int}{250}{1}{0}}
Hmm. Your discard conditions don't match the warn conditions you are
relying on to log the message. In particular, you won't be setting
$spam_score_int for messages over 100k, but you are testing it
unconditionally in the discard stanza. Assuming these are the only
discard actions in your config, I'd have to suspect that.
What is the purpose of using warn followed by discard, as opposed to
simply discard? ISTM it would be simpler and safer to have a single
stanza rather than the pair:
# Discard virus infested messages.
discard log_message = Discarding message with virus $malware_name
malware = *
# Discard spam messages with score over 25
discard log_message = Message rejected as spam (scored $spam_score points)
condition = ${if <{$message_size}{100k}{1}{0}}
spam = nobody:true
condition = ${if >{$spam_score_int}{250}{1}{0}}
This change may or may not prevent the unexpected discard, but at
least it will prevent discards without a matching log_message.
- Fred