-
Notifications
You must be signed in to change notification settings - Fork 71
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
Update VerifyAttestation logic #209
Conversation
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.
This is basically correct, I can clean this up a merge it.
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.
@jkl73 @alexmwu I made some changes to how we do the hash algorithm validation.
Basically, this change just rejects all SHA-1 signatures, rather than using the opts.AllowSHA1
option to make it configurable. We only really need to allow SHA-1 for the PCRs, but we shouldn't ever need to accept SHA-1 signatures. TPM2s will always have SHA256 support for signing keys, even if a firmware issue leaves us with only SHA-1 TCG eventlog events.
PTAL and let me know if it looks good to you. I split this up into two separate commits to make review easier.
4098f9e
to
e430bd4
Compare
3ba3bee
to
72ad2e3
Compare
LGTM |
We now only allow SHA-1 for PCRs and not for the signing algorithm. This does two things: - Reduces the risk of SHA-1 collision attacks - Reduces the scope of the AllowSHA1 flag - Simplifies the signing validation logic Signed-off-by: Joe Richey <joerichey@google.com>
Also splits out the cert/key verification stuff into its own functions. Signed-off-by: Joe Richey <joerichey@google.com>
Signed-off-by: Joe Richey <joerichey@google.com>
Update VerifyAttestation to ignore pubkey if cert exists
Update hash validation on the signing hash algorithm in VerifyQuote
Signed-off-by: Jiankun Lu jiankun@google.com