package
2.2.26+incompatible
Repository: https://github.com/gochain-io/gochain.git
Documentation: pkg.go.dev

# Functions

CalcDifficulty returns the difficulty for signer, given all signers and their most recently signed block numbers, with 0 meaning 'has not signed'.
ExtraAppendVote appends a vote to extra data as 20 bytes of address and a single byte for voter or signer election.
ExtraCandidate returns the candidate address of the proposal vote, or the zero value if one is not present.
ExtraEnsureVanity returns a slice of length 32, trimming extra or filling with 0s as necessary.
ExtraHasVote returns true if extra contains a proposal vote.
IsVoterElection returns true if extra votes on a voter election, or false if it votes on a signer election or does not contain a vote.
ExtraVanity returns a slice of the vanity portion of extra (up to 32).
New creates a Clique proof-of-authority consensus engine with the initial signers set to the ones provided by the user.
NewFaker returns a new fake consensus.Engine which sleeps for delay during header verification.
NewFakeFailer returns a new fake consensus.Engine which fails header verification at the given block.
NewFaker returns a new fake consensus.Engine.
NewFullFaker returns a new fake consensus.Engine which skips header verification entirely.

# Variables

Block reward in wei for successfully sealing a block.
ErrIneligibleSigner is returned if a signer is authorized to sign, but not eligible to sign this block.
ErrInvalidTimestamp is returned if the timestamp of a block is lower than the previous block's timestamp + the minimum block period.

# Structs

API is a user facing RPC API to allow controlling the signer and voting mechanisms of the proof-of-authority scheme.
Clique is the proof-of-authority consensus engine proposed to support the Ethereum testnet following the Ropsten attacks.
Snapshot is the state of the authorization voting at a given point in time.
Tally is a simple vote tally to keep the current score of votes.
Vote represents a single vote that an authorized signer made to modify the list of authorizations.