file

package
v0.0.0-...-d3fb13d Latest Latest
Warning

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

Go to latest
Published: Mar 10, 2025 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DeleteOldCheckpoints

func DeleteOldCheckpoints(logInfoFile string) error

DeleteOldCheckpoints persists the latest 100 checkpoints. This expects that the log file is not being concurrently written to

func ReadLatestCTSignedTreeHead

func ReadLatestCTSignedTreeHead(logInfoFile string) (*ct.SignedTreeHead, error)

ReadLatestCTSignedTreeHead reads the most recent signed tree head from the log file

func ReadLatestCheckpoint

func ReadLatestCheckpoint(logInfoFile string) (*util.SignedCheckpoint, error)

ReadLatestCheckpoint reads the most recent signed checkpoint from the log file

func WriteCTSignedTreeHead

func WriteCTSignedTreeHead(sth *ct.SignedTreeHead, logInfoFile string) error

WriteCTSignedTreeHead writes a signed tree head to a given log file

func WriteCheckpoint

func WriteCheckpoint(checkpoint *util.SignedCheckpoint, logInfoFile string) error

WriteCheckpoint writes a signed checkpoint to the log file

func WriteIdentity

func WriteIdentity(idFile string, idEntry identity.LogEntry) error

WriteIdentity writes an identity found in the log to a file

func WriteIdentityMetadata

func WriteIdentityMetadata(metadataFile string, idMetadata IdentityMetadata) error

WriteIdentityMetadata writes information about what log indices have been scanned to a file

Types

type IdentityMetadata

type IdentityMetadata struct {
	LatestIndex int `json:"latestIndex"`
}

func ReadIdentityMetadata

func ReadIdentityMetadata(metadataFile string) (*IdentityMetadata, error)

ReadIdentityMetadata reads the latest information about what log indices have been scanned to a file

func (IdentityMetadata) String

func (idMetadata IdentityMetadata) String() string

Jump to

Keyboard shortcuts

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