diff options
author | mrcsys | 2006-01-18 14:53:13 +0000 |
---|---|---|
committer | mrcsys | 2006-01-18 14:53:13 +0000 |
commit | df494ade428ddb4cb6a9a6f8b3885cf1b2478f06 (patch) | |
tree | fa3065731f8c087efbd03e2c8fdcf63bbd19b21d /nanohttp/nanohttp-ssl.c | |
parent | 4088eae7d38124978cf01eaf4bfe2d6aab3a42fd (diff) | |
download | csoap-df494ade428ddb4cb6a9a6f8b3885cf1b2478f06.tar.gz csoap-df494ade428ddb4cb6a9a6f8b3885cf1b2478f06.tar.bz2 |
Added start_ssl function to initialize library.
Diffstat (limited to 'nanohttp/nanohttp-ssl.c')
-rw-r--r-- | nanohttp/nanohttp-ssl.c | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/nanohttp/nanohttp-ssl.c b/nanohttp/nanohttp-ssl.c index 254b718..a2cdf17 100644 --- a/nanohttp/nanohttp-ssl.c +++ b/nanohttp/nanohttp-ssl.c @@ -166,22 +166,24 @@ user_verify (X509 * cert) } #endif -SSL_CTX * -initialize_ctx (const char *keyfile, const char *password, const char *calist) -{ - SSL_CTX *ctx = NULL; - - if (password == NULL) - password = ""; - - +void +start_ssl( void ){ /* Global system initialization */ log_verbose1 ("Initializing library"); SSL_library_init (); SSL_load_error_strings (); ERR_load_crypto_strings (); OpenSSL_add_ssl_algorithms (); +} +SSL_CTX * +initialize_ctx (const char *keyfile, const char *password, const char *calist) +{ + SSL_CTX *ctx = NULL; + + if (password == NULL) + password = ""; + /* Create our context */ ctx = SSL_CTX_new (SSLv23_method ()); |