Gnus development mailing list
 help / color / mirror / Atom feed
From: Eric Abrahamsen <eric@ericabrahamsen.net>
To: ding@gnus.org
Subject: Re: resending bounces: DKIM and Message-ID:
Date: Fri, 03 Nov 2023 16:14:55 -0700	[thread overview]
Message-ID: <87msvu8m4w.fsf@ericabrahamsen.net> (raw)
In-Reply-To: <rmi34xn2fg4.fsf@s1.lexort.com>

Greg Troxel <gdt@lexort.com> writes:

> I found a behavior problem that I think is a bug in both gnus and
> opendkim.  Headers that are supposed to be added by the originating MTA
> are not removed, so the resent message has odd content: duplicate DKIM
> header, and the same Message-ID:
>
> My system in NetBSD 9 amd64 with emacs 28.2, but I don't think that's
> particularly important.
>
> Reproduction Recipe:
>
>   - send a message to a mailing list that you are not subscribed to, so
>     that it will bounce, and CC: an actual person
>   - subscribe to the list and confirm
>   - In the summary at the bounce, S D b (gnus-summary-resend-bounced-mail)
>   - In the resulting message buffer, C-c C-c (realizing or not realizing
>     that the actual person will get a second copy)
>
> This seems to me to be a normal sequence of events, and I'm here because
> it actually happened.  It was a discussion of DKIM/DMARC configuration
> for mailman, so the person in the CC: got two copies and actually
> noticed that there were two DKIM headers from my domain.
>
>
> The problem is that the message that is sent has two DKIM headers.  This
> is because the one that was added by the MTA on the way to the
> mailinglist is present because it was in the bounce, and then opendkim
> added a new one, because it just adds.
>
> But also, the Message-ID: was generated for the first message, and the
> that is reused.  That seems also like a bug.
> 
> The proposal is to fix this by:
>
>   * in gnus
>     - adding a list of headers which should be removed from bounce
>       messages when doing gnus-summary-resend-bounced-mail

I believe this is called `message-ignored-bounced-headers'! It does not
currently include DKIM-Signature, but maybe it should. I haven't
actually tested this, but looking at the code I believe it should take
effect in this situation.

>     - set the list to Message-ID and DKIM-Signature to start with

This is deeper in the protocol weeds than I usually go, so this is a bit
tentative, but I will note that there's a separate
`gnus-summary-resend-message-edit' command, which will not preserve the
Message-ID header. I think there's an argument to be made that, if
you're re-sending the bounced the message, it is in fact the same
message over again. If you're changing the "To:" or other headers, on
the other hand, that sounds like a new message, and you should be using
"S D e" instead.

What do you think?

Eric



  parent reply	other threads:[~2023-11-03 23:15 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-03 12:23 Greg Troxel
2023-11-03 16:14 ` Emanuel Berg
2023-11-03 23:14 ` Eric Abrahamsen [this message]
2023-11-05 15:55   ` Greg Troxel
2023-11-05 19:30     ` Eric Abrahamsen
2023-11-07  0:53       ` Greg Troxel
2023-11-07  1:57         ` Emanuel Berg
2023-11-07  3:15           ` Emanuel Berg
2023-11-07 13:49           ` Greg Troxel
2023-11-07 13:59             ` Emanuel Berg
2023-11-07  3:38         ` Eric Abrahamsen
2023-11-11 16:58           ` Greg Troxel
2023-11-19 19:44             ` Eric Abrahamsen
2023-11-19 21:36               ` Dan Christensen
2023-11-20  0:01                 ` Greg Troxel
2023-11-10 16:38         ` Eric Abrahamsen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87msvu8m4w.fsf@ericabrahamsen.net \
    --to=eric@ericabrahamsen.net \
    --cc=ding@gnus.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).