trust

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Mar 12, 2022 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package trust defines interfaces that extend the capabilities of a trust storage compared to the trust.DB interface. These additional capabilities are used outside of the trust package. For example, they are used by the service management API to get insights into the state of the trust storage.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ChainID

func ChainID(chain []*x509.Certificate) []byte

ChainID maps certificate chain to an ID.

Types

type TRCsQuery

type TRCsQuery struct {
	// ISD is the ISD identifier of the TRCs.
	ISD []addr.ISD
	// Latest indicates if only the latest TRC of each ISD is requested.
	Latest bool
}

TRCsQuery identifies a set of TRCs that need to be looked up.

type TrustAPI

type TrustAPI interface {
	// SignedTRCs returns the TRCs matching the TRCsQuery from the trust database.
	SignedTRCs(context.Context, TRCsQuery) (cppki.SignedTRCs, error)
	// Chain looks up the chain for a given ChainID.
	Chain(context.Context, []byte) ([]*x509.Certificate, error)
}

TrustAPI defines methods used by the trust service management API.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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