rename type
Signed-off-by: Meredith Lancaster <malancas@github.com>
This commit is contained in:
parent
ff9b6bb883
commit
8ab5f247af
4 changed files with 5 additions and 5 deletions
|
|
@ -122,7 +122,7 @@ func runDownload(opts *Options) error {
|
|||
|
||||
opts.Logger.VerbosePrintf("Downloading trusted metadata for artifact %s\n\n", opts.ArtifactPath)
|
||||
|
||||
c := verification.FetchAttestationsConfig{
|
||||
c := verification.FetchRemoteAttestations{
|
||||
APIClient: opts.APIClient,
|
||||
Digest: artifact.DigestWithAlg(),
|
||||
Limit: opts.Limit,
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ const SLSAPredicateV1 = "https://slsa.dev/provenance/v1"
|
|||
var ErrUnrecognisedBundleExtension = errors.New("bundle file extension not supported, must be json or jsonl")
|
||||
var ErrEmptyBundleFile = errors.New("provided bundle file is empty")
|
||||
|
||||
type FetchAttestationsConfig struct {
|
||||
type FetchRemoteAttestations struct {
|
||||
APIClient api.Client
|
||||
Digest string
|
||||
Limit int
|
||||
|
|
@ -96,7 +96,7 @@ func loadBundlesFromJSONLinesFile(path string) ([]*api.Attestation, error) {
|
|||
return attestations, nil
|
||||
}
|
||||
|
||||
func GetRemoteAttestations(c FetchAttestationsConfig) ([]*api.Attestation, error) {
|
||||
func GetRemoteAttestations(c FetchRemoteAttestations) ([]*api.Attestation, error) {
|
||||
if c.APIClient == nil {
|
||||
return nil, fmt.Errorf("api client must be provided")
|
||||
}
|
||||
|
|
|
|||
|
|
@ -32,7 +32,7 @@ func getAttestations(o *Options, a artifact.DigestedArtifact) ([]*api.Attestatio
|
|||
return attestations, msg, nil
|
||||
}
|
||||
|
||||
c := verification.FetchAttestationsConfig{
|
||||
c := verification.FetchRemoteAttestations{
|
||||
APIClient: o.APIClient,
|
||||
Digest: a.DigestWithAlg(),
|
||||
Limit: o.Limit,
|
||||
|
|
|
|||
|
|
@ -227,7 +227,7 @@ func runVerify(opts *Options) error {
|
|||
opts.Logger.Printf(opts.Logger.ColorScheme.Red("✗ No attestations found for subject %s\n"), artifact.DigestWithAlg())
|
||||
return err
|
||||
}
|
||||
|
||||
// Print the message signifying failure fetching attestations
|
||||
opts.Logger.Printf(opts.Logger.ColorScheme.Red(logMsg))
|
||||
return err
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue