Commit Graph

3517 Commits

Author SHA1 Message Date
varjolintu
c0796d8fb1 Add option to use entry only for HTTP Basic Auth 2019-12-21 17:28:27 -05:00
Janek Bevendorff
7f262a1210 Move FeatureSummary include to top of CMakeLists.txt
* Fixes #4024
2019-12-21 17:26:41 -05:00
James Ring
26afdb39d3 Fix crash upon exiting interactive mode if there is no current database. 2019-12-21 10:09:22 -05:00
Chih-Hsuan Yen
794cc1eeab Partial fix for building on Mac OS X < 10.12
This commit reverts #3357.

The previous PR is for the new symbol NSEventMaskKeyDown, which is
introduced in #3347. In #3794, #3347 is reverted, so the workaround
in #3357 is no longer needed. Furthermore, it causes build failures
on 10.11 (#3932) as the header file for type NSEventMask is removed
in #3794, too.

Note that this is not a complete fix. A complete patch can be found
at [1]. In MacPorts, the OS version for building a package is the same
as the OS that installs it, so #ifdef can be used to replace @available.
The latter language feature is not available until Xcode 9.

With the patch mentioned in the previous paragraph, KeePassXC 2.5.1
can be built on Mac OS X 10.9 or newer.

Ref: #2899

[1] de1bb703ad/security/KeePassXC/files/patch-old-mac.diff
2019-12-21 09:25:56 -05:00
Carlo Teubner
c70ebe6dce Fix memory leaks (mostly) in tests (#3922)
This makes most tests run successfully with asan.

The GUI tests still have a bunch of leaks, some from library code, and
some that look real but which I didn't immediately manage to figure out.

* TestOpVaultReader: use QSharedPointer
2019-12-21 09:25:17 -05:00
varjolintu
c0f29cc790 Show UI warning for invalid URLs 2019-12-21 09:22:16 -05:00
varjolintu
663393d994 Remove extra check for additional URLs 2019-12-20 22:17:30 -05:00
Jonathan White
8e76c30dd1 Prevent reloading database while editing an entry or group
* Fix #3933 and  fix #3857. Interaction with entries and groups is disabled while the database is being reloaded or saved to prevent changes from occurring. Prevent the database from being reloading if an entry or group is currently being edited.

* Fix #3941 - Only notify components when the database file actually changes (determined by checksum). This prevents spurious merge requests when the file is merely touched by another service (e.g., DropBox).

* Fix code format of ElidedLabel.cpp
2019-12-14 21:26:12 -05:00
Jonathan White
f9cb2bd5df Correct multiple issues with database saving
* Mark the database as clean after fully completing the file save operation INSTEAD of when merely writing the database to a file.

* Stop the modified timer when marking the database as clean, this prevents latent erroneous modified signals from being emitted.

* Do not restart the modified timer after a new change is detected while it is still running.
2019-12-14 21:26:12 -05:00
Aetf
6dd9702b79 FdoSecrets: handle the exposed group being moved to recycle bin 2019-11-29 08:37:19 -05:00
Balazs Gyurak
9363123047 Add ability to hide a protected attribute after reveal 2019-11-23 10:07:39 -05:00
Balazs Gyurak
c0b1c9e106 Run code formatter 2019-11-23 10:07:39 -05:00
Balazs Gyurak
6c65b486e4 Disable database unlock form while decrypting 2019-11-23 09:56:39 -05:00
Jonathan White
dc6c9186c9 Fix start minimized to tray for unix 2019-11-23 09:53:40 -05:00
Balazs Gyurak
ed60a3dcce HTML encode url in ElidedLabel
* Fix #3905 - prevent double quotes and other invalid HTML characters from impeding on display of url in ElidedLabel
2019-11-23 09:50:22 -05:00
Balazs Gyurak
5c54dfe581 Release database before exiting CLI interactive mode 2019-11-23 08:18:59 -05:00
Balazs Gyurak
697f265249 Correctly initialize standalone PW generator mode 2019-11-23 08:18:51 -05:00
Balazs Gyurak
024e00cc97 Only show warning about snap browsers on Linux 2019-11-23 08:15:58 -05:00
Aetf
a66f8ec04d FdoSecrets: fix crash when enabling the plugin on a non-exposed database 2019-11-23 07:58:39 -05:00
varjolintu
e2c95f75f1 Fix subdomain matching 2019-11-23 07:53:09 -05:00
Sergey Vilgelm
a590289900 Add a new line after in Analyze command
Adding a new line after the message "Evaluating database entries against HIBP file, this will take a while..." helps
to separate a report and the comment.
2019-11-17 22:42:39 -05:00
Janek Bevendorff
0fd883686c
Release 2.5.1
Added

- Add programmatic use of the EntrySearcher [#3760]
- Explicitly clear database memory upon locking even if the object is not deleted immediately [#3824]
- macOS: Add ability to perform notarization of built package [#3827]

Changed

- Reduce file hash checking to every 30 seconds to correct performance issues [#3724]
- Correct formatting of notes in entry preview widget [#3727]
- Improve performance and UX of database statistics page [#3780]
- Improve interface for key file selection to discourage use of the database file [#3807]
- Hide Auto-Type sequences column when not needed [#3794]
- macOS: Revert back to using Carbon API for hotkey detection [#3794]
- CLI: Do not show protected fields by default [#3710]

Fixed

- Secret Service: Correct issues interfacing with various applications [#3761]
- Fix building without additional features [#3693]
- Fix handling TOTP secret keys that require padding [#3764]
- Fix database unlock dialog password field focus [#3764]
- Correctly label open databases as locked on launch [#3764]
- Prevent infinite recursion when two databases AutoOpen each other [#3764]
- Browser: Fix incorrect matching of invalid URLs [#3759]
- Properly stylize the application name on Linux [#3775]
- Show application icon on Plasma Wayland sessions [#3777]
- macOS: Check for Auto-Type permissions on use instead of at launch [#3794]
2019-11-11 20:53:43 +01:00
Janek Bevendorff
db63a40461
Update translations 2019-11-11 20:53:39 +01:00
Janek Bevendorff
90cf5c08ad
Remove explicit PR links from CHANGELOG 2019-11-11 20:51:20 +01:00
Jonathan White
0454f4ea4c Correct finding snapcraft.yaml in release-tool 2019-11-11 11:44:12 -05:00
Jonathan White
d37e71b793 Bump version and update changelog 2019-11-11 11:37:23 -05:00
varjolintu
3d0964bce9 Fix URL matching 2019-11-10 08:43:10 -05:00
dxdc
4437e6a609 Encode trailing equal signs from base32 TOTP key
Fixes #3255
2019-11-10 08:42:50 -05:00
Janek Bevendorff
7659bbb711
Fix release-tool on macOS and add notarization. (#3827) 2019-11-10 00:08:20 +01:00
Jonathan White
a07bae2530 Correct formatting of preview widget fields (#3727)
* Fix #3701 - replace QLabel with QTextEdit to enable scrolling of notes

* Notes are plain text. They will remain as plain text and hyperlinks will not be enabled in the notes. Until the notes editor is moved to a rich text / html editor this will remain the case.

* Convert username and password fields in preview pane to QLineEdit's to allow for full copying and viewing if larger than the field width.
2019-11-09 18:16:05 +01:00
Janek Bevendorff
29ca08f9ff Fix DatabaseUnlockDialog window sizing.
Fixes the default shrink-wrap and wonky upscaling
behaviour of the DatabaseUnlockDialog window.
2019-11-09 10:00:34 -05:00
Jonathan White
d3978980d2 Perform file hash checks asynchronously (#3815) 2019-11-09 14:02:34 +01:00
Jonathan White
7ba9fcc0e5 macOS: Check for Auto-Type permissions on use instead of at launch
* Fix #3689 - link the use of Auto-Type with the permissions required to use it
2019-11-09 13:53:44 +01:00
Jonathan White
440331d319 Revert "Remove Carbon from Mac Auto-Type (#3347)"
This reverts commit ce1f19cacc.
2019-11-09 13:53:44 +01:00
Jonathan White
035823e414 Hide Auto-Type sequences column when unnecessary
* Fix #3688 - hide the sequences column if all of the entry matches return the same sequence. This cleans up redundent data in the Auto-Type selection dialog introduced in 2.5.0.
2019-11-09 13:53:44 +01:00
Janek Bevendorff
5996ba51c9 Use PasswordKey for storing transformed secrets.
The transformed secrets were stored in normal QByteArrays,
which are at risk of being swapped out. We now use secure
PasswordKey objects instead. There are still a few areas
where QByteArrays are used for storing secrets, but since
they are all temporary, they are less critical. It may be
worth hunting those down as well, though.
2019-11-09 11:33:32 +01:00
Janek Bevendorff
22af66e3b5 Ensure database contents are released right away.
When we lock a database, we reset the database pointer to
free its resources. Since various other widgets besides the
DatabaseWidget hold references to the shared pointer object,
however, it cannot be guaranteed that the actual database
object will be freed right away. This patch adds a releaseData()
method which is called upon database lock to ensure all
residual data is cleared without having to rely on the actual
database object being cleaned up.
2019-11-09 11:33:32 +01:00
Jonathan White
87ca7c7f7b Improve UX of database statistics page
* Fix #3766 - move database statistics processing into async task and only perform the calculation when the statistics tab is activated.
2019-11-08 22:24:30 -05:00
Jonathan White
f9d2696046 Relax strictness of TOTP Base32 validation
* Fix #3754 - Accept valid TOTP keys that require padding when converted to Base32.
* Allow use of spaces and lower case letters in the TOTP secret key.
2019-11-09 00:53:40 +01:00
Jonathan White
4edb623745 Prevent recursive loads using AutoOpen
* Fix #3334 - AutoOpen is now processed after the database widget is put into view mode to prevent infinite recursion of unlock attempts if two databases  auto open each other.
2019-11-09 00:53:40 +01:00
Jonathan White
cb9929712c Start Database Widget in view mode
* Fix #3713 - DatabaseWidget starts in locked mode instead of view mode fixing tab names on launch.
2019-11-09 00:53:40 +01:00
Jonathan White
837df4f4cb Fix issues with database unlock
* Fix #3735 - Don't focus on OpenDatabaseWidget fields that are not visible; ensures password field is focused after database lock.

* Fix #3487 - Password input is selected after failed unlock.

* Fix #1938 - Password input is focused after toggling visibility using the keyboard
2019-11-09 00:53:40 +01:00
guihkx
6339d61419 Properly stylize the application name (#3775)
This is just a cosmetic change. On KDE Plasma, the title of the tray icon is set by either the name of the binary, or by calling `setApplicationName()`. So having it properly stylized looks better.
2019-11-08 23:54:56 +01:00
Aetf
f9097c84e9 FdoSecrets: use EntrySearcher's internal search API 2019-11-08 17:37:50 -05:00
Aetf
b96c1e92a3 Expose EntrySearcher's SearchTerm for internal code usage 2019-11-08 17:37:50 -05:00
Aetf
329701a34e Secret Service Integration Fixes (#3761)
* FdoSecrets: create prompt object only when necessary

* FdoSecrets: negotiationOutput should always return a valid QVariant otherwise QDBus will fail to create a reply, causing timeout in client.

* FdoSecrets: include in debug info
2019-11-07 21:28:49 -05:00
Janek Bevendorff
5d2766e016 Make the purpose of the key file field clearer.
The new unlock dialogue seems to confuse users
as to what the purpose of the key file is. This
patch changes the generic "Select file..." affordance
to the more explicit "Select key file..." and adds
a help button to the label just like the one we
already have for the hardware key. Furthermore,
it prevents the user from using the KDBX file as its
own key file (since that would never work anyway).

The change breaks existing translations on purpose
(instead of simply adjusting the en_US locale)
in order to force translators to update this string
for their languages.

Resolves #3678
2019-11-07 21:26:56 -05:00
Elvis Angelaccio
1722397040 Show application icon in Plasma Wayland sessions (#3777)
This is required to show the keepassxc icon on Wayland windows in a
Plasma Wayland session.

kwin_wayland fetches application icons from .desktop files and it
expects the desktop filename to be set on the QGuiApplication instance.

Without this, kwin sets a generic Wayland icon as fallback.
2019-11-03 12:00:16 +01:00
Rafael Sadowski
38a663163d Check include malloc.h and malloc_usable_size(3)
One some operating systems  malloc(3) is not in malloc.h nor in
malloc_np.h, instead it is in stdlib.h.

In addition, not all systems support malloc_usable_size(3). You could
argue it's not safe.

This patch tries to be portable and it fix the build on OpenBSD.
2019-11-01 22:54:24 -04:00
louib
f4d6b4d13a CLI: do not display protected fields by default. 2019-11-01 22:53:54 -04:00