From: Teemu Likonen <tlikonen@iki.fi>
To: emacs-devel@gnu.org
Cc: Daiki Ueno <ueno@unixuser.org>, Michael Olson <mwolson@gnu.org>
Subject: [PATCH] Fix bug in handling GnuPG's TRUST_MARGINAL status
Date: Sun, 25 Jun 2017 20:50:54 +0300 [thread overview]
Message-ID: <87tw34dkht.fsf@mithlond.arda> (raw)
[-- Attachment #1: Type: text/plain, Size: 2488 bytes --]
Hi!
There's a minor bug in lisp/epg.el file in handling GnuPG's
TRUST_MARGINAL status. The effect is that marginal trust (really:
validity) is never stored to epg-signature structure and never show by
epg-signature-to-string function (and Gnus). Below is a patch with
extended context.
(I can commit it myself. But let's hear an "OK" from persons responsible
for the code.)
From ae4668138b49580a86d7fd962866cca1329fec45 Mon Sep 17 00:00:00 2001
From: Teemu Likonen <tlikonen@iki.fi>
Date: Sun, 25 Jun 2017 20:37:54 +0300
Subject: [PATCH] Fix bug in handling GnuPG's TRUST_MARGINAL status
* lisp/epg.el (epg--status-TRUST_MARGINAL): Change symbol `marginal'
to `good'.
---
lisp/epg.el | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lisp/epg.el b/lisp/epg.el
index 587271b000..1e24b8d116 100644
--- a/lisp/epg.el
+++ b/lisp/epg.el
@@ -1035,31 +1035,31 @@ epg--status-VALIDSIG
(defun epg--status-TRUST_UNDEFINED (context _string)
(let ((signature (car (epg-context-result-for context 'verify))))
(if (and signature
(eq (epg-signature-status signature) 'good))
(setf (epg-signature-validity signature) 'undefined))))
(defun epg--status-TRUST_NEVER (context _string)
(let ((signature (car (epg-context-result-for context 'verify))))
(if (and signature
(eq (epg-signature-status signature) 'good))
(setf (epg-signature-validity signature) 'never))))
(defun epg--status-TRUST_MARGINAL (context _string)
(let ((signature (car (epg-context-result-for context 'verify))))
(if (and signature
- (eq (epg-signature-status signature) 'marginal))
+ (eq (epg-signature-status signature) 'good))
(setf (epg-signature-validity signature) 'marginal))))
(defun epg--status-TRUST_FULLY (context _string)
(let ((signature (car (epg-context-result-for context 'verify))))
(if (and signature
(eq (epg-signature-status signature) 'good))
(setf (epg-signature-validity signature) 'full))))
(defun epg--status-TRUST_ULTIMATE (context _string)
(let ((signature (car (epg-context-result-for context 'verify))))
(if (and signature
(eq (epg-signature-status signature) 'good))
(setf (epg-signature-validity signature) 'ultimate))))
(defun epg--status-NOTATION_NAME (context string)
--
2.11.0
--
/// Teemu Likonen - .-.. <https://keybase.io/tlikonen> //
// PGP: 4E10 55DC 84E9 DFF6 13D7 8557 719D 69D3 2453 9450 ///
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]
next reply other threads:[~2017-06-25 17:50 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-06-25 17:50 Teemu Likonen [this message]
2017-06-26 9:22 ` [PATCH] Fix bug in handling GnuPG's TRUST_MARGINAL status Daiki Ueno
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=87tw34dkht.fsf@mithlond.arda \
--to=tlikonen@iki.fi \
--cc=emacs-devel@gnu.org \
--cc=mwolson@gnu.org \
--cc=ueno@unixuser.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.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.