[tpm2] Re: How to remove contexts using tpm2-tools v3.1.3?

Roberts, William C <william.c.roberts at intel.com>
Newsgroups dev.linux.lists.tpm2
Message-ID <SN6PR11MB34379D11C3F9E0BB4144D5E9B8769@SN6PR11MB3437.namprd11.prod.outlook.com>
Unfortunately, no.

Can you update to the latest release? The newest tools release would vastly enhance your experience.

Could you use the python bindings:
    pip install tpm2-pytss
That would require tpm2-tss libraries from version 2.4.0 or newer.
________________________________
From: Han <keepsimple(a)gmail.com>
Sent: Wednesday, December 15, 2021 12:50 PM
To: tpm2(a)lists.01.org <tpm2(a)lists.01.org>
Subject: [tpm2] How to remove contexts using tpm2-tools v3.1.3?

Hi,

I'm new to tpm2-tools and am using tpm2-tools version 3.1.3 on Raspberry Pi CM4. It turns out it doesn't have tpm2_flushcontext which was added in v4.0. Is there any other tools in tpm2-tools 3.1.3 that can remove contexts? My goal is to free up some memory in TPM as it returned the following error:

$ tpm2_rc_decode 0x902
error layer
  hex: 0x0
  identifier: TSS2_TPM_RC_LAYER
  description: Error produced by the TPM
format 0 warning code
  hex: 0x02
  name: TPM2_RC_OBJECT_MEMORY
  description: out of memory for object contexts

--

Thanks

Han
attachment.htm (text/html, 5.4 KB)
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Unfortunately, no.</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Can you update to the latest release? The newest tools release would vastly enhance your experience.</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Could you use the python bindings:</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
&nbsp; &nbsp; pip install tpm2-pytss</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<span style="color: rgb(0, 0, 0); font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">That would require tpm2-tss libraries from version 2.4.0 or newer.</span><br>
</div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> Han &lt;[email protected]&gt;<br>
<b>Sent:</b> Wednesday, December 15, 2021 12:50 PM<br>
<b>To:</b> [email protected] &lt;[email protected]&gt;<br>
<b>Subject:</b> [tpm2] How to remove contexts using tpm2-tools v3.1.3?</font>
<div>&nbsp;</div>
</div>
<div>
<div dir="ltr">Hi,
<div><br>
</div>
<div><span style="font-family:inherit; font-size:15px; font-style:inherit; font-variant-ligatures:inherit; font-variant-caps:inherit; font-weight:inherit; color:rgb(35,38,41)">I'm new to tpm2-tools and am using tpm2-tools version 3.1.3 on Raspberry Pi CM4.
 It turns out it doesn't have</span><span style="font-family:inherit; font-size:15px; font-style:inherit; font-variant-ligatures:inherit; font-variant-caps:inherit; font-weight:inherit; color:rgb(35,38,41)">&nbsp;</span><span style="font-family:inherit; font-style:inherit; font-variant-ligatures:inherit; font-variant-caps:inherit; font-weight:inherit; color:rgb(35,38,41); white-space:pre-wrap; font-size:13px">tpm2_flushcontext
</span><span style="font-family:inherit; font-size:15px; font-style:inherit; font-variant-ligatures:inherit; font-variant-caps:inherit; font-weight:inherit; color:rgb(35,38,41)">which was added in v4.0.&nbsp;</span><span style="font-family:inherit; font-size:15px; font-style:inherit; font-variant-ligatures:inherit; font-variant-caps:inherit; font-weight:inherit; color:rgb(35,38,41)">Is
 there any other tools in tpm2-tools 3.1.3 that can remove contexts? My goal is to free up some memory in TPM as it returned the following error:</span></div>
<div class="x_gmail-postcell x_gmail-post-layout--right" style="margin:0px; padding:0px 16px 0px 0px; border:0px; font-variant-numeric:inherit; font-variant-east-asian:inherit; font-stretch:inherit; line-height:inherit; font-size:13px; vertical-align:top; box-sizing:inherit; width:auto; min-width:0px; color:rgb(35,38,41)">
<div class="x_gmail-s-prose x_gmail-js-post-body" style="margin:0px; padding:0px; border:0px; font-style:inherit; font-variant:inherit; font-weight:inherit; font-stretch:inherit; font-size:15px; vertical-align:baseline; box-sizing:inherit; width:659px">
<pre style="margin-top:0px; margin-bottom:0px; padding:12px; border:0px; font-style:inherit; font-variant:inherit; font-weight:inherit; font-stretch:inherit; line-height:1.30769; font-size:13px; vertical-align:baseline; box-sizing:inherit; width:auto; max-height:600px; overflow:auto; border-radius:5px"><code style="margin:0px; padding:0px; border:0px; font-style:inherit; font-variant:inherit; font-weight:inherit; font-stretch:inherit; line-height:inherit; vertical-align:baseline; box-sizing:inherit; background-color:transparent; white-space:inherit; border-radius:0px">$ tpm2_rc_decode 0x902
error layer
  hex: 0x0
  identifier: TSS2_TPM_RC_LAYER
  description: Error produced by the TPM
format 0 warning code
  hex: 0x02
  name: TPM2_RC_OBJECT_MEMORY
  description: out of memory for object contexts</code></pre>
<pre style="margin-top:0px; margin-bottom:0px; padding:12px; border:0px; font-style:inherit; font-variant:inherit; font-weight:inherit; font-stretch:inherit; line-height:1.30769; font-size:13px; vertical-align:baseline; box-sizing:inherit; width:auto; max-height:600px; overflow:auto; border-radius:5px">--</pre>
<pre style="margin-top:0px; margin-bottom:0px; padding:12px; border:0px; font-style:inherit; font-variant:inherit; font-weight:inherit; font-stretch:inherit; line-height:1.30769; font-size:13px; vertical-align:baseline; box-sizing:inherit; width:auto; max-height:600px; overflow:auto; border-radius:5px">Thanks</pre>
<pre style="margin-top:0px; margin-bottom:0px; padding:12px; border:0px; font-style:inherit; font-variant:inherit; font-weight:inherit; font-stretch:inherit; line-height:1.30769; font-size:13px; vertical-align:baseline; box-sizing:inherit; width:auto; max-height:600px; overflow:auto; border-radius:5px">Han</pre>
</div>
</div>
</div>
</div>
</body>
</html>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.