Documentation ¶
Index ¶
- Variables
- func GenerateUnsealedCID(proofType abi.RegisteredSealProof, pieces []abi.PieceInfo) (cid.Cid, error)
- func GetRequiredPadding(oldLength abi.PaddedPieceSize, newPieceLength abi.PaddedPieceSize) ([]abi.PaddedPieceSize, abi.PaddedPieceSize)
- func SealProofTypeFromSectorSize(ssize abi.SectorSize, nv network.Version) (abi.RegisteredSealProof, error)
- type Config
- type FakeVerifier
- func (f *FakeVerifier) GenerateWinningPoStSectorChallenge(ctx context.Context, proofType abi.RegisteredPoStProof, minerID abi.ActorID, ...) ([]uint64, error)
- func (f *FakeVerifier) VerifyAggregateSeals(aggregate proof7.AggregateSealVerifyProofAndInfos) (bool, error)
- func (f *FakeVerifier) VerifyReplicaUpdate(update proof7.ReplicaUpdateInfo) (bool, error)
- func (f *FakeVerifier) VerifySeal(proof7.SealVerifyInfo) (bool, error)
- func (f *FakeVerifier) VerifyWindowPoSt(context.Context, proof7.WindowPoStVerifyInfo) (bool, error)
- func (f *FakeVerifier) VerifyWinningPoSt(ctx context.Context, info proof7.WinningPoStVerifyInfo) (bool, error)
- type Sealer
- func (sb *Sealer) AddPiece(ctx context.Context, sector storage.SectorRef, ...) (abi.PieceInfo, error)
- func (sb *Sealer) FinalizeSector(ctx context.Context, sector storage.SectorRef, keepUnsealed []storage.Range) error
- func (sb *Sealer) GenerateWindowPoSt(ctx context.Context, minerID abi.ActorID, ...) ([]proof.PoStProof, []abi.SectorID, error)
- func (sb *Sealer) GenerateWinningPoSt(ctx context.Context, minerID abi.ActorID, ...) ([]proof.PoStProof, error)
- func (sb *Sealer) NewSector(ctx context.Context, sector storage.SectorRef) error
- func (sb *Sealer) SealPreCommit1(ctx context.Context, sector storage.SectorRef, ticket abi.SealRandomness, ...) (out storage.PreCommit1Out, err error)
- func (sb *Sealer) SealPreCommit2(ctx context.Context, sector storage.SectorRef, phase1Out storage.PreCommit1Out) (storage.SectorCids, error)
- func (sb *Sealer) Stop()
- type SectorProvider
- type Storage
Constants ¶
This section is empty.
Variables ¶
View Source
var PC2CheckRounds = 3
View Source
var ProofVerifier = proofVerifier{}
Functions ¶
func GenerateUnsealedCID ¶
func GenerateUnsealedCID(proofType abi.RegisteredSealProof, pieces []abi.PieceInfo) (cid.Cid, error)
func GetRequiredPadding ¶
func GetRequiredPadding(oldLength abi.PaddedPieceSize, newPieceLength abi.PaddedPieceSize) ([]abi.PaddedPieceSize, abi.PaddedPieceSize)
func SealProofTypeFromSectorSize ¶
func SealProofTypeFromSectorSize(ssize abi.SectorSize, nv network.Version) (abi.RegisteredSealProof, error)
Types ¶
type Config ¶
type Config struct { SealProofType abi.RegisteredSealProof // contains filtered or unexported fields }
type FakeVerifier ¶
type FakeVerifier struct { }
FakeVerifier is a simple mock Verifier for testing.
func (*FakeVerifier) GenerateWinningPoStSectorChallenge ¶
func (f *FakeVerifier) GenerateWinningPoStSectorChallenge(ctx context.Context, proofType abi.RegisteredPoStProof, minerID abi.ActorID, randomness abi.PoStRandomness, eligibleSectorCount uint64) ([]uint64, error)
func (*FakeVerifier) VerifyAggregateSeals ¶
func (f *FakeVerifier) VerifyAggregateSeals(aggregate proof7.AggregateSealVerifyProofAndInfos) (bool, error)
func (*FakeVerifier) VerifyReplicaUpdate ¶ added in v1.2.0
func (f *FakeVerifier) VerifyReplicaUpdate(update proof7.ReplicaUpdateInfo) (bool, error)
func (*FakeVerifier) VerifySeal ¶
func (f *FakeVerifier) VerifySeal(proof7.SealVerifyInfo) (bool, error)
func (*FakeVerifier) VerifyWindowPoSt ¶
func (f *FakeVerifier) VerifyWindowPoSt(context.Context, proof7.WindowPoStVerifyInfo) (bool, error)
func (*FakeVerifier) VerifyWinningPoSt ¶
func (f *FakeVerifier) VerifyWinningPoSt(ctx context.Context, info proof7.WinningPoStVerifyInfo) (bool, error)
type Sealer ¶
type Sealer struct {
// contains filtered or unexported fields
}
func New ¶
func New(sectors SectorProvider) (*Sealer, error)
func (*Sealer) FinalizeSector ¶
func (*Sealer) GenerateWindowPoSt ¶
func (*Sealer) GenerateWinningPoSt ¶
func (*Sealer) SealPreCommit1 ¶
func (*Sealer) SealPreCommit2 ¶
func (sb *Sealer) SealPreCommit2(ctx context.Context, sector storage.SectorRef, phase1Out storage.PreCommit1Out) (storage.SectorCids, error)
type SectorProvider ¶
type SectorProvider interface { // * returns storiface.ErrSectorNotFound if a requested existing sector doesn't exist // * returns an error when allocate is set, and existing isn't, and the sector exists AcquireSector(ctx context.Context, id storage.SectorRef, existing storiface.SectorFileType, allocate storiface.SectorFileType, ptype storiface.PathType) (storiface.SectorPaths, func(), error) }
type Storage ¶
type Storage interface { SealPreCommit1(ctx context.Context, sector storage.SectorRef, ticket abi.SealRandomness, pieces []abi.PieceInfo) (storage.PreCommit1Out, error) SealPreCommit2(ctx context.Context, sector storage.SectorRef, pc1o storage.PreCommit1Out) (storage.SectorCids, error) FinalizeSector(ctx context.Context, sector storage.SectorRef, keepUnsealed []storage.Range) error }
Click to show internal directories.
Click to hide internal directories.