storage

package
v0.0.0-...-9285389 Latest Latest
Warning

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

Go to latest
Published: Apr 21, 2025 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CTStorage

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

CTStorage implements ct.Storage.

func NewCTStorage

func NewCTStorage(logStorage *tessera.Appender, issuerStorage IssuerStorage, dedupStorage dedup.BEDedupStorage) (*CTStorage, error)

NewCTStorage instantiates a CTStorage object.

func (*CTStorage) Add

func (cts *CTStorage) Add(ctx context.Context, entry *ctonly.Entry) tessera.IndexFuture

Add stores CT entries.

func (CTStorage) AddCertDedupInfo

func (cts CTStorage) AddCertDedupInfo(ctx context.Context, c *x509.Certificate, sctDedupInfo dedup.SCTDedupInfo) error

AddCertDedupInfo stores <cert_hash, SCTDedupInfo> in the deduplication storage.

func (*CTStorage) AddIssuerChain

func (cts *CTStorage) AddIssuerChain(ctx context.Context, chain []*x509.Certificate) error

AddIssuerChain stores every chain certificate under its sha256.

If an object is already stored under this hash, continues.

func (CTStorage) GetCertDedupInfo

func (cts CTStorage) GetCertDedupInfo(ctx context.Context, c *x509.Certificate) (dedup.SCTDedupInfo, bool, error)

GetCertDedupInfo fetches the SCTDedupInfo of a given certificate from the deduplication storage.

type CreateStorage

type CreateStorage func(context.Context, note.Signer) (*CTStorage, error)

CreateStorage instantiates a Tessera storage implementation with a signer option.

type IssuerStorage

type IssuerStorage interface {
	AddIssuersIfNotExist(ctx context.Context, kv []KV) error
}

IssuerStorage issuer certificates under their hex encoded sha256.

type KV

type KV struct {
	K []byte
	V []byte
}

Directories

Path Synopsis
Package bbolt implements modules/dedup using BBolt.
Package bbolt implements modules/dedup using BBolt.

Jump to

Keyboard shortcuts

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