Repository navigation
Harden wolfTPM transport handling - #634
aidangarske wants to merge 13 commits into
Conversation
3bf899e to
3565eec
Compare
wolfSSL-Fenrir-bot
left a comment
There was a problem hiding this comment.
Fenrir Automated Review — PR #634
Scan targets checked: wolftpm-src, wolftpm-bugs
Coverage: 7 of 14 in-scope changed file(s) opened by the reviewer; not opened: hal/tpm_io_fwtpm.c, src/fwtpm/fwtpm_main.c, tests/fwtpm_io_test_adapter.c, tests/fwtpm_unit_tests.c, wolftpm/fwtpm/fwtpm.h, wolftpm/fwtpm/fwtpm_io.h, wolftpm/fwtpm/fwtpm_tis.h
Fenrir result: Approved ✅
No new issues found in the changed files.
Advisory only — this automated result does not count as a GitHub approval.
Review tier: Lite
| int cmdPort; /* Command port (default 2321) */ | ||
| int platPort; /* Platform port (default 2322) */ | ||
| FWTPM_IO_HAL ioHal; /* IO transport HAL callbacks */ | ||
| FWTPM_IO_HAL ioHal; /* Reserved IO transport callbacks */ |
There was a problem hiding this comment.
Fix comment alignment while you are in this code. ioHal should be functional, so please double check.
|
|
||
| /* IO transport HAL callbacks — socket transport only (not used in TIS mode) */ | ||
| /* Reserved IO transport callbacks. The built-in socket server stores this | ||
| * structure but does not currently invoke it (not available in TIS mode). */ |
3565eec to
f331d0e
Compare
|
|
||
| FWTPM_Init(&ctx); | ||
|
|
||
| /* Set custom IO transport after FWTPM_Init, which does not preserve the IO HAL */ |
There was a problem hiding this comment.
Do we still need to remove this code example?
|
|
||
| FWTPM_Init(&ctx); | ||
|
|
||
| /* Set custom IO transport after FWTPM_Init, which does not preserve the IO HAL */ |
|
|
||
| /* For read we always need this guard time. | ||
| * (success wake or real read) */ | ||
| XSLEEP_MS(WRITE_TO_READ_GUARD_TIME); /* guard time - should be min 250us */ |
There was a problem hiding this comment.
Are we not able to map XSLEEP_MS -> esp_rom_delay_us (ms * 1000)?
f331d0e to
613e325
Compare
F-14027- 8e1385c - NV state deletion failures are now returned instead of being treated as successful cleanup.F-14091- 5c7381b - Rejected I2C reads now clear the caller's output buffer.F-14214- 9043cef - Writes to the read-only TIS burst-count registers are now ignored.F-14684- 177d4e7 - The MSSIM transport now rejects unsupported hash-data framing.F-15711- c71a3c7 - The Espressif HAL now honors configured transfer and device overrides.F-15713- 1e56d44 - Atmel SPI status polling now has a finite retry bound.F-15714- 2afeab0 - HAL initialization now returns SPI setup failures.F-15730- a992186 - Semaphore comments now accurately document their trust boundary.F-15734- 69dd9ed - The TIS wait helper documentation now states its actual return contract.F-15735- 89b1014 - Transport API documentation now describes the implemented return values.F-15737- ebdd6ba - Socket HAL documentation now matches its actual error handling.F-15770- 08f429f - Espressif I2C timing guards now use microseconds consistently.F-15771- 3bf899e - Infineon I2C timing guards now account for the accessed register.