Download raw body.
lmtp relay fix multible recipients
Hi tech
The lmtp relay doesn't correct handle multible responses for the DATA
command when having multible recipient. This results in a teporary error
for the secound (and following) recipients. The log shows the folloing:
> 84b3d669d00f3903 mta delivery evpid=7446558dffc99e03 from=sender@fsmi.org to=list@fsmi.org rcpt=<-> source="127.0.0.1" relay="127.0.0.1 (localhost)" delay=0s result="TempFail" stat="Remote host sent too much data"
This is because in mta_io() the MTA_LMTP_EOM state is not handled after
the mta_response() call. A patch is attached.
Philipp
diff --git a/usr.sbin/smtpd/mta_session.c b/usr.sbin/smtpd/mta_session.c
index 8aa23779f8f..ebb0489668a 100644
--- a/usr.sbin/smtpd/mta_session.c
+++ b/usr.sbin/smtpd/mta_session.c
@@ -1330,6 +1330,9 @@ mta_io(struct io *io, int evt, void *arg)
mta_connect(s);
return;
}
+ if (s->state == MTA_LMTP_EOM) {
+ goto nextline;
+ }
if (io_datalen(s->io)) {
log_debug("debug: mta: remaining data in input buffer");
lmtp relay fix multible recipients