keepassxreboot / keepassxc

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

Search query cleared although deactivated in the settings #10936

Closed genseirin closed 3 months ago

genseirin commented 3 months ago

Overview

The settings offer the option to automatically lock the database while not clearing the search query. This is very useful because after unlocking the database you often want to continue working with the same entries that you searched before.

The content of the search field anyway is saved per database, so if you switch between databases, the corresponding search term is applied.

Steps to Reproduce

  1. Go to the settings, "Security". Set a time in "Lock databases after inactivity of" and uncheck "Clear search query after". Save.
  2. Enter something into the search field
  3. Wait until the database is automatically locked
  4. Unlock the database

Expected Behavior

The previous search term should be restored after unlocking the database.

Actual Behavior

The search field is empty and elements are shown unfiltered.

Context

KeePassXC - 2.7.9 Revision: 8f6dd13

Operating System: macOS 14.5

droidmonkey commented 3 months ago

Those settings have nothing to do with each other. If you want, you can save a search query by clicking the save icon in the search field. That makes it easy to recall.

genseirin commented 3 months ago

Exactly, the point is that the search field should be independent from the auto-locking feature. And I don't think that persisting a field content is the same as saving it and later deleting all the saved searches afterwards.

droidmonkey commented 3 months ago

The search is cleared for security reasons. Doing otherwise would require us to store the search string in memory which could leak data.