Skip to content

Commit

Permalink
fix validation error (sigstore#503)
Browse files Browse the repository at this point in the history
Signed-off-by: Asra Ali <asraa@google.com>
  • Loading branch information
asraa authored and mikhailswift committed Dec 1, 2021
1 parent abe3689 commit b5a7923
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/types/hashedrekord/v0.0.1/entry.go
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ func (v *V001Entry) validate() error {
}
v.sigObj, err = artifactFactory.NewSignature(bytes.NewReader(sig.Content))
if err != nil {
return errors.Wrap(err, "creating new signature object")
return types.ValidationError(err)
}

key := sig.PublicKey
Expand All @@ -167,7 +167,7 @@ func (v *V001Entry) validate() error {
}
v.keyObj, err = artifactFactory.NewPublicKey(bytes.NewReader(key.Content))
if err != nil {
return errors.Wrap(err, "creating new public key object")
return types.ValidationError(err)
}

data := v.HashedRekordObj.Data
Expand Down

0 comments on commit b5a7923

Please sign in to comment.