sessionmanager

package
v0.0.28 Latest Latest
Warning

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

Go to latest
Published: Apr 1, 2026 License: MIT Imports: 21 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type SendFunc

type SendFunc func(ctx context.Context, peerID string, data []byte) error

SendFunc is a function type for sending messages to participants.

type SessionManager

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

SessionManager manages TSS protocol sessions and handles incoming messages.

func NewSessionManager

func NewSessionManager(
	eventStore *eventstore.Store,
	coord *coordinator.Coordinator,
	keyshareManager *keyshare.Manager,
	pushCore *pushcore.Client,
	chains *chains.Chains,
	send SendFunc,
	partyID string,
	sessionExpiryTime time.Duration,
	sessionExpiryCheckInterval time.Duration,
	sessionExpiryBlockDelay uint64,
	logger zerolog.Logger,
	pushSigner *pushsigner.Signer,
) *SessionManager

NewSessionManager creates a new session manager.

func (*SessionManager) HandleIncomingMessage

func (sm *SessionManager) HandleIncomingMessage(ctx context.Context, peerID string, data []byte) error

HandleIncomingMessage handles an incoming message. peerID: The peer ID of the sender data: The raw message bytes (should be JSON-encoded coordinator.Message)

func (*SessionManager) Start added in v0.0.16

func (sm *SessionManager) Start(ctx context.Context)

Start starts the session manager's background goroutines (e.g. expiry checker).

Jump to

Keyboard shortcuts

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