Kagome
Polkadot Runtime Engine in C++17
kagome::crypto::Secp256k1ProviderImpl Class Reference

#include <secp256k1_provider_impl.hpp>

Inheritance diagram for kagome::crypto::Secp256k1ProviderImpl:
Collaboration diagram for kagome::crypto::Secp256k1ProviderImpl:

Public Member Functions

 ~Secp256k1ProviderImpl () override=default
 
 Secp256k1ProviderImpl ()
 
outcome::result< secp256k1::UncompressedPublicKeyrecoverPublickeyUncompressed (const secp256k1::RSVSignature &signature, const secp256k1::MessageHash &message_hash) const override
 recover public key in uncompressed form More...
 
outcome::result< secp256k1::CompressedPublicKeyrecoverPublickeyCompressed (const secp256k1::RSVSignature &signature, const secp256k1::MessageHash &message_hash) const override
 recover public key in compressed form More...
 
- Public Member Functions inherited from kagome::crypto::Secp256k1Provider
virtual ~Secp256k1Provider ()=default
 

Private Member Functions

outcome::result< secp256k1_pubkey > recoverPublickey (const secp256k1::RSVSignature &signature, const secp256k1::MessageHash &message_hash) const
 

Private Attributes

std::unique_ptr< secp256k1_context, void(*)(secp256k1_context *)> context_
 

Detailed Description

Definition at line 23 of file secp256k1_provider_impl.hpp.

Constructor & Destructor Documentation

kagome::crypto::Secp256k1ProviderImpl::~Secp256k1ProviderImpl ( )
overridedefault
kagome::crypto::Secp256k1ProviderImpl::Secp256k1ProviderImpl ( )

Definition at line 12 of file secp256k1_provider_impl.cpp.

Member Function Documentation

outcome::result< secp256k1_pubkey > kagome::crypto::Secp256k1ProviderImpl::recoverPublickey ( const secp256k1::RSVSignature signature,
const secp256k1::MessageHash message_hash 
) const
private

Definition at line 79 of file secp256k1_provider_impl.cpp.

outcome::result< secp256k1::CompressedPublicKey > kagome::crypto::Secp256k1ProviderImpl::recoverPublickeyCompressed ( const secp256k1::RSVSignature signature,
const secp256k1::MessageHash message_hash 
) const
overridevirtual

recover public key in compressed form

Parameters
signaturesignature
message_hashblake2s message hash
Returns
compressed public key or error

Implements kagome::crypto::Secp256k1Provider.

Definition at line 38 of file secp256k1_provider_impl.cpp.

outcome::result< secp256k1::UncompressedPublicKey > kagome::crypto::Secp256k1ProviderImpl::recoverPublickeyUncompressed ( const secp256k1::RSVSignature signature,
const secp256k1::MessageHash message_hash 
) const
overridevirtual

recover public key in uncompressed form

Parameters
signaturesignature
message_hashblake2s message hash
Returns
uncompressed public key or error

Implements kagome::crypto::Secp256k1Provider.

Definition at line 18 of file secp256k1_provider_impl.cpp.

Member Data Documentation

std::unique_ptr<secp256k1_context, void (*)(secp256k1_context *)> kagome::crypto::Secp256k1ProviderImpl::context_
private

Definition at line 43 of file secp256k1_provider_impl.hpp.


The documentation for this class was generated from the following files: