[Cryptech-Commits] [sw/pkcs11] 01/02: Track API changes in sw/libhal pkcs8 branch.

git at cryptech.is git at cryptech.is
Tue Apr 11 04:31:40 UTC 2017


This is an automated email from the git hooks/post-receive script.

sra at hactrn.net pushed a commit to branch pkcs8
in repository sw/pkcs11.

commit af9cedc2515a6851716bd2ccc1857937d7f5c495
Author: Rob Austein <sra at hactrn.net>
AuthorDate: Sat Apr 8 20:01:56 2017 -0400

    Track API changes in sw/libhal pkcs8 branch.
---
 pkcs11.c | 19 ++++++-------------
 1 file changed, 6 insertions(+), 13 deletions(-)

diff --git a/pkcs11.c b/pkcs11.c
index 821b037..2350012 100644
--- a/pkcs11.c
+++ b/pkcs11.c
@@ -1213,8 +1213,7 @@ static int p11_object_create_rsa_public_key(const p11_session_t * const session,
     ok = (hal_check(hal_rsa_public_key_to_der(key, der, NULL, sizeof(der))) &&
           hal_check(hal_rpc_pkey_load(p11_session_hal_client(session),
                                       p11_session_hal_session(session),
-                                      &pkey, HAL_KEY_TYPE_RSA_PUBLIC, HAL_CURVE_NONE,
-                                      &uuid, der, sizeof(der), flags)));
+                                      &pkey, &uuid, der, sizeof(der), flags)));
   }
 
   if (ok)
@@ -1275,8 +1274,7 @@ static int p11_object_create_ec_public_key(const p11_session_t * const session,
     ok = (hal_check(hal_ecdsa_public_key_to_der(key, der, NULL, sizeof(der))) &&
           hal_check(hal_rpc_pkey_load(p11_session_hal_client(session),
                                       p11_session_hal_session(session),
-                                      &pkey, HAL_KEY_TYPE_EC_PUBLIC, curve,
-                                      &uuid, der, sizeof(der), flags)));
+                                      &pkey, &uuid, der, sizeof(der), flags)));
   }
 
   if (ok)
@@ -1355,9 +1353,7 @@ static int p11_object_create_rsa_private_key(const p11_session_t * const session
     ok = (hal_check(hal_rsa_private_key_to_der(key, der, NULL, sizeof(der))) &&
           hal_check(hal_rpc_pkey_load(p11_session_hal_client(session),
                                       p11_session_hal_session(session),
-                                      &pkey, HAL_KEY_TYPE_RSA_PRIVATE,
-                                      HAL_CURVE_NONE, &uuid,
-                                      der, sizeof(der), flags)));
+                                      &pkey, &uuid, der, sizeof(der), flags)));
     memset(der, 0, sizeof(der));
   }
 
@@ -1429,8 +1425,7 @@ static int p11_object_create_ec_private_key(const p11_session_t * const session,
     ok = (hal_check(hal_ecdsa_private_key_to_der(key, der, NULL, sizeof(der))) &&
           hal_check(hal_rpc_pkey_load(p11_session_hal_client(session),
                                       p11_session_hal_session(session),
-                                      &pkey, HAL_KEY_TYPE_EC_PRIVATE, curve,
-                                      &uuid, der, sizeof(der), flags)));
+                                      &pkey, &uuid, der, sizeof(der), flags)));
     memset(der, 0, sizeof(der));
   }
 
@@ -1963,8 +1958,7 @@ static CK_RV generate_keypair_rsa_pkcs(p11_session_t *session,
         !hal_check(hal_rsa_public_key_from_der(&key, keybuf, sizeof(keybuf), der, der_len))     ||
         !hal_check(hal_rpc_pkey_load(p11_session_hal_client(session),
                                      p11_session_hal_session(session),
-                                     &public_pkey, HAL_KEY_TYPE_RSA_PUBLIC, HAL_CURVE_NONE,
-                                     &public_uuid, der, der_len, public_flags))                 ||
+                                     &public_pkey, &public_uuid, der, der_len, public_flags))   ||
         !hal_check(hal_rsa_key_get_modulus(key, NULL, &modulus_len, 0)))
       lose(CKR_FUNCTION_FAILED);
 
@@ -2064,8 +2058,7 @@ static CK_RV generate_keypair_ec(p11_session_t *session,
         !hal_check(hal_ecdsa_public_key_from_der(&key, keybuf, sizeof(keybuf), der, der_len))   ||
         !hal_check(hal_rpc_pkey_load(p11_session_hal_client(session),
                                      p11_session_hal_session(session),
-                                     &public_pkey, HAL_KEY_TYPE_EC_PUBLIC, curve,
-                                     &public_uuid, der, der_len, public_flags)))
+                                     &public_pkey, &public_uuid, der, der_len, public_flags)))
       lose(CKR_FUNCTION_FAILED);
 
     uint8_t point[hal_ecdsa_key_to_ecpoint_len(key)];



More information about the Commits mailing list