David Garske
1426f76e4c
New WOLFTPM2 types for handle, session and key. New wrappers for starting session and creating/loading keys. Changed `TPM2_GetNonce` to use current ctx and not use arg. Cleanup of bad arg return code.
2018-03-03 18:49:53 -05:00
David Garske
fca0af99a8
Progress with refactor to support parameter encryption/decryption using both session auth and object auth. Cleanup with the response parsing to reduce code / simplify.
2018-03-03 05:03:14 -08:00
David Garske
98181f573a
Cleanups based on peer review. Changed the IO callback return type to int.
2018-03-02 09:22:36 +01:00
David Garske
5364c711f0
Fixes after refactor. Further fixes for error code string lookup.
2018-02-28 07:58:27 +01:00
David Garske
6fa51c27a8
Fix for error code reporting. The `RC_VER1`, `RC_FMT1` and `RC_WARN` values are a bit-mask to indicate group. Only the LSB 8-bits indicate error code.
2018-02-28 00:24:25 +01:00
David Garske
85cd1a5b68
Initial progress on supporting encrypt/decrypt for TPM commands. Moved the software RNG support into TPM code. Added new `TPM2_Cleanup` function for making sure resources are free'd and global ctx released.
2018-02-27 23:49:07 +01:00
David Garske
fa0d94fbb3
Refactor TIS and Packet code into separate files. Updates to README.md. Increased the Raspberry Pi SPI clock to 33Mhz.
2018-02-27 23:45:41 +01:00
David Garske
5cd7d3cc50
Progress with getting NV working.
2018-02-26 23:53:42 +01:00
David Garske
c2d23f927e
Fixes for parsing/appending `TPMT_SIGNATURE`. Added tests for `TPM2_ECDH_KeyGen`, `TPM2_ECC_Parameters`, `TPM2_VerifySignature` and `TPM2_NV_UndefineSpace`.
2018-02-26 01:28:40 +01:00
David Garske
99afd8f0d5
Added way to set the auth resp using `TPM2_SetSessionAuth`.
2018-02-24 21:25:31 -08:00
David Garske
69eea6f034
Fixes for TPM2 commands expecting TPM_ST_SESSIONS. Added tests for TPM2_ReadPublic, TPM2_MakeCredential, TPM2_PolicyCommandCode, TPM2_ObjectChangeAuth.
2018-02-24 21:18:49 -08:00
David Garske
2d8e3b3eb7
Added TPM2_StirRandom, TPM2_PolicyRestart, TPM2_LoadExternal and TPM2_EvictControl. Fix for CC value typo. Updates to README.md.
2018-02-24 19:30:18 -08:00
David Garske
986fd398b7
Progress with creating keys. Able to create storage (platform) and endorsement primary keys. Still working on creating ECC key.
2018-02-23 12:18:43 -08:00
David Garske
6c901be08a
Progress with creating an ECC key.
2018-02-19 16:35:03 -08:00
David Garske
f4cd4028d5
Fixes for session auth information and getting CreatePrimary working.
2018-02-16 12:22:34 -08:00
David Garske
e02518dc3e
Added `TPM2_CreatePrimary` test.
2018-02-15 15:45:15 -08:00
David Garske
78876923cc
Adds wrapper code. Adds tests for `TPM2_PolicyPCR` and `TPM2_FlushContext`.
2018-02-15 10:20:19 -08:00
David Garske
43b0682dd8
Fixes for proper handling of `TPMT_SYM_DEF` or `TPMT_SYM_DEF_OBJECT` when `TPM_ALG_NULL` (don't append keyBits and mode). Refactor of the param details and scheme. Refactor of the session information into TPM context.
2018-02-14 14:11:01 -08:00
David Garske
156fc9b521
Added Linux SPI stdio support for running on Rasberry Pi. Cleanups for wolfTPM.
2018-02-08 12:21:39 -08:00
David Garske
35a585828b
Updates to the IDE example for STM32.
2018-02-07 15:28:31 -08:00
David Garske
8bf8ae340f
wolfTPM v1.0 TPM 2.0 support:
...
* Support for all TPM2 API's using TIS and SPI IO callback.
* Helper for getting TPM return code string `TPM2_GetRCString`.
* TPM 2.0 demo code in `examples/tpm/tpm2_demo.c` with support for STM32 CubeMX SPI as reference.
Requires wolfSSL (https://github.com/wolfSSL/wolfssl/pull/1344 )
2018-02-06 16:27:50 -08:00