Documentation ¶
Index ¶
- Variables
- func GetCheckpointNumber(epochDuration uint64, blockNumber uint64) uint64
- func GetSignatureAddress(data []byte, sig []byte) (common.Address, error)
- func GetValSetAddresses(h *types.Header) ([]common.Address, error)
- func PrepareCommittedSeal(hash common.Hash) []byte
- func SigHash(header *types.Header) (hash common.Hash)
- func WriteCommittedSeals(h *types.Header, committedSeals [][]byte) error
- func WriteSeal(h *types.Header, seal []byte) error
- func WriteValSet(h *types.Header, validators []common.Address) error
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrInvalidSealLength = errors.New("seal is expected to be multiplication of 65")
)
Functions ¶
func GetCheckpointNumber ¶
GetCheckpointNumber returns check-point block where header contains valset of current epoch
func GetSignatureAddress ¶
GetSignatureAddress gets the signer address from the signature
func GetValSetAddresses ¶
GetValSetAddresses returns the address of validators from the extra-data field.
func PrepareCommittedSeal ¶
PrepareCommittedSeal returns a committed seal for the given hash
func SigHash ¶
sigHash returns the hash signing. It is the hash of the entire header apart from the 65 byte signature contained at the end of the extra data.
func WriteCommittedSeals ¶
WriteCommittedSeals writes the extra-data field of a block header with given committed seals.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.