proposal

package
v0.3.2-rc.1 Latest Latest
Warning

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

Go to latest
Published: Sep 20, 2022 License: GPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrInvalidSignersNum = errors.New("proposal msg allows 1 signer")

ErrInvalidSignersNum represents an error when the number of signers is invalid.

Functions

func Justify

func Justify(share *beacon.Share, state *qbft.State, round specqbft.Round, roundChanges, prepares []*specqbft.SignedMessage, proposedValue []byte) error

Justify implements: predicate JustifyProposal(hPROPOSAL, λi, round, value)

return
	round = 1
	∨ received a quorum Qrc of valid <ROUND-CHANGE, λi, round, prj , pvj> messages such that:
		∀ <ROUND-CHANGE, λi, round, prj , pvj> ∈ Qrc : prj = ⊥ ∧ prj = ⊥
		∨ received a quorum of valid <PREPARE, λi, pr, value> messages such that:
			(pr, value) = HighestPrepared(Qrc)

TODO: move its tests to this package

func ValidateProposalMsg

func ValidateProposalMsg(share *beacon.Share, state *qbft.State, resolver LeaderResolver) pipelines.SignedMessagePipeline

ValidateProposalMsg validates proposal message

Types

type LeaderResolver

type LeaderResolver func(round specqbft.Round) uint64

LeaderResolver resolves round's leader

Jump to

Keyboard shortcuts

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