-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Password Health Check #3993
Password Health Check #3993
Conversation
a22708d
to
4c88902
Compare
04e78c4
to
c35a8e6
Compare
No idea what the problem with the Ubuntu TeamCity build is but I'm pretty sure it's unrelated to my code. |
Hmm. That must be the host that runs two agents. Somehow when I run two build agents on one machine, the second container has an incomplete configuration. Not sure why, though. |
75976df
to
5ecaa44
Compare
3233f27
to
3c38bd5
Compare
Would like to squash all these commits, ok? |
@droidmonkey Squashing is fine by me, but please scan the comments first to check if there's anything worth keeping. I think I put the source URL of the health check icon somewhere. |
When I look at your screenshot, two questions come to mind:
|
It depends on the individual's interpretation of what it means that a password has expired. A common interpretation is "the password is no longer valid", either because the service requires it to be renewed after a certain time (and you may lose access if you fail to do so), or because you chose to change the password after a certain time for security reasons. In either case, even though expiration doesn't change the actual password quality (as defined by its entropy), the password is no longer "healthy" after it has expired.
Health check only reports passwords that are not "healthy" (=that have an issue of some sort). "Positive" as in "all passwords are healthy, no action required" looks like this: In a medical context that would actually be called a "negative" result, so I hope I understood your question correctly. You know, if you get tested for a disease, a "negative" test result (=no disease found) is "positive" (=good) for you, and vice-versa. BTW, I kind of cheated, just added that message as a result of your question. Thanks for pointing it out. |
@wolframroesler EDIT Maybe it still needs a little styling. For example, a title line does not seem necessary to me. There is quite a lot of white space. And the hint "Hover over reason..." below the widget is probably not necessary either, right? Somehow I also find it strange that the sentence is completely left-aligned. With no space to the left. Do you have any ideas how to make this look more appealing?
For the first part: I would like a clearer solution here. Could you imagine that expired passwords would simply be marked differently and users would instead be given the opportunity to renew it after a health check? But the main window already shows this information, right? As an example from your screenshot "GitHub". It would suggest: "Weak password -> line break -> Password has expired". Additionally, it's crossed out, like in the main window, so there's a coherence here. How do you feel about my idea? |
A simple checkbox would suffice: "Evaluate expired passwords" |
@4jNsY6fCVqZv Well, since the KeePass system has a data field named "expired" but doesn't define what what exactly it is supposed to mean, everyone's free to use their own definition, however the fact that entries with expired password are shown crossed out in the entry list indicates that there's some significance to it. Also, flagging expiration as a serious issue in Health Check was one of the initial requirements requested in this issue (see comments above). I don't feel too good about making Health Check configurable. People may be thinking that everything's OK because of a clean Health Check, when in fact they just forgot about some check mark. Also, a check box for expired passwords is just the beginning, someone could have the idea of making the entire scoring system configurable, and I don't want to open that can of worms. (Well, not now, at least.) Let's talk about actual use cases. What exactly are your criteria to set an expiration date for a password? (This is a question for everyone.)
You can do that already, double-clicking the line in Health Check puts you right into the entry editor. Marking expired passwords differently isn't so easy because how about passwords that are both expired and have poor entropy? The "Reason" column already says "password has expired", that's all the information people need IMHO. |
To me I set an expiration on an entry if it needs to be changed by that time, or actually expires at that time (eg, credit card). I agree with your comments! |
My idea was not to make the health check configurable. It was:
What do you say concerning my comments under "EDIT"? As far as the use cases are concerned, I agree with @droidmonkey . |
Well, if I'm about to lose access to a service because my password expires tomorrow, I consider that password "unhealthy" even if it has high entropy. In this regard I'd rather err on the side of caution and report it; also, the current behavior was explicitly requested in the requirements (see comments above).
Assuming that "It" is a typo and you meant "I would suggest", that's exactly how it's implemented now. However, crossing it out additionally would be visual overload IMHO. |
4b37450
to
3462fc2
Compare
Perhaps we can add an "ignore" function to tell KeePassXC to not include certain entries in health reports? |
b753cad
to
f00b337
Compare
I squashed everything and will do a review for merging. |
because it's consistent, not because it's nice. Fixes keepassxreboot#3993
f00b337
to
e3548b0
Compare
We now have two classes, PasswordHealth to deal with a single password and HealthChecker to deal with all passwords of a database. Fixes keepassxreboot#3993
Sorry if this question is a bit stupid, but when is this feature available in the KeePassXC Snapshot Builds (https://snapshot.keepassxc.org/latest/) ? |
When it is merged to the develop branch |
I made several substantive changes. One thing to note, the cache in HealthChecker is never used. We can get rid of it, the checking process is extremely fast even with my main database. |
You're right. I'll remove it because YAGNI. |
As a point of reference please don't merge in develop to feature branches. We prefer to rebase on top of develop. |
because it's consistent, not because it's nice. Fixes keepassxreboot#3993
We now have two classes, PasswordHealth to deal with a single password and HealthChecker to deal with all passwords of a database. Fixes keepassxreboot#3993
7bc4d24
to
e9d37bf
Compare
Removed the cache. I suggest you leave this commit un-squashed so we can recover the cache code in case we need it again in the future. |
Sure that is a good compromise. |
d6fd4f2
to
51cb3f7
Compare
Introduce a password health check to the application that evaluates every entry in a database. Entries that fail various tests are listed for user review and action. Also moves the statistics panel to the new Database -> Reports widget. Recycled entries are excluded from the results. We now have two classes, PasswordHealth to deal with a single password and HealthChecker to deal with all passwords of a database. Tests include passwords that are expired, re-used, and weak. * Closes keepassxreboot#551 * Move zxcvbn usage to a centralized class (PasswordHealth) and replace its usages across the application to ensure standardized interpretation of entropy calculations. * Add new icons for the database reports view * Updated the demo database to show off the reports
The way the class is currently being used, the cache never does anything (because evaluate is never invoked twice for the same entry), so according to YAGNI it has to go. Fixes keepassxreboot#551
51cb3f7
to
ad23628
Compare
Added - Custom Light and Dark themes [#4110, #4769, #4791, #4796, #4892, #4915] - Compact mode to use classic Group and Entry line height [#4910] - View menu to quickly switch themes, compact mode, and toggle UI elements [#4910] - Search for groups and scope search to matched groups [#4705] - Save Database Backup feature [#4550] - Sort entries by "natural order" and move lines up/down [#4357] - Option to launch KeePassXC on system startup/login [#4675] - Caps Lock warning on password input fields [#3646] - Add "Size" column to entry view [#4588] - Browser-like tab experience using Ctrl+[Num] (Alt+[Num] on Linux) [#4063, #4305] - Password Generator: Define additional characters to choose from [#3876] - Reports: Database password health check (offline) [#3993] - Reports: HIBP online service to check for breached passwords [#4438] - Auto-Type: DateTime placeholders [#4409] - Browser: Show group name in results sent to browser extension [#4111] - Browser: Ability to define a custom browser location (macOS and Linux only) [#4148] - Browser: Ability to change root group UUID and inline edit connection ID [#4315, #4591] - CLI: `db-info` command [#4231] - CLI: Use wl-clipboard if xclip is not available (Linux) [#4323] - CLI: Incorporate xclip into snap builds [#4697] - SSH Agent: Key file path env substitution, SSH_AUTH_SOCK override, and connection test [#3769, #3801, #4545] - SSH Agent: Context menu actions to add/remove keys [#4290] Changed - Complete replacement of default database icons [#4699] - Complete replacement of application icons [#4066, #4161, #4203, #4411] - Complete rewrite of documentation and manpages using Asciidoctor [#4937] - Complete refactor of config files; separate between local and roaming [#4665] - Complete refactor of browser integration and proxy code [#4680] - Complete refactor of hardware key integration (YubiKey and OnlyKey) [#4584, #4843] - Significantly improve performance when saving and opening databases [#4309, #4833] - Remove read-only detection for database files [#4508] - Overhaul of password fields and password generator [#4367] - Replace instances of "Master Key" with "Database Credentials" [#4929] - Change settings checkboxes to positive phrasing for consistency [#4715] - Improve UX of using entry actions (focus fix) [#3893] - Set expiration time to Now when enabling entry expiration [#4406] - Always show "New Entry" in context menu [#4617] - Issue warning before adding large attachments [#4651] - Improve importing OPVault [#4630] - Improve AutoOpen capability [#3901, #4752] - Check for updates every 7 days even while still running [#4752] - Improve Windows installer UI/UX [#4675] - Improve config file handling of portable distribution [#4131, #4752] - macOS: Hide dock icon when application is hidden to tray [#4782] - Browser: Use unlock dialog to improve UX of opening a locked database [#3698] - Browser: Improve database and entry settings experience [#4392, #4591] - Browser: Improve confirm access dialog [#2143, #4660] - KeeShare: Improve monitoring file changes of shares [#4720] - CLI: Rename `create` command to `db-create` [#4231] - CLI: Cleanup `db-create` options (`--set-key-file` and `--set-password`) [#4313] - CLI: Use stderr for help text and password prompts [#4086, #4623] - FdoSecrets: Display existing secret service process [#4128] Fixed - Fix changing focus around the main window using tab key [#4641] - Fix search field clearing while still using the application [#4368] - Improve search help widget displaying on macOS and Linux [#4236] - Return keyboard focus after editing an entry [#4287] - Reset database path after failed "Save As" [#4526] - Use SHA256 Digest for Windows code signing [#4129] - Improve handling of ccache when building [#4104, #4335] - macOS: Properly re-hide application window after browser integration and Auto-Type usage [#4909] - Auto-Type: Fix crash when performing on new entry [#4132] - Browser: Send legacy HTTP settings to recycle bin [#4589] - Browser: Fix merging browser keys [#4685] - CLI: Fix encoding when exporting database [#3921] - SSH Agent: Improve reliability and underlying code [#3833, #4256, #4549, #4595] - FdoSecrets: Fix crash when editing settings before service is enabled [#4332]
same question |
It's under Database Reports. |
Type of change
Description and Context
This is the Health Check feature as discussed in #551.
Screenshots
Testing strategy
Tested manually, some unit tests added.
Checklist:
-DWITH_ASAN=ON
. [REQUIRED]