Skip to content

Commit 7f5a2ea

Browse files
kwallet: Replace md5 crate with the other one used in the workspace
1 parent ffe045e commit 7f5a2ea

3 files changed

Lines changed: 4 additions & 9 deletions

File tree

Cargo.lock

Lines changed: 1 addition & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

kwallet/parser/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ exclude.workspace = true
1616
blowfish = "0.9"
1717
cbc = "0.1"
1818
ecb = "0.1"
19-
md5 = "0.7"
19+
md-5 = "0.10"
2020
sha1 = "0.10"
2121
sha2 = "0.10"
2222
pbkdf2 = { version = "0.12", default-features = false, features = ["simple"] }

kwallet/parser/src/crypto.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,8 @@ fn validate_sha1(data: &[u8], expected_hash: &[u8]) -> Result<()> {
222222

223223
/// Compute MD5 hash
224224
pub fn compute_md5(data: &[u8]) -> [u8; 16] {
225-
md5::compute(data).into()
225+
use md5::Digest;
226+
md5::Md5::digest(data).into()
226227
}
227228

228229
/// Extract wallet data from decrypted payload and validate SHA-1 hash

0 commit comments

Comments
 (0)