Android application crashes on unlock but not login #821

Closed
opened 2026-02-04 22:50:18 +03:00 by OVERLORD · 32 comments
Owner

Originally created by @symphorien on GitHub (Oct 3, 2020).

Subject of the issue

Your environment

  • Bitwarden_rs version: 1.16.3 with and without this patch backported, just in case: 0b6a003a8b.patch
  • Install method: NixOS
  • Clients used: Bitwarden f-droid 2.6.1 LineageOS 17.1 (android 10)
  • Reverse proxy and version: nginx 1.16.1
  • Version of mysql/postgresql: sqlite
  • Other relevant information:

Steps to reproduce

Lock the vault
Type the master password, and unlock.
The application crashes
Logcat:

21:25:28.486 12658 12658 I MonoDroid: UNHANDLED EXCEPTION:
21:25:28.495 12658 12658 I MonoDroid: System.Exception: PBKDF2 iteration minimum is 5000.
21:25:28.495 12658 12658 I MonoDroid:   at Bit.Core.Services.CryptoService.MakeKeyAsync (System.String password, System.String salt, System.Nullable`1[T] kdf, System.Nullable`1[T] kdfIterations) [0x0009d] in <9f872fb189f94834a4003aff394890d6>:0 
21:25:28.495 12658 12658 I MonoDroid:   at Bit.App.Pages.LockPageViewModel.SubmitAsync () [0x009e9] in <26e6ab0d79a14f20b188c6e5329517c2>:0 
21:25:28.495 12658 12658 I MonoDroid:   at Bit.App.Pages.LockPage.<Unlock_Clicked>b__17_1 () [0x0006d] in <26e6ab0d79a14f20b188c6e5329517c2>:0 
21:25:28.495 12658 12658 I MonoDroid:   at System.Runtime.CompilerServices.AsyncMethodBuilderCore+<>c.<ThrowAsync>b__7_0 (System.Object state) [0x00000] in <8b5405f22643417f995402e834d2ceac>:0 
21:25:28.495 12658 12658 I MonoDroid:   at Android.App.SyncContext+<>c__DisplayClass2_0.<Post>b__0 () [0x00000] in <4ed8ad1e269942a1a95e75a1ad177714>:0 
21:25:28.495 12658 12658 I MonoDroid:   at Java.Lang.Thread+RunnableImplementor.Run () [0x00008] in <4ed8ad1e269942a1a95e75a1ad177714>:0 
21:25:28.495 12658 12658 I MonoDroid:   at Java.Lang.IRunnableInvoker.n_Run (System.IntPtr jnienv, System.IntPtr native__this) [0x00008] in <4ed8ad1e269942a1a95e75a1ad177714>:0 
21:25:28.495 12658 12658 I MonoDroid:   at (wrapper dynamic-method) Android.Runtime.DynamicMethodNameCounter.50(intptr,intptr)
21:25:28.502 12658 12658 D AndroidRuntime: Shutting down VM
21:25:28.503 12658 12658 E AndroidRuntime: FATAL EXCEPTION: main
21:25:28.503 12658 12658 E AndroidRuntime: Process: com.x8bit.bitwarden, PID: 12658
21:25:28.503 12658 12658 E AndroidRuntime: android.runtime.JavaProxyThrowable: System.Exception: PBKDF2 iteration minimum is 5000.
21:25:28.503 12658 12658 E AndroidRuntime:   at Bit.Core.Services.CryptoService.MakeKeyAsync (System.String password, System.String salt, System.Nullable`1[T] kdf, System.Nullable`1[T] kdfIterations) [0x0009d] in <9f872fb189f94834a4003aff394890d6>:0 
21:25:28.503 12658 12658 E AndroidRuntime:   at Bit.App.Pages.LockPageViewModel.SubmitAsync () [0x009e9] in <26e6ab0d79a14f20b188c6e5329517c2>:0 
21:25:28.503 12658 12658 E AndroidRuntime:   at Bit.App.Pages.LockPage.<Unlock_Clicked>b__17_1 () [0x0006d] in <26e6ab0d79a14f20b188c6e5329517c2>:0 
21:25:28.503 12658 12658 E AndroidRuntime:   at System.Runtime.CompilerServices.AsyncMethodBuilderCore+<>c.<ThrowAsync>b__7_0 (System.Object state) [0x00000] in <8b5405f22643417f995402e834d2ceac>:0 
21:25:28.503 12658 12658 E AndroidRuntime:   at Android.App.SyncContext+<>c__DisplayClass2_0.<Post>b__0 () [0x00000] in <4ed8ad1e269942a1a95e75a1ad177714>:0 
21:25:28.503 12658 12658 E AndroidRuntime:   at Java.Lang.Thread+RunnableImplementor.Run () [0x00008] in <4ed8ad1e269942a1a95e75a1ad177714>:0 
21:25:28.503 12658 12658 E AndroidRuntime:   at Java.Lang.IRunnableInvoker.n_Run (System.IntPtr jnienv, System.IntPtr native__this) [0x00008] in <4ed8ad1e269942a1a95e75a1ad177714>:0 
21:25:28.503 12658 12658 E AndroidRuntime:   at (wrapper dynamic-method) Android.Runtime.DynamicMethodNameCounter.50(intptr,intptr)
21:25:28.503 12658 12658 E AndroidRuntime: 	at mono.java.lang.RunnableImplementor.n_run(Native Method)
21:25:28.503 12658 12658 E AndroidRuntime: 	at mono.java.lang.RunnableImplementor.run(RunnableImplementor.java:30)
21:25:28.503 12658 12658 E AndroidRuntime: 	at android.os.Handler.handleCallback(Handler.java:883)
21:25:28.503 12658 12658 E AndroidRuntime: 	at android.os.Handler.dispatchMessage(Handler.java:100)
21:25:28.503 12658 12658 E AndroidRuntime: 	at android.os.Looper.loop(Looper.java:214)
21:25:28.503 12658 12658 E AndroidRuntime: 	at android.app.ActivityThread.main(ActivityThread.java:7356)
21:25:28.503 12658 12658 E AndroidRuntime: 	at java.lang.reflect.Method.invoke(Native Method)
21:25:28.503 12658 12658 E AndroidRuntime: 	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:491)
21:25:28.503 12658 12658 E AndroidRuntime: 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:940)
21:25:28.507  1365  7690 W ActivityTaskManager:   Force finishing activity com.x8bit.bitwarden/.MainActivity
21:25:28.507  1365 13388 I DropBoxManagerService: add tag=data_app_crash isTagEnabled=true flags=0x2
21:25:28.523  1365  3729 E BufferQueueProducer: [unnamed-1365-31] setMaxDequeuedBufferCount: 2 dequeued buffers would exceed the maxBufferCount (2) (maxAcquired 1 async 0 mDequeuedBufferCannotBlock 0)

Expected behaviour

Unlock the vault

Actual behaviour

Bitwarden closes

Originally created by @symphorien on GitHub (Oct 3, 2020). <!-- Please fill out the following template to make solving your problem easier and faster for us. This is only a guideline. If you think that parts are unneccessary for your issue, feel free to remove them. Remember to hide/obfuscate personal and confidential information, such as names, global IP/DNS adresses and especially passwords, if neccessary. --> ### Subject of the issue <!-- Describe your issue here.--> ### Your environment <!-- The version number, obtained from the logs or the admin page --> * Bitwarden_rs version: 1.16.3 with and without this patch backported, just in case: https://github.com/dani-garcia/bitwarden_rs/commit/0b6a003a8baa909798097100627571b090b1e066.patch <!-- How the server was installed: Docker image / package / built from source --> * Install method: NixOS * Clients used: Bitwarden f-droid 2.6.1 LineageOS 17.1 (android 10) * Reverse proxy and version: nginx 1.16.1 * Version of mysql/postgresql: sqlite * Other relevant information: ### Steps to reproduce Lock the vault Type the master password, and unlock. The application crashes Logcat: ``` 21:25:28.486 12658 12658 I MonoDroid: UNHANDLED EXCEPTION: 21:25:28.495 12658 12658 I MonoDroid: System.Exception: PBKDF2 iteration minimum is 5000. 21:25:28.495 12658 12658 I MonoDroid: at Bit.Core.Services.CryptoService.MakeKeyAsync (System.String password, System.String salt, System.Nullable`1[T] kdf, System.Nullable`1[T] kdfIterations) [0x0009d] in <9f872fb189f94834a4003aff394890d6>:0 21:25:28.495 12658 12658 I MonoDroid: at Bit.App.Pages.LockPageViewModel.SubmitAsync () [0x009e9] in <26e6ab0d79a14f20b188c6e5329517c2>:0 21:25:28.495 12658 12658 I MonoDroid: at Bit.App.Pages.LockPage.<Unlock_Clicked>b__17_1 () [0x0006d] in <26e6ab0d79a14f20b188c6e5329517c2>:0 21:25:28.495 12658 12658 I MonoDroid: at System.Runtime.CompilerServices.AsyncMethodBuilderCore+<>c.<ThrowAsync>b__7_0 (System.Object state) [0x00000] in <8b5405f22643417f995402e834d2ceac>:0 21:25:28.495 12658 12658 I MonoDroid: at Android.App.SyncContext+<>c__DisplayClass2_0.<Post>b__0 () [0x00000] in <4ed8ad1e269942a1a95e75a1ad177714>:0 21:25:28.495 12658 12658 I MonoDroid: at Java.Lang.Thread+RunnableImplementor.Run () [0x00008] in <4ed8ad1e269942a1a95e75a1ad177714>:0 21:25:28.495 12658 12658 I MonoDroid: at Java.Lang.IRunnableInvoker.n_Run (System.IntPtr jnienv, System.IntPtr native__this) [0x00008] in <4ed8ad1e269942a1a95e75a1ad177714>:0 21:25:28.495 12658 12658 I MonoDroid: at (wrapper dynamic-method) Android.Runtime.DynamicMethodNameCounter.50(intptr,intptr) 21:25:28.502 12658 12658 D AndroidRuntime: Shutting down VM 21:25:28.503 12658 12658 E AndroidRuntime: FATAL EXCEPTION: main 21:25:28.503 12658 12658 E AndroidRuntime: Process: com.x8bit.bitwarden, PID: 12658 21:25:28.503 12658 12658 E AndroidRuntime: android.runtime.JavaProxyThrowable: System.Exception: PBKDF2 iteration minimum is 5000. 21:25:28.503 12658 12658 E AndroidRuntime: at Bit.Core.Services.CryptoService.MakeKeyAsync (System.String password, System.String salt, System.Nullable`1[T] kdf, System.Nullable`1[T] kdfIterations) [0x0009d] in <9f872fb189f94834a4003aff394890d6>:0 21:25:28.503 12658 12658 E AndroidRuntime: at Bit.App.Pages.LockPageViewModel.SubmitAsync () [0x009e9] in <26e6ab0d79a14f20b188c6e5329517c2>:0 21:25:28.503 12658 12658 E AndroidRuntime: at Bit.App.Pages.LockPage.<Unlock_Clicked>b__17_1 () [0x0006d] in <26e6ab0d79a14f20b188c6e5329517c2>:0 21:25:28.503 12658 12658 E AndroidRuntime: at System.Runtime.CompilerServices.AsyncMethodBuilderCore+<>c.<ThrowAsync>b__7_0 (System.Object state) [0x00000] in <8b5405f22643417f995402e834d2ceac>:0 21:25:28.503 12658 12658 E AndroidRuntime: at Android.App.SyncContext+<>c__DisplayClass2_0.<Post>b__0 () [0x00000] in <4ed8ad1e269942a1a95e75a1ad177714>:0 21:25:28.503 12658 12658 E AndroidRuntime: at Java.Lang.Thread+RunnableImplementor.Run () [0x00008] in <4ed8ad1e269942a1a95e75a1ad177714>:0 21:25:28.503 12658 12658 E AndroidRuntime: at Java.Lang.IRunnableInvoker.n_Run (System.IntPtr jnienv, System.IntPtr native__this) [0x00008] in <4ed8ad1e269942a1a95e75a1ad177714>:0 21:25:28.503 12658 12658 E AndroidRuntime: at (wrapper dynamic-method) Android.Runtime.DynamicMethodNameCounter.50(intptr,intptr) 21:25:28.503 12658 12658 E AndroidRuntime: at mono.java.lang.RunnableImplementor.n_run(Native Method) 21:25:28.503 12658 12658 E AndroidRuntime: at mono.java.lang.RunnableImplementor.run(RunnableImplementor.java:30) 21:25:28.503 12658 12658 E AndroidRuntime: at android.os.Handler.handleCallback(Handler.java:883) 21:25:28.503 12658 12658 E AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:100) 21:25:28.503 12658 12658 E AndroidRuntime: at android.os.Looper.loop(Looper.java:214) 21:25:28.503 12658 12658 E AndroidRuntime: at android.app.ActivityThread.main(ActivityThread.java:7356) 21:25:28.503 12658 12658 E AndroidRuntime: at java.lang.reflect.Method.invoke(Native Method) 21:25:28.503 12658 12658 E AndroidRuntime: at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:491) 21:25:28.503 12658 12658 E AndroidRuntime: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:940) 21:25:28.507 1365 7690 W ActivityTaskManager: Force finishing activity com.x8bit.bitwarden/.MainActivity 21:25:28.507 1365 13388 I DropBoxManagerService: add tag=data_app_crash isTagEnabled=true flags=0x2 21:25:28.523 1365 3729 E BufferQueueProducer: [unnamed-1365-31] setMaxDequeuedBufferCount: 2 dequeued buffers would exceed the maxBufferCount (2) (maxAcquired 1 async 0 mDequeuedBufferCannotBlock 0) ``` ### Expected behaviour Unlock the vault ### Actual behaviour Bitwarden closes
Author
Owner

@symphorien commented on GitHub (Oct 3, 2020):

Note that according to the web vault, I'm using more than 5000 iterations
image

@symphorien commented on GitHub (Oct 3, 2020): Note that according to the web vault, I'm using more than 5000 iterations ![image](https://user-images.githubusercontent.com/12595971/95000482-c4426280-05b0-11eb-9a57-693df0ac9b3c.png)
Author
Owner

@cylonr commented on GitHub (Oct 4, 2020):

Same error here.
I ve save a movie
https://youtu.be/KJDp-aHDxLs

@cylonr commented on GitHub (Oct 4, 2020): Same error here. I ve save a movie https://youtu.be/KJDp-aHDxLs
Author
Owner

@symphorien commented on GitHub (Oct 4, 2020):

I did this:

  • log out
  • log in
  • reboot
    and now it works, and I don't know why ¯\_(ツ)_/¯
@symphorien commented on GitHub (Oct 4, 2020): I did this: * log out * log in * reboot and now it works, and I don't know why ¯\\\_(ツ)\_/¯
Author
Owner

@BlackDex commented on GitHub (Oct 4, 2020):

@symphorien, @cylonr
May i ask which version of bitwarden_rs you are running?
This could be an issue with a missing endpoint /api/accounts/verify-password.

If you check your bitwarden.log, can you see something in there during that exact same time?

@BlackDex commented on GitHub (Oct 4, 2020): @symphorien, @cylonr May i ask which version of bitwarden_rs you are running? This could be an issue with a missing endpoint /api/accounts/verify-password. If you check your bitwarden.log, can you see something in there during that exact same time?
Author
Owner

@symphorien commented on GitHub (Oct 4, 2020):

Bitwarden_rs version: 1.16.3

I tried with and without this patch backported, just in case: 0b6a003a8b.patch

@symphorien commented on GitHub (Oct 4, 2020): Bitwarden_rs version: 1.16.3 I tried with and without this patch backported, just in case: https://github.com/dani-garcia/bitwarden_rs/commit/0b6a003a8baa909798097100627571b090b1e066.patch
Author
Owner

@BlackDex commented on GitHub (Oct 4, 2020):

@symphorien and what do you see in the bitwarden logs?
Maybe try to raise the log-level to debug?

@BlackDex commented on GitHub (Oct 4, 2020): @symphorien and what do you see in the bitwarden logs? Maybe try to raise the log-level to debug?
Author
Owner

@symphorien commented on GitHub (Oct 4, 2020):

There is nothing to be seen in the server logs, and I can't raise the level to debug now that I can't reproduce any more...

@symphorien commented on GitHub (Oct 4, 2020): There is nothing to be seen in the server logs, and I can't raise the level to debug now that I can't reproduce any more...
Author
Owner

@BlackDex commented on GitHub (Oct 4, 2020):

not even a 404 not found or something?
There should be at least something?
If there is nothing then i don't think it has something to do with bitwarden_rs.
I have read some stuff about a small defect in an android version, but not sure.

@BlackDex commented on GitHub (Oct 4, 2020): not even a 404 not found or something? There should be at least something? If there is nothing then i don't think it has something to do with bitwarden_rs. I have read some stuff about a small defect in an android version, but not sure.
Author
Owner

@symphorien commented on GitHub (Oct 4, 2020):

No match for 40x or 50x status codes.

@symphorien commented on GitHub (Oct 4, 2020): No match for 40x or 50x status codes.
Author
Owner

@BlackDex commented on GitHub (Oct 5, 2020):

Strange, in that case i doubt that it has to do something with the bitwarden_rs api backend actually.
And more a specific issue with the bitwarden app for android maybe in combination with the specific phone software, brand, version, other apps.

@BlackDex commented on GitHub (Oct 5, 2020): Strange, in that case i doubt that it has to do something with the bitwarden_rs api backend actually. And more a specific issue with the bitwarden app for android maybe in combination with the specific phone software, brand, version, other apps.
Author
Owner

@symphorien commented on GitHub (Oct 5, 2020):

I have an hypothesis:
I had the bug, then applied the patch, then tried to unlock and it failed. I opened the issue and only then logged out and logged in again. Then it worked. Hypothesis: the patch must be present at login time to fix the bug.

Could you confirm that backporting 0b6a003a8b and logging out and in again fixes the problem, @cylonr ?

@symphorien commented on GitHub (Oct 5, 2020): I have an hypothesis: I had the bug, then applied the patch, then tried to unlock and it failed. I opened the issue and only then logged out and logged in again. Then it worked. Hypothesis: the patch must be present at login time to fix the bug. Could you confirm that backporting https://github.com/dani-garcia/bitwarden_rs/commit/0b6a003a8baa909798097100627571b090b1e066 and logging out and in again fixes the problem, @cylonr ?
Author
Owner

@BlackDex commented on GitHub (Oct 5, 2020):

Um, because that specific endpoint is only called during unlock, never during login.

@BlackDex commented on GitHub (Oct 5, 2020): Um, because that specific endpoint is only called during unlock, never during login.
Author
Owner

@fazo96 commented on GitHub (Oct 7, 2020):

Hi, I have the same problem. Everything was fine until two days ago when I started running into this bug. I think bitwarden for android has been updated and some change triggers this bug.

I don't know if the problem is on bitwarden_rs's side or on the bitwarden app's side. What can I do to help out?

@fazo96 commented on GitHub (Oct 7, 2020): Hi, I have the same problem. Everything was fine until two days ago when I started running into this bug. I think bitwarden for android has been updated and some change triggers this bug. I don't know if the problem is on bitwarden_rs's side or on the bitwarden app's side. What can I do to help out?
Author
Owner

@BlackDex commented on GitHub (Oct 7, 2020):

@fazo96, in the bitwardenrs logs, do you see anything when you try to unlock??

@BlackDex commented on GitHub (Oct 7, 2020): @fazo96, in the bitwardenrs logs, do you see anything when you try to unlock??
Author
Owner

@fazo96 commented on GitHub (Oct 9, 2020):

I tried replicating the bug by unlocking normally and the only log lines that came up while I was using the android app are:

bitwarden_1          | [2020-10-09 12:08:33][request][INFO] GET /api/accounts/revision-date
bitwarden_1          | [2020-10-09 12:08:33][response][INFO] GET /api/accounts/revision-date (revision_date) => 200 OK

They appeared when I opened the app. I then entered my passphrase and the app crashed. I kept doing it a few more times, no new log lines appeared on the server.

Then I logged out from the app and logged back in, which is what I have to do every time I need to unlock the vault to avoid the app crashing, and these logs appeared:

bitwarden_1          | [2020-10-09 12:10:25][request][INFO] POST /api/accounts/prelogin
bitwarden_1          | [2020-10-09 12:10:25][response][INFO] POST /api/accounts/prelogin (prelogin) => 200 OK
bitwarden_1          | [2020-10-09 12:10:25][request][INFO] POST /identity/connect/token
bitwarden_1          | [2020-10-09 12:10:25][bitwarden_rs::api::identity][INFO] User <fazo96> logged in successfully. IP: <redacted>
bitwarden_1          | [2020-10-09 12:10:25][response][INFO] POST /identity/connect/token (login) => 200 OK
bitwarden_1          | [2020-10-09 12:10:25][request][INFO] GET /api/sync
bitwarden_1          | [2020-10-09 12:10:25][response][INFO] GET /api/sync?<data..> (sync) => 200 OK

It is actually 14:11 now not 12:10 because I am in a GMT+2 timezone. Maybe the problem is the clock is out of sync? The server runs inside docker. However, up until a few days ago it has always worked fine and I made no changes to the server.

@fazo96 commented on GitHub (Oct 9, 2020): I tried replicating the bug by unlocking normally and the only log lines that came up while I was using the android app are: ``` bitwarden_1 | [2020-10-09 12:08:33][request][INFO] GET /api/accounts/revision-date bitwarden_1 | [2020-10-09 12:08:33][response][INFO] GET /api/accounts/revision-date (revision_date) => 200 OK ``` They appeared when I opened the app. I then entered my passphrase and the app crashed. I kept doing it a few more times, no new log lines appeared on the server. Then I logged out from the app and logged back in, which is what I have to do every time I need to unlock the vault to avoid the app crashing, and these logs appeared: ``` bitwarden_1 | [2020-10-09 12:10:25][request][INFO] POST /api/accounts/prelogin bitwarden_1 | [2020-10-09 12:10:25][response][INFO] POST /api/accounts/prelogin (prelogin) => 200 OK bitwarden_1 | [2020-10-09 12:10:25][request][INFO] POST /identity/connect/token bitwarden_1 | [2020-10-09 12:10:25][bitwarden_rs::api::identity][INFO] User <fazo96> logged in successfully. IP: <redacted> bitwarden_1 | [2020-10-09 12:10:25][response][INFO] POST /identity/connect/token (login) => 200 OK bitwarden_1 | [2020-10-09 12:10:25][request][INFO] GET /api/sync bitwarden_1 | [2020-10-09 12:10:25][response][INFO] GET /api/sync?<data..> (sync) => 200 OK ``` It is actually 14:11 now not 12:10 because I am in a GMT+2 timezone. Maybe the problem is the clock is out of sync? The server runs inside docker. However, up until a few days ago it has always worked fine and I made no changes to the server.
Author
Owner

@BlackDex commented on GitHub (Oct 9, 2020):

Which android version are you using? I can't replicate this at all.
Im running Version: 2.6.2 (3206) on android. And the last testing docker image.

@BlackDex commented on GitHub (Oct 9, 2020): Which android version are you using? I can't replicate this at all. Im running Version: 2.6.2 (3206) on android. And the last `testing` docker image.
Author
Owner

@kykc commented on GitHub (Oct 11, 2020):

I've just had an exactly the same problem. When I was gathering information to report here I've somehow fixed it unintentionally, at least for now.

So, initial situation is the same: can login, but got crash on unlock.

Exception

FATAL EXCEPTION: main
Process: com.x8bit.bitwarden, PID: 16012
android.runtime.JavaProxyThrowable: System.Exception: PBKDF2 iteration minimum is 5000.
  at Bit.Core.Services.CryptoService.MakeKeyAsync (System.String password, System.String salt, System.Nullable`1[T] kdf, System.Nullable`1[T] kdfIterations) [0x00087] in <6dfd726fecb34ba79c31a035ec98a215>:0 
  at Bit.App.Pages.LockPageViewModel.SubmitAsync () [0x0078a] in <0c3398d4c9ce4e56ba576728f942d695>:0 
  at Bit.App.Pages.LockPageViewModel.<.ctor>b__22_0 () [0x00062] in <0c3398d4c9ce4e56ba576728f942d695>:0 
  at System.Runtime.CompilerServices.AsyncMethodBuilderCore+<>c.<ThrowAsync>b__7_0 (System.Object state) [0x00000] in <8f1a893b5ab6478299d5fb8196347666>:0 
  at Android.App.SyncContext+<>c__DisplayClass2_0.<Post>b__0 () [0x00000] in <3b6b09cca6ad40039584e80046fcd050>:0 
  at Java.Lang.Thread+RunnableImplementor.Run () [0x00008] in <3b6b09cca6ad40039584e80046fcd050>:0 
  at Java.Lang.IRunnableInvoker.n_Run (System.IntPtr jnienv, System.IntPtr native__this) [0x00008] in <3b6b09cca6ad40039584e80046fcd050>:0 
  at (wrapper dynamic-method) Android.Runtime.DynamicMethodNameCounter.51(intptr,intptr)
  at mono.java.lang.RunnableImplementor.n_run(Native Method)
  at mono.java.lang.RunnableImplementor.run(RunnableImplementor.java:30)
  at android.os.Handler.handleCallback(Handler.java:873)
  at android.os.Handler.dispatchMessage(Handler.java:99)
  at android.os.Looper.loop(Looper.java:193)
  at android.app.ActivityThread.main(ActivityThread.java:6859)
  at java.lang.reflect.Method.invoke(Native Method)
  at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858)

Configuration

  • Bitwarden client 2.6.1 (3178) from play market
  • bitwarden_rs 1.14.1 with sqlite3 db (from bitwardenrs/server docker hub)
  • Device: Lenovo X705F tablet
  • OS: Android 9
  • Patch level: August 5, 2020
  • Kernel: 4.9.112-perf+
  • Build: YT-X705F_S001038_200827_ROW

Story

Yesterday I've tried to update bitwarden_rs to the latest 1.17.0 but the issue was still there. However, I didn't try to logout and then login again on the client. I've just tried to unlock after bitwarden_rs update and still got the same crashes.

Today I've found this issue and decided to participate. When gathering all the version numbers and stuff I've logged out of bitwarden account to get the client version from about menu. And then I logged back in the issue was gone.

@kykc commented on GitHub (Oct 11, 2020): I've just had an exactly the same problem. When I was gathering information to report here I've somehow fixed it unintentionally, at least for now. So, initial situation is the same: can login, but got crash on unlock. ## Exception ``` FATAL EXCEPTION: main Process: com.x8bit.bitwarden, PID: 16012 android.runtime.JavaProxyThrowable: System.Exception: PBKDF2 iteration minimum is 5000. at Bit.Core.Services.CryptoService.MakeKeyAsync (System.String password, System.String salt, System.Nullable`1[T] kdf, System.Nullable`1[T] kdfIterations) [0x00087] in <6dfd726fecb34ba79c31a035ec98a215>:0 at Bit.App.Pages.LockPageViewModel.SubmitAsync () [0x0078a] in <0c3398d4c9ce4e56ba576728f942d695>:0 at Bit.App.Pages.LockPageViewModel.<.ctor>b__22_0 () [0x00062] in <0c3398d4c9ce4e56ba576728f942d695>:0 at System.Runtime.CompilerServices.AsyncMethodBuilderCore+<>c.<ThrowAsync>b__7_0 (System.Object state) [0x00000] in <8f1a893b5ab6478299d5fb8196347666>:0 at Android.App.SyncContext+<>c__DisplayClass2_0.<Post>b__0 () [0x00000] in <3b6b09cca6ad40039584e80046fcd050>:0 at Java.Lang.Thread+RunnableImplementor.Run () [0x00008] in <3b6b09cca6ad40039584e80046fcd050>:0 at Java.Lang.IRunnableInvoker.n_Run (System.IntPtr jnienv, System.IntPtr native__this) [0x00008] in <3b6b09cca6ad40039584e80046fcd050>:0 at (wrapper dynamic-method) Android.Runtime.DynamicMethodNameCounter.51(intptr,intptr) at mono.java.lang.RunnableImplementor.n_run(Native Method) at mono.java.lang.RunnableImplementor.run(RunnableImplementor.java:30) at android.os.Handler.handleCallback(Handler.java:873) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loop(Looper.java:193) at android.app.ActivityThread.main(ActivityThread.java:6859) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858) ``` ## Configuration * Bitwarden client 2.6.1 (3178) from play market * bitwarden_rs 1.14.1 with sqlite3 db (from `bitwardenrs/server` docker hub) * Device: Lenovo X705F tablet * OS: Android 9 * Patch level: August 5, 2020 * Kernel: 4.9.112-perf+ * Build: YT-X705F_S001038_200827_ROW ## Story Yesterday I've tried to update bitwarden_rs to the latest 1.17.0 but the issue was still there. However, I didn't try to logout and then login again on the client. I've just tried to unlock after bitwarden_rs update and still got the same crashes. Today I've found this issue and decided to participate. When gathering all the version numbers and stuff I've logged out of bitwarden account to get the client version from about menu. And then I logged back in the issue was gone.
Author
Owner

@BlackDex commented on GitHub (Oct 11, 2020):

I just tried this in an android emulator using an emulated Nexus 5X using Android 9 but i can't replicate this whole issue.

Could you please provide some more information like

  • Which reverse-proxy.
  • What kind of SSL Certificate you are using.
  • Did you changed the KDF Iterations.
  • Do you have MFA enabled.
@BlackDex commented on GitHub (Oct 11, 2020): I just tried this in an android emulator using an emulated `Nexus 5X` using `Android 9` but i can't replicate this whole issue. Could you please provide some more information like - Which reverse-proxy. - What kind of SSL Certificate you are using. - Did you changed the `KDF Iterations`. - Do you have MFA enabled.
Author
Owner

@kykc commented on GitHub (Oct 11, 2020):

Sure thing.

  • No reverse proxy, bitwarden_rs instance is listening on local network address (plain HTTP)
  • None, plain HTTP
  • No, at least intentionally
  • MFA is disabled
@kykc commented on GitHub (Oct 11, 2020): Sure thing. * No reverse proxy, bitwarden_rs instance is listening on local network address (plain HTTP) * None, plain HTTP * No, at least intentionally * MFA is disabled
Author
Owner

@BlackDex commented on GitHub (Oct 11, 2020):

Well, there is your issue.
The bitwarden client's do not work (that well) without SSL.

@BlackDex commented on GitHub (Oct 11, 2020): Well, there is your issue. The bitwarden client's do not work (that well) without SSL.
Author
Owner

@kykc commented on GitHub (Oct 11, 2020):

I know about the issues with web access and disabled crypto APIs in modern browsers, but windows/linux/android apps worked fine up until this moment. Thank you, I'll wrap my instance in SSL if problem persists.

@kykc commented on GitHub (Oct 11, 2020): I know about the issues with web access and disabled crypto APIs in modern browsers, but windows/linux/android apps worked fine up until this moment. Thank you, I'll wrap my instance in SSL if problem persists.
Author
Owner

@BlackDex commented on GitHub (Oct 11, 2020):

Well, i just quickly tested it on my local dev environment, but it does seem to work.

Also, i can't reproduce the error over there.
I need more information.
Like, is there any call done to bitwarden_rs at all when you want to unlock?
Because, if not, it really is a client issue.

@BlackDex commented on GitHub (Oct 11, 2020): Well, i just quickly tested it on my local dev environment, but it does seem to work. Also, i can't reproduce the error over there. I need more information. Like, is there any call done to bitwarden_rs at all when you want to unlock? Because, if not, it really is a client issue.
Author
Owner

@BlackDex commented on GitHub (Oct 11, 2020):

AH! I have found the culprit!
https://github.com/bitwarden/mobile/issues/1006

@BlackDex commented on GitHub (Oct 11, 2020): AH! I have found the culprit! https://github.com/bitwarden/mobile/issues/1006
Author
Owner

@BlackDex commented on GitHub (Oct 11, 2020):

@kykc Could you check your vault for any items which do not have a "name" set?

@BlackDex commented on GitHub (Oct 11, 2020): @kykc Could you check your vault for any items which do not have a "name" set?
Author
Owner

@BlackDex commented on GitHub (Oct 11, 2020):

@kykc Could you open your sqlite3 database and check the ciphers table and see if you have anything in the name column that doesn't start with a 2. ? or stands out very different from the other items?

@BlackDex commented on GitHub (Oct 11, 2020): @kykc Could you open your sqlite3 database and check the `ciphers` table and see if you have anything in the `name` column that doesn't start with a 2. ? or stands out very different from the other items?
Author
Owner

@BlackDex commented on GitHub (Oct 11, 2020):

Or, if you are comfortable with it, give me a dump of the ciphers table?
There is nothing in there which i can use to retrieve your passwords or which sites etc.. But it can help we to debug your issue.

Just run:

sqlite3 db.sqlite3 ".dump ciphers" > bitwarden-rs_ciphers.txt
@BlackDex commented on GitHub (Oct 11, 2020): Or, if you are comfortable with it, give me a dump of the `ciphers` table? There is nothing in there which i can use to retrieve your passwords or which sites etc.. But it can help we to debug your issue. Just run: ```bash sqlite3 db.sqlite3 ".dump ciphers" > bitwarden-rs_ciphers.txt ```
Author
Owner

@BlackDex commented on GitHub (Oct 12, 2020):

Or could you try the following please.

Install and configure the bitwarden cli https://bitwarden.com/help/article/cli/.
Install the tool jq, most distro's have that in there repo's https://stedolan.github.io/jq/download/.
Check if you can execute bw list items and get a bunch of data returned.
If that works, execute the following.

bw list items | jq '.[] | select(.name==null)'
@BlackDex commented on GitHub (Oct 12, 2020): Or could you try the following please. Install and configure the bitwarden cli https://bitwarden.com/help/article/cli/. Install the tool `jq`, most distro's have that in there repo's https://stedolan.github.io/jq/download/. Check if you can execute `bw list items` and get a bunch of data returned. If that works, execute the following. ```bash bw list items | jq '.[] | select(.name==null)' ```
Author
Owner

@kykc commented on GitHub (Oct 12, 2020):

Sure:

kykc@station ./bw list items | jq '.[] | select(.name==null)'
? Master password: [hidden]
kykc@station

Seems that there is no such objects in my vault (I've also checked that bw returns data as such). But, as I've mentioned earlier I cannot reproduce the issue myself currently. It was gone after I've updated bitwarden_rs (1.14.1 to 1.17.0) and logged out and then back in.

PS I've also checked that jq works as expected

./bw list items | jq '.[] | select(.name=="AION")'

{
  "object": "item",
  "id": "REDACTED",
  "organizationId": null,
  "folderId": "REDACTED",
  "type": 1,
  "name": "AION",
  "notes": "REDACTED",
  "favorite": false,
  "login": {
    "username": "REDACTED",
    "password": "REDACTED",
    "totp": null,
    "passwordRevisionDate": null
  },
  "collectionIds": [],
  "revisionDate": "2018-07-11T16:52:45.579Z"
}
@kykc commented on GitHub (Oct 12, 2020): Sure: ``` kykc@station ./bw list items | jq '.[] | select(.name==null)' ? Master password: [hidden] kykc@station ``` Seems that there is no such objects in my vault (I've also checked that `bw` returns data as such). But, as I've mentioned earlier I cannot reproduce the issue myself currently. It was gone after I've updated bitwarden_rs (1.14.1 to 1.17.0) and logged out and then back in. PS I've also checked that `jq` works as expected ``` ./bw list items | jq '.[] | select(.name=="AION")' { "object": "item", "id": "REDACTED", "organizationId": null, "folderId": "REDACTED", "type": 1, "name": "AION", "notes": "REDACTED", "favorite": false, "login": { "username": "REDACTED", "password": "REDACTED", "totp": null, "passwordRevisionDate": null }, "collectionIds": [], "revisionDate": "2018-07-11T16:52:45.579Z" } ```
Author
Owner

@BlackDex commented on GitHub (Oct 12, 2020):

Ah, wait, it is fixed now?
Yea, 1.14.1 was missing some /api endpoints, so that explains it.
Those are fixed in 1.17.0 indeed :).

@BlackDex commented on GitHub (Oct 12, 2020): Ah, wait, it is fixed now? Yea, 1.14.1 was missing some /api endpoints, so that explains it. Those are fixed in 1.17.0 indeed :).
Author
Owner

@kykc commented on GitHub (Oct 12, 2020):

Yes, I've had 1.14.1 when I observed the issue. Then that's it, I guess. Thanks a lot for your support! 👍

@kykc commented on GitHub (Oct 12, 2020): Yes, I've had 1.14.1 when I observed the issue. Then that's it, I guess. Thanks a lot for your support! 👍
Author
Owner

@BlackDex commented on GitHub (Oct 12, 2020):

Your welcome

@BlackDex commented on GitHub (Oct 12, 2020): Your welcome
Author
Owner

@fazo96 commented on GitHub (Oct 13, 2020):

Solved for me too when updating to 1.17 👍 Thanks!

I had some trouble figuring out why it was not updating until I noticed I was using the bitwardenrs/server:raspberry docker image.

In case anyone has the same problem, that image tag is no longer updated and you need to pull bitwardenrs/server:latest and use that instead, which now works on all platforms so a specific tag for usage on arm hardware is not needed anymore.

@fazo96 commented on GitHub (Oct 13, 2020): Solved for me too when updating to 1.17 :+1: Thanks! I had some trouble figuring out why it was not updating until I noticed I was using the `bitwardenrs/server:raspberry` docker image. In case anyone has the same problem, that image tag is no longer updated and you need to pull `bitwardenrs/server:latest` and use that instead, which now works on all platforms so a specific tag for usage on arm hardware is not needed anymore.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/vaultwarden#821