Noel Jones wrote:
On 4/12/2011 8:28 AM, Randy Ramsdell wrote:
Hi,

I am trying to block all mail going to a certain domain. We use
smtpd_recipient_restrictions = check_recipient_access
hash:/etc/postfix/protected_lists

and it counterpart:

smtpd_restriction_classes = list_blocks
list_blocks = check_sender_access
hash:/etc/postfix/list_members,reject

The user@host is not found in list_members.

I added the domain in protected_lists in this form.

$domain.com reject

When sending to his domain, the message bounces with a "Host
or domain name not found"

The domain does not exist but until the code can reviewed and
changed, I have to block these messages.

Any suggestions as to why this does not work?

You've not given enough evidence for anyone to say where the error is.


I use the protected_lists to block certain groups, people etc from sending to internal lists. There really is no error thrown by postfix. It is a configuration problem in general.

An example:
$USER@               permit_mynetworks,permit_sasl_authenticated,reject

Or how do I
configure postfix to not check DNS and simply reject/discard?

I think the easiest way to ban a domain is to add it to the transport_maps with an entry something like
bad.example.com  error:invalid domain


  -- Noel Jones

I added this to transports and postmapped it:

.someinvaliddomainname.com error:Mail for *.someinvaliddomainname.com not delivered.

I can still recieve the bounce which is what I am trying to stop. I do not want to bounce for DNS issues. I want to simply reject or better yet, discard.

Reply via email to