Per Jessen wrote:
david rankin wrote:
OK, here is another question. How do I handle the situation where $myorgin is rbpllc.com, but rankin-bertin.com, rankinlawfirm.com and guillorylaw.com all resolve to the same IP? Ideally, I would like to have mail to root@anyofthose.com rejected from the internet. First thought is multiple listing in check_recipient_access hash:/etc/postfix/recipients_internal_only:
/etc/postfix/recipients_internal_only: root@rbpllc.com REJECT root@rankin-bertin.com REJECT root@rankinlawfirm.com REJECT
I'm assuming you've got those other domain names set up as virtual hosts, in which case the above will work just fine.
Actually, the check does not care in what kind of address class the domain
is, the check will will only compare the key "recipient address" against
the database and then return the result.
smtpd_recipient_restrictions =
check_recipient_access hash:/etc/postfix/recipients_rejected,
permit_mynetworks,
permit_sasl_authenticated,
reject_unauth_destination,
....
/etc/postfix/recipients_rejected:
bumblebee@smurf.invalid REJECT
suse-linux-e-owner@suse.de REJECT
smurf.invalid is not (and will never be) in my domain classes.
suse-linux-e-owner is valid (for suse.de) but will be rejected by this
test as well.
Jan 17 10:57:32 katgar postfix/smtpd[18187]: NOQUEUE: reject: RCPT from
grobi.washu.lab[192.168.0.4]: 554 5.7.1