Skip to content
  • 0 Votes
    6 Posts
    1k Views
    M

    @TLaren And where can I find this plugin and where should I copy it?

  • 0 Votes
    2 Posts
    258 Views
    Christian EhrlicherC

    See https://bugreports.qt.io/browse/QTBUG-84797
    MYSQL_OPT_SSL_MODE is not yet added and when it will only be added for Qt6.6 and higher.

  • 0 Votes
    1 Posts
    168 Views
    No one has replied
  • 0 Votes
    5 Posts
    4k Views
    E

    Ok, thanks for the reply. It pointed me in the correct direction and after many failures I finally figured it out.
    I guess you only learn when you need to dig deep.

    The only thing I had to do was install the correct version of openSSL. Since it is my first time I had no idea what the letter actually meant, I picked the first build, which was version g, I had to install version n.

    For all future wanderers, the only thing you need to do to make the client work is one of the two options:

    Just copy ssleay32.dll and libeay32.dll to working directory OR Install the latest version and set PATH to the folder where the two dlls are located.

    After that you can use QWebSocket without even knowing SSL exists. Just call:

    QWebSocket socket; socket.open( QUrl("someaddress") );

    And, when the dlls are found the warnings disappear.

    That's it.

  • 0 Votes
    2 Posts
    4k Views
    p3c0P

    @PelleKrogstad
    I too had the same requirement. Looking further into I found out that the slot for onIgnoreSslErrors was never called as it is required for Self Signed Certificates and which cause these SSL errors.
    So actually the request needs to modified a bit which could be done by re-implementing createRequest
    Thus in QNAM subclassed class:

    QNetworkReply *MyNam::createRequest(QNetworkAccessManager::Operation op, const QNetworkRequest &request, QIODevice *outgoingData) { QNetworkRequest req = request; QSslConfiguration conf = req.sslConfiguration(); conf.setProtocol(QSsl::AnyProtocol); req.setSslConfiguration(conf); QNetworkReply *reply = QNetworkAccessManager::createRequest(op, req, outgoingData); qDebug() << req.url(); return reply; }

    And thus the ignoreSSLErrors slot was called where the errors were ignored. This worked for me. Let me know if it works for you.