Skip to contentSkip to conversation

ima/ima_measurements.sh: Add info about tests expecting tcb policy

PATCH New Petr Vorel 2 participants 3 messages Apr 27, 2018 – May 1, 2018

lore
Share & tools
lore

Petr Vorel

author
#0 lore raw

PATCH 1/1 ima/ima_measurements.sh: Add info about tests expecting tcb policy

IMA tests assume tcb policy [1]. But only measurement tests are failing, let's puts the info only for them.

This should be better detected [1] as after tests running for first time tcb policy is loaded by ima_policy.sh test.

[1] https://lists.linux.it/pipermail/ltp/2018-April/007924.html

---
 testcases/kernel/security/integrity/ima/tests/ima_measurements.sh | 2 ++
 1 file changed, 2 insertions(+)
testcases/kernel/security/integrity/ima/tests/ima_measurements.sh +2 -0
index 294e29d30..88eabd2a3 100755
@@ -37,6 +37,8 @@ setup()
 	DIGEST_INDEX=
 	grep -q "ima-ng" $ASCII_MEASUREMENTS && DIGEST_INDEX=1
 	grep -q "ima-sig" $ASCII_MEASUREMENTS && DIGEST_INDEX=2
+
+	tst_res TINFO "IMA measurement tests assume tcb policy to be loaded (ima_policy=tbc)"
 }
 
 # TODO: find support for rmd128 rmd256 rmd320 wp256 wp384 tgr128 tgr160
Signature · 1 line
2.16.3
#1 lore raw

PATCH 1/1 ima/ima_measurements.sh: Add info about tests expecting tcb policy

Quoted 20 lines · Petr Vorel

IMA tests assume tcb policy [1]. But only measurement tests are failing, let's puts the info only for them.

This should be better detected [1] as after tests running for first time tcb policy is loaded by ima_policy.sh test.

[1] https://lists.linux.it/pipermail/ltp/2018-April/007924.html

---
 testcases/kernel/security/integrity/ima/tests/ima_measurements.sh | 2 ++
 1 file changed, 2 insertions(+)
testcases/kernel/security/integrity/ima/tests/ima_measurements.sh +0 -0
index 294e29d30..88eabd2a3 100755

testcases/kernel/security/integrity/ima/tests/ima_measurements.sh setup() · line 42

Quoted 6 lines
testcases/kernel/security/integrity/ima/tests/ima_measurements.sh +2 -0
@@ -37,6 +37,8 @@ setup()
 	DIGEST_INDEX=
 	grep -q "ima-ng" $ASCII_MEASUREMENTS && DIGEST_INDEX=1
 	grep -q "ima-sig" $ASCII_MEASUREMENTS && DIGEST_INDEX=2
+
+	tst_res TINFO "IMA measurement tests assume tcb policy to be loaded (ima_policy=tbc)"
 }

^tcb

Quoted 1 line
testcases/kernel/security/integrity/ima/tests/ima_measurements.sh +0 -0
 # TODO: find support for rmd128 rmd256 rmd320 wp256 wp384 tgr128 tgr160
author
#2 lore raw

PATCH 1/1 ima/ima_measurements.sh: Add info about tests expecting tcb policy

Hi Mimi,

Quoted 2 lines

testcases/kernel/security/integrity/ima/tests/ima_measurements.sh setup() · line 41

Quoted 1 line
testcases/kernel/security/integrity/ima/tests/ima_measurements.sh +1 -0
+	tst_res TINFO "IMA measurement tests assume tcb policy to be loaded (ima_policy=tbc)"

^tcb

Thanks for reporting, fixed.

Kind regards,
Petr