You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Scan targets checked:wolftpm-src, wolftpm-bugs Coverage: 7 of 9 in-scope changed file(s) opened by the reviewer; not opened: wolftpm/fwtpm/fwtpm.h, wolftpm/fwtpm/fwtpm_crypto.h
Findings: 2 2 finding(s) posted as inline comments (see file-level comments below)
This review was generated automatically by Fenrir. Reported findings require changes before merge.
NV clear fails to erase stored data on Startup(CLEAR)
src/fwtpm/fwtpm_command.c:1078
[Medium, CWE-200] TPMA_NV_CLEAR_STCLEAR means the NV contents are cleared on Startup(CLEAR), but this branch only clears WRITTEN and the separate written flag. A subsequent partial write can make the index readable again while exposing untouched bytes from before the clear. Clear the stored data as part of this transition and preserve it in the existing rollback path if persistence fails.
Retry path leaves command secrets after transport failure
src/tpm2.c:653
[Medium, CWE-316] The retry-enabled variant has the same gap: a transport/SPDM failure returns at lines 629-631 before this final-attempt wipe, leaving the serialized command and its auth/plaintext parameters in the shared buffer. Wipe the command body on that early return too.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.