-
Notifications
You must be signed in to change notification settings - Fork 8
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
treewide: allow multiple validators #783
Conversation
3010fed
to
a353ac8
Compare
8520ec6
to
590bf28
Compare
590bf28
to
9cab51c
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.
lgtm
9cab51c
to
24e862b
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.
I'm not quite done with the review yet, but here are some preliminary comments.
ff9bf81
to
95fc2fb
Compare
95fc2fb
to
e72e418
Compare
d5ca88e
to
8537531
Compare
Could you add some tests please? |
I'm not exactly sure how we would go about testing the validators. There were no unit tests before, and implementing some would definitely require some considerations. I don't think this is something that should be done in this PR. For end-to-end testing, we'd probably also want a scenario where we'd have multiple reference values. But with the current Azure offerings, I don't think it's possible to request such a platform. What did you have in mind exactly @Freax13 ? |
I was thinking that we could have a test where we have multiple reference values with only one of them being the correct one and then make sure that attestation still works. If we really wanted multiple different platforms, we could also generate such reports once and hard-code them for the tests. |
Okay, I guess we could have some kind of testdata and put this into a unit test, or have an e2e test |
a5cf563
to
1479e93
Compare
This changes the attestation (as of now, only SEV-SNP) to be passed multiple validators. The aTLS code already handles multiple validators, but the code previously passed only one. This way, attestation will now work by being handed a list of validators, and returning success as soon as one can successfully validate a report. Furthermore, the `atls.NoValidator` is now obsolete, and semantically represented by passing an empty list of validators.
1479e93
to
0700ff2
Compare
This changes the attestation (as of now, only SEV-SNP) to be passed
multiple validators. The aTLS code already handles multiple validators,
but the code previously passed only one. This way, attestation will now
work by being handed a list of validators, and returning success as soon
as one can successfully validate a report. Furthermore, the
atls.NoValidator
is now obsolete, and semantically represented bypassing an empty list of validators.