proving

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Nov 9, 2022 License: MIT Imports: 11 Imported by: 1

Documentation

Index

Constants

View Source
const (
	NumNoncesPerIteration = 10 // TODO(moshababo): update the recommended value
	MaxNumIterations      = 10 // TODO(moshababo): update the recommended value
)

Variables

View Source
var (
	FastOracle = oracle.FastOracle
	UInt64LE   = shared.UInt64LE
)

Functions

This section is empty.

Types

type Challenge

type Challenge = shared.Challenge

type Config

type Config = config.Config

type ConfigMismatchError

type ConfigMismatchError = shared.ConfigMismatchError

type DiskState

type DiskState = initialization.DiskState

type Logger

type Logger = shared.Logger

type Metadata

type Metadata = initialization.Metadata

type Proof

type Proof = shared.Proof

type ProofMetadata

type ProofMetadata = shared.ProofMetadata

type Prover

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

func NewProver

func NewProver(cfg Config, datadir string, commitment []byte) (*Prover, error)

func (*Prover) GenerateProof

func (p *Prover) GenerateProof(challenge Challenge) (*Proof, *ProofMetadata, error)

GenerateProof (analogous to the PoST protocol Execution phase) receives a challenge that cannot be predicted, and reads the entire PoST data to generate a proof in response to the challenge to prove that the prover data exists at the time of invocation. Generating a proof can be repeated arbitrarily many times without repeating the PoST protocol Initialization phase; thus despite the initialization essentially serving as a PoW, the amortized computational complexity can be made arbitrarily small.

func (*Prover) SetLogger

func (p *Prover) SetLogger(logger Logger)

Jump to

Keyboard shortcuts

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