Skip to content
This repository has been archived by the owner on Feb 4, 2022. It is now read-only.

Fail to decrypt secure storage data on changing phone/resetting it messes up app #534

Open
lifenautjoe opened this issue May 23, 2020 · 0 comments

Comments

@lifenautjoe
Copy link
Member

See on Sentry l/okuna/okuna-app/issues/15924/?query=is:unresolved

PlatformException: PlatformException(error, Unsupported value: javax.crypto.BadPaddingException: error:1e000065:Cipher functions:OPENSSL_internal:BAD_DECRYPT, null)
  File "message_codecs.dart", line 569, in StandardMethodCodec.decodeEnvelope
  File "platform_channel.dart", line 156, in MethodChannel._invokeMethod
  File "<asynchronous suspension>"
  File "flutter_secure_storage.dart", line 30, in FlutterSecureStorage.read
  File "<asynchronous suspension>"
  File "storage.dart", line 26, in OBStorage.get
  File "<asynchronous suspension>"
  File "user.dart", line 2329, in UserService._getStoredAuthToken
  File "<asynchronous suspension>"
  File "user.dart", line 475, in UserService.hasAuthToken
  File "<asynchronous suspension>"
  File "home.dart", line 464, in OBHomePageState.didChangeAppLifecycleState
  File "<asynchronous suspension>"
  File "unparsed"

We need to handle this error on OBStorage.get to clear up the storage and retrieve nothing instead of failing.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant