All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mimi Zohar <zohar@linux.ibm.com>
To: linux-integrity <linux-integrity@vger.kernel.org>
Cc: ltp@lists.linux.it, Petr Vorel <pvorel@suse.cz>
Subject: [PATCH] ima: skip verifying TPM 2.0 PCR values
Date: Thu, 16 May 2019 17:12:42 -0400	[thread overview]
Message-ID: <1558041162.3971.2.camel@linux.ibm.com> (raw)

TPM 1.2 exported the PCRs.  Reading the TPM 2.0 PCRs requires a
userspace application.  For now, skip this test.

Signed-off-by: Mimi Zohar <zohar@linux.ibm.com>
---
 testcases/kernel/security/integrity/ima/tests/ima_tpm.sh | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/testcases/kernel/security/integrity/ima/tests/ima_tpm.sh b/testcases/kernel/security/integrity/ima/tests/ima_tpm.sh
index 0ffc3c02247d..ebe4b4c360e4 100755
--- a/testcases/kernel/security/integrity/ima/tests/ima_tpm.sh
+++ b/testcases/kernel/security/integrity/ima/tests/ima_tpm.sh
@@ -88,6 +88,14 @@ test2()
 	tst_res TINFO "verify PCR values"
 	tst_check_cmds evmctl
 
+	local tpm_description="/sys/class/tpm/tpm0/device/description"
+	if [ -f "$tpm_description" ]; then
+		if grep -q "^\TPM 2.0" $tpm_description; then
+			tst_res TCONF "TPM 2.0 enabled, but not supported"
+			return 0
+		fi
+	fi
+
 	tst_res TINFO "evmctl version: $(evmctl --version)"
 
 	local pcrs_path="/sys/class/tpm/tpm0/device/pcrs"
-- 
2.7.5


WARNING: multiple messages have this Message-ID (diff)
From: Mimi Zohar <zohar@linux.ibm.com>
To: ltp@lists.linux.it
Subject: [LTP] [PATCH] ima: skip verifying TPM 2.0 PCR values
Date: Thu, 16 May 2019 17:12:42 -0400	[thread overview]
Message-ID: <1558041162.3971.2.camel@linux.ibm.com> (raw)

TPM 1.2 exported the PCRs.  Reading the TPM 2.0 PCRs requires a
userspace application.  For now, skip this test.

Signed-off-by: Mimi Zohar <zohar@linux.ibm.com>
---
 testcases/kernel/security/integrity/ima/tests/ima_tpm.sh | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/testcases/kernel/security/integrity/ima/tests/ima_tpm.sh b/testcases/kernel/security/integrity/ima/tests/ima_tpm.sh
index 0ffc3c02247d..ebe4b4c360e4 100755
--- a/testcases/kernel/security/integrity/ima/tests/ima_tpm.sh
+++ b/testcases/kernel/security/integrity/ima/tests/ima_tpm.sh
@@ -88,6 +88,14 @@ test2()
 	tst_res TINFO "verify PCR values"
 	tst_check_cmds evmctl
 
+	local tpm_description="/sys/class/tpm/tpm0/device/description"
+	if [ -f "$tpm_description" ]; then
+		if grep -q "^\TPM 2.0" $tpm_description; then
+			tst_res TCONF "TPM 2.0 enabled, but not supported"
+			return 0
+		fi
+	fi
+
 	tst_res TINFO "evmctl version: $(evmctl --version)"
 
 	local pcrs_path="/sys/class/tpm/tpm0/device/pcrs"
-- 
2.7.5


             reply	other threads:[~2019-05-16 21:13 UTC|newest]

Thread overview: 42+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-16 21:12 Mimi Zohar [this message]
2019-05-16 21:12 ` [LTP] [PATCH] ima: skip verifying TPM 2.0 PCR values Mimi Zohar
2019-05-17  6:51 ` Petr Vorel
2019-05-17  6:51   ` [LTP] " Petr Vorel
2019-05-17 11:19   ` Mimi Zohar
2019-05-17 11:19     ` [LTP] " Mimi Zohar
2019-05-17 11:28     ` Petr Vorel
2019-05-17 11:28       ` [LTP] " Petr Vorel
2019-05-17 13:50 ` Nayna
2019-05-17 13:50   ` [LTP] " Nayna
2019-05-17 15:04   ` Petr Vorel
2019-05-17 15:04     ` [LTP] " Petr Vorel
2019-10-24 12:18     ` Petr Vorel
2019-10-24 12:18       ` Petr Vorel
2019-10-24 17:20       ` Jarkko Sakkinen
2019-10-24 17:20         ` Jarkko Sakkinen
2019-10-24 18:20         ` Jason Gunthorpe
2019-10-24 18:20           ` Jason Gunthorpe
2019-10-24 19:14           ` Jarkko Sakkinen
2019-10-24 19:14             ` Jarkko Sakkinen
2019-10-24 23:36             ` Jason Gunthorpe
2019-10-24 23:36               ` Jason Gunthorpe
2019-10-28 20:51               ` Jarkko Sakkinen
2019-10-28 20:51                 ` Jarkko Sakkinen
2019-10-24 21:38         ` Jerry Snitselaar
2019-10-24 21:38           ` Jerry Snitselaar
2019-10-24 23:26           ` Jason Gunthorpe
2019-10-24 23:26             ` Jason Gunthorpe
2019-10-25  0:47           ` Mimi Zohar
2019-10-25  0:47             ` Mimi Zohar
2019-10-25  2:11             ` Jerry Snitselaar
2019-10-25  2:11               ` Jerry Snitselaar
2019-10-25  8:56               ` Petr Vorel
2019-10-25  8:56                 ` Petr Vorel
2019-10-25 12:52                 ` Serge E. Hallyn
2019-10-25 12:52                   ` Serge E. Hallyn
2019-10-25 13:22                   ` Mimi Zohar
2019-10-25 13:22                     ` Mimi Zohar
2019-10-25 13:25                   ` Petr Vorel
2019-10-25 13:25                     ` Petr Vorel
2019-10-25 14:13                 ` Jerry Snitselaar
2019-10-25 14:13                   ` Jerry Snitselaar

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1558041162.3971.2.camel@linux.ibm.com \
    --to=zohar@linux.ibm.com \
    --cc=linux-integrity@vger.kernel.org \
    --cc=ltp@lists.linux.it \
    --cc=pvorel@suse.cz \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.