summaryrefslogtreecommitdiffstats
path: root/agent/learncard.c
diff options
context:
space:
mode:
Diffstat (limited to 'agent/learncard.c')
-rw-r--r--agent/learncard.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/agent/learncard.c b/agent/learncard.c
index 2e491e1..f007b6d 100644
--- a/agent/learncard.c
+++ b/agent/learncard.c
@@ -297,9 +297,12 @@ send_cert_back (ctrl_t ctrl, const char *id, void *assuan_context)
}
/* Perform the learn operation. If ASSUAN_CONTEXT is not NULL and
- SEND is true all new certificates are send back via Assuan. */
+ SEND is true all new certificates are send back via Assuan. If
+ REALLYFORCE is true a private key will be overwritten by a stub
+ key. */
int
-agent_handle_learn (ctrl_t ctrl, int send, void *assuan_context, int force)
+agent_handle_learn (ctrl_t ctrl, int send, void *assuan_context,
+ int force, int reallyforce)
{
int rc;
struct kpinfo_cb_parm_s parm;
@@ -413,8 +416,8 @@ agent_handle_learn (ctrl_t ctrl, int send, void *assuan_context, int force)
char *dispserialno;
agent_card_getattr (ctrl, "$DISPSERIALNO", &dispserialno);
- rc = agent_write_shadow_key (0, grip, serialno, item->id, pubkey,
- force, dispserialno);
+ rc = agent_write_shadow_key (grip, serialno, item->id, pubkey,
+ force, reallyforce, dispserialno);
xfree (dispserialno);
}
xfree (pubkey);