* [PATCH] Fix bug in handling GnuPG's TRUST_MARGINAL status
@ 2017-06-25 17:50 Teemu Likonen
2017-06-26 9:22 ` Daiki Ueno
0 siblings, 1 reply; 2+ messages in thread
From: Teemu Likonen @ 2017-06-25 17:50 UTC (permalink / raw)
To: emacs-devel; +Cc: Daiki Ueno, Michael Olson
[-- 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 --]
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] Fix bug in handling GnuPG's TRUST_MARGINAL status
2017-06-25 17:50 [PATCH] Fix bug in handling GnuPG's TRUST_MARGINAL status Teemu Likonen
@ 2017-06-26 9:22 ` Daiki Ueno
0 siblings, 0 replies; 2+ messages in thread
From: Daiki Ueno @ 2017-06-26 9:22 UTC (permalink / raw)
To: Teemu Likonen; +Cc: Michael Olson, emacs-devel
Teemu Likonen <tlikonen@iki.fi> writes:
> (if (and signature
> - (eq (epg-signature-status signature) 'marginal))
> + (eq (epg-signature-status signature) 'good))
> (setf (epg-signature-validity signature) 'marginal))))
Good catch, thank you.
Regards,
--
Daiki Ueno
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-06-26 9:22 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-06-25 17:50 [PATCH] Fix bug in handling GnuPG's TRUST_MARGINAL status Teemu Likonen
2017-06-26 9:22 ` Daiki Ueno
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.