Skip to content

Remote attestation with PCRs and AMD SEV-SNP on GCP using RHCOS#39

Open
iroykaufman wants to merge 2 commits into
trusted-execution-clusters:mainfrom
iroykaufman:trustee-on-GCP
Open

Remote attestation with PCRs and AMD SEV-SNP on GCP using RHCOS#39
iroykaufman wants to merge 2 commits into
trusted-execution-clusters:mainfrom
iroykaufman:trustee-on-GCP

Conversation

@iroykaufman
Copy link
Copy Markdown

See README.md for details.

Comment thread trustee-on-GCP/rh-coreos/Containerfile Outdated
Comment thread trustee-on-GCP/rh-coreos/luks.bu
Comment thread trustee-on-GCP/rh-coreos/Containerfile Outdated
@alicefr
Copy link
Copy Markdown
Contributor

alicefr commented Oct 7, 2025

@iroykaufman can you please use the clevis pin instead of the old script running the attestation agent? It should also be easier for you. We should align to the latest way to perform attestation

@iroykaufman iroykaufman force-pushed the trustee-on-GCP branch 2 times, most recently from 0c280f3 to e2e5133 Compare October 23, 2025 08:48
Comment thread configs/trustee-gcp/containers/kbc.container
Comment thread coreos/justfile Outdated
label := if os == "scos" { scos_label } else { fcos_label }
archive := os + ".ociarchive"
platform := "qemu"
kbc_image := "quay.io/afrosi_rh/kbs-client-image:latest"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

This version support TPM as an additional device?

Copy link
Copy Markdown
Contributor

@alicefr alicefr Oct 30, 2025

Choose a reason for hiding this comment

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

Yes, it is built from the latest guest component, but you need to register the trusted AK in trustee.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

I checked again in the upstream and it's look like the TPM can only be primary device. This is where I look https://github.com/confidential-containers/guest-components/blob/main/attestation-agent/attester/src/lib.rs .
I created this PR#1093 to add this option

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Sorry, I might have misunderstood the previous comment. Isn't the tpm the attester used on GCP?

Copy link
Copy Markdown
Author

@iroykaufman iroykaufman Oct 30, 2025

Choose a reason for hiding this comment

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

Not only, also SEV-SNP is use for attestation. I add the option for a vm with TPM and another TEE to set the TPM as an additional device for attestation.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Ah I see. We didn't detect this because the local dev environment isn't a real CVM. Would you mind to fork the guest component in our org and add your patch there? In this way, we know which version is working and build the images out of it. Once, the PR is merged we can delete the repository.
We should try to have common images where we do our testing otherwise, it becomes very messy
/cc @Jakob-Naucke

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

I don't have permissions to add a fork.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I added you, you should have an invitation

Comment thread trustee-on-GCP/scripts/deploy-client.sh Outdated
Comment thread coreos/justfile Outdated
Comment thread trustee-on-GCP/README.md Outdated
Comment thread configs/trustee-gcp.bu Outdated
@iroykaufman iroykaufman force-pushed the trustee-on-GCP branch 3 times, most recently from c84a30a to ca6e9e4 Compare November 16, 2025 14:06
@iroykaufman iroykaufman force-pushed the trustee-on-GCP branch 2 times, most recently from 986fc71 to 02ee44c Compare November 23, 2025 15:05
@iroykaufman iroykaufman requested a review from alicefr November 23, 2025 15:08
Comment thread pin-trustee.bu Outdated
@@ -0,0 +1,21 @@
variant: fcos
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Comment thread run.sh Outdated
Comment thread configs/luks.bu Outdated
@@ -0,0 +1,41 @@
variant: fcos
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Comment thread coreos/Containerfile Outdated
Comment on lines +3 to +4
FROM quay.io/rkaufman/trustee-attester:TPM-additional-dev as kbc
FROM quay.io/trusted-execution-clusters/clevis-pin-trustee as clevis
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

why replacing the variables?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

This is also outdated, I replace all of them to be taken from quay.io/trusted-execution-clusters so it will match the upstream.

@@ -0,0 +1,32 @@
#!/bin/bash
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

What is script used for if you have also the script populate_kbs_gcp?

Comment thread configs/trustee/populate_kbs_gcp.sh Outdated
# Create attestation policy
## This policy allows access only if the system’s TPM or SNP
## hardware measurements match trusted reference values
cat << 'EOF' > A_policy.rego
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

It is a bit confusing because you have olso the configs/containers/policy.rego. Which on are you using for the demo?

Copy link
Copy Markdown
Author

@iroykaufman iroykaufman Nov 27, 2025

Choose a reason for hiding this comment

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

I'm using A_policy.rego. configs/containers/policy.rego was there from the previous setup for bare-metal VM

@alicefr
Copy link
Copy Markdown
Contributor

alicefr commented Nov 27, 2025

@iroykaufman can you please clean-up the commits structure? There are several commits that changes what the previous commit does, it makes it a bit hard to review and the git commit history isn't that clean. Also you have 2 scripts for populate the kbs, which one is the correct one?

@iroykaufman iroykaufman force-pushed the trustee-on-GCP branch 5 times, most recently from 4e3ca3c to 41425d6 Compare November 27, 2025 13:59
Comment thread coreos/usr/lib/dracut/modules.d/66tmp_tools/module-setup.sh Outdated
Comment thread scripts/GCP/deploy-vm.sh Outdated
Comment thread configs/trustee/populate_kbs.sh Outdated
@alicefr
Copy link
Copy Markdown
Contributor

alicefr commented Dec 16, 2025

@iroykaufman we are getting close, just a few last questions and comments

@iroykaufman iroykaufman requested a review from alicefr December 18, 2025 07:55
@iroykaufman iroykaufman force-pushed the trustee-on-GCP branch 5 times, most recently from 330c480 to 8a489ea Compare January 22, 2026 12:39
Copy link
Copy Markdown
Contributor

@uril uril left a comment

Choose a reason for hiding this comment

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

Looks good; I added some comments.

Comment thread configs/trustee/populate_kbs.sh Outdated
Comment thread configs/trustee/populate_kbs.sh Outdated
Comment thread coreos/justfile Outdated
Comment thread coreos/justfile Outdated
Signed-off-by: Roy Kaufman <rkaufman@redhat.com>
using AK registration

Signed-off-by: Roy Kaufman <rkaufman@redhat.com>
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.

4 participants