Lines Matching refs:pkeys
141 if (c->pkeys[i].x509 != NULL in ssl_set_pkey()
142 && !X509_check_private_key(c->pkeys[i].x509, pkey)) in ssl_set_pkey()
145 EVP_PKEY_free(c->pkeys[i].privatekey); in ssl_set_pkey()
147 c->pkeys[i].privatekey = pkey; in ssl_set_pkey()
148 c->key = &c->pkeys[i]; in ssl_set_pkey()
276 if (c->pkeys[i].privatekey != NULL) { in ssl_set_cert()
282 EVP_PKEY_copy_parameters(pkey, c->pkeys[i].privatekey); in ssl_set_cert()
285 if (!X509_check_private_key(x, c->pkeys[i].privatekey)) { in ssl_set_cert()
291 EVP_PKEY_free(c->pkeys[i].privatekey); in ssl_set_cert()
292 c->pkeys[i].privatekey = NULL; in ssl_set_cert()
298 X509_free(c->pkeys[i].x509); in ssl_set_cert()
300 c->pkeys[i].x509 = x; in ssl_set_cert()
301 c->key = &(c->pkeys[i]); in ssl_set_cert()
1039 if (!override && (c->pkeys[i].x509 != NULL in ssl_set_cert_and_key()
1040 || c->pkeys[i].privatekey != NULL in ssl_set_cert_and_key()
1041 || c->pkeys[i].chain != NULL)) { in ssl_set_cert_and_key()
1055 OSSL_STACK_OF_X509_free(c->pkeys[i].chain); in ssl_set_cert_and_key()
1056 c->pkeys[i].chain = dup_chain; in ssl_set_cert_and_key()
1058 X509_free(c->pkeys[i].x509); in ssl_set_cert_and_key()
1060 c->pkeys[i].x509 = x509; in ssl_set_cert_and_key()
1062 EVP_PKEY_free(c->pkeys[i].privatekey); in ssl_set_cert_and_key()
1064 c->pkeys[i].privatekey = privatekey; in ssl_set_cert_and_key()
1066 c->key = &(c->pkeys[i]); in ssl_set_cert_and_key()