aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2023-03-27 01:51:55 -0500
committerGitHub <noreply@github.com>2023-03-27 01:51:55 -0500
commit8c49b1ea5df2325148a48cb390c75b026c8ea6f9 (patch)
treee1a051db62754e4b8ba5a46cb6cb8c0d39271ecb
parentfbb1634750701e6c98eab6ae2afc6467edc13475 (diff)
parent15613b6620d21fff2e24d966c007aadb14630fdb (diff)
downloadrbw-8c49b1ea5df2325148a48cb390c75b026c8ea6f9.tar.gz
rbw-8c49b1ea5df2325148a48cb390c75b026c8ea6f9.zip
Merge pull request #113 from quexten/fix/argon2-login
Fix argon2 login
-rw-r--r--src/identity.rs4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/identity.rs b/src/identity.rs
index 123dc31..7836a11 100644
--- a/src/identity.rs
+++ b/src/identity.rs
@@ -41,7 +41,6 @@ impl Identity {
hasher.update(email.as_bytes());
let salt = hasher.finalize();
- let mut output_key_material = [0u8];
let argon2_config = argon2::Argon2::new(
argon2::Algorithm::Argon2id,
argon2::Version::V0x13,
@@ -57,10 +56,9 @@ impl Identity {
&argon2_config,
password.password(),
&salt,
- &mut output_key_material,
+ enc_key,
)
.map_err(|_| Error::Argon2)?;
- enc_key.copy_from_slice(&output_key_material);
}
};