From 477badfc705c5dd59cfd8a577eab9eaf4a510e0f Mon Sep 17 00:00:00 2001 From: Illia Ostapyshyn Date: Wed, 20 Dec 2023 13:57:28 +0100 Subject: [PATCH] Use S/MIME key from content for mail signing via OpenSSL * lisp/gnus/mml-smime.el (mml-smime-openssl-sign): Use the key passed in the cont argument instead of the first smime-keys entry. --- lisp/gnus/mml-smime.el | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/lisp/gnus/mml-smime.el b/lisp/gnus/mml-smime.el index 896c95f8d3e..713b7fe5b68 100644 --- a/lisp/gnus/mml-smime.el +++ b/lisp/gnus/mml-smime.el @@ -130,10 +130,7 @@ mml-smime-verify-test (funcall func handle ctl)))) (defun mml-smime-openssl-sign (_cont) - (when (null smime-keys) - (customize-variable 'smime-keys) - (error "No S/MIME keys configured, use customize to add your key")) - (smime-sign-buffer (cdar smime-keys)) + (smime-sign-buffer (cdr (assq 'keyfile cont))) (goto-char (point-min)) (while (search-forward "\r\n" nil t) (replace-match "\n" t t)) -- 2.43.0