Kagome
Polkadot Runtime Engine in C++17
vote_crypto_provider.hpp
Go to the documentation of this file.
1 
6 #ifndef KAGOME_CORE_CONSENSUS_GRANDPA_VOTE_CRYPTO_PROVIDER_HPP
7 #define KAGOME_CORE_CONSENSUS_GRANDPA_VOTE_CRYPTO_PROVIDER_HPP
8 
10 
12 
17  public:
18  virtual ~VoteCryptoProvider() = default;
19 
20  virtual bool verifyPrimaryPropose(
21  const SignedMessage &primary_propose) const = 0;
22  virtual bool verifyPrevote(const SignedMessage &prevote) const = 0;
23  virtual bool verifyPrecommit(const SignedMessage &precommit) const = 0;
24 
25  virtual std::optional<SignedMessage> signPrimaryPropose(
26  const PrimaryPropose &primary_propose) const = 0;
27  virtual std::optional<SignedMessage> signPrevote(
28  const Prevote &prevote) const = 0;
29  virtual std::optional<SignedMessage> signPrecommit(
30  const Precommit &precommit) const = 0;
31  };
32 
33 } // namespace kagome::consensus::grandpa
34 
35 #endif // KAGOME_CORE_CONSENSUS_GRANDPA_VOTE_CRYPTO_PROVIDER_HPP
virtual std::optional< SignedMessage > signPrimaryPropose(const PrimaryPropose &primary_propose) const =0
virtual bool verifyPrecommit(const SignedMessage &precommit) const =0
virtual bool verifyPrevote(const SignedMessage &prevote) const =0
virtual bool verifyPrimaryPropose(const SignedMessage &primary_propose) const =0
virtual std::optional< SignedMessage > signPrecommit(const Precommit &precommit) const =0
virtual std::optional< SignedMessage > signPrevote(const Prevote &prevote) const =0