Documentation ¶
Index ¶
- Constants
- func CreateNewTestStoreForNestedSbom() referrerstore.ReferrerStore
- type MemoryTestStore
- func (store *MemoryTestStore) GetBlobContent(_ context.Context, _ common.Reference, digest digest.Digest) ([]byte, error)
- func (store *MemoryTestStore) GetConfig() *config.StoreConfig
- func (store *MemoryTestStore) GetReferenceManifest(_ context.Context, _ common.Reference, desc ocispecs.ReferenceDescriptor) (ocispecs.ReferenceManifest, error)
- func (store *MemoryTestStore) GetSubjectDescriptor(_ context.Context, subjectReference common.Reference) (*ocispecs.SubjectDescriptor, error)
- func (store *MemoryTestStore) ListReferrers(_ context.Context, _ common.Reference, _ []string, _ string, ...) (referrerstore.ListReferrersResult, error)
- func (store *MemoryTestStore) Name() string
- type TestStore
- func (s *TestStore) GetBlobContent(_ context.Context, _ common.Reference, _ digest.Digest) ([]byte, error)
- func (s *TestStore) GetConfig() *config.StoreConfig
- func (s *TestStore) GetReferenceManifest(_ context.Context, _ common.Reference, _ ocispecs.ReferenceDescriptor) (ocispecs.ReferenceManifest, error)
- func (s *TestStore) GetSubjectDescriptor(_ context.Context, subjectReference common.Reference) (*ocispecs.SubjectDescriptor, error)
- func (s *TestStore) ListReferrers(_ context.Context, _ common.Reference, _ []string, _ string, ...) (referrerstore.ListReferrersResult, error)
- func (s *TestStore) Name() string
Constants ¶
View Source
const ( TestSubjectWithDigest = "localhost:5000/net-monitor:v1@sha256:b556844e6e59451caf4429eb1de50aa7c50e4b1cc985f9f5893affe4b73f9935" SbomArtifactType = "application/spdx+json" SignatureArtifactType = "application/vnd.cncf.notary.signature" )
Variables ¶
This section is empty.
Functions ¶
func CreateNewTestStoreForNestedSbom ¶
func CreateNewTestStoreForNestedSbom() referrerstore.ReferrerStore
Types ¶
type MemoryTestStore ¶ added in v1.1.0
type MemoryTestStore struct { Subjects map[digest.Digest]*ocispecs.SubjectDescriptor Referrers map[digest.Digest][]ocispecs.ReferenceDescriptor Manifests map[digest.Digest]ocispecs.ReferenceManifest Blobs map[digest.Digest][]byte }
func (*MemoryTestStore) GetBlobContent ¶ added in v1.1.0
func (*MemoryTestStore) GetConfig ¶ added in v1.1.0
func (store *MemoryTestStore) GetConfig() *config.StoreConfig
func (*MemoryTestStore) GetReferenceManifest ¶ added in v1.1.0
func (store *MemoryTestStore) GetReferenceManifest(_ context.Context, _ common.Reference, desc ocispecs.ReferenceDescriptor) (ocispecs.ReferenceManifest, error)
func (*MemoryTestStore) GetSubjectDescriptor ¶ added in v1.1.0
func (store *MemoryTestStore) GetSubjectDescriptor(_ context.Context, subjectReference common.Reference) (*ocispecs.SubjectDescriptor, error)
func (*MemoryTestStore) ListReferrers ¶ added in v1.1.0
func (store *MemoryTestStore) ListReferrers(_ context.Context, _ common.Reference, _ []string, _ string, subjectDesc *ocispecs.SubjectDescriptor) (referrerstore.ListReferrersResult, error)
func (*MemoryTestStore) Name ¶ added in v1.1.0
func (store *MemoryTestStore) Name() string
type TestStore ¶
type TestStore struct { References []ocispecs.ReferenceDescriptor ResolveMap map[string]digest.Digest ExtraSubject string }
func (*TestStore) GetBlobContent ¶
func (*TestStore) GetConfig ¶
func (s *TestStore) GetConfig() *config.StoreConfig
func (*TestStore) GetReferenceManifest ¶
func (s *TestStore) GetReferenceManifest(_ context.Context, _ common.Reference, _ ocispecs.ReferenceDescriptor) (ocispecs.ReferenceManifest, error)
func (*TestStore) GetSubjectDescriptor ¶
func (*TestStore) ListReferrers ¶
func (s *TestStore) ListReferrers(_ context.Context, _ common.Reference, _ []string, _ string, _ *ocispecs.SubjectDescriptor) (referrerstore.ListReferrersResult, error)
Click to show internal directories.
Click to hide internal directories.