notaryproject / notation-action

GitHub Actions for signing and verifying artifacts with Notation
https://notaryproject.dev/
Apache License 2.0
16 stars 7 forks source link

fix: fixed trust store logic in verify #38

Closed Two-Hearts closed 1 year ago

Two-Hearts commented 1 year ago

The verify action would fail if user verify with the same truststore dir more than one time. It would fail at the second verification. This is because, notation cert add would fail if cert already exists.

The fix is cleaning up notation/truststore per verify. We do this because every verify is independent of each other, and notation/truststore actually serves as a snapshot of the user input truststore dir. As long as the user set their truststore following notation's spec, the verify should work.