<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<html lang="en">
<head>
<meta content="text/html; charset=US-ASCII" http-equiv="Content-Type">
<title>
GitLab
</title>
<style>img {
max-width: 100%; height: auto;
}
</style>
</head>
<body>
<div class="content">
<p style="color: #777777;">
<a href="https://gitlab.com/nmav">Nikos Mavrogiannopoulos</a>
commented:
</p>
<div style="">
<p dir="auto"><a href="https://gitlab.com/dwmw2" data-user="274866" data-reference-type="user" data-container="body" data-placement="bottom" class="gfm gfm-project_member" title="David Woodhouse">@dwmw2</a> I'm slow proceeding assuming that (1) will happen and in the meantime creating <a href="https://gitlab.com/nmav/gnutls/blob/tmp-tpm2/tests/tpm2-key.c">a test tool to convert such keys</a>. I created also <a href="https://gitlab.com/nmav/gnutls/blob/tmp-tpm2/tests/tpm2.sh">a basic test-suite</a> based on Stefan's swtpm, but I seem to be unable to make it pass (the testsuite generates keys and tries to sign a certificate).</p>
<p dir="auto">The error is during the signing:</p>
<pre class="code highlight js-syntax-highlight plaintext" lang="plaintext" v-pre="true"><code><span id="LC1" class="line" lang="plaintext">Signing certificate...</span>
<span id="LC2" class="line" lang="plaintext">|<2>| signing structure using ECDSA-SHA256</span>
<span id="LC3" class="line" lang="plaintext">|<2>| tpm2: EC sign function called for 32 bytes.</span>
<span id="LC4" class="line" lang="plaintext">|<2>| tpm2: Establishing connection with TPM.</span>
<span id="LC5" class="line" lang="plaintext">WARNING:esys:src/tss2-esys/esys_tcti_default.c:134:tcti_from_file() Could not load TCTI file: libtss2-tcti-default.so </span>
<span id="LC6" class="line" lang="plaintext">WARNING:esys:src/tss2-esys/esys_tcti_default.c:134:tcti_from_file() Could not load TCTI file: libtss2-tcti-tabrmd.so </span>
<span id="LC7" class="line" lang="plaintext">WARNING:esys:src/tss2-esys/api/Esys_ReadPublic.c:326:Esys_ReadPublic_Finish() Received TPM Error </span>
<span id="LC8" class="line" lang="plaintext">ERROR:esys:src/tss2-esys/esys_tr.c:219:Esys_TR_FromTPMPublic_Finish() Error ReadPublic ErrorCode (0x00000184) </span>
<span id="LC9" class="line" lang="plaintext">ERROR:esys:src/tss2-esys/esys_tr.c:309:Esys_TR_FromTPMPublic() Error TR FromTPMPublic ErrorCode (0x00000184) </span>
<span id="LC10" class="line" lang="plaintext">|<3>| ASSERT: tpm2_esys.c[init_tpm2_key]:291</span>
<span id="LC11" class="line" lang="plaintext">|<2>| tpm2: Esys_TR_FromTPMPublic failed for handle 0x2f326c72: 0x184</span>
<span id="LC12" class="line" lang="plaintext">|<3>| ASSERT: privkey.c[privkey_sign_and_hash_data]:1298</span>
<span id="LC13" class="line" lang="plaintext">|<3>| ASSERT: sign.c[_gnutls_x509_pkix_sign]:187</span>
<span id="LC14" class="line" lang="plaintext">|<3>| ASSERT: x509_write.c[gnutls_x509_crt_privkey_sign]:1834</span></code></pre>
<p dir="auto">That points to a <a href="https://gitlab.com/nmav/gnutls/blob/tmp-tpm2/lib/tpm2_esys.c#L288">failure in <code>Esys_TR_FromTPMPublic</code></a> with 0x184 as error. I cannot figure it out. Do you see something obvious in <a href="https://gitlab.com/nmav/gnutls/blob/tmp-tpm2/tests/tpm2.sh#L191">the keys I generate</a> with tpm2-tools?</p>
</div>
</div>
<div class="footer" style="margin-top: 10px;">
<p style="font-size: small; color: #777;">
—
<br>
Reply to this email directly or <a href="https://gitlab.com/gnutls/gnutls/issues/594#note_201651055">view it on GitLab</a>.
<br>
You're receiving this email because of your account on gitlab.com.
If you'd like to receive fewer emails, you can
<a href="https://gitlab.com/sent_notifications/a070155c5bfd01538bdf57e46401dab5/unsubscribe">unsubscribe</a>
from this thread or
adjust your notification settings.
<script type="application/ld+json">{"@context":"http://schema.org","@type":"EmailMessage","action":{"@type":"ViewAction","name":"View Issue","url":"https://gitlab.com/gnutls/gnutls/issues/594#note_201651055"}}</script>
</p>
</div>
</body>
</html>