Re: [PATCH 1/6] tpm: implement TPM2 function to get update counter

2023-08-03 Thread Tushar Sugandhi
On 8/3/23 01:57, Jarkko Sakkinen wrote: On Thu Aug 3, 2023 at 4:22 AM EEST, Mimi Zohar wrote: On Wed, 2023-08-02 at 06:58 +0300, Jarkko Sakkinen wrote: From long description I see zero motivation to ack this change, except some heresay about IMA requiring it. Why does IMA need update_cnt and

Re: [PATCH 1/6] tpm: implement TPM2 function to get update counter

2023-08-03 Thread Tushar Sugandhi
On 8/3/23 01:43, Jarkko Sakkinen wrote: On Thu Aug 3, 2023 at 12:04 AM EEST, Tushar Sugandhi wrote: Btw, the function tpm2_pcr_read is not exposed directly to the other subsystems (like IMA).  It is exposed via tpm_pcr_read. Do you want to expose tpm2_pcr_read directly, or do you want me to

Re: [PATCH 1/6] tpm: implement TPM2 function to get update counter

2023-08-03 Thread Tushar Sugandhi
On 8/2/23 18:22, Mimi Zohar wrote: On Wed, 2023-08-02 at 06:58 +0300, Jarkko Sakkinen wrote: From long description I see zero motivation to ack this change, except some heresay about IMA requiring it. Why does IMA need update_cnt and why this is not documented to the long description? The

Re: [PATCH 1/6] tpm: implement TPM2 function to get update counter

2023-08-03 Thread Jarkko Sakkinen
On Thu Aug 3, 2023 at 4:22 AM EEST, Mimi Zohar wrote: > On Wed, 2023-08-02 at 06:58 +0300, Jarkko Sakkinen wrote: > > > > From long description I see zero motivation to ack this change, except > > some heresay about IMA requiring it. Why does IMA need update_cnt and > > why this is not documented

Re: [PATCH 1/6] tpm: implement TPM2 function to get update counter

2023-08-03 Thread Jarkko Sakkinen
On Thu Aug 3, 2023 at 12:04 AM EEST, Tushar Sugandhi wrote: > Btw, the function tpm2_pcr_read is not exposed directly to the other > subsystems (like IMA).  It is exposed via tpm_pcr_read. > > Do you want to expose tpm2_pcr_read directly, > or do you want me to update the function signature of

Re: [PATCH 1/6] tpm: implement TPM2 function to get update counter

2023-08-02 Thread Mimi Zohar
On Wed, 2023-08-02 at 06:58 +0300, Jarkko Sakkinen wrote: > > From long description I see zero motivation to ack this change, except > some heresay about IMA requiring it. Why does IMA need update_cnt and > why this is not documented to the long description? The motivation is to detect whether

Re: [PATCH 1/6] tpm: implement TPM2 function to get update counter

2023-08-02 Thread Tushar Sugandhi
On 8/1/23 20:58, Jarkko Sakkinen wrote: On Wed Aug 2, 2023 at 12:01 AM EEST, Tushar Sugandhi wrote: Thanks for the response Jarkko. On 8/1/23 12:02, Jarkko Sakkinen wrote: The short summary is cryptic to say the least. Do you mean the patch subject line, or the description below? It is in

Re: [PATCH 1/6] tpm: implement TPM2 function to get update counter

2023-08-01 Thread Jarkko Sakkinen
On Wed Aug 2, 2023 at 12:01 AM EEST, Tushar Sugandhi wrote: > Thanks for the response Jarkko. > > On 8/1/23 12:02, Jarkko Sakkinen wrote: > > The short summary is cryptic to say the least. > Do you mean the patch subject line, or the description below? It is in the process documentation:

Re: [PATCH 1/6] tpm: implement TPM2 function to get update counter

2023-08-01 Thread Tushar Sugandhi
Thanks for the response Jarkko. On 8/1/23 12:02, Jarkko Sakkinen wrote: The short summary is cryptic to say the least. Do you mean the patch subject line, or the description below? "update counter" does not map it to have anything to do with PCRs. Agreed.  I noticed that when I was testing

Re: [PATCH 1/6] tpm: implement TPM2 function to get update counter

2023-08-01 Thread Jarkko Sakkinen
The short summary is cryptic to say the least. "update counter" does not map it to have anything to do with PCRs. Why not "tpm: Read pcrUpdateCounter field from TPM2_PCR_Read"? On Tue Aug 1, 2023 at 9:19 PM EEST, Tushar Sugandhi wrote: > The TPM2_PCR_Read command returns TPM2_PCR_Read Response

[PATCH 1/6] tpm: implement TPM2 function to get update counter

2023-08-01 Thread Tushar Sugandhi
The TPM2_PCR_Read command returns TPM2_PCR_Read Response struct[1]. It contains pcrUpdateCounter member which contains the current value of TPM PCR update counter. The update counter provides the number of times the PCRs are updated, which is essential for tracking changes and verifying system