1

Consider the following SMTP-Session:

220 mx.example.com ESMTP Postfix
EHLO example.com
250-mx.example.com
250-PIPELINING
250-SIZE 10240000
250-ETRN
250-STARTTLS
250-ENHANCEDSTATUSCODES
250-8BITMIME
250-DSN
250 SMTPUTF8
MAIL FROM:<>
250 2.1.0 Ok
RCPT TO:<test@example.com>
250 2.1.5 Ok
DATA
354 End data with <CR><LF>.<CR><LF>
Subject: Test
Test
.
451 4.7.1 Try again later

What is a client supposed to do after this? Is he allowed to send an RSET and try another Mail?

This Question is loosely related to this rspamd issue and I am not sure who behaves wrong:

  • rspamd for not handling multiple mails in one session correctly if the first delivery fails
  • Postfix for not sending rspamd the correct Milter Commands
  • OpenSMTPd for delivering another mail after one that already failed
Subito
  • 378
  • 1
  • 3
  • 11
  • In general the RFC mandated and implied behaviour is to attempt delivery of each message and in case of an transient error to retry the failed message(s) after *a while* and be intelligent about retrying. See RFC 5321 [section-4.2.1](https://tools.ietf.org/html/rfc5321#section-4.2.1) and [section-4.5.4](https://tools.ietf.org/html/rfc5321#section-4.5.4) – HBruijn Feb 26 '18 at 14:30
  • 1
    Making @HBruijn reply more specific: You may try to send another message(s) over this SMTP session. IMHO it may make sense to drop SMTP session after two such temporary rejects [my personal rule of thumb] – AnFi Feb 26 '18 at 15:30
  • Thanks, thats already helpful. So it seems that OpenSMTPd and Postfix are probably behaving correctly (according to the RFC, which is not very specific on the "in this session"-part) and rspamd has some kind of bug which always rejects the second (third, fourth...) message after the first has not succeeded. – Subito Feb 26 '18 at 15:52

0 Answers0