From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Sean Whitton Newsgroups: gmane.emacs.bugs Subject: bug#54429: 29.0.50; message-resend should not use the original sender's address for the envelope-from Date: Wed, 16 Mar 2022 13:23:26 -0700 Message-ID: <87zglpy7cx.fsf@melete.silentflame.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="40051"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Notmuch/0.31.4 (https://notmuchmail.org) Emacs/29.0.50 (x86_64-pc-linux-gnu) To: 54429@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Mar 16 21:24:17 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nUaBr-000A9w-7f for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 16 Mar 2022 21:24:16 +0100 Original-Received: from localhost ([::1]:50556 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nUaBq-0001vq-6W for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 16 Mar 2022 16:24:14 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:59232) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nUaBf-0001vi-Aq for bug-gnu-emacs@gnu.org; Wed, 16 Mar 2022 16:24:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:58473) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nUaBf-0006Yh-1y for bug-gnu-emacs@gnu.org; Wed, 16 Mar 2022 16:24:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nUaBe-00043v-Jm for bug-gnu-emacs@gnu.org; Wed, 16 Mar 2022 16:24:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Sean Whitton Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 16 Mar 2022 20:24:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 54429 X-GNU-PR-Package: emacs X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.164746221415576 (code B ref -1); Wed, 16 Mar 2022 20:24:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 16 Mar 2022 20:23:34 +0000 Original-Received: from localhost ([127.0.0.1]:52370 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nUaBB-000438-SP for submit@debbugs.gnu.org; Wed, 16 Mar 2022 16:23:34 -0400 Original-Received: from lists.gnu.org ([209.51.188.17]:56230) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nUaBA-000431-DZ for submit@debbugs.gnu.org; Wed, 16 Mar 2022 16:23:32 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:59086) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nUaBA-0001rg-8F for bug-gnu-emacs@gnu.org; Wed, 16 Mar 2022 16:23:32 -0400 Original-Received: from out5-smtp.messagingengine.com ([66.111.4.29]:45889) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nUaB8-0006VV-4X for bug-gnu-emacs@gnu.org; Wed, 16 Mar 2022 16:23:31 -0400 Original-Received: from compute2.internal (compute2.nyi.internal [10.202.2.46]) by mailout.nyi.internal (Postfix) with ESMTP id D5DCB5C01D7 for ; Wed, 16 Mar 2022 16:23:27 -0400 (EDT) Original-Received: from mailfrontend1 ([10.202.2.162]) by compute2.internal (MEProxy); Wed, 16 Mar 2022 16:23:27 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=spwhitton.name; h=cc:content-type:date:date:from:from:in-reply-to:message-id :mime-version:reply-to:sender:subject:subject:to:to; s=fm3; bh=P Id5T3GJHUde+yAfbbrKI2n9UYF3P6gFzPGyyIh1ubc=; b=WG1wi84b0MWLOp6D0 R5z300F4Sd+0cuOqR/k9dsp18eTYvbrU4iAKlTeD4J4oXRlQgpIT3McswPGJuhIV w498pgZ586+xo4RBXOQrism52HRTY1Hr2KZ2LLbefAFvMk2oizOpzbtwX8X7UrCS HpAZlqNTCV2xAWQhZqJ4SZUHDUacQ29HK/LTlAHGqCzJ8SH6o72TKzTe+a3K5Jkd HB3pmFNe3gIZNLQuELsDt6RgQyh7FxpafT+6kuQPAOUEfW67vTxv9/o76PGHURSy Sf7E+AXgboq/yxdqydKETIMbPJQAT74JTzMZYbQm69gX8Vlu8yO0D0j+Pnfg1rsH yFsxA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:date:from:from :in-reply-to:message-id:mime-version:reply-to:sender:subject :subject:to:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm3; bh=PId5T3GJHUde+yAfbbrKI2n9UYF3P6gFzPGyyIh1u bc=; b=k3Z+wwDP9NhbBIipk7LdJv4JIy9F4ok6e3u6hTW9v8bCfoXgqJoKYQXqn VGMZGdPssrtYgrpnOPaJ3+ZrgRJqx/HbsXIopVmPICBtJltHgn6b6Ls7DVRczmmc EP6jhkuPTS0bPKQXnPwQTI0KZ2HzJ5ty//FvxF2glscNRDIu8FPpwM1JMMVTv+nn d39AG6EBb2uT4fxawBUOwCPZOd3ywaY+wfkkBP3vIwGSS07Gjh30ooNUwQ/s7ZG3 qRDRK0p9Lr8lIP2AtiN9Tx5c0lROnsm+cuzk1rzVmrq6WX1nozH9uNRVZf1T8sBx 2hXfU2YNLS2w4yDDOaH1We0MbErfA== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvvddrudefvddgudeffecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh necuuegrihhlohhuthemuceftddtnecunecujfgurhephffvufgffffkgggtsehmtddtre dtredtnecuhfhrohhmpefuvggrnhcuhghhihhtthhonhcuoehsphifhhhithhtohhnsehs phifhhhithhtohhnrdhnrghmvgeqnecuggftrfgrthhtvghrnhepkeeggeeujeeludegve evveeljeffhfelhfegfffhudehhffhkedvheeftedvueelnecuvehluhhsthgvrhfuihii vgeptdenucfrrghrrghmpehmrghilhhfrhhomhepshhpfihhihhtthhonhesshhpfihhih htthhonhdrnhgrmhgv X-ME-Proxy: Original-Received: by mail.messagingengine.com (Postfix) with ESMTPA for ; Wed, 16 Mar 2022 16:23:27 -0400 (EDT) Original-Received: by melete.silentflame.com (Postfix, from userid 1000) id 4F5297E17D3; Wed, 16 Mar 2022 13:23:26 -0700 (MST) Received-SPF: pass client-ip=66.111.4.29; envelope-from=spwhitton@spwhitton.name; helo=out5-smtp.messagingengine.com X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:228450 Archived-At: --=-=-= Content-Type: text/plain If `message-sendmail-envelope-from' is `header' then the envelope-from will be the original sender's address, not the resender's. But when resending, the envelope-from should be the resender's address. Defuse that particular case. -- Sean Whitton --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=0001-Don-t-use-the-original-sender-s-address-as-the-envel.patch >From 03abba1ccdc8604ff7e59ab8b4c55d18185d0fd1 Mon Sep 17 00:00:00 2001 From: Sean Whitton Date: Wed, 16 Mar 2022 13:19:57 -0700 Subject: [PATCH] Don't use the original sender's address as the envelope-from * lisp/gnus/message.el (message-resend): Avoid setting the envelope-from to the original sender's address rather than the resender's. --- lisp/gnus/message.el | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/lisp/gnus/message.el b/lisp/gnus/message.el index 800c7dcea0..ad04a5e865 100644 --- a/lisp/gnus/message.el +++ b/lisp/gnus/message.el @@ -8016,7 +8016,18 @@ message-resend (select-safe-coding-system-function nil) message-required-mail-headers message-generate-hashcash - rfc2047-encode-encoded-words) + rfc2047-encode-encoded-words + ;; If `message-sendmail-envelope-from' is `header' then + ;; the envelope-from will be the original sender's + ;; address, not the resender's. But when resending, the + ;; envelope-from should be the resender's address. Defuse + ;; that particular case. + (message-sendmail-envelope-from + (and (not (and (eq message-sendmail-envelope-from + 'obey-mail-envelope-from) + (eq mail-envelope-from 'header))) + (not (eq message-sendmail-envelope-from 'header)) + message-sendmail-envelope-from))) (message-send-mail)) (when gcc (message-goto-eoh) -- 2.30.2 --=-=-=--