Update object in the session after key creation (if object already exists).

This commit is contained in:
Alessio Di Mauro
2015-08-11 16:28:59 +02:00
parent bf56cd8f30
commit 2a6acc5259
5 changed files with 72 additions and 8 deletions
-2
View File
@@ -78,8 +78,6 @@ static CK_RV COMMON_token_generate_key(ykpiv_state *state, CK_BBOOL rsa, CK_BYTE
*certptr++ = 0xfe; /* LRC */
*certptr++ = 0;
dump_hex(data, (size_t)(certptr - data), stderr, CK_TRUE);
// Store the certificate into the token
if (ykpiv_save_object(state, key_to_object_id(key), data, (size_t)(certptr - data)) != YKPIV_OK)
return CKR_DEVICE_ERROR;