Closed zanebeckwith closed 5 years ago
Thanks.
FYI: That failed travis build appears to have been a transient issue; I can't recreate it (either on travis or locally).
The issue was an assert that failed due to the TPM returning one of the signature values with a size different from expected (since it's an assert, I don't know what the size actually was). After that assert, I copy the output from the signature value and into an AMCL curve point structure. The size to copy is constant (set by the modulus of the finite field).
It's very strange that the size wouldn't be the same constant value, and I think this must have been due to some failure in the simulator.
I think this actually isn't a problem, surprisingly, because of the static sizing of xaptum-tpm.
However, avoiding a buffer overflow is easy so I'm adding that as a separate PR.
More-recent TPM2.0 specifications include a change to the TPM2_Sign operation that breaks the old implementation of this library. This series updates our implementation to accord with that change.
fixes #112