-
Notifications
You must be signed in to change notification settings - Fork 144
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
Want to use TPM as localCA #788
Comments
You would have to use a pkcs11 driver for TPM 2 (such as https://github.com/tpm2-software/tpm2-pkcs11) and use it for signing the certificate of the swtpm. For this you would have to have a signing key in the pkcs11 device and determine the pkcs11 URI of the key. There's a test case using softhsm as a pkcs11 device in this repo that shows how this can be done: https://github.com/stefanberger/swtpm/blob/master/tests/test_tpm2_swtpm_localca_pkcs11.test For this to work you need to modify an existing swtpm-localca.conf file to contain the pkcs11 URI of the key, and possibly also its PIN, rather than the typical name of the private key file: swtpm/tests/test_tpm2_swtpm_localca_pkcs11.test Lines 131 to 137 in 346b3d6
The challenge is likely to setup the pkcs11 device to provide the signing key. |
Actually, you could also try to follow this man page here for setting up the CA -- look for TPM 2 as CA: https://github.com/stefanberger/swtpm/blob/master/man/man8/swtpm-create-tpmca.pod#example |
This here is the workflow on Fedora (as root):
The tools needs some minor updating due to missing tpmtool now on Fedora but otherwise the packages are all available and ready to be used. |
Awesome! thanks for ur help |
I let you close this issue if it's resolved. Thanks. |
I would like to sign a vTPM ek certificate with hardware TPM to build a trust chain from TPM to vTPM, is there anyway to do so?
The text was updated successfully, but these errors were encountered: