From a4427401d8bcb95d07ee0d48b8dce8d1ad70394d Mon Sep 17 00:00:00 2001 From: Miloslav Trmač Date: Tue, 30 Nov 2010 19:36:37 +0100 Subject: Use subjectPublicKeyInfo for public keys in DER form Also avoid subjectPublicKeyInfo encoding/decoding when handling RSA key details. --- include/ncrypto/ncrypto.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/ncrypto/ncrypto.h b/include/ncrypto/ncrypto.h index d9508bf..3938b45 100644 --- a/include/ncrypto/ncrypto.h +++ b/include/ncrypto/ncrypto.h @@ -71,8 +71,9 @@ CK_RV ncr_symm_key_destroy (struct ncr_symm_key *key); struct ncr_public_key; struct ncr_private_key; -CK_RV ncr_public_key_create (struct ncr_public_key **key, CK_KEY_TYPE type, - const void *der, size_t der_size); +/* The X.509v3 subjectPublicKeyInfo structure is used for public keys. */ +CK_RV ncr_public_key_create (struct ncr_public_key **key, const void *der, + size_t der_size); CK_RV ncr_public_key_export (struct ncr_public_key *key, void *dest, size_t *dest_size_ptr); CK_RV ncr_public_key_destroy (struct ncr_public_key *key); -- cgit