Qt - SLL error on Windows
Asked Answered
E

2

6

My app is throwing the following errors on windows:

QSslSocket: cannot call unresolved function SSLv3_client_method

QSslSocket: cannot call unresolved function SSL_CTX_new

QSslSocket: cannot call unresolved function SSL_library_init

QSslSocket: cannot call unresolved function ERR_get_error

QSslSocket: cannot call unresolved function ERR_error_string

I have already installed the VS C++ Redistributables and OpenSSL but I have no idea on how to tell Qt to link against openSSL dynamically. I'm using the LGPL version of the Qt binaries and Qt Creator all on Windows 7 (the Linux build works just fine)

Electrochemistry answered 3/12, 2010 at 17:49 Comment(0)
E
4

For some reason Qt wasn't dealing very well with the dlls downloaded from Win32 OpenSSL Installation Project. As I had observed that the application ran smoothly on machines with Tortoise Svn installed I just copied the dlls provided with Tortoise and this worked very well for me.

I know, it's weird that those dlls worked and those from the Win32 OpenSSL Installation Project didn't but for now copying the dlls from the Tortoise Svn installation folder solved my issue.

Electrochemistry answered 7/12, 2010 at 22:19 Comment(2)
which are those DLL files or you just copy all of them?Ezequieleziechiele
Same problem for me. When I install Ruby22-x64 and Qt finds ssleay32.dll shipped with ruby, mine Qt application starts crashing.Ariel
Q
4

Download the the latest OpenSSL pre-build binaries from this website.

I used Win32 OpenSSL v0.9.8r Light as there is some debate about the v1 release. [Client tools are fine you don't need the full distribution]

Make sure that you install the dlls so that they are visible in the windows path. Either;

  • the windows / system32 directory
  • the application directory
  • or add the location of the dlls to the path enviroment variable

This works for me with Qt v4.6.2

Quietism answered 3/5, 2011 at 10:37 Comment(1)
Copying system .dlls from 3rd party websites especially those involving secure communications IS NOT a very wise cyber practice.Perspire

© 2022 - 2024 — McMap. All rights reserved.