gpg: Fix printing of pubkey algo in --verbose signature verify.
authorWerner Koch <wk@gnupg.org>
Thu, 1 Sep 2016 14:00:06 +0000 (16:00 +0200)
committerWerner Koch <wk@gnupg.org>
Thu, 1 Sep 2016 14:39:41 +0000 (16:39 +0200)
commit37e3c897252babc203447be9d2f286a4507875ad
tree0ad165e090729c083de46cc973115e6ef9a3ea0e
parent44690befad49589e5083b4998a1a79eebf297d01
gpg: Fix printing of pubkey algo in --verbose signature verify.

* g10/sig-check.c (check_signature2): Replace arg PK by R_PK and
change the semantics.  Also clear the other R_ args on function entry,
use gpg_error() and change retturn type to gpg_error_t.
* g10/mainproc.c (do_check_sig): Add arg R_PK.
(list_node): Pass NULL for new arg.
(check_sig_and_print): Rework to make use of the returned PK.
--

The output

gpg: textmode signature, digest algorithm SHA256, key algorithm rsa2048

showed the pubkey algo of the primary key which was surprising.
Changed to print the algo of the subkey used for verification.

Signed-off-by: Werner Koch <wk@gnupg.org>
g10/mainproc.c
g10/packet.h
g10/sig-check.c