g10: Support key attribute change at --card-edit/generate.
authorNIIBE Yutaka <gniibe@fsij.org>
Thu, 29 Mar 2018 02:56:02 +0000 (11:56 +0900)
committerNIIBE Yutaka <gniibe@fsij.org>
Thu, 29 Mar 2018 02:56:02 +0000 (11:56 +0900)
commita1515b3bbc10a210040dda3b482bcdb933fa8d7c
treeb985f1f5090ea4f1edaf0d5366be97a61c665fd9
parent02d7bb819ff44cc90212568dd6ce24ae1dc5d17f
g10: Support key attribute change at --card-edit/generate.

* g10/card-util.c (ask_card_rsa_keysize): Drop support for magic
number 25519 for ed25519/cv25519.  Rename from ask_card_keyattr.
(ask_card_keyattr): Support ECC, as well as RSA.
(do_change_keyattr): Support ECC dropping magical number 25519.
* g10/keygen.c (ask_curve): Allow call from outside, adding last arg
of CURRENT.
(generate_keypair): Follow the change of ask_curve.
(generate_subkeypair): Likewise.

--

GnuPG-bug-id: 3781
Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
g10/card-util.c
g10/keygen.c
g10/main.h