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

PlatformException: PlatformException(Exception encountered, read, javax.crypto.BadPaddingException: error:1e000065:C... #1121

Closed
sentry-io bot opened this issue Feb 12, 2022 · 3 comments · Fixed by #1730
Assignees
Labels
Milestone

Comments

@sentry-io
Copy link

sentry-io bot commented Feb 12, 2022

Sentry Issue: SMOOTHIE-SZ

PlatformException: PlatformException(Exception encountered, read, javax.crypto.BadPaddingException: error:1e000065:Cipher functions:OPENSSL_internal:BAD_DECRYPT
	at com.android.org.conscrypt.NativeCrypto.EVP_CipherFinal_ex(Native Method)
	at com.android.org.conscrypt.OpenSSLEvpCipher.doFinalInternal(OpenSSLEvpCipher.java:152)
	at com.android.org.conscrypt.OpenSSLCipher.engineDoFinal(OpenSSLCipher.java:374)
	at javax.crypto.Cipher.doFinal(Cipher.java:2055)
	at e.e.a.e.b.b(StorageCipher18Implementation.java:7)
	at e.e.a.d.m(FlutterSecureStoragePlugin.java:2)
	at e.e.a.d.t(FlutterSecureStoragePlugin.java:2)
	at e.e.a.d.f(FlutterSecureStoragePlugin.java:1)
	at e.e.a.d$b.run(FlutterSecureStoragePlugin.java:25)
	at android.os.Handler.handleCallback(Handler.java:938)
	at android.os.Handler.dispatchMessage(Handler.java:99)
	at android.os.Looper.loopOnce(Looper.java:226)
	at android.os.Looper.loop(Looper.java:313)
	at android.os.HandlerThread.run(HandlerThread.java:67)
, null)
  File "user_management_helper.dart", line 46, in UserManagementHelper.mountCredentials
@M123-dev
Copy link
Member

So what happend is: I logged in on the playstore version and then installed a debug apk with flutter run which has overwritten the old one which probably causes the decryption to fail.
We should catch these kind of erros, delete the credentials and show a snackbar that you got logged out

@M123-dev M123-dev added the P5 label Feb 12, 2022
@monsieurtanuki
Copy link
Contributor

@M123-dev It's a developer's problem, not a real life one. I'm surprised flutter even allowed you to overwrite a version: Android would not mix a Play Store and a dev version and would not install.

@M123-dev
Copy link
Member

No really overwriting, it is like a new install but it keeps the app data but removes all references to the playstore etc and since the decryption fails we can see that its still secure, but maybe this also happens in other cases for example when someone migrates all data to a new phone or something so a little check does no harm

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

Successfully merging a pull request may close this issue.

3 participants