-
Notifications
You must be signed in to change notification settings - Fork 53
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
Calling MakeCredential without a TPM #160
Comments
Hi! That's an interesting idea! The TL;DR is that we don't support this and as far as I can tell, it would be a bit of work to support in the first place. I had to dig a bit around the specs/implementation of that
So in the tool they have code to actually do that, here. I think in this crate's case if we want to do the same thing, we'd do it as an Actually, come to think of it, this might be better suited for a separate (small) crate - separate folder in this repo - that pulls in only the FFI types and doesn't link with the TSS library, since you don't need to call it, you just need some of the types defined by it. |
I actually have an implementation of this for myself, which I planned to open source next week. |
Sweet! Is this in Rust? I'd be more than happy for it to be hosted here, unless you want to upstream it somewhere else - as long as there's an option out there! |
I have a usecase that could use a non-TPM backed implementation of |
I didn't try it but just recently by a random chance I found this: https://github.com/puiterwijk/tpmless-tpm2-rs/blob/main/src/credentials.rs#L62 : pub fn make_credential<CVT, KT, ONT>( From @puiterwijk's crate that's described as "Various TPM 2 related functions without the need of a live TPM". Hopefully this will be relevant to you, if not sorry for the noise :) |
There are a couple of problems with that implementation - I was hoping to use it for Parsec testing as well, however:
|
🤦 I just connected dots that someone was asking about it and didn't read the implementation to the end that it ends with a Okay, it was a noise after all - sorry for the commotion! 🙇 |
No, I think it's good to have an update on that here! I should've actually written something about it back when I was doing my key attestation work :) I hope I'll have some time to actually implement the "missing" KDF functions in Rust (by reusing some other pure-Rust crypto crates), implement |
I got the make credentials crypto to work with openssl3 (afaik only openssl3 provides the required kdf methods) and custom patches for openssl-rs here: https://github.com/baloo/reproducibility-lab/blob/main/pkgs/pcr-eventlog-attestation/src/tpm/credential.rs |
Indeed, I saw that OpenSSL 3 provides the right tools, but there were no proper bindings in Rust, and I couldn't wait for the proper bindings to come out 😢 Glad to see it's been done, though!! Have you tried upstreaming/making the changes in the "official" |
yeah, it has been closed because the author merged target branch and I haven't put the effort to rebase/resend the PR. |
Move end to end tests to own crate
It's been really hard to get traction with sfackler on anything, it may be worth using the RustCrypto ecosystem https://github.com/RustCrypto/ |
That is my plan. |
Yep, I'm planning similar for does some improved aes examples and maybe even x509. Would been keen to see and review any prs :) |
In tpm2-tools,
tpm2_makecredential
can be called without a TPM.Is there any way to call
context.makecredential(...)
without initializing a TCTI?The text was updated successfully, but these errors were encountered: