View Single Post
  #1  
Old 23rd May 2013, 21:28
cbj4074 cbj4074 is offline
Senior Member
 
Join Date: Nov 2010
Posts: 395
Thanks: 30
Thanked 58 Times in 50 Posts
Default Force disconnect instead of 554 5.7.1 <user@example.com> Relay access denied

I am using Postfix and have noticed vast numbers of messages like this one lately:

Code:
postfix/smtpd[20961]: NOQUEUE: reject: RCPT from some-host.example.com[1.2.3.4]: 554 5.7.1 <user@domain2.com>: Relay access denied; from=<user@domain1.com> to=<user@domain2> proto=ESMTP helo=<[169.254.97.163]>
This results from automated "bots" attempting to hammer mail through this server (even though relaying is not allowed).

I find this annoying. Is there some way to drop the connection immediately if the user-agent has not authenticated? I don't want anybody sending mail through this server who isn't authenticated, unless the connection is coming from 127.0.0.1. Everyone else can simply be disconnected immediately.

This must be possible in Postfix. Any help is greatly appreciated.

P.S. Yes, I have searched on this subject, but, unfortunately, almost all of the resources returned relate to people who are receiving "relay access denied" erroneously when trying to send legitimate mail themselves.
Reply With Quote
Sponsored Links