getCertificate(alias) returns null
crescent7272 opened this issue · 0 comments
crescent7272 commented
Hello, this is the full error stack. The exception is thrown from android 8.1.0 device.
Fatal Exception: java.lang.NullPointerException: Attempt to invoke virtual method 'java.security.PublicKey java.security.cert.Certificate.getPublicKey()' on a null object reference
at com.yakivmospan.scytale.Store.getAsymmetricKeyFromAndroidKeyStore(Store.java:17)
at com.yakivmospan.scytale.Store.getAsymmetricKey(Store.java:11)
at br.com.***.library.securemobiletoken.KeystoreUtils.encryptString(KeystoreUtils.java:21)
at br.com.***.library.securemobiletoken.SecureMobileToken.setBalance(SecureMobileToken.java:29)
at br.com.***.***.fragments.wallet.prepaid.FragmentWallet.firebaseAction(FragmentWallet.java:397)
at br.com.***.***.fragments.wallet.prepaid.FragmentWallet.access$300(FragmentWallet.java)
at br.com.***.***.fragments.wallet.prepaid.FragmentWallet$3.onDataChange(FragmentWallet.java:44)
at com.google.firebase.database.core.ValueEventRegistration.fireEvent(ValueEventRegistration.java:13)
at com.google.firebase.database.core.view.DataEvent.fire(DataEvent.java:2)
at com.google.firebase.database.core.view.EventRaiser$1.run(EventRaiser.java:63)
at android.os.Handler.handleCallback(Handler.java:790)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:164)
at android.app.ActivityThread.main(ActivityThread.java:6647)
at java.lang.reflect.Method.invoke(Method.java)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:811)
Is this a bug? Thanks in advance.