123 Commits

Author SHA1 Message Date
Adrian Martin
ea2f17b9a9
Feature: HTML export from CLI tool (#11590)
This commit introduces support for exporting a KeePassXC database in
HTML format via the CLI tool. The key changes include:
- Refactoring HtmlExporter:
  - Moved HtmlExporter to the format directory and made its API
    compatible with CsvExporter.
  - Since the original HtmlExporter had a direct dependency on the
    gui/Icons functions and indirect dependencies on the
    gui/DatabaseIcons class, only the non-GUI parts were moved to
    format/HtmlExporter.
  - All icon-related functionality was encapsulated in a new child
    class, gui/HtmlGuiExporter.
    - The gui/HtmlGuiExporter retains the original functionality of the
      HtmlExporter class.
    - The format/HtmlExporter now generates HTML export without icons.
      Adding icon support to format/HtmlExporter would require moving
      icon management logic to the core, which could have broader
      implications.
- CLI integration:
  - Updated cli/Export to use format/HtmlExporter.
- GUI Integration:
  - Updated gui/export/ExportDialog to use gui/HtmlGuiExporter.
- Build System Updates:
  - Updated CMakeLists.txt to build HtmlExporter as part of core_SOURCES
    and HtmlGuiExporter as part of gui_SOURCES.
- Testing:
  - Updated TestCli to automatically verify the output of the HTML
    export.

Signed-off-by: AdriandMartin <adriandmartin@protonmail.com>
2025-02-23 16:19:13 -05:00
Jonathan White
903b8f189e
Improve browser notice about snap/flatpak support 2025-02-22 20:45:19 -05:00
Jonathan White
43205995c6
Remove remote database code
This should not have been backported to 2.7.x branch
2025-02-22 12:56:00 -05:00
Jonathan White
3b2f54daff
Show database public icon on tab when visible (#11725)
* Show database public icon on tab when visible

* Remove unnecessary assert
2025-02-10 19:18:11 -05:00
outfoxxed
3083626bda
Add --minimized CLI option 2025-02-10 19:17:54 -05:00
Jonathan White
5ad6562578
Refactor Database Settings (#9485)
Includes following changes:

* Encryption Settings now has a similar key with the new database wizard for switching between Advanced and Simple Settings
* The extra UI layer DatabaseSettingsDialog.ui has been removed. DatabaseSettingsDialog class now inherits EditWidget instead of DialogyWidget (just like Application Settings).
* Extra classes for separate page settings (DatabaseSettingsPageFdoSecrets, DatabaseSettingsPageKeeShare) have been removed. Instead the widgets are used directly in DatabaseSettingsDialog. Same could be done later to Application

---------

Co-authored-by: Jonathan White <support@dmapps.us>
2025-02-10 19:16:31 -05:00
Jonathan White
f48dcb3dba
Implement function to clear all ssh-agent identities (#10649)
Fixes #8346

---------

Co-authored-by: Jonathan White <support@dmapps.us>
2025-02-02 09:47:00 -05:00
Jonathan White
57235219f2
Fix issues with reloading and handling of externally modified db file (#10612)
Fixes #5290
Fixes #9062
Fixes #8545

* Fix data loss on failed reload

- External modifications to the db file can no longer be missed.
- Fixed dialogFinished signal of DatabaseOpenDialog was not emitted when dialog was closed via the 'X' (close) button
- For reloading with a modified db, an additional choice has been added to allow the user to ignore the changes in the file on disk.
- User is now presented with an unlock database dialog if reload fails to open the db automatically. For example when the user removed the YubiKey, failed to touch the YubiKey within the timeout period, or db pw has been changed.
- Mark db as modified when db file is gone or invalid.
- Prevent saving when db is being reloaded
- If merge is triggered by a save action, continue on with the save action after the user makes their choice

---------

Co-authored-by: vuurvlieg <vuurvli3g@protonmail.com>
Co-authored-by: Jonathan White <support@dmapps.us>
2025-02-02 09:43:02 -05:00
Jonathan White
4e40a7fd79
Allow adjusting application font size
* Closes #6822
* Fix fixed font not following default font's point size
2025-02-02 09:27:11 -05:00
xavives
6cc6e42542
Add Group Path column choice in entry view
* Closes #9574
2025-01-19 09:35:04 -05:00
Felix Nüsse
e82e9dad3b
Show Row-Backgroundcolor in a column
Fixes #6553

Allow users to choose to show the entry background color as a column instead of changing the background of the entire row.
2025-01-19 09:32:12 -05:00
Jonathan White
fbad1b51f0
Add ability to expire entries from context menus (#8731)
Closes #1972

Add ability to immediately expire an entry from the context menu

---------
Co-authored-by: Jonathan White <support@dmapps.us>
2025-01-19 09:29:47 -05:00
varjolintu
abf5a2ef8b
Fix setting window title as modified 2025-01-19 09:28:42 -05:00
Kuznetsov Oleg
99c8936568
Add New/Preview Entry Attachments dialog and functionality (#11637)
Closes #11506
Closes #3383

* This change adds a new opportunity to add attachments that don’t require a real file in the file system.
* Add a new dialog window to add and preview attachments and integrate it into the EntryAttachmentsWidget.
* Attachment preview support for images and plain text files.

Additional enhancements:
* Fix sizing of attachment columns
* Add padding to attachment table items
* Fix targeting of preview widget styling to not impact unintended children
2025-01-19 09:28:36 -05:00
Jonathan White
080e315a09
Add Proton Pass importer
* Closes #10465
2025-01-03 18:30:24 -05:00
Kuznetsov Oleg
8a3de7334b
Show a clear error if no slots on hardware key(s) are configured (#11609)
Fixes #11543

Also fix delayed polling on window activation

---------

Co-authored-by: w15dev <w15developer@proton.me>
Co-authored-by: Jonathan White <support@dmapps.us>
2025-01-03 18:20:11 -05:00
Stephan Heffner
12b2360855
Passphrase "MIXED case" Type (#11255)
* An additional approach to create passphrases with one random word being in UPPERCASE.
* Also remove duplicate character count from passphrase generator

---------

Co-authored-by: Stephan Heffner <stephan@heffner.it>
Co-authored-by: Jonathan White <support@dmapps.us>
2025-01-03 18:19:48 -05:00
Jonathan White
241155e64d
Implement T-CONV and T-REPLACE-RX entry placeholders
* Closes #7293
* Move existing T-CONV and T-REPLACE-RX code from AutoType to Entry. Replumb AutoType to use the entry functions.
* Improve placeholder code in various place
2024-12-21 23:41:46 -05:00
Jonathan White
c12b0c5568
Improve related splitter UX
* Prevent group pane from being hidden just by dragging. Introduce new View menu setting to hide the group pane.
* Replace the preview panel "close" icon with a "collapse down" icon making the intention clearer.
* Better organize the view menu
2024-12-21 23:25:45 -05:00
Sami Vänttinen
383c6d05d1
Support passkeys with Bitwarden import (#11401) 2024-12-21 23:25:15 -05:00
Jonathan White
06699c6692
Add option to disable opening a browser window when double-clicking the "URL" column (#11332) 2024-10-12 07:45:39 -04:00
Jonathan White
0731a64957
Add database name, color, and icon options for unlock view (#10819)
Closes #10783

Adds three database configuration options (stored as public custom data) that allow a database to have a public name/summary, color, and/or icon to be displayed on the unlock screen. This information is configured in the Database Settings and stored in the database public custom data (ie, unencrypted).

The name/summary is stored in KPXC_PUBLIC_NAME, the color is stored in KPXC_PUBLIC_COLOR, and the icon is stored in KPXC_PUBLIC_ICON.

---------

Co-authored-by: Jonathan White <support@dmapps.us>
2024-10-07 23:47:40 -04:00
Jonathan White
3c26709da9
Overhaul action states and add icons to toolbar
* Fixes #10981
2024-10-07 18:07:15 -04:00
Jonathan White
413eec9b8c
Add Import/Export to application settings
* Closes #9452 - add import/export buttons to application settings

* Fixes #11120 - duplicate both menubar and toolbar visibility settings into the application settings

* Fixes #8561 - improve placement of various settings between General and Security pages

* Improve tool tip for backup database setting
* Improve wording of various settings
2024-10-07 17:49:58 -04:00
Jonathan White
94eb3ffa7a
Minor UI fixes
* Fixes #11044 - password generator excluded characters tooltip was incorrect

* Fixes #11084 - allow more than 30 days for showing expiring passwords. Also fix the ability to properly translate this control.

* Fixes #11212 - don't show password on creating new database

* Fixes #10726 - improve indication of hardware key polling. Also improve layout spacing of unlock dialog.

* Fixes #11142 - provide better link for challenge-response information
2024-10-07 17:48:53 -04:00
varjolintu
292046ff7f
Allow deleting extension plugin data from Browser Statistics 2024-09-13 22:48:51 -04:00
Jonathan White
ad9ef88e15
Prevent duplicate entries in passphrase wordlists
Replace a QVector for the wordlist with a QSet. This removes all duplicate entries in a given wordlist.
Thus, it hinders a malicious wordlist that has the proper length (>4000 entries) but with repetitions (effectively << 4000 entries) to be used and potentially create weaker passphrases than estimated.

Example:
List with 4000 items but only 64 unique words would lead to only 48 bit of Entropy instead of ~95 bit!
2024-09-13 22:48:16 -04:00
Felix Nüsse
8bdbccf13f
Use Icons for password strength (#9844)
---------

Co-authored-by: Jonathan White <support@dmapps.us>
2024-08-13 22:48:59 -04:00
Sami Vänttinen
e565f89d47
Add option to disable database lock when switching user on macOS (#9707) 2024-08-13 22:37:30 -04:00
Jonathan White
3d66618818
Refactor browser Access Control Dialog (#9607) 2024-08-13 22:35:16 -04:00
StoyanDimitrov
8599f0903c
Fix typos in tooltips from EditEntryWidgetBrowser.ui 2024-07-02 06:53:13 -04:00
Jonathan White
ff89a05743
Show character count in password generator dialog (#10940)
Displays the number of characters in the password field in the password generator dialog. This fixes #10858.
2024-06-30 22:22:59 -04:00
James Carroll
ee08ef421d
Snap: Improve Web-browser Native Messaging host functionality (#10906)
* Snap: Improve Web-browser Native Messaging host functionality

This commit allows for the snap distribution of KeepassXC to self-manage native messaging manifests
This is done by making the binary aware of the snapd environment changes that currently prevent this.
Furthermore, the snap sandbox is expanded to the bare minimum needed to access these privileged files.

Please note if running a self-compiled / untrusted KeepassXC snap build (I.E, installed with --dangerous)
that you must manually run `sudo snap connect keepassxc:browser-native-messaging` to grant permissions.

This will work on all distributions that expose `/snap/bin/` - such as Ubuntu, Debian, etc.
For systems which don't provide `/snap/`, such as Fedora, follow instructions for enabling "Classic" snaps.
e.g., `sudo ln -s /var/lib/snapd/snap /snap`

---------

Co-authored-by: Jonathan White <support@dmapps.us>
2024-06-19 15:50:52 -04:00
Jonathan White
ed3f7f5a16
Improve overall database settings behavior
* Fixes #10723 - only display password strength warning when actively editing the password
* Also improve behavior of minimum quality warning
* Improve behavior and handling of password changes with the database settings dialog
* Prevents loss of newly entered password when toggling between elements in the settings page
* On error, switch to tab that prevents saving database settings for easier correction
2024-06-16 17:19:57 -04:00
Jonathan White
c3259b2610
Improve CSV import when title field isn't specified
* Fixes #10433
2024-06-16 17:11:33 -04:00
Jonathan White
0aba77ee55
Improve handling of encrypted Bitwarden json
* Fixes #10785
2024-06-16 17:11:13 -04:00
Jonathan White
6fbab25478
Add action item for removing a passkey from entry (#10777) 2024-06-02 07:38:03 -04:00
Jonathan White
1b3abf8ab0
Fix SSH Agent broken decrypt button (#10638)
* SSH Agent: Fix broken decrypt button (Fixes #10637)

---------

Co-authored-by: Jonathan White <support@dmapps.us>
2024-06-02 07:35:25 -04:00
Jonathan White
c9d71e7781
Passkeys: Register to an existing entry 2024-05-05 16:07:00 -04:00
egglessness
8c91836038
Add configurable password strength check on database password (#9782)
* Set default value of DatabasePasswordMinimumQuality to 3 (do not accept a master password that is less than Good)

* Add custom message box button "Continue with weak password"
2024-04-29 17:26:06 -04:00
Jonathan White
d14821fb16
Bitwarden and 1PUX importer improvements
* Fixes #10400
  - Support TOTP entries with bare secrets instead of otpauth urls for Bitwarden. Vice-versa for 1PUX.
  - Support Bitwarden Argon2id encryption scheme

* Fixes #10380 - Support Bitwarden organization collections
2024-04-29 09:53:31 -04:00
Jonathan White
d7c054e9b2
Correct minor issues in translations 2024-04-29 09:51:52 -04:00
Jonathan White
3b8dc028c1
Improve database encryption settings UX
Fixes #6190

Remove the advanced settings checkbox and replace with a dedicated tab widget interface to toggle between basic and advanced encryption settings.
2024-04-28 23:41:45 -04:00
Jonathan White
bab48b42f7
Add auto-save delay per database (#9100)
Add a new propery autosaveDelay in Metadata of the db.
The property is saved in customData to not affect database structure as this setting is unique to keepasxc.
The propery sets delay to wait since last modification before saving.

Co-authored-by: jNullj <jNullj@users.noreply.github.com>
2024-04-28 23:41:45 -04:00
Jonathan White
775efc65ed
QMenubar option to show/hide itself (#10341)
--------

Co-authored-by: Mikko Saarinki <mikko.saarinki@michaelkingston.fi>
Co-authored-by: Jonathan White <support@dmapps.us>
2024-04-28 23:41:44 -04:00
Jonathan White
651bcfc904
Remove password repeat application setting
* This removes the application setting to require typing the password in again even though it is visible.
* Removed automatic password repeat when the password is made visible on changing.
2024-04-28 23:41:44 -04:00
Sami Vänttinen
a5c3bf6d9d
Passkeys: Add warning on export (#10411) 2024-04-27 23:20:23 -04:00
Jonathan White
18cfbf729c Add 1Password 1PUX and Bitwarden JSON Importers
* Closes #7545 - Support 1Password 1PUX import format based on https://support.1password.com/1pux-format/

* Closes #8367 - Support Bitwarden JSON import format (both unencrypted and encrypted) based on https://bitwarden.com/help/encrypted-export/

* Fixes #9577 - OPVault import when fields have the same name or type

* Introduce the import wizard to handle all import tasks (CSV, KDBX1, OPVault, 1PUX, JSON)

* Clean up CSV parser code to make it much more efficient and easier to read

* Combine all importer tests (except CSV) into one test file
2024-03-09 15:21:46 -05:00
Jonathan White
f20b531430 Automatically detect USB device changes 2024-03-09 15:21:46 -05:00
Jonathan White
b7a1c620e4 Passkeys improvements (#10318)
Refactors the Passkey implementation to include more checks and a structure that is more aligned with the official specification.
Notable changes:
- _BrowserService_ no longer does the checks by itself. A new class _BrowserPasskeysClient_ constructs the relevant objects, acting as a client. _BrowserService_ only acts as a bridge between the client and _BrowserPasskeys_ (authenticator) and calls the relevant popups for user interaction.
- A new helper class _PasskeyUtils_ includes the actual checks and parses the objects.
- _BrowserPasskeys_ is pretty much intact, but some functions have been moved to PasskeyUtils.
- Fixes Ed25519 encoding in _BrowserCBOR_.
- Adds new error messages.
- User confirmation for Passkey retrieval is also asked even if `discouraged` is used. This goes against the specification, but currently there's no other way to verify the user.
- `cross-platform` is also accepted for compatibility. This could be removed if there's a potential issue with it.
- Extension data is now handled correctly during Authentication.
- Allowed and excluded credentials are now handled correctly.
- `KPEX_PASSKEY_GENERATED_USER_ID` is renamed to `KPEX_PASSKEY_CREDENTIAL_ID`
- Adds a new option "Allow localhost with Passkeys" to Browser Integration -> Advanced tab. By default it's not allowed to access HTTP sites, but `http://localhost` can be allowed for debugging and testing purposes for local servers.
- Add tag `Passkey` to a Passkey entry, or an entry with an imported Passkey.

Fixes #10287.
2024-03-09 15:21:46 -05:00