Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/keepassxreboot/keepassxc.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJanek Bevendorff <janek@jbev.net>2017-12-27 16:20:28 +0300
committerJonathan White <droidmonkey@users.noreply.github.com>2018-01-15 02:26:28 +0300
commit871332ecf0603c46c020482553c6420e1c18943f (patch)
tree6567cf3e14742e58a1ddbfccebaa5ff23a6bdc19 /src/keys/FileKey.h
parent21a6c0fd89cf44179281feca1ae923c45fc313aa (diff)
Add warning when using legacy key file formats.
Diffstat (limited to 'src/keys/FileKey.h')
-rw-r--r--src/keys/FileKey.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/keys/FileKey.h b/src/keys/FileKey.h
index af324e530..2aa48909b 100644
--- a/src/keys/FileKey.h
+++ b/src/keys/FileKey.h
@@ -28,10 +28,19 @@ class QIODevice;
class FileKey: public Key
{
public:
+ enum Type {
+ None,
+ Hashed,
+ KeePass2XML,
+ FixedBinary,
+ FixedBinaryHex
+ };
+
bool load(QIODevice* device);
bool load(const QString& fileName, QString* errorMsg = nullptr);
QByteArray rawKey() const override;
FileKey* clone() const override;
+ Type type() const;
static void create(QIODevice* device, int size = 128);
static bool create(const QString& fileName, QString* errorMsg = nullptr, int size = 128);
@@ -44,6 +53,7 @@ private:
bool loadHashed(QIODevice* device);
QByteArray m_key;
+ Type m_type = None;
};
#endif // KEEPASSX_FILEKEY_H