dkgsignkey

package
v2.6.1-mercury-20231117 Latest Latest
Warning

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

Go to latest
Published: Nov 17, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Key

type Key struct {
	PublicKey kyber.Point
	// contains filtered or unexported fields
}

Key is DKG signing key that conforms to the keystore.Key interface

func FromEncryptedJSON

func FromEncryptedJSON(keyJSON []byte, password string) (Key, error)

FromEncryptedJSON returns a dkgsignkey.Key from encrypted data in go-ethereum keystore format.

func MustNewXXXTestingOnly

func MustNewXXXTestingOnly(sk *big.Int) Key

MustNewXXXTestingOnly creates a new DKGSign key from the given secret key. NOTE: for testing only.

func New

func New() (Key, error)

New creates a new DKGSign key

func (Key) GoString

func (k Key) GoString() string

GoString implements fmt.GoStringer

func (Key) ID

func (k Key) ID() string

ID returns the ID of this key

func (Key) KyberScalar

func (k Key) KyberScalar() kyber.Scalar

KyberScalar returns the private key as a kyber.Scalar object

func (Key) PublicKeyString

func (k Key) PublicKeyString() string

PublicKeyString returns the hex representation of this key's public key

func (Key) Raw

func (k Key) Raw() Raw

Raw returns the key raw data

func (Key) String

func (k Key) String() string

String returns the string representation of this key

func (Key) ToEncryptedJSON

func (key Key) ToEncryptedJSON(password string, scryptParams utils.ScryptParams) (export []byte, err error)

ToEncryptedJSON exports this key into a JSON object following the format of EncryptedDKGSignKeyExport

type Raw

type Raw []byte

Raw represents a raw dkgsign secret key in little-endian byte order.

func (Raw) GoString

func (r Raw) GoString() string

func (Raw) Key

func (r Raw) Key() Key

Key returns a Key object from this raw data.

func (Raw) String

func (r Raw) String() string

Jump to

Keyboard shortcuts

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