/third_party/node/deps/openssl/openssl/crypto/ec/ |
H A D | ecdh_ossl.c | 29 const EC_POINT *pub_key, const EC_KEY *ecdh) in ossl_ecdh_compute_key() 31 if (ecdh->group->meth->ecdh_compute_key == NULL) { in ossl_ecdh_compute_key() 36 return ecdh->group->meth->ecdh_compute_key(psec, pseclen, pub_key, ecdh); in ossl_ecdh_compute_key() 50 const EC_POINT *pub_key, const EC_KEY *ecdh) in ossl_ecdh_simple_compute_key() 61 if ((ctx = BN_CTX_new_ex(ecdh->libctx)) == NULL) in ossl_ecdh_simple_compute_key() 70 priv_key = EC_KEY_get0_private_key(ecdh); in ossl_ecdh_simple_compute_key() 76 group = EC_KEY_get0_group(ecdh); in ossl_ecdh_simple_compute_key() 82 if (EC_KEY_get_flags(ecdh) & EC_FLAG_COFACTOR_ECDH) { in ossl_ecdh_simple_compute_key() 28 ossl_ecdh_compute_key(unsigned char **psec, size_t *pseclen, const EC_POINT *pub_key, const EC_KEY *ecdh) ossl_ecdh_compute_key() argument 49 ossl_ecdh_simple_compute_key(unsigned char **pout, size_t *poutlen, const EC_POINT *pub_key, const EC_KEY *ecdh) ossl_ecdh_simple_compute_key() argument
|
/third_party/openssl/crypto/ec/ |
H A D | ecdh_ossl.c | 29 const EC_POINT *pub_key, const EC_KEY *ecdh) in ossl_ecdh_compute_key() 31 if (ecdh->group->meth->ecdh_compute_key == NULL) { in ossl_ecdh_compute_key() 36 return ecdh->group->meth->ecdh_compute_key(psec, pseclen, pub_key, ecdh); in ossl_ecdh_compute_key() 50 const EC_POINT *pub_key, const EC_KEY *ecdh) in ossl_ecdh_simple_compute_key() 61 if ((ctx = BN_CTX_new_ex(ecdh->libctx)) == NULL) in ossl_ecdh_simple_compute_key() 70 priv_key = EC_KEY_get0_private_key(ecdh); in ossl_ecdh_simple_compute_key() 76 group = EC_KEY_get0_group(ecdh); in ossl_ecdh_simple_compute_key() 82 if (EC_KEY_get_flags(ecdh) & EC_FLAG_COFACTOR_ECDH) { in ossl_ecdh_simple_compute_key() 28 ossl_ecdh_compute_key(unsigned char **psec, size_t *pseclen, const EC_POINT *pub_key, const EC_KEY *ecdh) ossl_ecdh_compute_key() argument 49 ossl_ecdh_simple_compute_key(unsigned char **pout, size_t *poutlen, const EC_POINT *pub_key, const EC_KEY *ecdh) ossl_ecdh_simple_compute_key() argument
|
/kernel/linux/linux-5.10/include/crypto/ |
H A D | ecdh.h | 31 * struct ecdh - define an ECDH private key 37 struct ecdh { struct 53 unsigned int crypto_ecdh_key_len(const struct ecdh *params); 68 int crypto_ecdh_encode_key(char *buf, unsigned int len, const struct ecdh *p); 82 int crypto_ecdh_decode_key(const char *buf, unsigned int len, struct ecdh *p);
|
/kernel/linux/linux-6.6/include/crypto/ |
H A D | ecdh.h | 31 * struct ecdh - define an ECDH private key 36 struct ecdh { struct 51 unsigned int crypto_ecdh_key_len(const struct ecdh *params); 66 int crypto_ecdh_encode_key(char *buf, unsigned int len, const struct ecdh *p); 80 int crypto_ecdh_decode_key(const char *buf, unsigned int len, struct ecdh *p);
|
/third_party/node/src/crypto/ |
H A D | crypto_ec.cc | 15 #include <openssl/ecdh.h> 160 ECDH* ecdh; in GenerateKeys() local 161 ASSIGN_OR_RETURN_UNWRAP(&ecdh, args.Holder()); in GenerateKeys() 163 if (!EC_KEY_generate_key(ecdh->key_.get())) in GenerateKeys() 201 ECDH* ecdh; in ComputeSecret() local 202 ASSIGN_OR_RETURN_UNWRAP(&ecdh, args.Holder()); in ComputeSecret() 206 if (!ecdh->IsKeyPairValid()) in ComputeSecret() 211 ecdh->group_, in ComputeSecret() 224 int field_size = EC_GROUP_get_degree(ecdh->group_); in ComputeSecret() 230 bs->Data(), bs->ByteLength(), pub.get(), ecdh in ComputeSecret() 245 ECDH* ecdh; GetPublicKey() local 268 ECDH* ecdh; GetPrivateKey() local 294 ECDH* ecdh; SetPrivateKey() local 350 ECDH* ecdh; SetPublicKey() local [all...] |
/kernel/linux/linux-5.10/crypto/ |
H A D | ecdh_helper.c | 10 #include <crypto/ecdh.h> 27 unsigned int crypto_ecdh_key_len(const struct ecdh *params) in crypto_ecdh_key_len() 34 const struct ecdh *params) in crypto_ecdh_encode_key() 58 struct ecdh *params) in crypto_ecdh_decode_key()
|
H A D | ecdh.c | 11 #include <crypto/ecdh.h> 39 struct ecdh params; in ecdh_set_secret() 143 static struct kpp_alg ecdh = { variable 149 .cra_name = "ecdh", 150 .cra_driver_name = "ecdh-generic", 159 return crypto_register_kpp(&ecdh); in ecdh_init() 164 crypto_unregister_kpp(&ecdh); in ecdh_exit() 169 MODULE_ALIAS_CRYPTO("ecdh");
|
/kernel/linux/linux-6.6/crypto/ |
H A D | ecdh_helper.c | 10 #include <crypto/ecdh.h> 27 unsigned int crypto_ecdh_key_len(const struct ecdh *params) in crypto_ecdh_key_len() 34 const struct ecdh *params) in crypto_ecdh_encode_key() 57 struct ecdh *params) in crypto_ecdh_decode_key()
|
H A D | ecdh.c | 12 #include <crypto/ecdh.h> 30 struct ecdh params; in ecdh_set_secret() 143 .cra_name = "ecdh-nist-p192", 144 .cra_driver_name = "ecdh-nist-p192-generic", 168 .cra_name = "ecdh-nist-p256", 169 .cra_driver_name = "ecdh-nist-p256-generic", 193 .cra_name = "ecdh-nist-p384", 194 .cra_driver_name = "ecdh-nist-p384-generic", 240 MODULE_ALIAS_CRYPTO("ecdh");
|
/device/soc/hisilicon/hi3861v100/sdk_liteos/third_party/mbedtls/include/mbedtls/ |
H A D | debug.h | 69 #define MBEDTLS_SSL_DEBUG_ECDH( level, ecdh, attr ) \ 70 mbedtls_debug_printf_ecdh( ssl, level, __FILE__, __LINE__, ecdh, attr ) 81 #define MBEDTLS_SSL_DEBUG_ECDH( level, ecdh, attr ) do { } while( 0 ) 248 * \param ecdh the ECDH context 256 const mbedtls_ecdh_context *ecdh,
|
/third_party/wpa_supplicant/wpa_supplicant-2.9/src/crypto/ |
H A D | crypto_openssl.c | 1971 struct crypto_ecdh *ecdh; in crypto_ecdh_init() local 1976 ecdh = os_zalloc(sizeof(*ecdh)); in crypto_ecdh_init() 1977 if (!ecdh) in crypto_ecdh_init() 1980 ecdh->ec = crypto_ec_init(group); in crypto_ecdh_init() 1981 if (!ecdh->ec) in crypto_ecdh_init() 1984 ec_params = EC_KEY_new_by_curve_name(ecdh->ec->nid); in crypto_ecdh_init() 2009 if (EVP_PKEY_keygen(kctx, &ecdh->pkey) != 1) { in crypto_ecdh_init() 2020 return ecdh; in crypto_ecdh_init() 2022 crypto_ecdh_deinit(ecdh); in crypto_ecdh_init() 2028 crypto_ecdh_get_pubkey(struct crypto_ecdh *ecdh, int inc_y) crypto_ecdh_get_pubkey() argument 2088 crypto_ecdh_set_peerkey(struct crypto_ecdh *ecdh, int inc_y, const u8 *key, size_t len) crypto_ecdh_set_peerkey() argument 2183 crypto_ecdh_deinit(struct crypto_ecdh *ecdh) crypto_ecdh_deinit() argument [all...] |
H A D | crypto_wolfssl.c | 1728 struct crypto_ecdh *ecdh = NULL; in crypto_ecdh_init() local 1735 ecdh = os_zalloc(sizeof(*ecdh)); in crypto_ecdh_init() 1736 if (!ecdh) in crypto_ecdh_init() 1739 ecdh->ec = crypto_ec_init(group); in crypto_ecdh_init() 1740 if (!ecdh->ec) in crypto_ecdh_init() 1743 ret = wc_ecc_make_key_ex(&rng, ecdh->ec->key.dp->size, &ecdh->ec->key, in crypto_ecdh_init() 1744 ecdh->ec->key.dp->id); in crypto_ecdh_init() 1751 return ecdh; in crypto_ecdh_init() 1759 crypto_ecdh_deinit(struct crypto_ecdh *ecdh) crypto_ecdh_deinit() argument 1768 crypto_ecdh_get_pubkey(struct crypto_ecdh *ecdh, int inc_y) crypto_ecdh_get_pubkey() argument 1800 crypto_ecdh_set_peerkey(struct crypto_ecdh *ecdh, int inc_y, const u8 *key, size_t len) crypto_ecdh_set_peerkey() argument [all...] |
H A D | crypto.h | 926 struct wpabuf * crypto_ecdh_get_pubkey(struct crypto_ecdh *ecdh, int inc_y); 927 struct wpabuf * crypto_ecdh_set_peerkey(struct crypto_ecdh *ecdh, int inc_y, 929 void crypto_ecdh_deinit(struct crypto_ecdh *ecdh);
|
/third_party/wpa_supplicant/wpa_supplicant-2.9_standard/src/crypto/ |
H A D | crypto_wolfssl.c | 1710 struct crypto_ecdh *ecdh = NULL; in crypto_ecdh_init() local 1717 ecdh = os_zalloc(sizeof(*ecdh)); in crypto_ecdh_init() 1718 if (!ecdh) in crypto_ecdh_init() 1721 ecdh->ec = crypto_ec_init(group); in crypto_ecdh_init() 1722 if (!ecdh->ec) in crypto_ecdh_init() 1725 ret = wc_ecc_make_key_ex(&rng, ecdh->ec->key.dp->size, &ecdh->ec->key, in crypto_ecdh_init() 1726 ecdh->ec->key.dp->id); in crypto_ecdh_init() 1733 return ecdh; in crypto_ecdh_init() 1741 crypto_ecdh_deinit(struct crypto_ecdh *ecdh) crypto_ecdh_deinit() argument 1750 crypto_ecdh_get_pubkey(struct crypto_ecdh *ecdh, int inc_y) crypto_ecdh_get_pubkey() argument 1782 crypto_ecdh_set_peerkey(struct crypto_ecdh *ecdh, int inc_y, const u8 *key, size_t len) crypto_ecdh_set_peerkey() argument 1829 crypto_ecdh_prime_len(struct crypto_ecdh *ecdh) crypto_ecdh_prime_len() argument [all...] |
H A D | crypto_openssl.c | 2059 struct crypto_ecdh *ecdh; in crypto_ecdh_init() local 2064 ecdh = os_zalloc(sizeof(*ecdh)); in crypto_ecdh_init() 2065 if (!ecdh) in crypto_ecdh_init() 2068 ecdh->ec = crypto_ec_init(group); in crypto_ecdh_init() 2069 if (!ecdh->ec) in crypto_ecdh_init() 2072 ec_params = EC_KEY_new_by_curve_name(ecdh->ec->nid); in crypto_ecdh_init() 2097 if (EVP_PKEY_keygen(kctx, &ecdh->pkey) != 1) { in crypto_ecdh_init() 2108 return ecdh; in crypto_ecdh_init() 2110 crypto_ecdh_deinit(ecdh); in crypto_ecdh_init() 2118 struct crypto_ecdh *ecdh; crypto_ecdh_init2() local 2142 crypto_ecdh_get_pubkey(struct crypto_ecdh *ecdh, int inc_y) crypto_ecdh_get_pubkey() argument 2202 crypto_ecdh_set_peerkey(struct crypto_ecdh *ecdh, int inc_y, const u8 *key, size_t len) crypto_ecdh_set_peerkey() argument 2297 crypto_ecdh_deinit(struct crypto_ecdh *ecdh) crypto_ecdh_deinit() argument 2307 crypto_ecdh_prime_len(struct crypto_ecdh *ecdh) crypto_ecdh_prime_len() argument [all...] |
H A D | crypto.h | 987 * @ecdh: ECDH context from crypto_ecdh_init() or crypto_ecdh_init2() 992 struct wpabuf * crypto_ecdh_get_pubkey(struct crypto_ecdh *ecdh, int inc_y); 996 * @ecdh: ECDH context from crypto_ecdh_init() or crypto_ecdh_init2() 1003 struct wpabuf * crypto_ecdh_set_peerkey(struct crypto_ecdh *ecdh, int inc_y, 1008 * @ecdh: ECDH context from crypto_ecdh_init() or crypto_ecdh_init2() 1010 void crypto_ecdh_deinit(struct crypto_ecdh *ecdh); 1017 size_t crypto_ecdh_prime_len(struct crypto_ecdh *ecdh);
|
/kernel/linux/linux-6.6/drivers/crypto/hisilicon/hpre/ |
H A D | hpre_crypto.c | 7 #include <crypto/ecdh.h> 126 struct hpre_ecdh_ctx ecdh; member 141 struct kpp_request *ecdh; member 1218 if (is_ecdh && ctx->ecdh.p) { in hpre_ecc_clear_ctx() 1219 /* ecdh: p->a->k->b */ in hpre_ecc_clear_ctx() 1220 memzero_explicit(ctx->ecdh.p + shift, sz); in hpre_ecc_clear_ctx() 1221 dma_free_coherent(dev, sz << 3, ctx->ecdh.p, ctx->ecdh.dma_p); in hpre_ecc_clear_ctx() 1222 ctx->ecdh.p = NULL; in hpre_ecc_clear_ctx() 1270 static int hpre_ecdh_fill_curve(struct hpre_ctx *ctx, struct ecdh *param [all...] |
/third_party/mbedtls/include/mbedtls/ |
H A D | debug.h | 55 #define MBEDTLS_SSL_DEBUG_ECDH(level, ecdh, attr) \ 56 mbedtls_debug_printf_ecdh(ssl, level, __FILE__, __LINE__, ecdh, attr) 67 #define MBEDTLS_SSL_DEBUG_ECDH(level, ecdh, attr) do { } while (0)
|
/third_party/mbedtls/library/ |
H A D | psa_crypto_ecp.c | 24 #include <mbedtls/ecdh.h> 544 mbedtls_ecdh_context ecdh; in mbedtls_psa_key_agreement_ecdh() local 547 mbedtls_ecdh_init(&ecdh); in mbedtls_psa_key_agreement_ecdh() 560 mbedtls_ecdh_get_params(&ecdh, their_key, MBEDTLS_ECDH_THEIRS)); in mbedtls_psa_key_agreement_ecdh() 565 mbedtls_ecdh_get_params(&ecdh, ecp, MBEDTLS_ECDH_OURS)); in mbedtls_psa_key_agreement_ecdh() 571 mbedtls_ecdh_calc_secret(&ecdh, in mbedtls_psa_key_agreement_ecdh() 586 mbedtls_ecdh_free(&ecdh); in mbedtls_psa_key_agreement_ecdh()
|
H A D | debug.c | 420 const mbedtls_ecdh_context *ecdh, in mbedtls_debug_printf_ecdh_internal() 424 const mbedtls_ecdh_context *ctx = ecdh; in mbedtls_debug_printf_ecdh_internal() 426 const mbedtls_ecdh_context_mbed *ctx = &ecdh->ctx.mbed_ecdh; in mbedtls_debug_printf_ecdh_internal() 449 const mbedtls_ecdh_context *ecdh, in mbedtls_debug_printf_ecdh() 453 mbedtls_debug_printf_ecdh_internal(ssl, level, file, line, ecdh, attr); in mbedtls_debug_printf_ecdh() 455 switch (ecdh->var) { in mbedtls_debug_printf_ecdh() 457 mbedtls_debug_printf_ecdh_internal(ssl, level, file, line, ecdh, in mbedtls_debug_printf_ecdh() 417 mbedtls_debug_printf_ecdh_internal(const mbedtls_ssl_context *ssl, int level, const char *file, int line, const mbedtls_ecdh_context *ecdh, mbedtls_debug_ecdh_attr attr) mbedtls_debug_printf_ecdh_internal() argument 447 mbedtls_debug_printf_ecdh(const mbedtls_ssl_context *ssl, int level, const char *file, int line, const mbedtls_ecdh_context *ecdh, mbedtls_debug_ecdh_attr attr) mbedtls_debug_printf_ecdh() argument
|
H A D | debug_internal.h | 159 * \param ecdh the ECDH context 167 const mbedtls_ecdh_context *ecdh,
|
/kernel/linux/linux-6.6/net/bluetooth/ |
H A D | ecdh_helper.c | 26 #include <crypto/ecdh.h> 40 * secret: memory where the ecdh computed shared secret will be saved. 75 pr_err("alg: ecdh: compute shared secret failed. err %d\n", in compute_ecdh_secret() 106 struct ecdh p = {0}; in set_ecdh_privkey()
|
/kernel/linux/linux-5.10/net/bluetooth/ |
H A D | ecdh_helper.c | 26 #include <crypto/ecdh.h> 56 * secret: memory where the ecdh computed shared secret will be saved. 96 pr_err("alg: ecdh: compute shared secret failed. err %d\n", in compute_ecdh_secret() 127 struct ecdh p = {0}; in set_ecdh_privkey()
|
/third_party/nghttp2/examples/ |
H A D | libevent-server.c | 162 EC_KEY *ecdh; in create_ssl_ctx() local 163 ecdh = EC_KEY_new_by_curve_name(NID_X9_62_prime256v1); in create_ssl_ctx() 164 if (!ecdh) { in create_ssl_ctx() 168 SSL_CTX_set_tmp_ecdh(ssl_ctx, ecdh); in create_ssl_ctx() 169 EC_KEY_free(ecdh); in create_ssl_ctx()
|
/third_party/libwebsockets/lib/tls/openssl/ |
H A D | openssl-server.c | 165 EC_KEY *ecdh, *EC_key = NULL; local 426 ecdh = EC_KEY_new_by_curve_name(ecdh_nid); 427 if (NULL == ecdh) { 431 SSL_CTX_set_tmp_ecdh(vhost->tls.ssl_ctx, ecdh); 432 EC_KEY_free(ecdh);
|