Kunzisoft / KeePassDX

Lightweight vault and password manager for Android, KeePassDX allows editing encrypted data in a single file in KeePass format and fill in the forms in a secure way.
https://www.keepassdx.com/
GNU General Public License v3.0
4.57k stars 269 forks source link

Feature 'Reload database' doesn't appear to work #873

Closed wzahra closed 3 years ago

wzahra commented 3 years ago

Hello,

Thanks for your work on this app. I have my database file (.KDBX) stored in Google Drive so I can use it with KeePassXC in Windows. On Android, I access the database by browsing Drive for the database and key (.KEYX) files. If I then lock KeePassDX, update a record in the database via KeePassXC and allow the database to sync to Drive (via Google Backup & Sync, and confirm the sync was successful), KeePassDX still loads the old version of the database. Specifically, in KeePassDX:

Interestingly, if I make a change to the database file in KeePassDX and tap 'Save', the database is updated in Drive and when Google Backup & Sync updates the local database file in Windows, KeePassXC displays the change made in KeePassDX (and the change previously made in KeePassXC is not present).

I have not experimented with alternatives to Drive for the file synchronisation.

Am I doing something wrong? Is this a bug? If so, is there a workaround (e.g. using a particular alternative to Drive)?

As a side note, ideally, KeePassDX would download the current version of the database from Drive every time I decrypt it - that way, I'm always using the current version upon decrypting it - without needing to tap the 'Reload database' button.

Thanks,

Will

J-Jamet commented 3 years ago

Hello, There is no cache in KeePassDX at this level. The uploaded file is always the one provided by the content-provider of Google Drive.

This means the data stream is the one provided externally so I think Google Drive needs to keep the file cached while it is updated internally.

Reloading the database reopens the stream and completely reloads the file, but if it is always the same provided, KeePassDX cannot invent data.

So I'm not sure what to do to force Google Drive to retrieve the latest info.

wzahra commented 3 years ago

Thanks for your reply. I'll try using a different Android phone and see if I get the same result.

wzahra commented 3 years ago

I uninstalled the Google Drive app and reinstalled it and now this issue is no longer happening - it looks like there was something broken in the Drive app. On another phone, I didn't have Drive installed. I installed it, tested this issue, and it worked fine.