mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Mimi Zohar <zohar@linux.vnet.ibm.com>
To: Jason Gunthorpe <jgunthorpe@obsidianresearch.com>
Cc: "Jonathan M. McCune" <jonmccune@cmu.edu>,
	Rajiv Andrade <srajiv@linux.vnet.ibm.com>,
	Greg KH <greg@kroah.com>,
	linux-kernel@vger.kernel.org, jbeulich@novell.com,
	jmorris@namei.org, tpmdd-devel@lists.sourceforge.net,
	m.selhorst@sirrix.com, Andrew Morton <akpm@linux-foundation.org>,
	Roland.Dreier@us.ibm.com
Subject: Re: [tpmdd-devel] [PATCH] TPM: Fixup pubek sysfs file
Date: Mon, 14 Sep 2009 23:06:23 -0400	[thread overview]
Message-ID: <1252983983.3745.67.camel@dyn9002018117.watson.ibm.com> (raw)
In-Reply-To: <20090914194626.GF25981@obsidianresearch.com>

On Mon, 2009-09-14 at 13:46 -0600, Jason Gunthorpe wrote: 
> On Mon, Sep 14, 2009 at 03:23:09PM -0400, Jonathan M. McCune wrote:
> 
> >> Can anyone think of a reason why the PCRs should be accessed from
> >> sysfs? I can't. They are only really useful in connection with other
> >> complex TPM operations. Userspace can fully access them using the
> >> relevant TPM calls.

> > Fair enough, though they are useful in combination with IMA and as a  
> > sanity check that the driver is working correctly.

The IMA ltp testsuite currently uses the sysfs PCR values 0-7 to
validate the boot aggregate, the first measurement in the the IMA
measurement list. 

> [..]
> > IMA can leverage the ability to read and extend PCRs, and its security  
> > properties derive from that functionality being a part of the kernel.  
> > PCR reading is currently part of the TPM driver in 
> > drivers/char/tpm/tpm.c.
> 
> Sanzzy
> 
> > Thus, to the question, "Can we remove the ability of the kernel to send  
> > TPM commands such as GetCapability and PCRRead?" I believe the answer is  
> > no. Or at least, not without causing a lot of work for the IMA system.

Definitely! On boot, IMA reads pcr 0-7 to calculate the boot aggregate.
IMA then extends the PCR, normally PCR-10, with the boot aggregate and
stores it as the first measurement in the IMA measurement list. Each
subsequent measurement, based on policy, extends the PCR and is appended
to the IMA measurement list. 
  
> > Although it may be worth discussing whether this functionality should be  
> > moved from the driver into IMA.

Are you really suggesting moving the tpm_pcr_read()/extend() to IMA?
Why?

> Fair enough, fortunately TPM_PCRRead and TPM_Extend are two of the
> simplest commands. As has been done special casing the fixed size
> messages is easy and robust.

Mimi


  parent reply	other threads:[~2009-09-15  3:06 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-04  4:52 Jason Gunthorpe
2009-09-04  5:02 ` Roland Dreier
2009-09-04 21:03   ` Andrew Morton
2009-09-04 21:23     ` Jason Gunthorpe
2009-09-11 16:28       ` Greg KH
     [not found]       ` <17754_1252731784_n8C533ou010944_20090911162837.GC17677@kroah.com>
2009-09-14 18:01         ` [tpmdd-devel] " Jonathan M. McCune
2009-09-14 18:34           ` Rajiv Andrade
2009-09-14 18:43             ` Jason Gunthorpe
2009-09-14 19:23               ` Jonathan M. McCune
2009-09-14 19:46                 ` Jason Gunthorpe
2009-09-14 19:50                   ` Greg KH
2009-09-15  3:06                   ` Mimi Zohar [this message]
2009-09-15 18:52                     ` Jonathan M. McCune
2009-09-15 16:34           ` Hal Finney
2009-09-11 16:28     ` Greg KH
2009-09-14 20:48 ` Rajiv Andrade

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=1252983983.3745.67.camel@dyn9002018117.watson.ibm.com \
    --to=zohar@linux.vnet.ibm.com \
    --cc=Roland.Dreier@us.ibm.com \
    --cc=akpm@linux-foundation.org \
    --cc=greg@kroah.com \
    --cc=jbeulich@novell.com \
    --cc=jgunthorpe@obsidianresearch.com \
    --cc=jmorris@namei.org \
    --cc=jonmccune@cmu.edu \
    --cc=linux-kernel@vger.kernel.org \
    --cc=m.selhorst@sirrix.com \
    --cc=srajiv@linux.vnet.ibm.com \
    --cc=tpmdd-devel@lists.sourceforge.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®