OpenSSL: remove reference to openssl internal struct
With this change, curl compiles with the new OPENSSL_NO_SSL_INTERN cflag. This flag might become the default in some distant future.
This commit is contained in:
committed by
Daniel Stenberg
parent
8ef7a5706e
commit
81524cbfa0
@@ -239,8 +239,7 @@ static CURLcode sslctxfun(CURL * curl, void * sslctx, void * parm) {
|
|||||||
SSL_CTX_set_cipher_list(ctx,"RC4-MD5");
|
SSL_CTX_set_cipher_list(ctx,"RC4-MD5");
|
||||||
SSL_CTX_set_mode(ctx, SSL_MODE_AUTO_RETRY);
|
SSL_CTX_set_mode(ctx, SSL_MODE_AUTO_RETRY);
|
||||||
|
|
||||||
X509_STORE_add_cert(ctx->cert_store,sk_X509_value(p->ca,
|
X509_STORE_add_cert(SSL_CTX_get_cert_store(ctx), sk_X509_value(p->ca, sk_X509_num(p->ca)-1));
|
||||||
sk_X509_num(p->ca)-1));
|
|
||||||
|
|
||||||
SSL_CTX_set_verify_depth(ctx,2);
|
SSL_CTX_set_verify_depth(ctx,2);
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2011, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2012, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -1636,7 +1636,8 @@ ossl_connect_step1(struct connectdata *conn,
|
|||||||
if(data->set.str[STRING_SSL_CRLFILE]) {
|
if(data->set.str[STRING_SSL_CRLFILE]) {
|
||||||
/* tell SSL where to find CRL file that is used to check certificate
|
/* tell SSL where to find CRL file that is used to check certificate
|
||||||
* revocation */
|
* revocation */
|
||||||
lookup=X509_STORE_add_lookup(connssl->ctx->cert_store,X509_LOOKUP_file());
|
lookup=X509_STORE_add_lookup(SSL_CTX_get_cert_store(connssl->ctx),
|
||||||
|
X509_LOOKUP_file());
|
||||||
if(!lookup ||
|
if(!lookup ||
|
||||||
(!X509_load_crl_file(lookup,data->set.str[STRING_SSL_CRLFILE],
|
(!X509_load_crl_file(lookup,data->set.str[STRING_SSL_CRLFILE],
|
||||||
X509_FILETYPE_PEM)) ) {
|
X509_FILETYPE_PEM)) ) {
|
||||||
@@ -1647,7 +1648,7 @@ ossl_connect_step1(struct connectdata *conn,
|
|||||||
else {
|
else {
|
||||||
/* Everything is fine. */
|
/* Everything is fine. */
|
||||||
infof(data, "successfully load CRL file:\n");
|
infof(data, "successfully load CRL file:\n");
|
||||||
X509_STORE_set_flags(connssl->ctx->cert_store,
|
X509_STORE_set_flags(SSL_CTX_get_cert_store(connssl->ctx),
|
||||||
X509_V_FLAG_CRL_CHECK|X509_V_FLAG_CRL_CHECK_ALL);
|
X509_V_FLAG_CRL_CHECK|X509_V_FLAG_CRL_CHECK_ALL);
|
||||||
}
|
}
|
||||||
infof(data,
|
infof(data,
|
||||||
|
|||||||
Reference in New Issue
Block a user