Skip to content

Certificate Format Updates#258

Open
amd-aliem wants to merge 3 commits into
AMDEPYC:mainfrom
amd-aliem:cert-format-updates
Open

Certificate Format Updates#258
amd-aliem wants to merge 3 commits into
AMDEPYC:mainfrom
amd-aliem:cert-format-updates

Conversation

@amd-aliem

@amd-aliem amd-aliem commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

Adds host and guest environment detection to certification reports so results include the exact software versions used during the run.

  • All detection is best-effort - failures produce None, never errors.
  • Guest OS detection happens lazily on first successful VM launch, then is cached in the environment dict.
  • The environment dict is threaded through existing call chains rather than stored as global state.
  • guest kernel reporting to be added in a follow-up PR.
Example Certification Formatting

Achieved Certification Level 3.0.0-1

Certified level: 3.0.0-1
Started: 2026-06-30T23:04:58.182398+00:00
Completed: 2026-06-30T23:05:13.829545+00:00

Environment

  • Host OS: Ubuntu 25.04
  • Host kernel: 6.14.0-37-generic
  • Guest OS: Ubuntu 26.04 LTS
  • QEMU: 9.2.1 (Debian 1:9.2.1+ds-1ubuntu5.2)
  • OVMF: 2025.02-3ubuntu2.2 (ovmf)

Level 3.0.0-0

Test Scope Result
attestation-test mixed

Level 3.0.0-1

Test Scope Result
snphost-config-commit host

Also improve cert markdown report headings and test table.
Copilot AI review requested due to automatic review settings June 30, 2026 22:33
Add os_info module to detect OS name/version from /etc/os-release on
both host (local file) and guest (via vsock). Display OS info in CLI
output and include it in the markdown report environment section.

Signed-off-by: Harika Nittala <lnittala@amd.com>
@amd-aliem amd-aliem force-pushed the cert-format-updates branch from 97863ef to 7d63ff0 Compare June 30, 2026 22:36

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR extends the certification reporting pipeline to capture and emit host/guest environment details (OS/kernel/QEMU/OVMF) so certification results record the software context used during a run.

Changes:

  • Added host environment detection (OS, kernel, QEMU, OVMF) and plumbed an environment dict through CLI execution and report writers.
  • Added guest OS detection via vsock and updates the shared environment dict after a successful VM launch.
  • Updated Markdown/JSON outputs to include the detected environment metadata, and refactored OVMF path discovery into a helper.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
sev_verify/vm_profile.py Adds find_ovmf_path() helper and reuses it when resolving OVMF firmware.
sev_verify/output.py Adds environment support to JSON/Markdown writers and renders an “Environment” section in Markdown.
sev_verify/os_info.py Introduces host /etc/os-release parsing and guest OS detection via vsock; updates the environment dict.
sev_verify/environment.py Implements best-effort host component/version detection (QEMU, kernel, OVMF, OS).
sev_verify/cli.py Wires environment detection into CLI flow; updates environment with guest OS after VM launches; passes environment into outputs.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread sev_verify/os_info.py Outdated
Comment thread sev_verify/os_info.py Outdated
Comment thread sev_verify/output.py
Copilot AI review requested due to automatic review settings June 30, 2026 22:37

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.

Comment thread sev_verify/output.py Outdated
Comment thread sev_verify/os_info.py Outdated
Comment thread sev_verify/os_info.py Outdated
Copilot AI review requested due to automatic review settings June 30, 2026 22:40

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.

Comment thread sev_verify/output.py Outdated
Comment thread sev_verify/output.py
Comment thread sev_verify/os_info.py
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@amd-aliem amd-aliem force-pushed the cert-format-updates branch from 18cfd45 to b0a9736 Compare June 30, 2026 23:08
@benland72

Copy link
Copy Markdown
  • All detection is best-effort - failures produce None, never errors.

Quick question(s):

  1. Will there be documentation updates to reflect that subtlety about detection being best effort with the possibility of seeing "None" ?
  2. Does a green check mark for a mixed scope test imply that it passed on both host and guest?

@amd-aliem

Copy link
Copy Markdown
Contributor Author

Quick question(s):

  1. Will there be documentation updates to reflect that subtlety about detection being best effort with the possibility of seeing "None" ?
  • Yes we can add a section to the Certifications page to call this out - it's likely a small bug if None shows up, the 'best effort' is to still allow the certificate to be pushed and published instead of erroring out, as the env section is informational.
  1. Does a green check mark for a mixed scope test imply that it passed on both host and guest?
  • Yes, failing any of the steps will result in a fail for the whole test.

@DGonzalezVillal

Copy link
Copy Markdown
Contributor

I personally like when I can also see the steps run for each test as part of the certification, just to get an idea of what's happening on each test. Do you guys think that makes the certificate too clustered?. That way also people don't necessarily need to see the source code of each test to see what's going on. I do like the additions of the environment.

Also for different cert generations, do you guys think we will generate different certificates? a cert for 3.0.0, one for 3.1.0 and one for 4.0.0?

@amd-aliem

Copy link
Copy Markdown
Contributor Author

I personally like when I can also see the steps run for each test as part of the certification, just to get an idea of what's happening on each test. Do you guys think that makes the certificate too clustered?. That way also people don't necessarily need to see the source code of each test to see what's going on. I do like the additions of the environment.

Agree, this will be added as a part of the PR that's currently in draft - it appends the steps after this part and you'll see it in the GH issue - see amd-aliem#187 for an example.

Also for different cert generations, do you guys think we will generate different certificates? a cert for 3.0.0, one for 3.1.0 and one for 4.0.0?

Agree that each manifest should have its own certificate (so we'll have one GH issue per HW generation set).

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.

5 participants