mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-08-02 19:46:06 -04:00
Correctly set KDBX envelope version
Shows a warning when trying to open with a newer minor version than what is currently supported. We always try to save with the lowest KDBX version possible for maximum compatibility.
This commit is contained in:
parent
67603ab42e
commit
a3dc977e58
30 changed files with 209 additions and 162 deletions
|
@ -87,7 +87,7 @@ void TestKdbx2::testFormat200Upgrade()
|
|||
reader.readDatabase(filename, key, db.data());
|
||||
QVERIFY2(!reader.hasError(), reader.errorString().toStdString().c_str());
|
||||
QVERIFY(!db.isNull());
|
||||
QCOMPARE(reader.version(), KeePass2::FILE_VERSION_2 & KeePass2::FILE_VERSION_CRITICAL_MASK);
|
||||
QCOMPARE(reader.version(), KeePass2::FILE_VERSION_2);
|
||||
QCOMPARE(db->kdf()->uuid(), KeePass2::KDF_AES_KDBX3);
|
||||
|
||||
QBuffer buffer;
|
||||
|
@ -110,6 +110,6 @@ void TestKdbx2::testFormat200Upgrade()
|
|||
|
||||
// database should now be upgraded to KDBX 3 without data loss
|
||||
verifyKdbx2Db(targetDb);
|
||||
QCOMPARE(reader.version(), KeePass2::FILE_VERSION_3_1 & KeePass2::FILE_VERSION_CRITICAL_MASK);
|
||||
QCOMPARE(reader.version(), KeePass2::FILE_VERSION_3_1);
|
||||
QCOMPARE(targetDb->kdf()->uuid(), KeePass2::KDF_AES_KDBX3);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue