diff options
author | Justus Winter <justus@sequoia-pgp.org> | 2019-12-13 14:51:09 +0100 |
---|---|---|
committer | Justus Winter <justus@sequoia-pgp.org> | 2019-12-13 14:51:09 +0100 |
commit | 3f46ca0bc5cb3ad1e38874c5ad72dce15825a58f (patch) | |
tree | a7ba3778f07a67a454c6e70cfbc01ffff1d7faba /sqv | |
parent | 9cb6caf33bd4176401de824a74c05a38d3eef2b5 (diff) |
openpgp: Remove hash algorithm from computed hash.
- The signature knows the hash algorithm.
Diffstat (limited to 'sqv')
-rw-r--r-- | sqv/src/sqv.rs | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/sqv/src/sqv.rs b/sqv/src/sqv.rs index 4b640a42..b2eecdda 100644 --- a/sqv/src/sqv.rs +++ b/sqv/src/sqv.rs @@ -260,8 +260,7 @@ fn real_main() -> Result<(), failure::Error> { let mut digest = vec![0u8; hash.digest_size()]; hash.digest(&mut digest); - let hash_algo = sig.hash_algo(); - sig.set_computed_hash(Some((hash_algo, digest))); + sig.set_computed_hash(Some(digest)); match sig.verify(key) { Ok(true) => { |