Commit Graph

2927 Commits

Author SHA1 Message Date
Janek Bevendorff
bd654ea1db
Merge pull request #1702 from dwilches/hotfix/1313-grey-out-apply-button
Grey out Apply button when there are no changes
2018-03-31 13:54:43 +02:00
Daniel Wilches
240939ce3b Request confirmation to discard unsaved changes
Solves #1181
2018-03-29 18:35:08 -07:00
Daniel Wilches
78ef6f0d04 Grey out Apply button when there are no changes
Resolves #1313

What this commit does:
* Whenever the Apply button is pressed, and if the save was successful, then the Apply button is disabled.
* Each subwidget used by EditEntryWidget has now a signal called `widgetUpdated` that is emitted when the widgets' internal content changes. The EditEntryWidget subscribes to that signal to know when to enable the Apply button (by calling `entryUpdated()`).
* There are some views that are not isolated in their own widgets (`m_advancedUi`, for example) so in those cases I invoked `entryUpdated()` directly whenever I detected an update:
  * some updates occur directly in a Qt widget like when editing the text of a QLineItem, so in that case I connected the widget's signals directly to the `entryUpdated()` slot.
  * some updates occur in EditEntryWidget, so in those cases the invocation to `entryUpdated()` is made as soon as the change is detected (for example when the user has confirmed an action in a dialog).

A known problem: there are some situations when the Apply button will get enabled even if there are no changes, this is because the app changes the value of a field by itself so it's considered an update (for example, clicking on the "Reveal" button changes the text shown in a text field).
The solution to this can be a bit complicated: disabling temporarily the `entryUpdated()` whenever the app is going to do an action with such side-effects.
So I preferred to let the Apply button get enabled in those cases.
2018-03-29 18:35:08 -07:00
Valeriy Malov
0650b3084e Do not ignore MainWindow closeEvent when closing to tray
Ignoring closeEvent signals that the application doesn't want the widget
to be closed. This may cause unwanted shutdown interruption. There's no
difference between close() and hide() unless WA_DeleteOnClose is set, so
it's better to just accept the event if we're hiding the window
afterwards anyway.

Resolves #856
2018-03-22 12:29:25 +01:00
Janek Bevendorff
e92d5e80ee
Merge branch 'release/2.3.2' into develop 2018-03-18 01:14:42 +01:00
dinony
7e75d04055 Docs (#1749)
Update build instructions
2018-03-18 01:10:00 +01:00
Janek Bevendorff
ed2da34d7a
Merge pull request #1725 from Throne3d/fix/1647-translations
Improve translation base strings
2018-03-18 00:01:27 +01:00
Jonathan White
4a207f079b Enable high entropy ASLR for Windows builds 2018-03-17 12:13:47 -04:00
Piraty
123701080d Keep openSSH-portable's blowfish code unmodified
and use a stub "includes.h".

This also fixes build issues against musl-libc, which does not
implicitly include <sys/types.h>
2018-03-17 11:03:36 +01:00
Olivier Le Moal
3353b329fc Fix wrong reply size in NativeMessagingBase
* Using length() on QString won't return correct size in bytes when string
contains UTF-8 chars.
2018-03-13 22:32:31 +01:00
Edward Jones
963a7802d1 Fix pluralization of confirmation prompts 2018-03-13 20:41:16 +00:00
Edward Jones
e66adfbf68 Make more strings translatable
Includes making certain modifiers (like "[locked]") positionable, in
case languages put this before the word
2018-03-13 20:41:12 +00:00
Edward Jones
3def6a3bc4 Fix weird base strings and reduce concatenation 2018-03-13 20:40:39 +00:00
Edward Jones
e718e9f5e5 Fix file dialog filter translations 2018-03-13 19:55:37 +00:00
Joan Bruguera
970cedf972 Add again wrongly removed conditional macro for Mac.
Add again the wrongly removed conditional macro for Mac, along with a TODO asking for further documentation on its significance.
2018-03-12 21:30:25 +01:00
Joan Bruguera
f305517724 Skip the tray restore/hide test of #1595 if there's no tray (fix CI build). 2018-03-12 21:30:25 +01:00
Joan Bruguera
8646586c1a Add GUI test for issue #1595 (minus the minimize at startup case). 2018-03-12 21:30:25 +01:00
Joan Bruguera
bf9c1b3205 Cover the fix/WA for Linux #1595 behind compile time flags & comment. 2018-03-12 21:30:25 +01:00
Joan Bruguera
467867016d Fix toggle window from tray can't hide the window on Windows (#1595)
Fix unreliable check on toggleWindow() which causes Windows systems to be unable to hide the window by clicking on the tray icon (see issue #1595).
2018-03-12 21:30:25 +01:00
Joan Bruguera
319c8201be Fix flickering & not restoring from tray on some Linuxes (#1595).
Fix/work around KeePassXC flickering and not restoring from tray on some Linux systems, which happens if the window is hidden and minimized by code at the same time (see issue #1595).
2018-03-12 21:30:25 +01:00
varjolintu
f620ad979f Fix extension URL 2018-03-11 10:59:20 -04:00
Thomas Luzat
64f5ee6399 SSH Agent: Helpful error message for adding keys
This adds more helpful error messages when adding keys to an agent
fails.

Closes #1667.
2018-03-11 10:57:30 -04:00
Thomas Luzat
46099fdd71 SSH Agent: Update available attachments immediately
The list of available attachments for SSH agent is now updated
immediately when adding or removing file attachments.

Closes #1668.
2018-03-11 10:57:14 -04:00
Steven Noonan
dc1aead2a2 OpenSSHKey: when writing to agent, ensure comment string is at least one byte
This unbreaks adding keys to gpg-agent.

Signed-off-by: Steven Noonan <steven@uplinklabs.net>
2018-03-10 23:59:37 -05:00
Toni Spets
d156457405 Always hide password on unlock
Fixes #1692
2018-03-10 23:54:12 -05:00
Janek Bevendorff
2b91e4d27c Fix inconsistent mutex unlocking due to double slot execution, fixes #1561 2018-03-10 10:52:18 +01:00
Alessio Di Mauro
f164847f9b Replace in.readLine() with Utils::getPassword()
Fixes #1673.
2018-03-09 11:21:58 +01:00
Thomas Luzat
082ecc3f37 Fix dark tray icon option making all icons dark
Introduces a separate path for tray icons which are neither locked nor
unlocked.

Closes #1556.
2018-03-08 21:34:15 +01:00
Thomas Luzat
46e8e3dbbc Test speedup (#1678)
* Tests: Speed up AutoType testing

Decrease default autotype delay to 1 to improve test suite speed by
seconds. This shaves multiple seconds off the whole test suite. In some
cases, the largest part.

Also, initialize config just creating the test instance, just in case
that it ever depends on the configuration values at that point already.

* Tests: Speed up Kdbx4 testing

This speeds up the Kdbx4 tests by using parameters optimized for speed
for the key derivation functions. On an i7-6700K the tests run close to
50% faster with this change (about 1.5s vs. 3s).
2018-03-08 10:20:25 +01:00
Janek Bevendorff
aa6327716f
Merge branch 'master' into develop 2018-03-06 22:56:18 +01:00
Janek Bevendorff
2fcaeeaec8
Release 2.3.1
- Fix unnecessary automatic upgrade to KDBX 4.0 and prevent challenge-response key being stripped [#1568]
- Abort saving and show an error message when challenge-response fails [#1659]
- Support inner stream protection on all string attributes [#1646]
- Fix favicon downloads not finishing on some websites [#1657]
- Fix freeze due to invalid STDIN data [#1628]
- Correct issue with encrypted RSA SSH keys [#1587]
- Fix crash on macOS due to QTBUG-54832 [#1607]
- Show error message if ssh-agent communication fails [#1614]
- Fix --pw-stdin and filename parameters being ignored [#1608]
- Fix Auto-Type syntax check not allowing spaces and special characters [#1626]
- Fix reference placeholders in combination with Auto-Type [#1649]
- Fix qtbase translations not being loaded [#1611]
- Fix startup crash on Windows due to missing SVG libraries [#1662]
- Correct database tab order regression [#1610]
- Fix GCC 8 compilation error [#1612]
- Fix copying of advanced attributes on KDE [#1640]
- Fix member initialization of CategoryListWidgetDelegate [#1613]
- Fix inconsistent toolbar icon sizes and provide higher-quality icons [#1616]
- Improve preview panel geometry [#1609]
2018-03-06 22:54:58 +01:00
Janek Bevendorff
d68d41a878
Update translations 2018-03-06 22:54:54 +01:00
Janek Bevendorff
642daa641b
Bump version to 2.3.1 and update CHANGELOG 2018-03-06 22:54:01 +01:00
Janek Bevendorff
323c271d01 Remove qsvg imageformat plugin to prevent crash when trying to load SVG icons, resolves #1602 2018-03-06 22:23:52 +01:00
Janek Bevendorff
2f821af0a0 Raise error if challenge-response failed during KDBX4 key transformation, resolves #1656 2018-03-06 22:08:09 +01:00
Janek Bevendorff
63a17f697c Fix freeze and high CPU usage on invalid STDIN data, resolves #1620 2018-03-06 21:55:32 +01:00
Steven Noonan
386b78b896 attributes: unbreak copy-to-clipboard on KDE
The 'text' property of the QAction gets mangled by KDE when it adds its
own accelerator shortcuts. But the data property is ours. Use that for
keying instead.

Signed-off-by: Steven Noonan <steven@uplinklabs.net>
2018-03-06 19:22:38 +01:00
Thomas Luzat
4c9dcf5c98 KdbxXmlReader: Support Protected attribute on most nodes
Similar to KeePass2 most elements are checked for a

Protected="True"

attribute. Previously, files KDBX 3.1 files with protected Binary
entries, as seen in the wild, could not be read (mangled passwords and
file attachments).
2018-03-06 19:11:10 +01:00
Toni Spets
084758908a SSH Agent: Show error messages if something fails 2018-03-06 18:59:42 +01:00
Janek Bevendorff
4ce0005711
Merge pull request #1657 from keepassxreboot/hotfix/1573-curl-download-hang
Add User-Agent header and set request timeout to avoid infinite download hangs
2018-03-06 17:13:14 +01:00
Janek Bevendorff
63d34ac348 Add User-Agent header and set request timeout to avoid infinite download hangs
Resolves #1573, resolves #1645
2018-03-06 16:06:44 +01:00
thez3ro
10170a555e add test case for recursive placeholders 2018-03-06 15:56:27 +01:00
Benoit Mortgat
18628612b2 Allow references in part of a field
When a field value is of the form ...{REF:...}...
Then:

* Auto-type does not work with that field
* References to this field are not properly resolved

This commit fixes both issues.
2018-03-05 23:31:29 +01:00
Janek Bevendorff
83974732f3
Merge pull request #1641 from tycho/lto-fixup
KdbxReader::readDatabase: abort if reading magic numbers fails
2018-03-05 20:31:51 +01:00
Steven Noonan
cdd6852709
KdbxReader::readDatabase: abort if reading magic numbers fails
Building with -flto caught the fact that we were ignoring the return
value of readMagicNumbers(), which potentially left the value of 'sig2'
uninitialized.

Signed-off-by: Steven Noonan <steven@uplinklabs.net>
2018-03-05 09:12:22 -08:00
thez3ro
5f9f27604b fix autotype custom attributes 2018-03-04 23:08:58 +01:00
Janek Bevendorff
d3a80513a7 Fix GCC 8 memset warning and set -Werror only for debug builds, resolves #1558 2018-03-04 21:18:13 +01:00
Janek Bevendorff
02b923b0e5 Make cipher and KDF settings properly translatable 2018-03-04 21:01:00 +01:00
Janek Bevendorff
2fd2085bb5 Fix qtbase translations not being loaded (regression) 2018-03-04 21:01:00 +01:00
Janek Bevendorff
df185b4343 Add more 32x32 icons 2018-03-04 18:43:27 +01:00