You've already forked opencryptoki
mirror of
https://github.com/opencryptoki/opencryptoki.git
synced 2026-10-25 17:39:16 +03:00
Newer EP11 firmware versions do not allow to get attribute CKA_VALUE_LEN
for private keys, because CKA_VALUE_LEN is not defined for these
key types. This now causes error CKR_ATTRIBUTE_TYPE_INVALID.
Older firmware versions ignored that and did not fail if CKA_VALUE_LEN
was attempted to be retrieved.
Use separate templates for getting the attributes of public, private or
secret keys, and get CKA_VALUE_LEN only for secret keys.
Fixes: 169ab762c2
Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>