better smtp handling

Issue #709 closed
Former user created an issue

It seems monit doesn't check for a 4xx error code and insists on sending the email:

In:  MAIL FROM:<monit@example.ltd> BODY=7BIT
Out: 451 4.7.1 Service unavailable - try again later
In:  RCPT TO:<webmaster@example.ltd> ORCPT=rfc822;webmaster@example.ltd
Out: 503 5.5.1 Error: need MAIL command
In:  DATA
Out: 503 5.5.1 Error: need RCPT command
In:  RSET
Out: 250 2.0.0 Ok
In:  QUIT
Out: 221 2.0.0 Bye

Comments (3)

  1. Tildeslash repo owner

    Are you sure these commands came from monit?

    1. Monit doesn't set BODY=7BIT option in MAIL FROM
    2. Monit doesn't set the ORCPT option in RCPT TO
    3. Monit never uses the RSET command
    4. Monit checks for code 250 in response to MAIL FROM command

    The communication is from some different SMTP client - not monit. ... maybe even some spam bot (as these usually doesn't wait for server response and pipeline commands to the server) or some SMTP crawler.

  2. Log in to comment