6 #ifndef IROHA_CRYPTO_MODEL_SIGNER_HPP_ 7 #define IROHA_CRYPTO_MODEL_SIGNER_HPP_ 18 template <
typename Algorithm = CryptoSigner>
27 inline void sign(T &signable)
const noexcept {
30 signable.addSignature(SignedHexStringView{signature_hex},
31 PublicKeyHexStringView{keypair_.publicKey()});
35 sign<interface::Block>(m);
42 template <
typename Algorithm>
45 : keypair_(keypair) {}
50 #endif // IROHA_CRYPTO_MODEL_SIGNER_HPP_ Definition: keypair.hpp:19
void sign(T &signable) const noexcept
Definition: crypto_model_signer.hpp:27
sig_t sign(const uint8_t *msg, size_t msgsize, const pubkey_t &pub, const privkey_t &priv)
Definition: ed25519_impl.cpp:19
virtual ~CryptoModelSigner()=default
void sign(interface::Block &m) const override
Definition: crypto_model_signer.hpp:34
Definition: byte_range.hpp:14
Definition: crypto_model_signer.hpp:19
Definition: command_executor.hpp:12
CryptoModelSigner(const shared_model::crypto::Keypair &keypair)
Definition: crypto_model_signer.hpp:43
Definition: abstract_crypto_model_signer.hpp:16