Hi all,

I am trying to figure out the best way to reject RCPT TO addresses with no
domain part - i.e. "RCPT TO: <test>" or similar. I do not want to rewrite
to $myhostname or $mydomain or similar.

I am on postfix 2.10.

This is for an MSA function - if email passes validation checks and is
authenticated, it is immediately sent to another system for delivery or
transmission to remote networks. There is no local delivery on this server.
Due to the nature of the system, any incoming mail without a domain is due
to end user errors - so we want to reject it and present the client with an
error message in the SMTP exchange.

I have come up with some solutions which feel a lot like workarounds /
hacks - i.e. checking for .*@$myhostname as a recipient and rejecting it,
or something like that.

Are there any better ways to achieve this? I was expecting to find an
option, like "reject_no_domain" in recipient restrictions or something.
What I've found is that recipient_restrictions checks the resolved
recipient - not what the client presented.

I note that reject_non_fqdn_recipient exists, however, I'd like to be able
to accept mail addressed to user@gtld - for when people inevitably start
doing that if they're not already.

Thanks in advance !

--
Nathan Ward

Reply via email to