keepassxreboot / keepassxc

KeePassXC is a cross-platform community-driven port of the Windows application “Keepass Password Safe”.
https://keepassxc.org/
Other
20.61k stars 1.43k forks source link

Error message loop when unable to save #10809

Open Doc-Dish opened 3 months ago

Doc-Dish commented 3 months ago

Overview

I opened a KeePass database stored in my Google Drive attached to the Cinnamon desktop UI via GNOME Online Accounts. When trying to save changes, KeePassXC displayed an error message asking whether I wanted to disable safe saves, as it had failed to save the database multiple times. This error message is repeatedly thrown (leading to a 'stack' of errors), even if the previous one has not been acknowledged and the database cannot be closed as the application is inaccessible. The Cancel and Disable buttons cleared the current error, but did not stop more from being thrown.

Steps to Reproduce

  1. Open database from online account (requires Flatpak version)
  2. Modify database
  3. Save database

Expected Behavior

The error should be thrown (as the database can't be saved) but the Cancel button should return control to the application and allow the changes to be discarded and the database closed.

Actual Behavior

The error was thrown repeatedly (about once per second), each time creating a new error dialogue (on top of the previous one). The only way I could get out of the application was to end it with xkill.

Context

I assume that the access issue was due to using the Flatpak distribution.

KeePassXC - Version 2.7.8 Revision: f6757d3 Distribution: Flatpak

Qt 5.15.10 Debugging mode is disabled.

Operating system: KDE Flatpak runtime CPU architecture: x86_64 Kernel: linux 5.15.0-107-generic

Enabled extensions:

Cryptographic libraries:

Operating System: Linux Desktop Env: Cinnamon Windowing System: X11

Doc-Dish commented 3 months ago

KeePassXC-loop Screenshot of error message.

droidmonkey commented 3 months ago

Do you have delayed file saving turned on?

Doc-Dish commented 3 months ago

My apologies, I'm not sure which setting that is. My file management settings are: image

I'm assuming the inability to write to the database is due to using the Flatpak distribution (the distribution in the system package isn't able to access online accounts). The issue I'm reporting is that it appears that the application gets into an error loop when it can't write back to the database.

droidmonkey commented 3 months ago

Are you using the KeeShare feature? I could not reproduce this issue by simply setting my database file as read-only. Everything worked properly and I was only prompted once to disable safe saving.

Doc-Dish commented 3 months ago

KeeShare is set to not allow import or export, "Only show warnings and errors" is ticked and the "Own certificate" settings are populated (I haven't set these deliberately though).

I've had the same experience on 2 Linux Mint Cinnamon PCs trying to access a KeePass database stored in Google Drive via the "other locations" section of the Cinnamon file browser. Other Flatpak applications are also unable to write to this location.

I've set up google-drive-ocamlfuse to be able to access my database through the 'proper' Linux filesystem, so I'm unlikely to face the issue again.