Lines Matching refs:cert
95 CERT *ssl_cert_dup(CERT *cert) in ssl_cert_dup() argument
106 ret->ssl_pkey_num = cert->ssl_pkey_num; in ssl_cert_dup()
113 ret->key = &ret->pkeys[cert->key - cert->pkeys]; in ssl_cert_dup()
120 if (cert->dh_tmp != NULL) { in ssl_cert_dup()
121 ret->dh_tmp = cert->dh_tmp; in ssl_cert_dup()
125 ret->dh_tmp_cb = cert->dh_tmp_cb; in ssl_cert_dup()
126 ret->dh_tmp_auto = cert->dh_tmp_auto; in ssl_cert_dup()
129 CERT_PKEY *cpk = cert->pkeys + i; in ssl_cert_dup()
168 if (cert->conf_sigalgs) { in ssl_cert_dup()
169 ret->conf_sigalgs = OPENSSL_malloc(cert->conf_sigalgslen in ssl_cert_dup()
170 * sizeof(*cert->conf_sigalgs)); in ssl_cert_dup()
173 memcpy(ret->conf_sigalgs, cert->conf_sigalgs, in ssl_cert_dup()
174 cert->conf_sigalgslen * sizeof(*cert->conf_sigalgs)); in ssl_cert_dup()
175 ret->conf_sigalgslen = cert->conf_sigalgslen; in ssl_cert_dup()
179 if (cert->client_sigalgs) { in ssl_cert_dup()
180 ret->client_sigalgs = OPENSSL_malloc(cert->client_sigalgslen in ssl_cert_dup()
181 * sizeof(*cert->client_sigalgs)); in ssl_cert_dup()
184 memcpy(ret->client_sigalgs, cert->client_sigalgs, in ssl_cert_dup()
185 cert->client_sigalgslen * sizeof(*cert->client_sigalgs)); in ssl_cert_dup()
186 ret->client_sigalgslen = cert->client_sigalgslen; in ssl_cert_dup()
190 if (cert->ctype) { in ssl_cert_dup()
191 ret->ctype = OPENSSL_memdup(cert->ctype, cert->ctype_len); in ssl_cert_dup()
194 ret->ctype_len = cert->ctype_len; in ssl_cert_dup()
197 ret->cert_flags = cert->cert_flags; in ssl_cert_dup()
199 ret->cert_cb = cert->cert_cb; in ssl_cert_dup()
200 ret->cert_cb_arg = cert->cert_cb_arg; in ssl_cert_dup()
202 if (cert->verify_store) { in ssl_cert_dup()
203 X509_STORE_up_ref(cert->verify_store); in ssl_cert_dup()
204 ret->verify_store = cert->verify_store; in ssl_cert_dup()
207 if (cert->chain_store) { in ssl_cert_dup()
208 X509_STORE_up_ref(cert->chain_store); in ssl_cert_dup()
209 ret->chain_store = cert->chain_store; in ssl_cert_dup()
212 ret->sec_cb = cert->sec_cb; in ssl_cert_dup()
213 ret->sec_level = cert->sec_level; in ssl_cert_dup()
214 ret->sec_ex = cert->sec_ex; in ssl_cert_dup()
216 if (!custom_exts_copy(&ret->custext, &cert->custext)) in ssl_cert_dup()
219 if (cert->psk_identity_hint) { in ssl_cert_dup()
220 ret->psk_identity_hint = OPENSSL_strdup(cert->psk_identity_hint); in ssl_cert_dup()
297 CERT_PKEY *cpk = s != NULL ? s->cert->key : ctx->cert->key; in ssl_cert_set0_chain()
334 CERT_PKEY *cpk = s ? s->cert->key : ctx->cert->key; in ssl_cert_add0_chain_cert()
437 if (s->cert->verify_store) in ssl_verify_internal()
438 verify_store = s->cert->verify_store; in ssl_verify_internal()
1057 CERT *c = s != NULL ? s->cert : ctx->cert; in ssl_build_cert_chain()
1281 return s->cert->sec_cb(SSL_CONNECTION_GET_USER_SSL(s), NULL, op, bits, nid, in ssl_security()
1282 other, s->cert->sec_ex); in ssl_security()
1287 return ctx->cert->sec_cb(NULL, ctx, op, bits, nid, other, in ssl_ctx_security()
1288 ctx->cert->sec_ex); in ssl_ctx_security()