All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
To: Nayna <nayna@linux.vnet.ibm.com>
Cc: tpmdd-devel@lists.sourceforge.net, peterhuewe@gmx.de,
	tpmdd@selhorst.net, jgunthorpe@obsidianresearch.com,
	linux-security-module@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH v7 2/2] tpm: add securityfs support for TPM 2.0 firmware event log
Date: Wed, 4 Jan 2017 15:01:18 +0200	[thread overview]
Message-ID: <20170104130118.2brkojj65vjhzca3@intel.com> (raw)
In-Reply-To: <586CB46E.8050207@linux.vnet.ibm.com>

On Wed, Jan 04, 2017 at 02:08:06PM +0530, Nayna wrote:
> 
> 
> On 01/03/2017 07:03 PM, Jarkko Sakkinen wrote:
> > On Tue, Jan 03, 2017 at 01:09:18PM +0530, Nayna wrote:
> > > 
> > > 
> > > On 01/03/2017 03:42 AM, Jarkko Sakkinen wrote:
> > > > On Sun, Dec 11, 2016 at 12:35:33AM -0500, Nayna Jain wrote:
> > > > > Unlike the device driver support for TPM 1.2, the TPM 2.0 does
> > > > > not support the securityfs pseudo files for displaying the
> > > > > firmware event log.
> > > > > 
> > > > > This patch enables support for providing the TPM 2.0 event log in
> > > > > binary form. TPM 2.0 event log supports a crypto agile format that
> > > > > records multiple digests, which is different from TPM 1.2. This
> > > > > patch enables the tpm_bios_log_setup for TPM 2.0  and adds the
> > > > > event log parser which understand the TPM 2.0 crypto agile format.
> > > > > 
> > > > > Signed-off-by: Nayna Jain <nayna@linux.vnet.ibm.com>
> > > > 
> > > > There is something fundamentally wrong in this commit.
> > > > 
> > > > You must not allow this feature unless CONFIG_OF is set. It is the only
> > > > interface where the supply path of the event log is well defined on
> > > > platforms that include a TPM 2.0 chip.
> > > 
> > > As per current implementation, if ACPI with TPM 2.0 doesn't support event
> > > log, tpm_read_log_acpi() is expected to return rc and tpm_bios_log_setup
> > > will not create securityfs. This is inline with our design for TPM 1.2 event
> > > log.
> > 
> > At minimum you must have a check for TPM_CHIP_FLAG_TPM2 in the beginning
> > of tpm_read_log_acpi. It is wrong to even try to open TCPA in this case.
> 
> Sure, will add this check and return -ENODEV if check passes.

Yeah, this is acceptable for me.

> Thanks & Regards,
>     - Nayna

/Jarkko

WARNING: multiple messages have this Message-ID (diff)
From: Jarkko Sakkinen <jarkko.sakkinen-VuQAYsv1563Yd54FQh9/CA@public.gmane.org>
To: Nayna <nayna-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org>
Cc: linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-security-module-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	tpmdd-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
Subject: Re: [PATCH v7 2/2] tpm: add securityfs support for TPM 2.0 firmware event log
Date: Wed, 4 Jan 2017 15:01:18 +0200	[thread overview]
Message-ID: <20170104130118.2brkojj65vjhzca3@intel.com> (raw)
In-Reply-To: <586CB46E.8050207-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org>

On Wed, Jan 04, 2017 at 02:08:06PM +0530, Nayna wrote:
> 
> 
> On 01/03/2017 07:03 PM, Jarkko Sakkinen wrote:
> > On Tue, Jan 03, 2017 at 01:09:18PM +0530, Nayna wrote:
> > > 
> > > 
> > > On 01/03/2017 03:42 AM, Jarkko Sakkinen wrote:
> > > > On Sun, Dec 11, 2016 at 12:35:33AM -0500, Nayna Jain wrote:
> > > > > Unlike the device driver support for TPM 1.2, the TPM 2.0 does
> > > > > not support the securityfs pseudo files for displaying the
> > > > > firmware event log.
> > > > > 
> > > > > This patch enables support for providing the TPM 2.0 event log in
> > > > > binary form. TPM 2.0 event log supports a crypto agile format that
> > > > > records multiple digests, which is different from TPM 1.2. This
> > > > > patch enables the tpm_bios_log_setup for TPM 2.0  and adds the
> > > > > event log parser which understand the TPM 2.0 crypto agile format.
> > > > > 
> > > > > Signed-off-by: Nayna Jain <nayna-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org>
> > > > 
> > > > There is something fundamentally wrong in this commit.
> > > > 
> > > > You must not allow this feature unless CONFIG_OF is set. It is the only
> > > > interface where the supply path of the event log is well defined on
> > > > platforms that include a TPM 2.0 chip.
> > > 
> > > As per current implementation, if ACPI with TPM 2.0 doesn't support event
> > > log, tpm_read_log_acpi() is expected to return rc and tpm_bios_log_setup
> > > will not create securityfs. This is inline with our design for TPM 1.2 event
> > > log.
> > 
> > At minimum you must have a check for TPM_CHIP_FLAG_TPM2 in the beginning
> > of tpm_read_log_acpi. It is wrong to even try to open TCPA in this case.
> 
> Sure, will add this check and return -ENODEV if check passes.

Yeah, this is acceptable for me.

> Thanks & Regards,
>     - Nayna

/Jarkko

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot

  reply	other threads:[~2017-01-04 13:04 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-11  5:35 [PATCH v7 0/2] securityfs support for TPM 2.0 firmware event log Nayna Jain
2016-12-11  5:35 ` Nayna Jain
2016-12-11  5:35 ` [PATCH v7 1/2] tpm: enhance read_log_of() to support Physical TPM " Nayna Jain
2016-12-11  5:35   ` Nayna Jain
2016-12-12 14:40   ` Jarkko Sakkinen
2016-12-16 16:28     ` Nayna
2016-12-11  5:35 ` [PATCH v7 2/2] tpm: add securityfs support for TPM 2.0 firmware " Nayna Jain
2016-12-11  5:35   ` Nayna Jain
2017-01-02 22:12   ` Jarkko Sakkinen
2017-01-02 22:12     ` Jarkko Sakkinen
2017-01-03  7:39     ` Nayna
2017-01-03 13:33       ` Jarkko Sakkinen
2017-01-03 13:33         ` Jarkko Sakkinen
2017-01-04  8:38         ` Nayna
2017-01-04  8:38           ` Nayna
2017-01-04 13:01           ` Jarkko Sakkinen [this message]
2017-01-04 13:01             ` Jarkko Sakkinen

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=20170104130118.2brkojj65vjhzca3@intel.com \
    --to=jarkko.sakkinen@linux.intel.com \
    --cc=jgunthorpe@obsidianresearch.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-security-module@vger.kernel.org \
    --cc=nayna@linux.vnet.ibm.com \
    --cc=peterhuewe@gmx.de \
    --cc=tpmdd-devel@lists.sourceforge.net \
    --cc=tpmdd@selhorst.net \
    /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.