mirror of https://github.com/aria2/aria2
Move OpenSSL_add_all_algorithms() to Platform::setUp()
parent
d7d5e8570b
commit
ac996737e5
|
@ -149,9 +149,6 @@ bool OpenSSLTLSContext::addCredentialFile(const std::string& certfile,
|
||||||
}
|
}
|
||||||
bool OpenSSLTLSContext::addP12CredentialFile(const std::string& p12file)
|
bool OpenSSLTLSContext::addP12CredentialFile(const std::string& p12file)
|
||||||
{
|
{
|
||||||
// Need this to "decrypt" p12 files.
|
|
||||||
OpenSSL_add_all_algorithms();
|
|
||||||
|
|
||||||
std::stringstream ss;
|
std::stringstream ss;
|
||||||
BufferedFile(p12file.c_str(), "rb").transfer(ss);
|
BufferedFile(p12file.c_str(), "rb").transfer(ss);
|
||||||
|
|
||||||
|
|
|
@ -103,6 +103,8 @@ bool Platform::setUp()
|
||||||
// for SSL initialization
|
// for SSL initialization
|
||||||
SSL_load_error_strings();
|
SSL_load_error_strings();
|
||||||
SSL_library_init();
|
SSL_library_init();
|
||||||
|
// Need this to "decrypt" p12 files.
|
||||||
|
OpenSSL_add_all_algorithms();
|
||||||
#endif // HAVE_OPENSSL
|
#endif // HAVE_OPENSSL
|
||||||
#ifdef HAVE_LIBGCRYPT
|
#ifdef HAVE_LIBGCRYPT
|
||||||
if(!gcry_check_version(A2_MIN_GCRYPT_VERSION)) {
|
if(!gcry_check_version(A2_MIN_GCRYPT_VERSION)) {
|
||||||
|
|
Loading…
Reference in New Issue