diff options
author | Justus Winter <justus@sequoia-pgp.org> | 2019-12-13 15:19:33 +0100 |
---|---|---|
committer | Justus Winter <justus@sequoia-pgp.org> | 2019-12-13 16:37:02 +0100 |
commit | 87f175aacd370e3bf8e1d736a51e3710f7142506 (patch) | |
tree | 65e878e6ea01cbcdfa824623245a7c9c1f6cace9 /sqv/src/sqv.rs | |
parent | d79335f8572090109cb131f91269471bd54d3ba0 (diff) |
openpgp: Make Signature4::set_computed_hash private.
Diffstat (limited to 'sqv/src/sqv.rs')
-rw-r--r-- | sqv/src/sqv.rs | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/sqv/src/sqv.rs b/sqv/src/sqv.rs index b2eecdda..c1d83195 100644 --- a/sqv/src/sqv.rs +++ b/sqv/src/sqv.rs @@ -227,7 +227,7 @@ fn real_main() -> Result<(), failure::Error> { // Verify the signatures. let mut sigs_seen_from_cert = HashSet::new(); let mut good = 0; - 'sig_loop: for (mut sig, issuer) in sigs.into_iter() { + 'sig_loop: for (sig, issuer) in sigs.into_iter() { if trace { eprintln!("Checking signature allegedly issued by {}.", issuer); } @@ -260,9 +260,7 @@ fn real_main() -> Result<(), failure::Error> { let mut digest = vec![0u8; hash.digest_size()]; hash.digest(&mut digest); - sig.set_computed_hash(Some(digest)); - - match sig.verify(key) { + match sig.verify_digest(key, &digest[..]) { Ok(true) => { if let Some(t) = sig.signature_creation_time() { if let Some(not_before) = not_before { |