summaryrefslogtreecommitdiff
path: root/src/lib/libssl/ssl_cert.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/libssl/ssl_cert.c')
-rw-r--r--src/lib/libssl/ssl_cert.c17
1 files changed, 6 insertions, 11 deletions
diff --git a/src/lib/libssl/ssl_cert.c b/src/lib/libssl/ssl_cert.c
index 27256eea81..a32b2d4446 100644
--- a/src/lib/libssl/ssl_cert.c
+++ b/src/lib/libssl/ssl_cert.c
@@ -56,7 +56,7 @@
56 * [including the GNU Public Licence.] 56 * [including the GNU Public Licence.]
57 */ 57 */
58/* ==================================================================== 58/* ====================================================================
59 * Copyright (c) 1998-2007 The OpenSSL Project. All rights reserved. 59 * Copyright (c) 1998-2006 The OpenSSL Project. All rights reserved.
60 * 60 *
61 * Redistribution and use in source and binary forms, with or without 61 * Redistribution and use in source and binary forms, with or without
62 * modification, are permitted provided that the following conditions 62 * modification, are permitted provided that the following conditions
@@ -197,10 +197,8 @@ CERT *ssl_cert_dup(CERT *cert)
197 * if you find that more readable */ 197 * if you find that more readable */
198 198
199 ret->valid = cert->valid; 199 ret->valid = cert->valid;
200 ret->mask_k = cert->mask_k; 200 ret->mask = cert->mask;
201 ret->mask_a = cert->mask_a; 201 ret->export_mask = cert->export_mask;
202 ret->export_mask_k = cert->export_mask_k;
203 ret->export_mask_a = cert->export_mask_a;
204 202
205#ifndef OPENSSL_NO_RSA 203#ifndef OPENSSL_NO_RSA
206 if (cert->rsa_tmp != NULL) 204 if (cert->rsa_tmp != NULL)
@@ -502,6 +500,9 @@ int ssl_verify_cert_chain(SSL *s,STACK_OF(X509) *sk)
502 SSLerr(SSL_F_SSL_VERIFY_CERT_CHAIN,ERR_R_X509_LIB); 500 SSLerr(SSL_F_SSL_VERIFY_CERT_CHAIN,ERR_R_X509_LIB);
503 return(0); 501 return(0);
504 } 502 }
503 if (s->param)
504 X509_VERIFY_PARAM_inherit(X509_STORE_CTX_get0_param(&ctx),
505 s->param);
505#if 0 506#if 0
506 if (SSL_get_verify_depth(s) >= 0) 507 if (SSL_get_verify_depth(s) >= 0)
507 X509_STORE_CTX_set_depth(&ctx, SSL_get_verify_depth(s)); 508 X509_STORE_CTX_set_depth(&ctx, SSL_get_verify_depth(s));
@@ -515,10 +516,6 @@ int ssl_verify_cert_chain(SSL *s,STACK_OF(X509) *sk)
515 516
516 X509_STORE_CTX_set_default(&ctx, 517 X509_STORE_CTX_set_default(&ctx,
517 s->server ? "ssl_client" : "ssl_server"); 518 s->server ? "ssl_client" : "ssl_server");
518 /* Anything non-default in "param" should overwrite anything in the
519 * ctx.
520 */
521 X509_VERIFY_PARAM_set1(X509_STORE_CTX_get0_param(&ctx), s->param);
522 519
523 if (s->verify_callback) 520 if (s->verify_callback)
524 X509_STORE_CTX_set_verify_cb(&ctx, s->verify_callback); 521 X509_STORE_CTX_set_verify_cb(&ctx, s->verify_callback);
@@ -755,8 +752,6 @@ int SSL_add_file_cert_subjects_to_stack(STACK_OF(X509_NAME) *stack,
755 sk_X509_NAME_push(stack,xn); 752 sk_X509_NAME_push(stack,xn);
756 } 753 }
757 754
758 ERR_clear_error();
759
760 if (0) 755 if (0)
761 { 756 {
762err: 757err: