Lines Matching refs:pkey_ctx
3259 EVP_PKEY_CTX *pkey_ctx = NULL; in tls_construct_cke_gost() local
3282 pkey_ctx = EVP_PKEY_CTX_new_from_pkey(sctx->libctx, in tls_construct_cke_gost()
3285 if (pkey_ctx == NULL) { in tls_construct_cke_gost()
3303 if (EVP_PKEY_encrypt_init(pkey_ctx) <= 0 in tls_construct_cke_gost()
3327 if (EVP_PKEY_CTX_ctrl(pkey_ctx, -1, EVP_PKEY_OP_ENCRYPT, in tls_construct_cke_gost()
3337 if (EVP_PKEY_encrypt(pkey_ctx, tmp, &msglen, pms, pmslen) <= 0) { in tls_construct_cke_gost()
3349 EVP_PKEY_CTX_free(pkey_ctx); in tls_construct_cke_gost()
3355 EVP_PKEY_CTX_free(pkey_ctx); in tls_construct_cke_gost()
3409 EVP_PKEY_CTX *pkey_ctx = NULL; in tls_construct_cke_gost18() local
3447 pkey_ctx = EVP_PKEY_CTX_new_from_pkey(sctx->libctx, in tls_construct_cke_gost18()
3450 if (pkey_ctx == NULL) { in tls_construct_cke_gost18()
3455 if (EVP_PKEY_encrypt_init(pkey_ctx) <= 0) { in tls_construct_cke_gost18()
3461 if (EVP_PKEY_CTX_ctrl(pkey_ctx, -1, EVP_PKEY_OP_ENCRYPT, in tls_construct_cke_gost18()
3467 if (EVP_PKEY_CTX_ctrl(pkey_ctx, -1, EVP_PKEY_OP_ENCRYPT, in tls_construct_cke_gost18()
3473 if (EVP_PKEY_encrypt(pkey_ctx, NULL, &msglen, pms, pmslen) <= 0) { in tls_construct_cke_gost18()
3479 || EVP_PKEY_encrypt(pkey_ctx, encdata, &msglen, pms, pmslen) <= 0) { in tls_construct_cke_gost18()
3484 EVP_PKEY_CTX_free(pkey_ctx); in tls_construct_cke_gost18()
3485 pkey_ctx = NULL; in tls_construct_cke_gost18()
3491 EVP_PKEY_CTX_free(pkey_ctx); in tls_construct_cke_gost18()