slashing

package
v0.9.6 Latest Latest
Warning

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

Go to latest
Published: May 10, 2021 License: Apache-2.0, MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ConsensusFaultChecker

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

Checks the validity of reported consensus faults.

func NewFaultChecker

func NewFaultChecker(chain chainReader, fork fork.IFork) *ConsensusFaultChecker

func (*ConsensusFaultChecker) VerifyConsensusFault

func (s *ConsensusFaultChecker) VerifyConsensusFault(ctx context.Context, h1, h2, extra []byte, view FaultStateView) (*runtime2.ConsensusFault, error)

Checks the validity of a consensus fault reported by serialized block headers h1, h2, and optional common-ancestor witness h3.

type FaultStateView

type FaultStateView interface {
	ResolveToKeyAddr(ctx context.Context, address address.Address) (address.Address, error)
	MinerInfo(ctx context.Context, maddr address.Address, nv network.Version) (*miner.MinerInfo, error)
}

Jump to

Keyboard shortcuts

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