mirror of
git://git.gnupg.org/gnupg.git
synced 2024-11-12 21:58:50 +01:00
43b23aa82b
* g10/keydb.h (struct kbnode_struct): Replace unused field RECNO by
new field TAG.
* g10/kbnode.c (alloc_node): Change accordingly.
* g10/import.c (import_one): Add arg r_valid.
(sec_to_pub_keyblock): Set tags.
(resync_sec_with_pub_keyblock): New.
(import_secret_one): Change return code to gpg_error_t. Return an
error code if sec_to_pub_keyblock failed. Resync secret keyblock.
--
When importing an invalid secret key ring for example without key
binding signatures or no UIDs, gpg used to let gpg-agent store the
secret keys anyway. This is clearly a bug because the diagnostics
before claimed that for example the subkeys have been skipped.
Importing the secret key parameters then anyway is surprising in
particular because a gpg -k does not show the key. After importing
the public key the secret keys suddenly showed up.
This changes the behaviour of
GnuPG-bug-id: 4392
to me more consistent but is not a solution to the actual bug.
Caution: The ecc.scm test now fails because two of the sample keys
don't have binding signatures.
Signed-off-by: Werner Koch <wk@gnupg.org>
(cherry picked from commit
|
||
---|---|---|
.. | ||
extrasamples | ||
fake-pinentries | ||
gpgme | ||
gpgscm | ||
gpgsm | ||
migrations | ||
openpgp | ||
pkits | ||
samplekeys | ||
samplemsgs | ||
567064FE6D14A17B2D811ABB407728BC558AA455 | ||
asschk.c | ||
cert_cci_sphinx_ca.pem | ||
cert_cci_test_wzs.pem | ||
cert_cci_test_zs.pem | ||
cert_cci_user02.pem | ||
cert_cci_user03.pem | ||
cert_cci_user04.pem | ||
cert_cci_user06.pem | ||
cert_cci_user07.pem | ||
cert_testpki_testpca.pem | ||
ChangeLog-2011 | ||
crl_testpki_testpca.pem | ||
inittests | ||
key_g10code_pete1.pem | ||
key_g10code_theo1.pem | ||
Makefile.am | ||
run-tests.scm | ||
runtest | ||
skey_g10code_test1.pem | ||
sm-sign+verify | ||
sm-verify | ||
text-1.dsig.pem | ||
text-1.osig-bad.pem | ||
text-1.osig-badusage.pem | ||
text-1.osig.pem | ||
text-1.txt | ||
text-2.osig-bad.pem | ||
text-2.osig.pem | ||
text-2.txt | ||
text-3.txt |