ucam-department-of-psychiatry / camcops

Cambridge Cognitive and Psychiatric Test Kit (CamCOPS)
Other
12 stars 8 forks source link

Impossible to enter a correct password, having followed the forgotten password workflow #353

Closed martinburchell closed 2 weeks ago

martinburchell commented 1 month ago

Related to, but not fixed by #346, if the user enters an incorrect password in the password dialog, says they have forgotten their password on the next dialog and then cancels the dialog to confirm database deletion, they are then presented with the password dialog and it is impossible for them to enter a correct password.

Workaround is to restart the client.

martinburchell commented 1 month ago

If in SQLite, PRAGMA key is given the wrong key, PRAGMA cipher_migrate can get the database in a non-readable state. Looking at the documentation, the way to fix this is to disconnect and reconnect before trying again with the key.