aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authordec05eba <dec05eba@protonmail.com>2018-10-19 05:05:28 +0200
committerdec05eba <dec05eba@protonmail.com>2020-08-18 23:25:46 +0200
commitf1fca53a784b2a1d40d20059073b54ed4c49565e (patch)
treec0bfa0ff2abae8da5d6c04ae1b496a3d465e49ab /src
parent11c80ea37da9abae92337eeadbc9f5edca5a1498 (diff)
Fix password salt not stored, generating a new salt everytime
Diffstat (limited to 'src')
-rw-r--r--src/DatabaseStorage.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/DatabaseStorage.cpp b/src/DatabaseStorage.cpp
index 14b74e8..de9d0df 100644
--- a/src/DatabaseStorage.cpp
+++ b/src/DatabaseStorage.cpp
@@ -158,6 +158,7 @@ namespace odhtdb
metadataSerializer.add(STORAGE_VERSION);
randombytes_buf(passwordSalt, PASSWORD_SALT_LEN);
metadataSerializer.add(passwordSalt, PASSWORD_SALT_LEN);
+ fileOverwrite(metadataFilePath, { metadataSerializer.getBuffer().data(), metadataSerializer.getBuffer().size() });
}
catch(sibs::DeserializeException &e)
{