Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1559840

Re: [PATCH v5] tpm: Check size of response before accessing data

From Stefan Berger <stefanb@linux.vnet.ibm.com>
Newsgroups linux.kernel
Subject Re: [PATCH v5] tpm: Check size of response before accessing data
Date 2017-01-16 16:40 +0100
Message-ID <t0hy2-2jl-7@gated-at.bofh.it> (permalink)
References <t0fwd-WM-15@gated-at.bofh.it> <t0fwd-WM-13@gated-at.bofh.it> <t0fwf-WM-43@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On 01/16/2017 08:25 AM, Jarkko Sakkinen wrote:
> On Mon, Jan 16, 2017 at 03:24:09PM +0200, Jarkko Sakkinen wrote:
>> On Fri, Jan 13, 2017 at 09:36:34PM -0500, Stefan Berger wrote:
>>> Make sure that we have not received less bytes than what is indicated
>>> in the header of the TPM response. Also, check the number of bytes in
>>> the response before accessing its data.
>>>
>>> Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
>> There are some things that I want to comment after all but I can give
>> now
>>
>> Tested-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
>>
>> I also noticed that this patch is not CC'd to linux-kernel.
> Please go through the whole patch and remove arithmetic
> from every possible place where you only end up with a
> constant.

sizeof(cap.timeout) -- what do you want to do about that? Is that 
legitimate or do you want a number then??? What about offsetof's?

Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Re: [PATCH v5] tpm: Check size of response before accessing data Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com> - 2017-01-16 14:30 +0100
  Re: [PATCH v5] tpm: Check size of response before accessing data Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com> - 2017-01-16 14:30 +0100
    Re: [PATCH v5] tpm: Check size of response before accessing data Stefan Berger <stefanb@linux.vnet.ibm.com> - 2017-01-16 16:40 +0100
  Re: [PATCH v5] tpm: Check size of response before accessing data Stefan Berger <stefanb@linux.vnet.ibm.com> - 2017-01-16 15:50 +0100

csiph-web