Policy digest zeroed out after successful TPM2_Sign
by Nick Meyer
Hello,
I'm working on implementing a TPM2_Sign operation protected by a PCR
policy. I have discovered that the policy digest appears to be zeroed out
as part of the sign operation.
The initial symptom of this was a 0x99d return code on a second sign
operation (in a test suite), TPM_RC_POLICY_FAIL. In order to debug, I
placed TPM2_PolicyGetDigest commands immediately before and after the first
sign. The preceding policy digest is as expected a random-looking hash; the
policy digest immediately following the sign command is all zeroes.
I realized at that point that I had forgotten to set the continueSession
bit in the session attribute flags of the auth structure I passed to
TPM2_Sign. I fixed this, but it had no impact on the outcome or my
observations.
The first sign operation returns RC_SUCCESS as expected, and after making I
see the continueSession bit set both in the command and response auth
structures; however the subsequent policy digest is still zeroed out.
I had considered that a PCR was possibly being changed somehow,
invalidating the PCR policy; however, I would expect TPM_RC_PCR_CHANGED to
be returned in this case, not TPM_RC_POLICY_FAIL.
Is there another reason that this *successful* sign operation would be
invalidating the session?
Thanks for your insight.
*Nick Meyer*
Verizon Media
1 year, 11 months
Policy digest zeroed out after successful TPM2_Sign
by Nick Meyer
Hello,
I'm working on implementing a TPM2_Sign operation protected by a PCR
policy. I have discovered that the policy digest appears to be zeroed out
as part of the sign operation.
The initial symptom of this was a 0x99d return code on a second sign
operation (in a test suite), TPM_RC_POLICY_FAIL. In order to debug, I
placed TPM2_PolicyGetDigest commands immediately before and after the first
sign. The preceding policy digest is as expected a random-looking hash; the
policy digest immediately following the sign command is all zeroes.
I realized at that point that I had forgotten to set the continueSession
bit in the session attribute flags of the auth structure I passed to
TPM2_Sign. I fixed this, but it had no impact on the outcome or my
observations.
The first sign operation returns RC_SUCCESS as expected, and after making I
see the continueSession bit set both in the command and response auth
structures; however the subsequent policy digest is still zeroed out.
I had considered that a PCR was possibly being changed somehow,
invalidating the PCR policy; however, I would expect TPM_RC_PCR_CHANGED to
be returned in this case, not TPM_RC_POLICY_FAIL.
Is there another reason that this *successful* sign operation would be
invalidating the session?
Thanks for your insight.
*Nick Meyer*
Verizon Media
1 year, 11 months
Re: [tpm2] CONGRATULATIONS on achieving a passing best practices badge!
by Peter Huewe
Hi,
I'm pleased to announce that we just passed the Core Infrastructure
Initiative
Best Practice Badge Programm!
This is not an aprils fool but a serious achievement.
"The Linux Foundation (LF) Core Infrastructure Initiative (CII) Best
Practices badge
is a way for Free/Libre and Open Source Software (FLOSS) projects to show
that they
follow best practices. Projects can voluntarily self-certify, at no cost,
by using
this web application to explain how they follow each best practice. The CII
Best Practices Badge is inspired by the many badges available to projects
on GitHub.
Consumers of the badge can quickly assess which FLOSS projects are
following best
practices and as a result are more likely to produce higher-quality secure
software."
Taken from: https://bestpractices.coreinfrastructure.org/en
Thanks everybody who worked on getting this achievement and turning our
project
into a sustainable and healthy open source project.
Please find the full email below.
Thanks,
Peter
Am Montag, 1. April 2019 21:29:22 CEST schrieb
badgeapp(a)bestpractices.coreinfrastructure.org:
> Congratulations!
> According to the information that you've provided,
> your project has earned the CII best practices 'passing' badge.
> For more information, see this URL:
> https://bestpractices.coreinfrastructure.org/en/projects/2332
>
> Please add your badge to your project and/or repository site;
> you've earned it:
> * In markdown you can add this:
> [lists.coreinfrastructure.org.
> One of our goals is to encourage projects to make some improvements.
> We put some of these reports on the public wiki; please let us know
> if you do NOT want the changes publicly posted at
> https://github.com/coreinfrastructure/best-practices-badge/wiki/Impacts
> Thank you, and congratulations.
>
> --- David A. Wheeler, CII Best Practices Badge Technical Lead
>
>
>
1 year, 11 months