Open Foxboron opened 1 year ago
Thanks for this issue! Yes, we should use this.
I can write up a suggestion if we are fine with loosing support for a few curves.
Hmm, more than P224? I think we'd have to discuss this in our team but if you sent a PR it would prompt such discussion, thanks!
We'll largely be limited to the supported curves in crypto/ecdh
which would be P256, P384 and P521 which is a small subset of what TPMs intend to provide support for.
Alternatively one can implement the ecdh.Curve
interface on the stuff that would need it in the future.
Yeah, I will also take a look on my side to see if the Go crypto team would be receptive to adding those curves.
It seems like
tpmdirect
is dealing with a bit of low-level stuff to accomplish ECDH which is mostly solved with the newcrypto/ecdh
package.Would it be a good idea to consider using this package maybe?
Currently the only missing part is
TPMECCNistP224
whichcrypot/ecdh
doesn't implement.