resharing

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Jul 12, 2023 License: MIT Imports: 19 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TaskName = "ecdsa-resharing"
)

Variables

View Source
var File_protob_ecdsa_resharing_proto protoreflect.FileDescriptor

Functions

func NewDGRound1Message

func NewDGRound1Message(
	to []*tss.PartyID,
	from *tss.PartyID,
	ecdsaPub *crypto.ECPoint,
	vct cmt.HashCommitment,
) tss.ParsedMessage

func NewDGRound2Message1

func NewDGRound2Message1(
	to []*tss.PartyID,
	from *tss.PartyID,
	paillierPK *paillier.PublicKey,
	paillierPf paillier.Proof,
	NTildei, H1i, H2i *big.Int,
	dlnProof1, dlnProof2 *dlnproof.Proof,
) (tss.ParsedMessage, error)

func NewDGRound2Message2

func NewDGRound2Message2(
	to []*tss.PartyID,
	from *tss.PartyID,
) tss.ParsedMessage

func NewDGRound3Message1

func NewDGRound3Message1(
	to *tss.PartyID,
	from *tss.PartyID,
	share *vss.Share,
) tss.ParsedMessage

func NewDGRound3Message2

func NewDGRound3Message2(
	to []*tss.PartyID,
	from *tss.PartyID,
	vdct cmt.HashDeCommitment,
) tss.ParsedMessage

func NewDGRound4Message

func NewDGRound4Message(
	to []*tss.PartyID,
	from *tss.PartyID,
) tss.ParsedMessage

func NewLocalParty

func NewLocalParty(
	params *tss.ReSharingParameters,
	key keygen.LocalPartySaveData,
	out chan<- tss.Message,
	end chan<- keygen.LocalPartySaveData,
) tss.Party

Exported, used in `tss` client The `key` is read from and/or written to depending on whether this party is part of the old or the new committee. You may optionally generate and set the LocalPreParams if you would like to use pre-generated safe primes and Paillier secret. (This is similar to providing the `optionalPreParams` to `keygen.LocalParty`).

Types

type DGRound1Message

type DGRound1Message struct {
	EcdsaPubX   []byte `protobuf:"bytes,1,opt,name=ecdsa_pub_x,json=ecdsaPubX,proto3" json:"ecdsa_pub_x,omitempty"`
	EcdsaPubY   []byte `protobuf:"bytes,2,opt,name=ecdsa_pub_y,json=ecdsaPubY,proto3" json:"ecdsa_pub_y,omitempty"`
	VCommitment []byte `protobuf:"bytes,3,opt,name=v_commitment,json=vCommitment,proto3" json:"v_commitment,omitempty"`
	// contains filtered or unexported fields
}

The Round 1 data is broadcast to peers of the New Committee in this message.

func (*DGRound1Message) Descriptor deprecated

func (*DGRound1Message) Descriptor() ([]byte, []int)

Deprecated: Use DGRound1Message.ProtoReflect.Descriptor instead.

func (*DGRound1Message) GetEcdsaPubX

func (x *DGRound1Message) GetEcdsaPubX() []byte

func (*DGRound1Message) GetEcdsaPubY

func (x *DGRound1Message) GetEcdsaPubY() []byte

func (*DGRound1Message) GetVCommitment

func (x *DGRound1Message) GetVCommitment() []byte

func (*DGRound1Message) ProtoMessage

func (*DGRound1Message) ProtoMessage()

func (*DGRound1Message) ProtoReflect

func (x *DGRound1Message) ProtoReflect() protoreflect.Message

func (*DGRound1Message) Reset

func (x *DGRound1Message) Reset()

func (*DGRound1Message) String

func (x *DGRound1Message) String() string

func (*DGRound1Message) UnmarshalECDSAPub

func (m *DGRound1Message) UnmarshalECDSAPub(ec elliptic.Curve) (*crypto.ECPoint, error)

func (*DGRound1Message) UnmarshalVCommitment

func (m *DGRound1Message) UnmarshalVCommitment() *big.Int

func (*DGRound1Message) ValidateBasic

func (m *DGRound1Message) ValidateBasic() bool

type DGRound2Message1

type DGRound2Message1 struct {
	PaillierN     []byte   `protobuf:"bytes,1,opt,name=paillier_n,json=paillierN,proto3" json:"paillier_n,omitempty"`
	PaillierProof [][]byte `protobuf:"bytes,2,rep,name=paillier_proof,json=paillierProof,proto3" json:"paillier_proof,omitempty"`
	NTilde        []byte   `protobuf:"bytes,3,opt,name=n_tilde,json=nTilde,proto3" json:"n_tilde,omitempty"`
	H1            []byte   `protobuf:"bytes,4,opt,name=h1,proto3" json:"h1,omitempty"`
	H2            []byte   `protobuf:"bytes,5,opt,name=h2,proto3" json:"h2,omitempty"`
	Dlnproof_1    [][]byte `protobuf:"bytes,6,rep,name=dlnproof_1,json=dlnproof1,proto3" json:"dlnproof_1,omitempty"`
	Dlnproof_2    [][]byte `protobuf:"bytes,7,rep,name=dlnproof_2,json=dlnproof2,proto3" json:"dlnproof_2,omitempty"`
	// contains filtered or unexported fields
}

The Round 2 data is broadcast to other peers of the New Committee in this message.

func (*DGRound2Message1) Descriptor deprecated

func (*DGRound2Message1) Descriptor() ([]byte, []int)

Deprecated: Use DGRound2Message1.ProtoReflect.Descriptor instead.

func (*DGRound2Message1) GetDlnproof_1

func (x *DGRound2Message1) GetDlnproof_1() [][]byte

func (*DGRound2Message1) GetDlnproof_2

func (x *DGRound2Message1) GetDlnproof_2() [][]byte

func (*DGRound2Message1) GetH1

func (x *DGRound2Message1) GetH1() []byte

func (*DGRound2Message1) GetH2

func (x *DGRound2Message1) GetH2() []byte

func (*DGRound2Message1) GetNTilde

func (x *DGRound2Message1) GetNTilde() []byte

func (*DGRound2Message1) GetPaillierN

func (x *DGRound2Message1) GetPaillierN() []byte

func (*DGRound2Message1) GetPaillierProof

func (x *DGRound2Message1) GetPaillierProof() [][]byte

func (*DGRound2Message1) ProtoMessage

func (*DGRound2Message1) ProtoMessage()

func (*DGRound2Message1) ProtoReflect

func (x *DGRound2Message1) ProtoReflect() protoreflect.Message

func (*DGRound2Message1) Reset

func (x *DGRound2Message1) Reset()

func (*DGRound2Message1) String

func (x *DGRound2Message1) String() string

func (*DGRound2Message1) UnmarshalDLNProof1

func (m *DGRound2Message1) UnmarshalDLNProof1() (*dlnproof.Proof, error)

func (*DGRound2Message1) UnmarshalDLNProof2

func (m *DGRound2Message1) UnmarshalDLNProof2() (*dlnproof.Proof, error)

func (*DGRound2Message1) UnmarshalH1

func (m *DGRound2Message1) UnmarshalH1() *big.Int

func (*DGRound2Message1) UnmarshalH2

func (m *DGRound2Message1) UnmarshalH2() *big.Int

func (*DGRound2Message1) UnmarshalNTilde

func (m *DGRound2Message1) UnmarshalNTilde() *big.Int

func (*DGRound2Message1) UnmarshalPaillierPK

func (m *DGRound2Message1) UnmarshalPaillierPK() *paillier.PublicKey

func (*DGRound2Message1) UnmarshalPaillierProof

func (m *DGRound2Message1) UnmarshalPaillierProof() paillier.Proof

func (*DGRound2Message1) ValidateBasic

func (m *DGRound2Message1) ValidateBasic() bool

type DGRound2Message2

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

The Round 2 "ACK" is broadcast to peers of the Old Committee in this message.

func (*DGRound2Message2) Descriptor deprecated

func (*DGRound2Message2) Descriptor() ([]byte, []int)

Deprecated: Use DGRound2Message2.ProtoReflect.Descriptor instead.

func (*DGRound2Message2) ProtoMessage

func (*DGRound2Message2) ProtoMessage()

func (*DGRound2Message2) ProtoReflect

func (x *DGRound2Message2) ProtoReflect() protoreflect.Message

func (*DGRound2Message2) Reset

func (x *DGRound2Message2) Reset()

func (*DGRound2Message2) String

func (x *DGRound2Message2) String() string

func (*DGRound2Message2) ValidateBasic

func (m *DGRound2Message2) ValidateBasic() bool

type DGRound3Message1

type DGRound3Message1 struct {
	Share []byte `protobuf:"bytes,1,opt,name=share,proto3" json:"share,omitempty"`
	// contains filtered or unexported fields
}

The Round 3 data is sent to peers of the New Committee in this message.

func (*DGRound3Message1) Descriptor deprecated

func (*DGRound3Message1) Descriptor() ([]byte, []int)

Deprecated: Use DGRound3Message1.ProtoReflect.Descriptor instead.

func (*DGRound3Message1) GetShare

func (x *DGRound3Message1) GetShare() []byte

func (*DGRound3Message1) ProtoMessage

func (*DGRound3Message1) ProtoMessage()

func (*DGRound3Message1) ProtoReflect

func (x *DGRound3Message1) ProtoReflect() protoreflect.Message

func (*DGRound3Message1) Reset

func (x *DGRound3Message1) Reset()

func (*DGRound3Message1) String

func (x *DGRound3Message1) String() string

func (*DGRound3Message1) ValidateBasic

func (m *DGRound3Message1) ValidateBasic() bool

type DGRound3Message2

type DGRound3Message2 struct {
	VDecommitment [][]byte `protobuf:"bytes,1,rep,name=v_decommitment,json=vDecommitment,proto3" json:"v_decommitment,omitempty"`
	// contains filtered or unexported fields
}

The Round 3 data is broadcast to peers of the New Committee in this message.

func (*DGRound3Message2) Descriptor deprecated

func (*DGRound3Message2) Descriptor() ([]byte, []int)

Deprecated: Use DGRound3Message2.ProtoReflect.Descriptor instead.

func (*DGRound3Message2) GetVDecommitment

func (x *DGRound3Message2) GetVDecommitment() [][]byte

func (*DGRound3Message2) ProtoMessage

func (*DGRound3Message2) ProtoMessage()

func (*DGRound3Message2) ProtoReflect

func (x *DGRound3Message2) ProtoReflect() protoreflect.Message

func (*DGRound3Message2) Reset

func (x *DGRound3Message2) Reset()

func (*DGRound3Message2) String

func (x *DGRound3Message2) String() string

func (*DGRound3Message2) UnmarshalVDeCommitment

func (m *DGRound3Message2) UnmarshalVDeCommitment() cmt.HashDeCommitment

func (*DGRound3Message2) ValidateBasic

func (m *DGRound3Message2) ValidateBasic() bool

type DGRound4Message

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

The Round 4 "ACK" is broadcast to peers of the Old and New Committees from the New Committee in this message.

func (*DGRound4Message) Descriptor deprecated

func (*DGRound4Message) Descriptor() ([]byte, []int)

Deprecated: Use DGRound4Message.ProtoReflect.Descriptor instead.

func (*DGRound4Message) ProtoMessage

func (*DGRound4Message) ProtoMessage()

func (*DGRound4Message) ProtoReflect

func (x *DGRound4Message) ProtoReflect() protoreflect.Message

func (*DGRound4Message) Reset

func (x *DGRound4Message) Reset()

func (*DGRound4Message) String

func (x *DGRound4Message) String() string

func (*DGRound4Message) ValidateBasic

func (m *DGRound4Message) ValidateBasic() bool

type LocalParty

type LocalParty struct {
	*tss.BaseParty
	// contains filtered or unexported fields
}

func (*LocalParty) FirstRound

func (p *LocalParty) FirstRound() tss.Round

func (*LocalParty) PartyID

func (p *LocalParty) PartyID() *tss.PartyID

func (*LocalParty) Start

func (p *LocalParty) Start() *tss.Error

func (*LocalParty) StoreMessage

func (p *LocalParty) StoreMessage(msg tss.ParsedMessage) (bool, *tss.Error)

func (*LocalParty) String

func (p *LocalParty) String() string

func (*LocalParty) Update

func (p *LocalParty) Update(msg tss.ParsedMessage) (ok bool, err *tss.Error)

func (*LocalParty) UpdateFromBytes

func (p *LocalParty) UpdateFromBytes(wireBytes []byte, from *tss.PartyID, isBroadcast bool) (bool, *tss.Error)

func (*LocalParty) ValidateMessage

func (p *LocalParty) ValidateMessage(msg tss.ParsedMessage) (bool, *tss.Error)

Jump to

Keyboard shortcuts

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