Documentation ¶
Index ¶
Constants ¶
View Source
const ( // DefaultRemoteRoot is the default remote TUF root location. DefaultRemoteRoot = "https://tuf-repo-cdn.sigstore.dev" // TufRootEnv is the name of the environment variable that locates an alternate local TUF root location. TufRootEnv = "TUF_ROOT" // SigstoreNoCache is the name of the environment variable that, if set, configures this code to only store root data in memory. SigstoreNoCache = "SIGSTORE_NO_CACHE" )
Variables ¶
This section is empty.
Functions ¶
func NewSigstoreTufRepo ¶
func NewSigstoreTufRepo(t *testing.T, root TestSigstoreRoot) (tuf.LocalStore, *tuf.Repo)
This creates a new sigstore TUF repo whose signers can be used to create dynamic signed Rekor entries.
Types ¶
type MetadataStatus ¶
type RootStatus ¶
type RootStatus struct { Local string `json:"local"` Remote string `json:"remote"` Metadata map[string]MetadataStatus `json:"metadata"` Targets []string `json:"targets"` }
JSON output representing the configured root status
func GetRootStatus ¶
func GetRootStatus(ctx context.Context) (*RootStatus, error)
GetRootStatus gets the current root status for info logging
type StatusKind ¶
type StatusKind int
const ( UnknownStatus StatusKind = iota Active Expired )
func (StatusKind) MarshalText ¶
func (s StatusKind) MarshalText() ([]byte, error)
func (StatusKind) String ¶
func (s StatusKind) String() string
func (*StatusKind) UnmarshalText ¶
func (s *StatusKind) UnmarshalText(text []byte) error
type TUF ¶
func (*TUF) GetTargetsByMeta ¶
func (t *TUF) GetTargetsByMeta(usage UsageKind, fallbacks []string) ([]TargetFile, error)
Get target files by a custom usage metadata tag. If there are no files found, use the fallback target names to fetch the targets by name.
type TargetFile ¶
type TargetFile struct { Target []byte Status StatusKind }
type TestSigstoreRoot ¶
type TestSigstoreRoot struct { Rekor signature.Verifier FulcioCertificate *x509.Certificate }
type UsageKind ¶
type UsageKind int
func (UsageKind) MarshalText ¶
func (*UsageKind) UnmarshalText ¶
Click to show internal directories.
Click to hide internal directories.