all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* PGG incompatible with GnuPG >=2.0.10 (patch included)
@ 2009-06-18 14:46 Ulrich Mueller
  2009-06-18 16:13 ` Chong Yidong
  0 siblings, 1 reply; 5+ messages in thread
From: Ulrich Mueller @ 2009-06-18 14:46 UTC (permalink / raw)
  To: emacs-devel

GnuPG has changed the output format for listing of keys with
"gpg --with-colons --list-keys". It doesn't merge the primary user ID
and the primary key any more:

,----[ GnuPG 2.0.9 ]
| tru::1:1245322604:0:3:1:5
| pub:-:1024:17:39EA32FE8222EEEC:2007-03-15:::-:Ulrich Mueller <ulm@kph.uni-mainz.de>::scESC:
| uid:-::::2007-04-14::6C417503DC0A22396443B86A6D17B18D33765C41::Ulrich Mueller <ulm@gentoo.org>:
| sub:-:2048:16:4CC72125BEE5C5AF:2007-03-15::::::e:
`----

,----[ GnuPG 2.0.11 ]
| tru::1:1245322604:0:3:1:5
| pub:-:1024:17:39EA32FE8222EEEC:1173998442:::-:::scESC:
| uid:-::::1176565513::5F7ECDB3196B011228D6B4CE204DC59E1E588022::Ulrich Mueller <ulm@kph.uni-mainz.de>:
| uid:-::::1176565069::6C417503DC0A22396443B86A6D17B18D33765C41::Ulrich Mueller <ulm@gentoo.org>:
| sub:-:2048:16:4CC72125BEE5C5AF:1173998442::::::e:
`----

The format of the "colon listings" is described here:
<http://cvs.gnupg.org/cgi-bin/viewcvs.cgi/*checkout*/tags/gnupg-2.0.11/doc/DETAILS?rev=4943&root=GnuPG>

Unfortunately, PGG expects the user ID in the "pub" line and therefore
fails to parse the new output format. Attached is a patch that fixes
the problem for me.

Ulrich


2009-06-18  Ulrich Mueller  <ulm@kph.uni-mainz.de>

	* pgg-gpg.el (pgg-gpg-lookup-key-owner): Change regexp to make
	parsing of keys work with GnuPG 2.0.10 and later.

--- emacs-orig/lisp/pgg-gpg.el
+++ emacs-lisp/pgg-gpg.el
@@ -189,9 +189,9 @@
   (let ((args (list "--with-colons" "--no-greeting" "--batch"
 		    (if all "--list-secret-keys" "--list-keys")
 		    string))
-	(key-regexp (concat "^\\(sec\\|pub\\)"
+	(key-regexp (concat "^\\(sec\\|pub\\|uid\\)"
 			    ":[^:]*:[^:]*:[^:]*:\\([^:]*\\):[^:]*"
-			    ":[^:]*:[^:]*:[^:]*:\\([^:]*\\):")))
+			    ":[^:]*:[^:]*:[^:]*:\\([^:]+\\):")))
     (with-temp-buffer
       (apply #'call-process pgg-gpg-program nil t nil args)
       (goto-char (point-min))




^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2009-06-19  5:42 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-06-18 14:46 PGG incompatible with GnuPG >=2.0.10 (patch included) Ulrich Mueller
2009-06-18 16:13 ` Chong Yidong
2009-06-18 16:56   ` Ulrich Mueller
2009-06-18 17:51     ` Chong Yidong
2009-06-19  5:42       ` 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.