* epg-package-info.el.in (epg-bug-report-address): New constant.
[elisp/epg.git] / epg.el
diff --git a/epg.el b/epg.el
index 160f911..ea0d4a1 100644 (file)
--- a/epg.el
+++ b/epg.el
@@ -330,7 +330,7 @@ This function is for internal use only."
 (defun epg-context-set-passphrase-callback (context passphrase-callback
                                                    &optional handback)
   "Set the function used to query passphrase.
-If optional argument HANDBACK is specified, it is passed to CALLBACK."
+If optional argument HANDBACK is specified, it is passed to PASSPHRASE-CALLBACK."
   (unless (eq (car-safe context) 'epg-context)
     (signal 'wrong-type-argument (list 'epg-context-p context)))
   (aset (cdr context) 7 (if handback
@@ -340,7 +340,7 @@ If optional argument HANDBACK is specified, it is passed to CALLBACK."
 (defun epg-context-set-progress-callback (context progress-callback
                                                  &optional handback)
   "Set the function which handles progress update.
-If optional argument HANDBACK is specified, it is passed to CALLBACK."
+If optional argument HANDBACK is specified, it is passed to PROGRESS-CALLBACK."
   (unless (eq (car-safe context) 'epg-context)
     (signal 'wrong-type-argument (list 'epg-context-p context)))
   (aset (cdr context) 8 (if handback
@@ -1291,9 +1291,15 @@ This function is for internal use only."
     (y-or-n-p (if entry (cdr entry) (concat string "? ")))))
 
 (defun epg--prompt-GET_BOOL-untrusted_key.override (context string)
-  (y-or-n-p (if (equal (car epg-last-status) "USERID_HINT")
-               (format "Untrusted key %s.  Use anyway? "
-                       (cdr epg-last-status))
+  (y-or-n-p (if (and (equal (car epg-last-status) "USERID_HINT")
+                    (string-match "\\`\\([^ ]+\\) \\(.*\\)"
+                                  (cdr epg-last-status)))
+               (let* ((key-id (match-string 1 (cdr epg-last-status)))
+                      (user-id (match-string 2 (cdr epg-last-status)))
+                      (entry (assoc key-id epg-user-id-alist)))
+                 (if entry
+                     (setq user-id (cdr entry)))
+                 (format "Untrusted key %s %s.  Use anyway? " key-id user-id))
              "Use untrusted key anyway? ")))
 
 (defun epg--status-GET_BOOL (context string)
@@ -2471,7 +2477,7 @@ If you are unsure, use synchronous version of this function
 
 ;;;###autoload
 (defun epg-start-sign-keys (context keys &optional local)
-  "Initiate an sign keys operation.
+  "Initiate a sign keys operation.
 
 If you use this function, you will need to wait for the completion of
 `epg-gpg-program' by using `epg-wait-for-completion' and call