signer

package
v0.0.0-...-8cb8a38 Latest Latest
Warning

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

Go to latest
Published: Aug 24, 2023 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BroadcastHandler

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

func NewBroadcastHandler

func NewBroadcastHandler(signer *Signer) *BroadcastHandler

func (*BroadcastHandler) MismatchMessage

func (h *BroadcastHandler) MismatchMessage(msg pending_store.MessageWithPeerMetadata)

func (*BroadcastHandler) RawMessage

func (*BroadcastHandler) ValidatedMessage

func (h *BroadcastHandler) ValidatedMessage(msg types.BroadcastMessage)

type Signer

type Signer struct {
	Node *p2p.Node
	// contains filtered or unexported fields
}

Signer is a multi-party signer that handles messages between multiple peers for keygen, signing, and resharing.

func NewSigner

func NewSigner(
	node *p2p.Node,
	moniker string,
	partyID *tss.PartyID,
	key keygen.LocalPartySaveData,
	threshold int,
	broadcasterOptions ...broadcast.BroadcasterOption,
) (*Signer, error)

NewSigner returns a new Signer.

func (*Signer) GetParams

func (s *Signer) GetParams(participants []peer.ID) (*tss.Parameters, error)

func (*Signer) SignMessage

func (s *Signer) SignMessage(
	ctx context.Context,
	txHash eth_common.Hash,
	msgHash *big.Int,
) (*tss_common.SignatureData, error)

SignMessage signs a message with a corresponding txHash. This creates a signing session.

Jump to

Keyboard shortcuts

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