From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Lars Ingebrigtsen Newsgroups: gmane.emacs.bugs Subject: bug#26587: 26.0.50; Gnus signs with false S/MIME key Date: Wed, 09 Oct 2019 21:59:34 +0200 Message-ID: <87sgo14rmh.fsf@gnus.org> References: <87fuh22dk6.fsf@wilson.bronger.org> <87r241kb4y.fsf@gnus.org> <87pnj6s3bj.fsf@physik.rwth-aachen.de> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="240722"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) Cc: 26587@debbugs.gnu.org To: Torsten Bronger Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Oct 09 23:14:35 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1iIJI2-0010Ph-1D for geb-bug-gnu-emacs@m.gmane.org; Wed, 09 Oct 2019 23:14:34 +0200 Original-Received: from localhost ([::1]:58338 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iIJI0-0000FM-CJ for geb-bug-gnu-emacs@m.gmane.org; Wed, 09 Oct 2019 17:14:32 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:58949) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iII7v-0000wA-Qd for bug-gnu-emacs@gnu.org; Wed, 09 Oct 2019 16:00:04 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iII7u-0007jB-F7 for bug-gnu-emacs@gnu.org; Wed, 09 Oct 2019 16:00:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:45342) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1iII7u-0007j0-9X for bug-gnu-emacs@gnu.org; Wed, 09 Oct 2019 16:00:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1iII7u-0000a1-3D; Wed, 09 Oct 2019 16:00:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Lars Ingebrigtsen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org, bugs@gnus.org Resent-Date: Wed, 09 Oct 2019 20:00:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 26587 X-GNU-PR-Package: emacs,gnus X-GNU-PR-Keywords: security moreinfo Original-Received: via spool by 26587-submit@debbugs.gnu.org id=B26587.15706511812173 (code B ref 26587); Wed, 09 Oct 2019 20:00:01 +0000 Original-Received: (at 26587) by debbugs.gnu.org; 9 Oct 2019 19:59:41 +0000 Original-Received: from localhost ([127.0.0.1]:54162 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iII7Y-0000Yy-KU for submit@debbugs.gnu.org; Wed, 09 Oct 2019 15:59:40 -0400 Original-Received: from quimby.gnus.org ([80.91.231.51]:42770) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iII7X-0000Yq-6n for 26587@debbugs.gnu.org; Wed, 09 Oct 2019 15:59:39 -0400 Original-Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=marnie) by quimby.gnus.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1iII7T-0003wv-9t; Wed, 09 Oct 2019 21:59:37 +0200 In-Reply-To: <87pnj6s3bj.fsf@physik.rwth-aachen.de> (Torsten Bronger's message of "Wed, 9 Oct 2019 10:58:24 +0200") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 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.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:168789 Archived-At: Torsten Bronger writes: > When writing the message, I call (mml-secure-message-sign-smime). > The "From:" field contains "Torsten Bronger > ". My secret keys are: OK, my first attempt at this ended up with Message not complaining at all, but sending out a "signed" message with the following empty signature: --=-=-= Content-Type: application/pkcs7-signature; name=smime.p7s Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename=smime.p7s --=-=-=-- I've now made it bug out if it can't find any identity to sign with. Now, for the bug you're seeing... If I'm tracing the code right (and I may well not be), this is what's used to find what name to sign with: (defun mml-secure-signer-names (protocol sender) "Determine signer names for PROTOCOL and message from SENDER. Returned names may be e-mail addresses or key IDs and are determined based on `mml-secure-openpgp-signers' and `mml-secure-openpgp-sign-with-sender' with OpenPGP or `mml-secure-smime-signers' and `mml-secure-smime-sign-with-sender' with S/MIME." (if (eq 'OpenPGP protocol) (append mml-secure-openpgp-signers (if (and mml-secure-openpgp-sign-with-sender sender) (list (concat "<" sender ">")))) (append mml-secure-smime-signers (if (and mml-secure-smime-sign-with-sender sender) (list (concat "<" sender ">")))))) mml-secure-smime-sign-with-sender defaults to nil, so it's normally not used. So this returns just the value of mml-secure-smime-signers. What's that variable for you? -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no