Lines Matching refs:keydata
35 if (data->keydata == NULL) { in evp_keymgmt_util_try_import()
36 if ((data->keydata = evp_keymgmt_newdata(data->keymgmt)) == NULL) { in evp_keymgmt_util_try_import()
50 if (evp_keymgmt_import(data->keymgmt, data->keydata, data->selection, in evp_keymgmt_util_try_import()
54 evp_keymgmt_freedata(data->keymgmt, data->keydata); in evp_keymgmt_util_try_import()
55 data->keydata = NULL; in evp_keymgmt_util_try_import()
61 void *keydata) in evp_keymgmt_util_assign_pkey() argument
63 if (pkey == NULL || keymgmt == NULL || keydata == NULL in evp_keymgmt_util_assign_pkey()
68 pkey->keydata = keydata; in evp_keymgmt_util_assign_pkey()
73 EVP_PKEY *evp_keymgmt_util_make_pkey(EVP_KEYMGMT *keymgmt, void *keydata) in evp_keymgmt_util_make_pkey() argument
78 || keydata == NULL in evp_keymgmt_util_make_pkey()
80 || !evp_keymgmt_util_assign_pkey(pkey, keymgmt, keydata)) { in evp_keymgmt_util_make_pkey()
92 return evp_keymgmt_export(pk->keymgmt, pk->keydata, selection, in evp_keymgmt_util_export()
107 if (pk->keydata == NULL) in evp_keymgmt_util_export_to_provider()
120 return pk->keydata; in evp_keymgmt_util_export_to_provider()
133 void *ret = op->keydata; in evp_keymgmt_util_export_to_provider()
159 import_data.keydata = NULL; /* evp_keymgmt_util_try_import will create it */ in evp_keymgmt_util_export_to_provider()
173 evp_keymgmt_freedata(keymgmt, import_data.keydata); in evp_keymgmt_util_export_to_provider()
178 if (op != NULL && op->keydata != NULL) { in evp_keymgmt_util_export_to_provider()
179 void *ret = op->keydata; in evp_keymgmt_util_export_to_provider()
187 evp_keymgmt_freedata(keymgmt, import_data.keydata); in evp_keymgmt_util_export_to_provider()
200 if (!evp_keymgmt_util_cache_keydata(pk, keymgmt, import_data.keydata, in evp_keymgmt_util_export_to_provider()
203 evp_keymgmt_freedata(keymgmt, import_data.keydata); in evp_keymgmt_util_export_to_provider()
212 return import_data.keydata; in evp_keymgmt_util_export_to_provider()
217 evp_keymgmt_freedata(e->keymgmt, e->keydata); in op_cache_free()
257 void *keydata, int selection) in evp_keymgmt_util_cache_keydata() argument
261 if (keydata != NULL) { in evp_keymgmt_util_cache_keydata()
271 p->keydata = keydata; in evp_keymgmt_util_cache_keydata()
296 if (pk->keydata != NULL) { in evp_keymgmt_util_cache_keyinfo()
307 if (evp_keymgmt_get_params(pk->keymgmt, pk->keydata, params)) { in evp_keymgmt_util_cache_keyinfo()
318 void *keydata = NULL; in evp_keymgmt_util_fromdata() local
320 if ((keydata = evp_keymgmt_newdata(keymgmt)) == NULL in evp_keymgmt_util_fromdata()
321 || !evp_keymgmt_import(keymgmt, keydata, selection, params) in evp_keymgmt_util_fromdata()
322 || !evp_keymgmt_util_assign_pkey(target, keymgmt, keydata)) { in evp_keymgmt_util_fromdata()
323 evp_keymgmt_freedata(keymgmt, keydata); in evp_keymgmt_util_fromdata()
324 keydata = NULL; in evp_keymgmt_util_fromdata()
326 return keydata; in evp_keymgmt_util_fromdata()
335 return evp_keymgmt_has(pk->keymgmt, pk->keydata, selection); in evp_keymgmt_util_has()
363 keydata1 = pk1->keydata; in evp_keymgmt_util_match()
365 keydata2 = pk2->keydata; in evp_keymgmt_util_match()
449 void *to_keydata = to->keydata, *alloc_keydata = NULL; in evp_keymgmt_util_copy()
452 if (from == NULL || from->keydata == NULL) in evp_keymgmt_util_copy()
466 from->keydata, in evp_keymgmt_util_copy()
474 import_data.keydata = to_keydata; in evp_keymgmt_util_copy()
487 to_keydata = alloc_keydata = import_data.keydata; in evp_keymgmt_util_copy()
507 to->keydata = to_keydata; in evp_keymgmt_util_copy()
516 void *keydata = NULL; in evp_keymgmt_util_gen() local
518 if ((keydata = evp_keymgmt_gen(keymgmt, genctx, cb, cbarg)) == NULL in evp_keymgmt_util_gen()
519 || !evp_keymgmt_util_assign_pkey(target, keymgmt, keydata)) { in evp_keymgmt_util_gen()
520 evp_keymgmt_freedata(keymgmt, keydata); in evp_keymgmt_util_gen()
521 keydata = NULL; in evp_keymgmt_util_gen()
524 return keydata; in evp_keymgmt_util_gen()
534 void *keydata, in evp_keymgmt_util_get_deflt_digest_name() argument
552 if (!evp_keymgmt_get_params(keymgmt, keydata, params)) in evp_keymgmt_util_get_deflt_digest_name()