Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error with PhoneGap url. #51

Open
oswaldo89 opened this issue Jun 6, 2018 · 2 comments
Open

Error with PhoneGap url. #51

oswaldo89 opened this issue Jun 6, 2018 · 2 comments

Comments

@oswaldo89
Copy link

oswaldo89 commented Jun 6, 2018

even with the example URL, from the phonegap server I get the message > CONECTION_NOT_SECURE, i used the correct fingerprint from the phonegap server.

    $ionicPlatform.ready(function(){
        var server = "https://build.phonegap.com";
        var fingerprint = "C6 2D 93 39 C2 9F 82 8E 1E BE FD DC 2D 7B 7D 24 31 1A 59 E1 0B 4B C8 04 6E 21 F6 FA A2 37 11 45";

        window.plugins.sslCertificateChecker.check(successCallback,errorCallback,server,fingerprint);

         function successCallback(message) {
           alert(message);
         }

         function errorCallback(message) {
           alert(message);
           if (message === "CONNECTION_NOT_SECURE") {
             // There is likely a man in the middle attack going on, be careful!
           } else if (message.indexOf("CONNECTION_FAILED") >- 1) {
             // There was no connection (yet). Internet may be down. Try again (a few times) after a little timeout.
           }
         }
   })

i compiled on android device.
any suggestion? ?

@EddyVerbruggen
Copy link
Owner

I can only imagine you're not using the latest version of the plugin.

@oswaldo89
Copy link
Author

I add plugin with this command > cordova plugin add cordova-plugin-sslcertificatechecker

the version in package.json is > 6.0.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants