Skip to content

Commit

Permalink
fixing if statement
Browse files Browse the repository at this point in the history
Signed-off-by: chaosinthecrd <[email protected]>
  • Loading branch information
ChaosInTheCRD committed Feb 19, 2024
1 parent c289ad2 commit 086a263
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions cmd/verify.go
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ const (
// todo: this logic should be broken out and moved to pkg/
// we need to abstract where keys are coming from, etc
func runVerify(ctx context.Context, vo options.VerifyOptions, verifiers ...cryptoutil.Verifier) error {
if vo.KeyPath == "" && len(vo.CAPaths) == 0 && len(verifiers) == 0 {
if vo.KeyPath == "" && len(vo.PolicyCARootPaths) == 0 && len(verifiers) == 0 {
return fmt.Errorf("must supply either a public key, CA certificates or a verifier")
}

Expand Down Expand Up @@ -134,7 +134,6 @@ func runVerify(ctx context.Context, vo options.VerifyOptions, verifiers ...crypt

ptsVerifiers = append(ptsVerifiers, timestamp.NewVerifier(timestamp.VerifyWithCerts([]*x509.Certificate{cert})))
}

}

inFile, err := os.Open(vo.PolicyFilePath)
Expand Down

0 comments on commit 086a263

Please sign in to comment.