I read that there is problem method KeyChain.getPrivateKey(Context,String)
on Android 4.1 although on older versions it works. Does anybody has
solution how to get private key on JellyBean?
Code that does not work on 4.1, but works great on older versions.
PrivateKey pk;
try {
pk = KeyChain.getPrivateKey(context,string);
byte[] pkByte = pk.getEncoded();
pkBase64 = new String(Base64.encode(pkByte, Base64.NO_WRAP));
}
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en