Lines Matching refs:peer
41 static int get_peer_public_key(PEER_DATA *peer, OSSL_LIB_CTX *libctx) in get_peer_public_key() argument
50 if (!EVP_PKEY_get_octet_string_param(peer->priv, OSSL_PKEY_PARAM_PUB_KEY, in get_peer_public_key()
60 (char *)peer->curvename, 0); in get_peer_public_key()
65 && (EVP_PKEY_fromdata(ctx, &peer->pub, EVP_PKEY_PUBLIC_KEY, in get_peer_public_key()
71 static int create_peer(PEER_DATA *peer, OSSL_LIB_CTX *libctx) in create_peer() argument
78 (char *)peer->curvename, 0); in create_peer()
87 || EVP_PKEY_generate(ctx, &peer->priv) <= 0 in create_peer()
88 || !get_peer_public_key(peer, libctx)) { in create_peer()
89 EVP_PKEY_free(peer->priv); in create_peer()
90 peer->priv = NULL; in create_peer()
99 static void destroy_peer(PEER_DATA *peer) in destroy_peer() argument
101 EVP_PKEY_free(peer->priv); in destroy_peer()
102 EVP_PKEY_free(peer->pub); in destroy_peer()