registrant

package
v1.1.1 Latest Latest
Warning

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

Go to latest
Published: Feb 18, 2026 License: MIT Imports: 18 Imported by: 0

Documentation

Overview

Package registrant implements the registrant for the node.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IRegistrant added in v0.5.0

type IRegistrant interface {
	NodeID() uint32
	SignStagedEnvelope(
		stagedEnv queries.StagedOriginatorEnvelope,
		baseFee currency.PicoDollar,
		congestionFee currency.PicoDollar,
		retentionDays uint32,
	) (*envelopes.OriginatorEnvelope, error)
	SignPayerReportAttestation(
		reportID payerreport.ReportID,
	) (*payerreport.NodeSignature, error)
	SignClientEnvelopeToSelf(unsignedClientEnvelope []byte) ([]byte, error)
	TokenFactory() authn.TokenFactory
}

type Registrant

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

func NewRegistrant

func NewRegistrant(
	ctx context.Context,
	logger *zap.Logger,
	db *queries.Queries,
	nodeRegistry registry.NodeRegistry,
	privateKeyString string,
	serverVersion *semver.Version,
) (*Registrant, error)

func (*Registrant) NodeID

func (r *Registrant) NodeID() uint32

func (*Registrant) SignClientEnvelopeToSelf added in v0.5.0

func (r *Registrant) SignClientEnvelopeToSelf(unsignedClientEnvelope []byte) ([]byte, error)

func (*Registrant) SignPayerReportAttestation added in v0.5.0

func (r *Registrant) SignPayerReportAttestation(
	reportID payerreport.ReportID,
) (*payerreport.NodeSignature, error)

func (*Registrant) SignStagedEnvelope

func (r *Registrant) SignStagedEnvelope(
	stagedEnv queries.StagedOriginatorEnvelope,
	baseFee currency.PicoDollar,
	congestionFee currency.PicoDollar,
	retentionDays uint32,
) (*envelopes.OriginatorEnvelope, error)

func (*Registrant) TokenFactory

func (r *Registrant) TokenFactory() authn.TokenFactory

Jump to

Keyboard shortcuts

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