Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-80067

QWebEngine cannot show source code for dev-tools while SSL using self-signed cert

    XMLWordPrintable

Details

    • Bug
    • Resolution: Out of scope
    • P2: Important
    • None
    • 5.12.4, 5.13.1, 5.13
    • WebEngine
    • None

    Description

      1)http server using SSL width a self-signed cert
      2)client using QWebEngineView, and could not show souce code in dev-tools window.
      3)When add self-signed cert to system trust-ca list,then the source code could be shown.
      4)If add self-signed cert to trust list, it does not work.
      // Default ssl configuration
      QFile server_pem(":/Resources/ca/server.pem");
      server_pem.open(QIODevice::ReadOnly);
      QByteArray server_pem_data = server_pem.readAll();
      server_pem.close();
      QSslConfiguration ssl_configuration = QSslConfiguration::defaultConfiguration();
      QList<QSslCertificate> ssl_cert_list = ssl_configuration.caCertificates();
      ssl_cert_list.append(QSslCertificate(server_pem_data));
      //for (int i = 0; i < ssl_cert_list.size(); i++)

      { // qDebug() << "Cert_" << i << ":\t\t" << ssl_cert_list[i].subjectDisplayName(); //}

      ssl_configuration.setCaCertificates(ssl_cert_list);
      QSslConfiguration::setDefaultConfiguration(ssl_configuration);

      Is there any way to add self-signed cert to trust-ca list without insalling CA-cert for trusting to every computer?

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            qt_webengine_team Qt WebEngine Team
            secular_wheel Secular Wheel
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes