KeePassium icon indicating copy to clipboard operation
KeePassium copied to clipboard

Custom hotkeys/shortcuts/macros are blocked while KeePassium is running

Open ezamelczyk opened this issue 4 months ago • 2 comments

I'm using an MX Master 2s mouse and it has two buttons under my thumb that are mapped to switching workspaces (left/right). When I launch keepassium and unlock it everything works fine but when the keepassium window gains focus again it asks for a pin and it completely disables the desktop switching functionality of my mouse. It's like it's capturing all inputs and swallowing them. Unlocking it again does not fix the issue. I have to completely quit the app.

The issue does not occur with app protection disabled.

Environment:

  • Device: Macbook Pro M1
  • OS: macOS Sonoma 14.3.1
  • App Version: 1.48.142

ezamelczyk avatar Feb 15 '24 19:02 ezamelczyk

Yeah, this is quite an annoying one…

Apparently, Mac Catalyst automatically activates the (system-wide) Secure Input mode in password fields, but fails to disable it when the field/app loses input focus. As a result, the system blocks all the input monitoring/modifying apps (a macOS security feature) because it considers you keep entering something sensitive (a Mac Catalyst bug). Seems to be a widespread issue among macOS apps, too…

From a quick search, it seems to be possible to control this manually by tapping into some macOS-specific libraries. I will look into this.

keepassium avatar Feb 16 '24 14:02 keepassium

In order to test possible solutions, here are the steps to reproduce the issue:

  1. Enable app passcode and Touch ID
  2. Launch KeePassium, it shows Touch ID prompt. Secure input mode (SIM) = off
  3. In Touch ID prompt, click "Use Passcode", then click the passcode field to focus on it (SIM -> on)
  4. Press Esc to show Touch ID prompt again (SIM -> off)
  5. Cmd-Tab to another app (SIM = off)
  6. Cmd-Tab back to KeePassium (SIM -> on)
  7. Cmd-Tab to another app
    • Expected: SIM -> off
    • Observed: SIM remains ON, system-wide, until KeePassium is restarted

keepassium avatar Feb 26 '24 23:02 keepassium

@ezamelczyk, it should be better now, please check.

keepassium avatar Mar 06 '24 22:03 keepassium

Ok, I assume it is fixed.

keepassium avatar Mar 11 '24 18:03 keepassium