diff options
author | NIIBE Yutaka <[email protected]> | 2018-11-15 04:31:12 +0000 |
---|---|---|
committer | NIIBE Yutaka <[email protected]> | 2018-12-06 08:11:55 +0000 |
commit | d4bc8051525a33b28b1e33daf35d79c1d6cd9c41 (patch) | |
tree | 4d3c22c76a99f08c5de6e73d1d50c5b843c3dcad | |
parent | card: Display if KDF is enabled or not. (diff) | |
download | gnupg-d4bc8051525a33b28b1e33daf35d79c1d6cd9c41.tar.gz gnupg-d4bc8051525a33b28b1e33daf35d79c1d6cd9c41.zip |
scd: Make "learn" report about KDF data object.
* scd/app-openpgp.c (do_learn_status): Report KDF attr.
* g10/card-util.c (current_card_status): Output KDF for with_colons.
--
Backport of master commit: 05d163aebc04db109ec5e004eb04a4b3796f6421
Signed-off-by: NIIBE Yutaka <[email protected]>
-rw-r--r-- | g10/card-util.c | 4 | ||||
-rw-r--r-- | scd/app-openpgp.c | 2 |
2 files changed, 6 insertions, 0 deletions
diff --git a/g10/card-util.c b/g10/card-util.c index 45ae3ddb4..13c244518 100644 --- a/g10/card-util.c +++ b/g10/card-util.c @@ -509,6 +509,10 @@ current_card_status (ctrl_t ctrl, estream_t fp, es_fprintf (fp, "pinretry:%d:%d:%d:\n", info.chvretry[0], info.chvretry[1], info.chvretry[2]); es_fprintf (fp, "sigcount:%lu:::\n", info.sig_counter); + if (info.extcap.kdf) + { + es_fprintf (fp, "kdf:%s:\n", info.kdf_do_enabled ? "on" : "off"); + } for (i=0; i < 4; i++) { diff --git a/scd/app-openpgp.c b/scd/app-openpgp.c index 911bd8856..fa23fbef2 100644 --- a/scd/app-openpgp.c +++ b/scd/app-openpgp.c @@ -1827,6 +1827,8 @@ do_learn_status (app_t app, ctrl_t ctrl, unsigned int flags) do_getattr (app, ctrl, "CA-FPR"); do_getattr (app, ctrl, "CHV-STATUS"); do_getattr (app, ctrl, "SIG-COUNTER"); + if (app->app_local->extcap.kdf_do) + do_getattr (app, ctrl, "KDF"); if (app->app_local->extcap.private_dos) { do_getattr (app, ctrl, "PRIVATE-DO-1"); |