Skip to content
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

abi: parse v3 attestation reports #141

Merged
merged 1 commit into from
Nov 20, 2024

Conversation

daniel-weisse
Copy link
Contributor

On October 11th, AMD published revision 1.56 of the SEV-SNP Firmware ABI spec, which includes a new version for the attestation report struct.
The only change for the v3 report is the addition of cpuid family, model, and stepping information at bytes 0x188 to 0x18A.

This PR adds support for parse v3 reports.

I'm not super happy with the proto definition of the new fields as bytes, since it's really just a single byte.
If you have any better ideas on how to handle the values, please let me know.

@deeglaze
Copy link
Collaborator

I think formatting the family/model/stepping values in a uint32 the way they are expected to be in CPUID_1_EAX would be best if I'm honest, even if it's kind of weird looking. You'd have fmsToCpuid1Eax(f,m,s byte) uint32 and fmsFromCpuid1Eax(uint32) (byte,byte,byte) for the translations.

This should preclude needing ExtraPlatformInfo in the GUID table and a bunch of silliness in kds.go, but I won't block this PR on that. Just some cleanup.

@deeglaze deeglaze merged commit f3a6537 into google:main Nov 20, 2024
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants