Hi!
Is there any way to handle several recipients of a mail differently
from within a system filter?
To have some control of which users can send to non-local domains, a
system filter could be set up as follows:
[...]
# block mail to non-local users from local users according to setup
#
if ${lookup{$sender_address:out}lsearch{/etc/exim/mail.allow}{$value}} is "no" then
if foranyaddress $recipients ($thisaddress does not contain "yun.yagibdah.de") then
fail "\nSorry, you're not allowed to send mail\n\
to non-local users like <$thisaddress>.\n\
This has been configured by the system\n\
administrator.\n"
endif
endif
[...]
The filter looks up users in /etc/exim/mail.allow. That file contains
a list of users for whom restrictions should apply:
lee@???: in=yes out=no
foo@???: in=yes out=no
In this example, both lee and foo are restricted from sending mail to
non-local domains. This works until they create messages with multiple
recipients: all recipients would fail. But I want the message
delivered to those recipients that are local and rejected for those
that are remote.
How can I achieve that?
BTW, the filter file should exclude bounces from being rejected. How
can I put the empty string into filter files?
GH
--
This mail is copyrighted material and must not be processed by
closed-source software.