From a6142dbdbc5783043deb847dc64998c421860941 Mon Sep 17 00:00:00 2001 From: Werner Koch Date: Thu, 30 Mar 2017 15:18:45 +0200 Subject: gpg: Remove the use of the signature information from a KBX. * g10/keydb.c (keyblock_cache): Remove field SIGSTATUS. (keyblock_cache_clear): Adjust for that removal. (parse_keyblock_image): Remove arg SIGSTATUS. Remove the signature cache setting; this is now done in the parser. (keydb_get_keyblock): Do not set SIGSTATUS. (build_keyblock_image): Remove arg SIGSTATUS and simplify. Change caller. * kbx/keybox-blob.c: Explain that the signature information is not anymore used. (_keybox_create_openpgp_blob): Remove arg SIGSTATUS and change callers. * kbx/keybox-search.c (keybox_get_keyblock): Remove arg R_SIGSTATUS and change callers. * kbx/keybox-update.c (keybox_insert_keyblock): Likewise. -- This thing was too complicated and has been replaced by the new ring trust packet code. Signed-off-by: Werner Koch --- kbx/keybox-blob.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'kbx/keybox-blob.c') diff --git a/kbx/keybox-blob.c b/kbx/keybox-blob.c index f3bdceb3e..82f1cfec3 100644 --- a/kbx/keybox-blob.c +++ b/kbx/keybox-blob.c @@ -101,7 +101,9 @@ - u16 [NSIGS] Number of signatures - u16 Size of signature information (4) - NSIGS times: - - u32 Expiration time of signature with some special values: + - u32 Expiration time of signature with some special values. + Since version 2.1.20 these special valuesare not anymore + used for OpenPGP: - 0x00000000 = not checked - 0x00000001 = missing key - 0x00000002 = bad signature @@ -705,7 +707,6 @@ _keybox_create_openpgp_blob (KEYBOXBLOB *r_blob, keybox_openpgp_info_t info, const unsigned char *image, size_t imagelen, - u32 *sigstatus, int as_ephemeral) { gpg_error_t err; @@ -713,11 +714,6 @@ _keybox_create_openpgp_blob (KEYBOXBLOB *r_blob, *r_blob = NULL; - /* If we have a signature status vector, check that the number of - elements matches the actual number of signatures. */ - if (sigstatus && sigstatus[0] != info->nsigs) - return gpg_error (GPG_ERR_INTERNAL); - blob = xtrycalloc (1, sizeof *blob); if (!blob) return gpg_error_from_syserror (); @@ -756,7 +752,7 @@ _keybox_create_openpgp_blob (KEYBOXBLOB *r_blob, if (err) goto leave; pgp_create_uid_part (blob, info); - pgp_create_sig_part (blob, sigstatus); + pgp_create_sig_part (blob, NULL); init_membuf (&blob->bufbuf, 1024); blob->buf = &blob->bufbuf; -- cgit v1.2.3