Documentation
¶
Index ¶
- func Contains(s []*tss.PartyID, e *tss.PartyID) bool
- func GetMsgRound(msg []byte, partyID *tss.PartyID, isBroadcast bool) (abnormal.RoundInfo, error)
- func MsgToHashInt(digest []byte) *big.Int
- func MsgToHashString(msg []byte) (string, error)
- type BulkWireMsg
- type LocalCacheItem
- type Status
- type TssCommon
- func (t *TssCommon) GetAbnormalMgr() *abnormal2.Manager
- func (t *TssCommon) GetConf() TssConfig
- func (t *TssCommon) GetLocalPeerID() string
- func (t *TssCommon) GetPartyIDtoP2PID() map[string]peer.ID
- func (t *TssCommon) GetTaskDone() chan struct{}
- func (t *TssCommon) GetThreshHold() int
- func (t *TssCommon) InsertPartyIDtoP2PID(newMap map[string]peer.ID)
- func (t *TssCommon) NotifyTaskDone() error
- func (t *TssCommon) ProcessInboundMessages(finishChan chan struct{}, wg *sync.WaitGroup)
- func (t *TssCommon) ProcessOneMessage(wrappedMsg *messages.WrappedMessage, peerID string) error
- func (t *TssCommon) ProcessOutCh(msg tss.Message, msgType messages.TSSMessageTpe) error
- func (t *TssCommon) SetLocalPeerID(peerID string)
- func (t *TssCommon) SetPartyInfo(partyInfo *abnormal2.PartyInfo)
- func (t *TssCommon) TryGetLocalCacheItem(key string) *LocalCacheItem
- type TssConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetMsgRound ¶
func MsgToHashInt ¶
func MsgToHashString ¶
Types ¶
type BulkWireMsg ¶
type BulkWireMsg struct {
WiredBulkMsg []byte
MsgIdentifier string
Routing *tss.MessageRouting
}
func NewBulkWireMsg ¶
func NewBulkWireMsg(msg []byte, id string, r *tss.MessageRouting) BulkWireMsg
type LocalCacheItem ¶
type LocalCacheItem struct {
Msg *messages.WireMessage
Hash string
ConfirmedList map[string]string
// contains filtered or unexported fields
}
func NewLocalCacheItem ¶
func NewLocalCacheItem(msg *messages.WireMessage, hash string) *LocalCacheItem
func (*LocalCacheItem) GetPeers ¶
func (l *LocalCacheItem) GetPeers() []string
func (*LocalCacheItem) TotalConfirmParty ¶
func (l *LocalCacheItem) TotalConfirmParty() int
TotalConfirmParty number of parties that already confirmed their hash
func (*LocalCacheItem) UpdateConfirmList ¶
func (l *LocalCacheItem) UpdateConfirmList(P2PID, hash string)
UpdateConfirmList add the given party's hash into the confirm list
type TssCommon ¶
type TssCommon struct {
TssMsg chan *p2p.Message
P2PPeersLock sync.RWMutex
P2PPeers []peer.ID
// contains filtered or unexported fields
}
func NewTssCommon ¶
func NewTssCommon(peerID string, broadcastChannel chan *messages.BroadcastMsgChan, conf TssConfig, msgID string, privKey *ecdsa.PrivateKey, thresHold int) *TssCommon
func (*TssCommon) GetAbnormalMgr ¶
func (*TssCommon) GetLocalPeerID ¶
func (*TssCommon) GetTaskDone ¶
func (t *TssCommon) GetTaskDone() chan struct{}
func (*TssCommon) GetThreshHold ¶
func (*TssCommon) InsertPartyIDtoP2PID ¶
func (*TssCommon) NotifyTaskDone ¶
func (*TssCommon) ProcessInboundMessages ¶
func (*TssCommon) ProcessOneMessage ¶
func (t *TssCommon) ProcessOneMessage(wrappedMsg *messages.WrappedMessage, peerID string) error
func (*TssCommon) ProcessOutCh ¶
func (*TssCommon) SetLocalPeerID ¶
func (*TssCommon) SetPartyInfo ¶
func (*TssCommon) TryGetLocalCacheItem ¶
func (t *TssCommon) TryGetLocalCacheItem(key string) *LocalCacheItem
type TssConfig ¶
type TssConfig struct {
// KeyGenTimeoutSeconds defines how long do we wait the keygen parties to pass messages along
KeyGenTimeout time.Duration
// KeySignTimeoutSeconds defines how long do we wait keysign
KeySignTimeout time.Duration
// Pre-parameter define the pre-parameter generations timeout
PreParamTimeout time.Duration
// enable the tss monitor
EnableMonitor bool
}
Click to show internal directories.
Click to hide internal directories.