verifier

package
v0.1.14 Latest Latest
Warning

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

Go to latest
Published: May 19, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrVerificationFailed = errors.New("verification failed")

	ErrFailedUnmarshalPubkey          = fmt.Errorf("%w: failed to unmarshal pubkey", ErrVerificationFailed)
	ErrVerifyInvalidSignatureCount    = fmt.Errorf("%w: invalid signature count", ErrVerificationFailed)
	ErrVerifyMismatchedSignatureCount = fmt.Errorf("%w: mismatched signature count", ErrVerificationFailed)
	ErrVerifyInvalidSignature         = fmt.Errorf("%w: invalid signature", ErrVerificationFailed)
	ErrVerifySomeSignerUnauthorized   = fmt.Errorf("%w: node unauthorized", ErrVerificationFailed)
	ErrVerifyNonUniqueSignature       = fmt.Errorf("%w: signer has already signed", ErrVerificationFailed)
)

Functions

func ReportToSigData

func ReportToSigData(reportCtx [3][32]byte, sr types.Report) []byte

Types

type SignedReport

type SignedReport struct {
	RawRs         [][32]byte
	RawSs         [][32]byte
	RawVs         [32]byte
	ReportContext [3][32]byte
	Report        []byte
}

type Verifier

type Verifier interface {
	// Verify checks the report against its configuration, and then verifies signatures.
	// It replicates the Verifier contract's "verify" function for server side
	// report verification.
	// See also: contracts/src/v0.8/llo-feeds/Verifier.sol
	Verify(report SignedReport, f uint8, authorizedSigners []common.Address) (signers []common.Address, err error)
}

func NewVerifier

func NewVerifier() Verifier

Jump to

Keyboard shortcuts

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