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

azure: support Azure TDX CVMs for podvms #1703

Closed
mkulke opened this issue Feb 20, 2024 · 3 comments · Fixed by #1714
Closed

azure: support Azure TDX CVMs for podvms #1703

mkulke opened this issue Feb 20, 2024 · 3 comments · Fixed by #1714
Assignees
Labels
enhancement New feature or request podvm Related to podvm images provider/azure Issues related to Azure CAA provider

Comments

@mkulke
Copy link
Collaborator

mkulke commented Feb 20, 2024

at the moment we only build podvms images for Azure's SNP cvms. I think we need to need to extend the guest-components build-flags to also build the az-vtpm-tdx attester.

it's probably sufficient to extend make KBC="cc_kbc_az_snp_vtpm" to make KBC="cc_kbc_az_snp_vtpm cc_kbc_az_tdx_vtpm" for the guest-components's build. alternatively we can add guest-components build flag cc_kbc_az-cvm-vtpm that covers both.

@mkulke mkulke added enhancement New feature or request provider/azure Issues related to Azure CAA provider podvm Related to podvm images labels Feb 20, 2024
@cmaf
Copy link

cmaf commented Feb 22, 2024

@mkulke from the logs in a TDX VM in Azure using the nightly build image, I retrieved

[    0.000000] Hyper-V: Isolation Config: Group A 0x1, Group B 0xbe3

(suggested in https://www.youtube.com/watch?v=bG7T1Stm2c0). Is this sufficient or do we still need additional guest component build flags?

@mkulke
Copy link
Collaborator Author

mkulke commented Feb 22, 2024

So, if you are booting an instance size and see this in the logs, you can be positive that we're running on a TDX vm on azure.

sudo dmesg | grep -i encryption
[    0.624581] Memory Encryption Features active: Intel TDX
[    1.029536] software IO TLB: Memory encryption is active and system is using DMA bounce buffers

However if you want to do remote attestation with CoCo we need to add a compile-time-flag (i think) to guest-components: cc_kbc_az_tdx_vtpm, it might automagically work out of the box, but i'd be surprised. you could do a call to api-server-rest from inside the peerpod to see whether you can get a TDX report/TPM quote (kubectl exec into it):

curl http://127.0.0.1:8006/aa/evidence\?runtime_data\=xxxx

@fidencio
Copy link
Member

(suggested in https://www.youtube.com/watch?v=bG7T1Stm2c0). Is this sufficient or do we still need additional guest component build flags?

@cmaf, this is sufficient, and this is what we use as part of the cpuid project to check whether the VM is a TDX_GUEST or not, please, see: klauspost/cpuid@3a00e73

You're, indeed, running on a TDX guest!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request podvm Related to podvm images provider/azure Issues related to Azure CAA provider
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants