identity

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Mar 8, 2021 License: BSD-3-Clause Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	//SignatureSize = ed25519.SignatureSize + 4
	PublicKeySize = ed25519.PublicKeySize
	SignatureSize = ed25519.SignatureSize
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Key

type Key struct {
	// contains filtered or unexported fields
}

func Import

func Import(pub64, priv64 string) (*Key, error)

func KeyFromBytes

func KeyFromBytes(pub, priv []byte) (*Key, error)

func New

func New() (*Key, error)

func (*Key) HasPrivateKey

func (i *Key) HasPrivateKey() bool

func (*Key) HasPublicKey

func (i *Key) HasPublicKey() bool

func (*Key) Id

func (i *Key) Id() uint32

func (*Key) IdBytes

func (i *Key) IdBytes() []byte

func (*Key) IdStr

func (i *Key) IdStr() string

func (*Key) Keys

func (i *Key) Keys() (pub, priv []byte)

func (*Key) Sign

func (i *Key) Sign(message []byte, dohash bool) (sig []byte, err error)

func (*Key) Verify

func (i *Key) Verify(message, sig []byte, dohash bool) bool

Jump to

Keyboard shortcuts

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