Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. OpenSSL Problems
Forum Update on Monday, May 27th 2025

OpenSSL Problems

Scheduled Pinned Locked Moved Unsolved General and Desktop
4 Posts 2 Posters 323 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    AboutClod
    wrote on last edited by AboutClod
    #1

    Hi everyone!

    I'm facing issues while using QNetworkAccessManager for HTTPS requests. I tried with my server but also with some link on badssl, to try to handle SSL Errors.

    So this is my code:

    manager = new QNetworkAccessManager();
            manager->setProxy(QNetworkProxy::NoProxy);
    
            connect(manager,&QNetworkAccessManager::finished,this,&alfro::managerFinished);
    
            connect(manager,&QNetworkAccessManager::sslErrors,this,&alfro::ignorsa);
    
    
    
    
            
    
    
              QSslConfiguration cfg(QSslConfiguration::defaultConfiguration());
              cfg.setProtocol(QSsl::AnyProtocol);
    
              request.setSslConfiguration(cfg);
              request.setUrl(url);
    
              manager->get(request);
    

    Where "ignorsa" is my sslErrors slot handler and managerFinished is the slot handler when everything is ok.

    The only reply I can get is "QNetworkReply::SslHandshakeFailedError" and the errorString "SSL Handshake failed", from the slot managerFinished, so sslErrors signals is not emitted!

    But the Qt Doc says that when this happens the sslErrors should be emitted! And in my case it not! Never!

    I'm going crazy on this, because I thing this is something stupid and I can't figure out!

    I'm currently using Qt 5.12.6 LTS and updated few hours ago to OpenSSL 1.1.1b (Feb 2019).

    If I try to write in console the version used for the build and for the runtime it says:

    Support SSL:  true
    SSL version used for build:  "OpenSSL 1.1.1b  26 Feb 2019"
    SSL version used for run-time:  269488207
    

    Thank you for your help!

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi,

      What OS are you on ?

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0
      • A Offline
        A Offline
        AboutClod
        wrote on last edited by
        #3

        Hi @SGaist!

        I'm currently using Windows 7 Professional SP1 x64.

        Any hint?

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          Where are your OpenSSL dlls stored ? Can they be found by the application ?

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          0

          • Login

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved