diff options
-rw-r--r-- | NEWS | 3 | ||||
-rw-r--r-- | fetchmail-features.html | 6 | ||||
-rw-r--r-- | fetchmail.man | 3 | ||||
-rw-r--r-- | sink.c | 46 |
4 files changed, 24 insertions, 34 deletions
@@ -4,8 +4,9 @@ fetchmail-4.7.3 (): * Added new FAQ item G11 and added material to R1. * Do a full antispam check on the EOM response in case the local MTA does content analysis of the message body. +* Bouncemail now conforms to RFC1984 correctly. -There are 246 people on fetchmail-friends and 329 on fetchmail-announce. +There are 249 people on fetchmail-friends and 337 on fetchmail-announce. fetchmail-4.7.2 (Fri Dec 25 01:01:54 EST 1998): * Don't append the destination address to a postmaster name containing @. diff --git a/fetchmail-features.html b/fetchmail-features.html index 7cdf489f..23be2ce1 100644 --- a/fetchmail-features.html +++ b/fetchmail-features.html @@ -10,7 +10,7 @@ <table width="100%" cellpadding=0><tr> <td width="30%">Back to <a href="index.html">Fetchmail Home Page</a> <td width="30%" align=center>To <a href="/~esr/sitemap.html">Site Map</a> -<td width="30%" align=right>$Date: 1998/12/15 16:17:21 $ +<td width="30%" align=right>$Date: 1998/12/30 18:12:29 $ </table> <HR> @@ -18,7 +18,7 @@ <H2>Since 4.0:</H2> <UL> -<LI> Fetchmail now sends bouncemail on SMTP and LMTP errors. +<LI> Fetchmail now sends RFC1984-conformant bouncemail on SMTP and LMTP errors. <LI> Full support for LMTP according to RFC2033. @@ -165,7 +165,7 @@ get-mail, gwpop, pimp-1.0, pop-perl5-1.2, popc, popmail-1.6 and upop.<P> <table width="100%" cellpadding=0><tr> <td width="30%">Back to <a href="index.html">Fetchmail Home Page</a> <td width="30%" align=center>To <a href="/~esr/sitemap.html">Site Map</a> -<td width="30%" align=right>$Date: 1998/12/15 16:17:21 $ +<td width="30%" align=right>$Date: 1998/12/30 18:12:29 $ </table> <P><ADDRESS>Eric S. Raymond <A HREF="mailto:esr@thyrsus.com"><esr@snark.thyrsus.com></A></ADDRESS> diff --git a/fetchmail.man b/fetchmail.man index d6467bf5..81a3cc18 100644 --- a/fetchmail.man +++ b/fetchmail.man @@ -1783,8 +1783,7 @@ MDA. For maximum safety, however, don't use an mda command containing %F or %T when fetchmail is run from the root account itself. .PP Fetchmail's method of sending bouncemail requires that port 25 of localhost -be available for sending mail via SMTP. The bouncemail format conforms -to 1892, but not yet to 1894. +be available for sending mail via SMTP. .PP Send comments, bug reports, gripes, and the like to the fetchmail-friends list <fetchmail-friends@ccil.org>. An HTML FAQ is @@ -307,45 +307,35 @@ static int send_bouncemail(struct msgblk *msg, SockPrintf(sock, "--%s\r\n", boundary); SockPrintf(sock,"Content-Type: message/delivery-status\r\n"); SockPrintf(sock, "\r\n"); -#ifdef RFC1894 - SockPrintf(sock, "Reporting-MTA: DNS; %s\r\n", fetchmailhost); -#endif /* RFC1894 */ + SockPrintf(sock, "Reporting-MTA: dns; %s\r\n", fetchmailhost); for (i = 0; i < nerrors; i++) { -#ifndef RFC1894 - SockPrintf(sock, "%s\r\n", errors[i]); -#else /* Minimum RFC1894 compliance + Diagnostic-Code field */ SockPrintf(sock, "\r\n"); - /* - * And here's the real reason RFC1984-style DSNs don't - * work; we can't generate Final-Recipient properly. - * First, fetchmailhost is probably going to be just - * `localhost'. Secondly, we're only sure of the final - * recipient in the single-drop case; in the multidrop - * case, we don't have any idea how to get that - * information (it's not guaranteed that errors even - * correspond one-to-one with recipients). - */ - SockPrintf(sock, "Final-Recipient: RFC822; %s@%s\r\n", - msg->recipients->id, - fetchmailhost); + if (msg->recipients && !msg->recipients->next) + SockPrintf(sock, "Final-Recipient: rfc822; %s\r\n", + msg->recipients->id); + else + /* + * This is technically compliant with RFC1894, + * because "multidrop;" is an RFC822 group + * address. It kind of evades the intent, though. + * Unfortunately, it's just too hard to do the + * right thing here when there are multiiple + * multidrop recipients; we don't know how to + * associate them with the list of errors passed in. + */ + SockPrintf(sock,"Final-Recipient: rfc822; multidrop; (see the message headers below)\r\n"); SockPrintf(sock, "Action: failed\r\n"); if (strlen(errors[i]) > 9 && isdigit(errors[i][4]) - && errors[i][5] == '.' && isdigit(errors[i][6]) - && errors[i][7] == '.' && isdigit(errors[i][8])) - { + && errors[i][5] == '.' && isdigit(errors[i][6]) + && errors[i][7] == '.' && isdigit(errors[i][8])) /* Enhanced status code available, use it */ SockPrintf(sock, "Status: %5.5s\r\n", &(errors[i][4])); - SockPrintf(sock, "Diagnostic-Code: smtp; %3.3s%s\r\n", errors[i], &(errors[i][9])); - } else - { /* Enhanced status code not available, fake one */ SockPrintf(sock, "Status: %c.0.0\r\n", errors[i][0]); - SockPrintf(sock, "Diagnostic-Code: smtp; %s\r\n", errors[i]); - } -#endif /* RFC1894 */ + SockPrintf(sock, "Diagnostic-Code: %s\r\n", errors[i]); } SockPrintf(sock, "\r\n"); } |