I have code that creates its own Trust Store in order to connect to a private server.
When I run this on an HTC Desire C with Android 4.0.3 I get the exception: IOException: Wrong version of key store. at:
trustStore = KeyStore.getInstance("BKS");
InputStream in = getResources().openRawResource(R.raw.keystore);
trustStore.load(in, "xxxpasswordxxx".toCharArray());
on the last line where it does the load().
When I run the code on the following devices it works fine:
Nexus 7 and Android 4.4.4, Nexus 4 and Android 5.1, HTC One X+ and Android 4.2.2
The APK is the same (and the password is correct) for all devices. Any suggestions as to what I should look to try in order to fix it?