From f3f9f9b2844c35f7942ee904d5222523615cdad4 Mon Sep 17 00:00:00 2001 From: Werner Koch Date: Fri, 12 Dec 2014 12:35:45 +0100 Subject: gpg: Let --card--status create a shadow key (card key stub). * agent/command.c (cmd_learn): Add option --sendinfo. * agent/learncard.c (agent_handle_learn): Add arg "send" andsend certifciate only if that is set. * g10/call-agent.c (agent_scd_learn): Use --sendinfo. Make INFO optional. (agent_learn): Remove. * g10/keygen.c (gen_card_key): Replace agent_learn by agent_scd_learn. -- The requirement of using --card-status on the first use of card on a new box is a bit annoying but the alternative of always checking whether a card is available before a decryption starts does not sound promising either. Signed-off-by: Werner Koch --- g10/keygen.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'g10/keygen.c') diff --git a/g10/keygen.c b/g10/keygen.c index 89cc255bc..c25caadf2 100644 --- a/g10/keygen.c +++ b/g10/keygen.c @@ -4447,7 +4447,7 @@ gen_card_key (int algo, int keyno, int is_primary, kbnode_t pub_root, /* Send the learn command so that the agent creates a shadow key for card key. We need to do that now so that we are able to create the self-signatures. */ - err = agent_learn (); + err = agent_scd_learn (NULL); if (err) { /* Oops: Card removed during generation. */ -- cgit v1.2.3