keepassxreboot / keepassxc

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

`Failed to authenticate with Quick Unlock: Polkit authorization failed` error on Ubuntu 24.04 #11316

Open EmilEmilchen opened 1 month ago

EmilEmilchen commented 1 month ago

Overview

In the latest snapshot (2.8.0 c1a66a8) version of KeePassXC I get an error when trying to use QuickUnlock (Polkit) on Kubuntu 24.04.1: Failed to authenticate with Quick Unlock: Polkit authorization failed

Steps to Reproduce

  1. Install Kubuntu 24.04.1 LTS
  2. Download v2.8.0 c1a66a8 (or - as far I can tell - any v2.8.0 pre release) AppImage or flatpak
  3. Launch KeePassXC
  4. Open or Create a database
  5. Unlock it and try unlocking it using QuickUnlock

Expected Behavior

The polkit (PolicyKit1 KDE Agent) is supped to appear and allow for easy access to the database.

Actual Behavior

I get an error Failed to authenticate with Quick Unlock: Polkit authorization failed in the GUI:

The error

Context

I'm - as stated below - running KUbuntu 24.04.1 LTS under Wayland with an NVIDIA GPU (just mentioning this because it's been quite a pain to get everything working nicely with it and Wayland). I'm 99% sure though this isn't the problem here. Even when switching to my CPU's integrated graphics or X11 or both I still have the same problem. I was unable to find any additional debug information, cli doesn't show anything at all and as far as I can tell the debug/logging functionality of KeePassXC is rather limited (I could be mistaken, I definitely couldn't figure out how to get any more info). The PolicyKit1 KDE Agent dialog does show up and work just fine anywhere else. The most similar issue I was able to find is #9981 but that's definitely not the problem I'm encountering as I can confidently say that the dialog wasn't raised at all, not just not brought to the front. I even tried this on a clean install of Kubuntu 24.04.1 LTS where I just installed plasma-workspace-wayland and nvidia drivers as well as configured Wayland to use the Nvidia GPU.

KeePassXC - 2.8.0 Revision: c1a66a8

Operating System: Linux Desktop Env: KDE Windowing System: Wayland (error definitely also occurs with X11)

droidmonkey commented 1 month ago

https://github.com/keepassxreboot/keepassxc/issues/5991#issuecomment-2171750016

But we need to provide better notice when this file is not present. The quick unlock page also incorrectly shows even though polkit process was never initiated.