signature

package
v1.3.13 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 9, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ECDSA_SECP256K1_SIGNATURE_SIZE_BYTES = 65 // with recovery, without recovery we can skip the last byte
)
View Source
const (
	ED25519_SIGNATURE_SIZE_BYTES = 64
)

Variables

This section is empty.

Functions

func RecoverEcdsaSecp256K1 added in v0.7.1

func RecoverEcdsaSecp256K1(data []byte, sig primitives.EcdsaSecp256K1Sig) (primitives.EcdsaSecp256K1PublicKey, error)

func SignEcdsaSecp256K1 added in v0.7.1

func SignEcdsaSecp256K1(privateKey primitives.EcdsaSecp256K1PrivateKey, data []byte) (primitives.EcdsaSecp256K1Sig, error)

the given data must not be controlled by an adversary, it must be a hash over given data

func SignEd25519

func SignEd25519(privateKey primitives.Ed25519PrivateKey, data []byte) (primitives.Ed25519Sig, error)

func VerifyEcdsaSecp256K1 added in v0.7.1

func VerifyEcdsaSecp256K1(publicKey primitives.EcdsaSecp256K1PublicKey, data []byte, sig primitives.EcdsaSecp256K1Sig) bool

func VerifyEd25519

func VerifyEd25519(publicKey primitives.Ed25519PublicKey, data []byte, sig primitives.Ed25519Sig) bool

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL