Repository navigation
Support for tpm persistent handles in TSS2 privkey - #165
royalsreafer wants to merge 1 commit into
Conversation
a82ff3e to
d68463f
Compare
|
@royalsreafer I've just seen your approach to use persistent handles. Integrates much nicer into the existing ASN1 structure. |
|
Is there anything we can do to move this PR along? We're currently using a forked version of tpm2-openssl with this patch, which isn't a big deal on its own, but having it in the upstream release is even better. |
|
@AndreasFuchsTPM @moritzbuhl I've tagged you since you seem to be the most active at the moment. I wonder If there is anything I/we can do to move the PR along? Any response is much appreciated. |
|
I'll take a look on Monday. |
|
Could you rebase onto the recently committed CI fixes? |
40ceb7a to
182cd5c
Compare
Signed-off-by: RoyalReafer <royalsmods@hotmail.com>
|
Hi! Just wanted to check if there’s anything else needed before this can be merged. Since it’s approved and all checks are passing, it would be great to get it into upstream. Thanks! |
|
Since the public part of the persistent key is in the PEM it would make senste to compare the public part with the one on the TPM right after |
This commit adds support for encoding and decoding of TSS2 pem files which contain references to persistent handles. The handle is stored in the same privkey area as the keyblob. The length(4 bytes) and the first byte(0x81 for persistent handles) distinguishes it as a persistent key stored in the TPM. This approach keeps true to the ASN1 structure defined in OID "2.23.133.10.1.3" .
I've used this patch for a while now and has been working out for our use-case. The use-case being adding support for TPM2 keys without changing the code of applications. Many applications supporting OpenSSL, do not support loading TPM keys with the handle:81xxxxxx due to the ossl_store_ex not being called. TSS2 pem keys circumvent this and adding persistent key handle support to this format solved the issue with TPM2 persistent key support.
Another pull request with a different approach #162