Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. Problems with showing facebook page in Qml WebView in qt5 for windows
Forum Updated to NodeBB v4.3 + New Features

Problems with showing facebook page in Qml WebView in qt5 for windows

Scheduled Pinned Locked Moved QML and Qt Quick
15 Posts 5 Posters 7.1k 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.
  • I Offline
    I Offline
    IonRod
    wrote on last edited by
    #1

    Im trying to show facebook page in my Qt5 WebView using qml. On MacOs everything is fine but on Windows I've got a problem: "SSL handshake failed" I've installed openSSL from 0.9.8y to 1.0.1e but still got a problem. Also I've tried Qt versions: 5.0.0 and 5.0.1 (mingw and visual studio builds)

    I cannot use 4.8.* and older Qt version due to some reason.

    PS. Sorry for my bad english.

    1 Reply Last reply
    0
    • I Offline
      I Offline
      IonRod
      wrote on last edited by
      #2

      The problems seems to be in openSSL. When I'm performing command openssl s_client -connect www.facebook.com:443 it ruins with error: unable to get local issuer certificate

      1 Reply Last reply
      0
      • I Offline
        I Offline
        IonRod
        wrote on last edited by
        #3

        To reproduse bug just open https://www.facebook.com in QML WebView 3.0

        1 Reply Last reply
        0
        • I Offline
          I Offline
          IonRod
          wrote on last edited by
          #4

          Ok, i found the problem and the solution for Qt 4.*.
          The idea is to ignore SSL errors, you could find the example here:
          http://qt-project.org/forums/viewthread/8911

          Now the only one question is how to implement it in Qt 5.0.1 with QWebKit 3.0

          1 Reply Last reply
          0
          • I Offline
            I Offline
            IonRod
            wrote on last edited by
            #5

            The solutions is really simple:
            @import QtWebKit 3.0
            import QtWebKit.experimental 1.0

            WebView {
               id: webView;
               url: "https://www.facebook.com";
               experimental.certificateVerificationDialog: Item {
                   Component.onCompleted: {
                       model.accept();
                   }
               }
            }@

            1 Reply Last reply
            0
            • C Offline
              C Offline
              conny
              wrote on last edited by
              #6

              Thank you for sharing the solution with us!

              1 Reply Last reply
              0
              • I Offline
                I Offline
                IonRod
                wrote on last edited by
                #7

                No problem.

                Just an addition:
                It uses Experimental API, so probably in wont work on any system and any Qt5 version. I've tested it on Windows 7 and Qt 5.0.1 msvc2010 version.

                1 Reply Last reply
                0
                • K Offline
                  K Offline
                  krnekit
                  wrote on last edited by
                  #8

                  IonRod, can you post some links to the documentation about this experimental features of qml WebView?

                  1 Reply Last reply
                  0
                  • D Offline
                    D Offline
                    DRAX
                    wrote on last edited by
                    #9

                    For some reason suggested solution is not working for me. I am using Qt 5.4.
                    Is there some other workaround?

                    1 Reply Last reply
                    0
                    • D Offline
                      D Offline
                      DRAX
                      wrote on last edited by
                      #10

                      For some reason suggested solution is not working for me. I am using Qt 5.4.
                      Is there some other workaround?

                      1 Reply Last reply
                      0
                      • D Offline
                        D Offline
                        DRAX
                        wrote on last edited by
                        #11

                        Ok, I have found somewhere solution.
                        Basically I needed to put 2 files with .exe file:
                        libeay32.dll
                        ssleay32.dll

                        No need for experimental or anything, just add libraries and it works.

                        1 Reply Last reply
                        0
                        • D Offline
                          D Offline
                          DRAX
                          wrote on last edited by
                          #12

                          Ok, I have found somewhere solution.
                          Basically I needed to put 2 files with .exe file:
                          libeay32.dll
                          ssleay32.dll

                          No need for experimental or anything, just add libraries and it works.

                          1 Reply Last reply
                          0
                          • J Offline
                            J Offline
                            julienw
                            wrote on last edited by
                            #13

                            I put these files next to my executable but I still get a blank page (Qt 5.4.1).
                            Are you sure that you didn't do something else?

                            1 Reply Last reply
                            0
                            • J Offline
                              J Offline
                              julienw
                              wrote on last edited by
                              #14

                              I put these files next to my executable but I still get a blank page (Qt 5.4.1).
                              Are you sure that you didn't do something else?

                              D 1 Reply Last reply
                              0
                              • J julienw

                                I put these files next to my executable but I still get a blank page (Qt 5.4.1).
                                Are you sure that you didn't do something else?

                                D Offline
                                D Offline
                                DRAX
                                wrote on last edited by
                                #15

                                @julienw Yes, thats all. I downloaded OpenSSL and extracted those DLL's from installation directory.
                                Maybe you forgot some Qt DLL's to put along with your application.

                                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