1

I am working on an android chat application using smack api when i try to connect and login with openfire server I am getting an error:

jks implementation not found

But sometimes it allow me to login.

I am not getting the problem.

Here is my code:

if (Build.VERSION.SDK_INT >= 15) {
            config.setTruststoreType("AndroidCAStore");
            config.setTruststorePassword(null);
            config.setTruststorePath(null);
        } else {
            config.setTruststoreType("JKS");
            String path = System.getProperty("javax.net.ssl.trustStore");
            if (path == null)
                path = System.getProperty("java.home") + File.separator + "etc"
                        + File.separator + "security" + File.separator
                        + "cacerts.bks";
            config.setTruststorePath(path);
        }
Ricky Khatri
  • 952
  • 2
  • 16
  • 42
  • A little bit late, but it seems like a dup of http://stackoverflow.com/questions/11712671/smack-no-response-from-server-not-sure-why-am-i-getting-this-error. Accepted answer of this question advises to use "BKS" trust store type instead of "JKS". – Andrey Starodubtsev Jan 19 '16 at 12:35

0 Answers0