-
Notifications
You must be signed in to change notification settings - Fork 550
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cosigned: Unify cue data and policy before evaluating it #1793
Conversation
Codecov Report
@@ Coverage Diff @@
## main #1793 +/- ##
==========================================
- Coverage 32.70% 32.70% -0.01%
==========================================
Files 147 147
Lines 9300 9313 +13
==========================================
+ Hits 3042 3046 +4
- Misses 5903 5909 +6
- Partials 355 358 +3
Continue to review full report at Codecov.
|
f80b402
to
7625488
Compare
Can we try removing this and test if it now passes? 🤩 |
7625488
to
13fd665
Compare
test/testdata/cosigned/e2e/cip-requires-two-signatures-and-two-attestations.yaml
Show resolved
Hide resolved
13fd665
to
c4796ec
Compare
e027cff
to
7a87d68
Compare
Signed-off-by: hectorj2f <[email protected]>
Signed-off-by: hectorj2f <[email protected]>
Signed-off-by: hectorj2f <[email protected]>
Signed-off-by: hectorj2f <[email protected]>
Signed-off-by: hectorj2f <[email protected]>
Signed-off-by: hectorj2f <[email protected]>
Signed-off-by: hectorj2f <[email protected]>
Signed-off-by: hectorj2f <[email protected]>
7a87d68
to
2923f3d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thank you
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you so much for grinding through this!!!
* chore: update cue policy evaluation Signed-off-by: hectorj2f <[email protected]> * chore: change cue policy for the cip Signed-off-by: hectorj2f <[email protected]> * chore: avoid using names with hyphens Signed-off-by: hectorj2f <[email protected]> * test: add unit tests for the eval policy func Signed-off-by: hectorj2f <[email protected]> * test: delete job before creating it Signed-off-by: hectorj2f <[email protected]> * test: add statement to check the length of a struct Signed-off-by: hectorj2f <[email protected]> * test: add more unit tests for eval policy Signed-off-by: hectorj2f <[email protected]> * fix: wrong redirected file directory Signed-off-by: hectorj2f <[email protected]>
Summary
This PR adds code to compile both the policy and attestations data, then unify both cue files and finally validate them. The recommendation is to avoid using cuejson.Validate which expects the cue to be self-contained and applied as a schema to the JSON.
Ticket Link
Fixes
Release Note