Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inactivity timeout ignored on computer sleep #2014

Open
samuraiii opened this issue Jun 1, 2018 · 5 comments
Open

Inactivity timeout ignored on computer sleep #2014

samuraiii opened this issue Jun 1, 2018 · 5 comments
Assignees
Milestone

Comments

@samuraiii
Copy link

samuraiii commented Jun 1, 2018

I have inactivity timeout set on keepasxc, but database is not locked after longer time in sleep.

Expected Behavior

Database should lock after set inactivity time even if computer was sleeping during that time (at least it should lock itself after waking.

Current Behavior

Database is not locked even after 12 hours of sleep.

Steps to Reproduce (for bugs)

  1. install keepasxc
    2.create db and open it
    3.set inactivity timeout for lock
    4.put computer to sleep and wait for timeout to pass
    5.wake computer and find unlocked db

Context

Debug Info

KeePassXC - Version 2.2.4
Revision: 4723f66

Libraries:

  • Qt 5.9.4
  • libgcrypt 1.8.1

Operating system: Gentoo/Linux
CPU architecture: x86_64
Kernel: linux 4.15.18-gentoo

Enabled extensions:

  • KeePassHTTP
  • Auto-Type
@droidmonkey
Copy link
Member

This may be a bug, but why not activate lock db on screen lock?

@samuraiii
Copy link
Author

samuraiii commented Jun 1, 2018

Hello, I agree that this would be possible solution... for someone else.
I have 5 minute timeout on screen lock on all machines I use, and I have 9999 sec inactivity timeout on keepasxc.
That is because I want to have screen locked when I do something else but I do not want to enter (a lot more complex than screen password) password also to access my db.
I usually logout after I finish work for the day, which also "locks" the db.
But yesterday I needed to keep my work overnight so I just put my laptop to sleep and found this "bug".
That is why this seem to me worth reporting.

All of this setup is also because I use keepassxc as password storage for my Firefox with http connector.

Ps: Everything works as expected when the computer is just locked.

@orzechow
Copy link

I experience this issue nearly every day!

At work I need my passwords multiple times per hour, while I lock my screen very frequently (for meetings, nature’s call, …).
I prefer to have to unlock the database max. 2-3 times per day.
So automatic database locking on screen lock is not an option for me.

Thus I use the inactivity timeout to lock the database.

But as I suspend the session at the end of a workday (Ubuntu based system, suspend to RAM), the database is often still unlocked on the next morning.
I would expect KeepassXC to at least lock the database after system wakeup.

An even safer solution would be to lock the database when suspending right away (without locking on session lock). As this is a little different feature, I've created a new issue for that: #2753

@droidmonkey droidmonkey added this to Settings Overhaul in Release 2.8.0 Apr 10, 2021
@droidmonkey droidmonkey added this to the v2.7.1 milestone Mar 21, 2022
@droidmonkey droidmonkey self-assigned this Mar 21, 2022
@phoerious phoerious modified the milestones: v2.7.1, v2.7.2 Apr 12, 2022
@droidmonkey droidmonkey modified the milestones: v2.7.2, v2.8.0 Sep 7, 2022
@Spaak
Copy link

Spaak commented Mar 17, 2023

I experience this issue nearly every day!

At work I need my passwords multiple times per hour, while I lock my screen very frequently (for meetings, nature’s call, …). I prefer to have to unlock the database max. 2-3 times per day. So automatic database locking on screen lock is not an option for me.

Thus I use the inactivity timeout to lock the database.

But as I suspend the session at the end of a workday (Ubuntu based system, suspend to RAM), the database is often still unlocked on the next morning. I would expect KeepassXC to at least lock the database after system wakeup.

Yep, exactly the same situation for me, so inactivity timeout based on wall clock would be very helpful.

An even safer solution would be to lock the database when suspending right away (without locking on session lock). As this is a little different feature, I've created a new issue for that: #2753

Just chiming in to say that this suggestion #2753 would not be a solution on MacOS, since suspend/locking is managed quite differently there (you never actually "suspend" the system, just lock with the button or close the lid and MacOS figures out what to do in terms of power management--open lid always immediately wakes up no matter the downtime in between). The above (use walltime for inactivity locking timer) would be a solution on MacOS.

@buffytepper
Copy link

buffytepper commented Jan 29, 2024

I'm having this issue lately. When I first set it up, it had no issue. I set mine to lock after a business day and I have the same reasons as @orzechow. Whilst it's not working right now, I will choose to lock the db when my session/screen is locked. But it's not ideal as I will have to enter this password at a minimum several times per day.

edit: I now see my system (company managed) has the power settings to turn off after a given period of inactivity. So, it now makes sense why this happens all of a sudden. Still, I'm hoping that there is a fix in development

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Settings Overhaul
Release 2.8.0
Settings Overhaul
Development

No branches or pull requests

6 participants