Hello,
I am wondering if there is a way to check which router (or
alternatively, which driver) is used to direct a particular recipient
address in the RCPT ACL -- before any "redirect".
What I am trying to do is to reject mail from NULL senders (i.e.
bounces) unless the recipient address is a real user that sends
outgoing mail. Something like:
deny
message = This address never sends outgoing mail. \
You are responding to a forged sender address.
log_message = bogus bounce for system user
senders = :
domains = +local_domains
<if router != cyrus_lmtp>
I realize:
- That I can add a "!senders = :" condition to the system_aliases
router,
so that DSNs to system aliases are not accepted. However, in some
cases
(e.g. "mail", "root", etc..) these aliases merely shadows an
original system
user, which would otherwise be accepted anyway by the "local_user"
router.
- That I can check for a valid mailbox account by other means (in the
case of
Cyrus, by way of the "mbpath" command; otherwise, by checking for
/home/${lc:$local_part}). However, these means are specific to how
mail is
delivered, and essentially duplicate logic performed in the router
anyway.
Ideas?
Thanks,
-tor