pkcs11-tool: honour unsupported signature mechs

This commit is contained in:
Frank Morgner 2015-04-10 07:42:00 +02:00 committed by Viktor Tarasov
parent 643080baf9
commit 6e84ee0ba7
1 changed files with 3 additions and 0 deletions

View File

@ -3494,6 +3494,9 @@ static int test_signature(CK_SESSION_HANDLE sess)
ck_mech.mechanism = firstMechType;
rv = p11->C_SignInit(sess, &ck_mech, privKeyObject);
/* mechanism not implemented, don't test */
if (rv == CKR_MECHANISM_INVALID)
return errors;
if (rv != CKR_OK)
p11_fatal("C_SignInit", rv);