[LTP] ima_tpm.sh: properly detect failure to verify the IMA measurement list
linuxtestproject.agent@gmail.com
linuxtestproject.agent@gmail.com
Wed Aug 26 03:15:34 CEST 2026
Hi Mimi,
On Tue, 25 Aug 2026, Mimi Zohar wrote:
> ima_tpm.sh: properly detect failure to verify the IMA measurement list
> if [ -z "$pcr" ]; then
> tst_res $res "failed to find aggregate PCR-10 $msg"
> tst_res TINFO "hash file:"
> cat hash.txt >&2
> - return
> + return 1
> fi
> + else
> + tst_res TFAIL "aggregate PCR value does not match real PCR value"
> + fi
Could the helper's result classification be preserved here instead of
unconditionally adding TFAIL for every nonzero return?
When evmctl is older than 1.3.1 with a SHA-1 measurement list, setup allows
the test to continue with MISSING_EVMCTL=1. If that evmctl does not produce
a parseable aggregate, the helper reports TCONF through $res, but the new
return path then also records TFAIL. Since tst_res retains both result bits,
this unsupported-tool path becomes a test failure.
Verdict - Needs revision
---
Note:
The agent can sometimes produce false positives although often its
findings are genuine. If you find issues with the review, please
comment this email or ignore the suggestions.
Regards,
LTP AI Reviewer
More information about the ltp
mailing list