I upgraded to 5.8.0 from 5.3.0. We have a multidrop box and mails used
to bounce when sent to a nonexistent user. I have now noticed that no
bounce message is sent for a nonexistent user.
The transaction goes as:
SMTP> MAIL FROM:<linuxers-admin(_at_)hbcse(_dot_)tifr(_dot_)res(_dot_)in>
SIZE=3421
SMTP< 250 2.1.0 <linuxers-admin(_at_)hbcse(_dot_)tifr(_dot_)res(_dot_)in>...
Sender ok
SMTP> RCPT TO:<amarg(_at_)bombay(_dot_)retortsoft(_dot_)com>
SMTP< 550 5.1.1 <amarg(_at_)bombay(_dot_)retortsoft(_dot_)com>... User unknown
SMTP> RSET
SMTP< 250 2.0.0 Reset state
Saved error is still 550
On going through the diffs, I found the following diff in sink.c:
--- fetchmail-5.3.0/sink.c Wed May 16 13:30:09 2001
+++ fetchmail-5.8.0/sink.c Wed May 16 13:30:09 2001
@@ -759,6 +660,10 @@
else
{
char errbuf[POPBUFSIZE];
+ int res;
+
+ if ((res = handle_smtp_report(ctl, msg))==PS_REFUSED)
+ return(PS_REFUSED);
strcpy(errbuf, idp->id);
strcat(errbuf, ": ");
The handle_smtp_report() calls RSET immediately. This causes the
transaction to stop immediately and the bounce message is not
generated. Forwarding to postmaster also does not work. The body is
discarded.
If a mail is sent to one valid and one invalid user, the mail does not
go to the valid user also as the body is discarded after calling RSET!
Sunil Shetye.