| /optee_os/core/lib/libtomcrypt/src/headers/ |
| H A D | tomcrypt_pk.h | 242 } ecc_key; typedef 260 int ecc_get_size(const ecc_key *key); 263 int ecc_set_curve(const ltc_ecc_curve *cu, ecc_key *key); 264 int ecc_generate_key(prng_state *prng, int wprng, ecc_key *key); 265 int ecc_set_key(const unsigned char *in, unsigned long inlen, int type, ecc_key *key); 266 int ecc_get_key(unsigned char *out, unsigned long *outlen, int type, const ecc_key *key); 267 int ecc_get_oid_str(char *out, unsigned long *outlen, const ecc_key *key); 269 int ecc_make_key(prng_state *prng, int wprng, int keysize, ecc_key *key); 270 int ecc_make_key_ex(prng_state *prng, int wprng, ecc_key *key, const ltc_ecc_curve *cu); 271 void ecc_free(ecc_key *key); [all …]
|
| H A D | tomcrypt_private.h | 308 …d *a, void *b, void *prime, void *order, void *gx, void *gy, unsigned long cofactor, ecc_key *key); 309 int ecc_copy_curve(const ecc_key *srckey, ecc_key *key); 310 int ecc_set_curve_by_size(int size, ecc_key *key); 311 int ecc_import_subject_public_key_info(const unsigned char *in, unsigned long inlen, ecc_key *key); 314 int ecc_ssh_ecdsa_encode_name(char *buffer, unsigned long *buflen, const ecc_key *key); 326 int ltc_ecc_verify_key(const ecc_key *key);
|
| /optee_os/core/lib/libtomcrypt/ |
| H A D | sm2-kep.c | 26 size_t idlen, const ecc_key *key) in sm2_kep_compute_Z() 105 size_t ZAZB_len, ecc_key *initiator_eph_key, in sm2_kep_compute_S() 106 ecc_key *responder_eph_key) in sm2_kep_compute_S() 203 static TEE_Result sm2_kep_derive(ecc_key *my_key, ecc_key *my_eph_key, in sm2_kep_derive() 204 ecc_key *peer_key, ecc_key *peer_eph_key, in sm2_kep_derive() 213 ecc_key *initiator_eph_key = p->is_initiator ? my_eph_key : in sm2_kep_derive() 215 ecc_key *responder_eph_key = p->is_initiator ? peer_eph_key : in sm2_kep_derive() 217 ecc_key *initiator_key = p->is_initiator ? my_key : peer_key; in sm2_kep_derive() 218 ecc_key *responder_key = p->is_initiator ? peer_key : my_key; in sm2_kep_derive() 410 ecc_key ltc_my_key = { }; in crypto_acipher_sm2_kep_derive() [all …]
|
| H A D | ecc.c | 113 static TEE_Result ecc_set_curve_from_name(ecc_key *ltc_key, in ecc_set_curve_from_name() 134 ecc_key ltc_tmp_key; in _ltc_ecc_generate_keypair() 188 TEE_Result ecc_populate_ltc_private_key(ecc_key *ltc_key, in ecc_populate_ltc_private_key() 218 TEE_Result ecc_populate_ltc_public_key(ecc_key *ltc_key, in ecc_populate_ltc_public_key() 252 ecc_key ltc_key = { }; in _ltc_ecc_sign() 292 ecc_key ltc_key = { }; in _ltc_ecc_verify() 322 ecc_key ltc_private_key = { }; in _ltc_ecc_shared_secret() 323 ecc_key ltc_public_key = { }; in _ltc_ecc_shared_secret()
|
| H A D | acipher_helpers.h | 39 TEE_Result ecc_populate_ltc_private_key(ecc_key *ltc_key, 42 TEE_Result ecc_populate_ltc_public_key(ecc_key *ltc_key,
|
| /optee_os/core/lib/libtomcrypt/src/pk/ecc/ |
| H A D | ecc_make_key.c | 21 int ecc_make_key(prng_state *prng, int wprng, int keysize, ecc_key *key) in ecc_make_key() 30 int ecc_make_key_ex(prng_state *prng, int wprng, ecc_key *key, const ltc_ecc_curve *cu) in ecc_make_key_ex() 38 int ecc_generate_key(prng_state *prng, int wprng, ecc_key *key) in ecc_generate_key()
|
| H A D | ecc_ansi_x963_import.c | 18 int ecc_ansi_x963_import(const unsigned char *in, unsigned long inlen, ecc_key *key) in ecc_ansi_x963_import() 23 int ecc_ansi_x963_import_ex(const unsigned char *in, unsigned long inlen, ecc_key *key, const ltc_e… in ecc_ansi_x963_import_ex()
|
| H A D | ecc_import_x509.c | 7 static int s_ecc_import_x509_with_oid(const unsigned char *in, unsigned long inlen, ecc_key *key) in s_ecc_import_x509_with_oid() 33 static int s_ecc_import_x509_with_curve(const unsigned char *in, unsigned long inlen, ecc_key *key) in s_ecc_import_x509_with_curve() 86 int ecc_import_subject_public_key_info(const unsigned char *in, unsigned long inlen, ecc_key *key) in ecc_import_subject_public_key_info() 107 int ecc_import_x509(const unsigned char *in, unsigned long inlen, ecc_key *key) in ecc_import_x509()
|
| H A D | ecc_shared_secret.c | 21 int ecc_shared_secret(const ecc_key *private_key, const ecc_key *public_key, in ecc_shared_secret()
|
| H A D | ecc_set_curve_internal.c | 15 static void s_ecc_oid_lookup(ecc_key *key) in s_ecc_oid_lookup() 39 int ecc_copy_curve(const ecc_key *srckey, ecc_key *key) in ecc_copy_curve() 79 …id *a, void *b, void *prime, void *order, void *gx, void *gy, unsigned long cofactor, ecc_key *key) in ecc_set_curve_from_mpis()
|
| H A D | ecc_import.c | 20 int ecc_import(const unsigned char *in, unsigned long inlen, ecc_key *key) in ecc_import() 33 int ecc_import_ex(const unsigned char *in, unsigned long inlen, ecc_key *key, const ltc_ecc_curve *… in ecc_import_ex()
|
| H A D | ecc_import_openssl.c | 8 static int s_ecc_import_private_with_oid(const unsigned char *in, unsigned long inlen, ecc_key *key) in s_ecc_import_private_with_oid() 42 static int s_ecc_import_private_with_curve(const unsigned char *in, unsigned long inlen, ecc_key *k… in s_ecc_import_private_with_curve() 102 int ecc_import_openssl(const unsigned char *in, unsigned long inlen, ecc_key *key) in ecc_import_openssl()
|
| H A D | ecc_get_size.c | 18 int ecc_get_size(const ecc_key *key) in ecc_get_size()
|
| H A D | ecc_ansi_x963_export.c | 19 int ecc_ansi_x963_export(const ecc_key *key, unsigned char *out, unsigned long *outlen) in ecc_ansi_x963_export()
|
| H A D | ecc_get_oid_str.c | 15 int ecc_get_oid_str(char *out, unsigned long *outlen, const ecc_key *key) in ecc_get_oid_str()
|
| H A D | ecc_encrypt_key.c | 28 const ecc_key *key) in ecc_encrypt_key() 31 ecc_key pubkey; in ecc_encrypt_key()
|
| H A D | ecc_decrypt_key.c | 24 const ecc_key *key) in ecc_decrypt_key() 30 ecc_key pubkey; in ecc_decrypt_key()
|
| H A D | ecc_set_curve.c | 8 int ecc_set_curve(const ltc_ecc_curve *cu, ecc_key *key) in ecc_set_curve() 44 int ecc_set_curve_by_size(int size, ecc_key *key) in ecc_set_curve_by_size()
|
| H A D | ecc_free.c | 17 void ecc_free(ecc_key *key) in ecc_free()
|
| H A D | ecc_ssh_ecdsa_encode_name.c | 20 int ecc_ssh_ecdsa_encode_name(char *buffer, unsigned long *buflen, const ecc_key *key) in ecc_ssh_ecdsa_encode_name()
|
| H A D | ecc_export.c | 21 int ecc_export(unsigned char *out, unsigned long *outlen, int type, const ecc_key *key) in ecc_export()
|
| H A D | ecc_get_key.c | 16 int ecc_get_key(unsigned char *out, unsigned long *outlen, int type, const ecc_key *key) in ecc_get_key()
|
| H A D | ltc_ecc_verify_key.c | 16 int ltc_ecc_verify_key(const ecc_key *key) in ltc_ecc_verify_key()
|
| H A D | ecc_set_key.c | 8 int ecc_set_key(const unsigned char *in, unsigned long inlen, int type, ecc_key *key) in ecc_set_key()
|
| /optee_os/core/drivers/crypto/hisilicon/ |
| H A D | hpre_ecc.c | 965 struct ecc_keypair *ecc_key = NULL; in hpre_ecc_do_shared_secret() local 974 ecc_key = sdata->key_priv; in hpre_ecc_do_shared_secret() 977 curve = get_curve_from_list(ecc_key->curve); in hpre_ecc_do_shared_secret() 979 EMSG("Fail to get valid curve, id %"PRIu32, ecc_key->curve); in hpre_ecc_do_shared_secret() 988 ret = hpre_ecc_request_init(curve, &msg, ecc_key->d, pubkey); in hpre_ecc_do_shared_secret() 1021 struct ecc_keypair *ecc_key = sdata->key; in hpre_ecc_sign_params_fill() local 1036 crypto_bignum_bn2bin(ecc_key->d, d); in hpre_ecc_sign_params_fill() 1037 ecc_sign->d_bytes = crypto_bignum_num_bytes(ecc_key->d); in hpre_ecc_sign_params_fill() 1172 struct ecc_keypair *ecc_key = NULL; in hpre_ecc_sign() local 1181 ecc_key = sdata->key; in hpre_ecc_sign() [all …]
|