Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrSchemeNotExist = errors.New("scheme doesn't exist")
Functions ¶
Types ¶
type Scheme ¶
type Scheme interface { Verify(data []byte, signature []byte) bool Sign(data []byte) ([]byte, error) Name() string PublicKey() []byte Address() (string, error) PublicKeyHex() string }
func CreateScheme ¶
func CreateScheme(schemeName SchemeName, seed string) (Scheme, error)
type SchemeName ¶
type SchemeName string
const Ed25519 SchemeName = "ed25519"
const Secp256k1 SchemeName = "secp256k1"
const Sr25519 SchemeName = "sr25519"
Click to show internal directories.
Click to hide internal directories.