martinkasa / capacitor-secure-storage-plugin

Capacitor plugin for storing string values securly on iOS and Android.
MIT License
152 stars 53 forks source link

No available storage method found #71

Open RHinderiks opened 1 year ago

RHinderiks commented 1 year ago

Upgrading to the latest capacitor (v4) it looks like this plugin is no longer working. We get the following errors

11-30 10:02:26.059 E/Capacitor/Console(29244): File: http://localhost/vendor.js - Line 15075 - Msg: ERROR Error: Uncaught (in promise): Error: No available storage method found. 11-30 10:02:26.059 E/Capacitor/Console(29244): Error: No available storage method found. 11-30 10:02:26.059 E/Capacitor/Console(29244): at http://localhost/vendor.js:94851:25 11-30 10:02:26.059 E/Capacitor/Console(29244): at push.99140._ZoneDelegate.invoke (http://localhost/polyfills.js:422:30) 11-30 10:02:26.059 E/Capacitor/Console(29244): at http://localhost/polyfills.js:1339:38 11-30 10:02:26.059 E/Capacitor/Console(29244): at push.99140._ZoneDelegate.invokeTask (http://localhost/polyfills.js:456:35) 11-30 10:02:26.059 E/Capacitor/Console(29244): at Object.onInvokeTask (http://localhost/vendor.js:37288:33) 11-30 10:02:26.059 E/Capacitor/Console(29244): at push.99140._ZoneDelegate.invokeTask (http://localhost/polyfills.js:455:64) 11-30 10:02:26.059 E/Capacitor/Console(29244): at push.99140.Zone.runTask (http://localhost/polyfills.js:227:51) 11-30 10:02:26.060 E/Capacitor/Console(29244): File: http://localhost/vendor.js - Line 88712 - Msg: Cache initialization error: Error: No available storage method found.

bbjoern commented 1 year ago

Same for me. On Android its still working yet on iOS I get the same error. Anyone could please help out ? I don't have a Mac and cannot fix this.

"@capacitor/android": "^4.4.0", "@capacitor/app": "4.1.0", "@capacitor/browser": "^4.0.1", "@capacitor/configure": "^2.0.10", "@capacitor/core": "^4.4.0", "@capacitor/haptics": "^4.0.1", "@capacitor/ios": "^4.4.0",

"capacitor-secure-storage-plugin": "0.8.1"

bbjoern commented 1 year ago

Maybe change the iOS library to this one https://github.com/evgenyneu/keychain-swift ?

tafelnl commented 1 year ago

I upgraded to Capacitor v4 and v0.8.1 of this plugin, but didn't encounter issues. However because of your comment I'm hesitating to release it to production. Are you still encountering issues in combination with Capacitor v4?

BTW: what iOS version(s) are you testing it on?

tafelnl commented 1 year ago

Next to the already suggested https://github.com/evgenyneu/keychain-swift, there exist a few other alternatives: