aboutsummaryrefslogtreecommitdiffstats
path: root/src/identity.rs
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2023-03-09 20:43:27 -0500
committerJesse Luehrs <doy@tozt.net>2023-03-09 20:55:01 -0500
commitbe2e4aa459222a8194163fff92ccbedcafd6cb19 (patch)
tree79ee6a74f8061ccf46b09baaf8715f56e2f2f3fb /src/identity.rs
parent7729e435241f16e4707fe858c6ace15bd6049c34 (diff)
downloadrbw-be2e4aa459222a8194163fff92ccbedcafd6cb19.tar.gz
rbw-be2e4aa459222a8194163fff92ccbedcafd6cb19.zip
bump deps
Diffstat (limited to 'src/identity.rs')
-rw-r--r--src/identity.rs6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/identity.rs b/src/identity.rs
index 90d4fad..8a5dc61 100644
--- a/src/identity.rs
+++ b/src/identity.rs
@@ -24,7 +24,8 @@ impl Identity {
email.as_bytes(),
iterations.get(),
enc_key,
- );
+ )
+ .map_err(|_| Error::Pbkdf2)?;
let mut hash = crate::locked::Vec::new();
hash.extend(std::iter::repeat(0).take(32));
@@ -33,7 +34,8 @@ impl Identity {
password.password(),
1,
hash.data_mut(),
- );
+ )
+ .map_err(|_| Error::Pbkdf2)?;
let hkdf = hkdf::Hkdf::<sha2::Sha256>::from_prk(enc_key)
.map_err(|_| Error::HkdfExpand)?;