Documentation
¶
Overview ¶
Package note implements an attestation fetcher that can read from git commit notes.
Index ¶
- Variables
- func WithHttpAuth(username, password string) optFn
- func WithInit(init string) optFn
- func WithLocator(locator string) optFn
- func WithPush(push bool) optFn
- type Collector
- func (c *Collector) Fetch(ctx context.Context, opts attestation.FetchOptions) ([]attestation.Envelope, error)
- func (c *Collector) FetchByPredicateType(ctx context.Context, opts attestation.FetchOptions, ...) ([]attestation.Envelope, error)
- func (c *Collector) FetchBySubject(ctx context.Context, opts attestation.FetchOptions, subj []attestation.Subject) ([]attestation.Envelope, error)
- func (c *Collector) Store(ctx context.Context, opts attestation.StoreOptions, ...) error
- type Options
Constants ¶
This section is empty.
Variables ¶
View Source
var Build = func(istr string) (attestation.Repository, error) { return New(WithLocator(istr)) }
Implement the factory function
View Source
var TypeMoniker = "note"
Functions ¶
func WithHttpAuth ¶ added in v0.2.7
func WithHttpAuth(username, password string) optFn
func WithLocator ¶
func WithLocator(locator string) optFn
Types ¶
type Collector ¶
type Collector struct {
Options Options
}
func (*Collector) Fetch ¶
func (c *Collector) Fetch(ctx context.Context, opts attestation.FetchOptions) ([]attestation.Envelope, error)
Fetch queries the repository and retrieves any attestations matching the query
func (*Collector) FetchByPredicateType ¶
func (c *Collector) FetchByPredicateType(ctx context.Context, opts attestation.FetchOptions, pts []attestation.PredicateType) ([]attestation.Envelope, error)
func (*Collector) FetchBySubject ¶
func (c *Collector) FetchBySubject(ctx context.Context, opts attestation.FetchOptions, subj []attestation.Subject) ([]attestation.Envelope, error)
FetchBySubject calls the attestation reader with a filter preconfigured with subject hashes.
func (*Collector) Store ¶ added in v0.2.7
func (c *Collector) Store(ctx context.Context, opts attestation.StoreOptions, envelopes []attestation.Envelope) error
Store implements the attestation.Storer interface
type Options ¶
Click to show internal directories.
Click to hide internal directories.