-
Notifications
You must be signed in to change notification settings - Fork 179
Q0513
Nigel Metheringham edited this page Nov 30, 2012
·
3 revisions
I want my system filter to freeze all mails greater than 500K in size, but to exclude those to a specific domain. However, I don't seem to be able to use $domain in a system filter.
You cannot do this in a system filter, because a single message may have multiple recipients, some in the special domain, and some not. That is also the reason why $domain is not set in a system filter. If you want to take actions on a per-recipient basis, you have to do it in a router. However, freezing is not appropriate, because freezing stops all deliveries. You could, however, delay delivery to all but the special domains by using something like this:
delay_if_too_big:
driver = redirect
domains = !the.special.domain
condition = ${if >{$message_size}{500K}{yes}{no}}
allow_defer
data = :defer: message too big.
However, there isn't an easy way of releasing > such messages at present.
- My filter isn't working. How can I test it?
- What I really need is the ability to obtain the result of a pipe command
- I received a message with a Subject: line that contained a
- I want to search for
$
in the subject line, but I can't seem to get - My problem is that Exim replaces $local_part with an empty string in
- Using $recipients in a system filter gives me another problem: how
- What are the main differences between using an Exim filter and using
- How can I allow the use of relative paths in users' filter files when
- How can I set up a filter file to detect and block virus attachments?
- Is it possible to write code for scanning messages in Python?
- Whenever my system filter uses a
mail
command to send a message, I get - I'm trying to reference the Envelope-To: header in my filter, but
- I want my system filter to freeze all mails greater than 500K in size,
- When I try to send to two addresses I get an error in the filter file