From 6261c95184b86c43755071b351e6928f89e2343c Mon Sep 17 00:00:00 2001 From: Determinant Date: Mon, 10 Sep 2018 16:06:27 -0400 Subject: finish simple multithreaded verifier --- include/hotstuff/consensus.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'include/hotstuff/consensus.h') diff --git a/include/hotstuff/consensus.h b/include/hotstuff/consensus.h index 65ffff2..9e2558c 100644 --- a/include/hotstuff/consensus.h +++ b/include/hotstuff/consensus.h @@ -253,6 +253,13 @@ struct Vote: public Serializable { cert->get_blk_hash() == blk_hash; } + promise_t verify(VeriPool &vpool) const { + assert(hsc != nullptr); + return cert->verify(hsc->get_config().get_pubkey(voter), vpool).then([this](bool result) { + return result && cert->get_blk_hash() == blk_hash; + }); + } + operator std::string () const { DataStream s; s << "