secp256k1

package
v0.0.0-...-c9d2d86 Latest Latest
Warning

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

Go to latest
Published: May 25, 2018 License: ISC Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func S256

func S256() elliptic.Curve

Types

type Crypter

type Crypter struct {
}

func (*Crypter) DoubleSha256

func (this *Crypter) DoubleSha256(data []byte) []byte

func (*Crypter) GenerateKey

func (this *Crypter) GenerateKey() (crypter.IPrivateKey, crypter.IPublicKey, error)

func (*Crypter) Name

func (this *Crypter) Name() string

func (*Crypter) Sign

func (this *Crypter) Sign(privateKey crypter.IPrivateKey, message []byte) ([]byte, error)

func (*Crypter) ToPrivateKey

func (this *Crypter) ToPrivateKey(data []byte) crypter.IPrivateKey

func (*Crypter) ToPublicKey

func (this *Crypter) ToPublicKey(data []byte) crypter.IPublicKey

func (*Crypter) Verify

func (this *Crypter) Verify(publicKey crypter.IPublicKey, message, sig []byte) bool

type PrivateKey

type PrivateKey ecdsa.PrivateKey

func (*PrivateKey) Bytes

func (priv *PrivateKey) Bytes() []byte

func (*PrivateKey) Public

func (priv *PrivateKey) Public() crypter.IPublicKey

type PublicKey

type PublicKey ecdsa.PublicKey

func (*PublicKey) Bytes

func (pub *PublicKey) Bytes() []byte

Jump to

Keyboard shortcuts

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