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. MacOS & SSL
Qt 6.11 is out! See what's new in the release blog

MacOS & SSL

Scheduled Pinned Locked Moved General and Desktop
1 Posts 1 Posters 1.4k Views 1 Watching
  • 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.
  • S Offline
    S Offline
    sadgin
    wrote on last edited by
    #1

    Hello,

    Can anyone help me with my issue? I'm trying to get html page via https protocol, but always got error "SSL handshake failed".
    I've connected SIGNAL sslErrors with SLOT and add printing debug but this SLOT don't get in.
    Same code works fine under Windows and Linux. Qt version is 4.8.1 & 4.8.2.
    I don't got message "got ssl error "
    @@void Main::req() {
    manager = new QNetworkAccessManager(this);
    QNetworkRequest request;
    request.setUrl("https://mypage.com");
    request.setSslConfiguration(QSslConfiguration::defaultConfiguration ());
    connect(manager, SIGNAL(sslErrors(QNetworkReply*,QList<QSslError>)), this, SLOT(sslErrorHandler(QNetworkReply*, const QList<QSslError> & )));
    connect(manager, SIGNAL(finished(QNetworkReply*)),this, SLOT(gotPage(QNetworkReply*)));
    manager->get(request);
    }

    void Main::sslErrorHandler(QNetworkReply* qnr, const QList<QSslError> & errlist) {
    qDebug() << "got ssl errors";
    qnr->ignoreSslErrors();
    }
    @@

    [edit, code tags added, koahnig]

    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