mirror of
git://git.gnupg.org/gnupg.git
synced 2024-12-22 10:19:57 +01:00
tpm2d: Fix key import.
* tpm2d/tpm2.c (tpm2_import_key): Set the lengths from right variables. -- Fixes-commit: d631c8198c254107c0a4e704511fa0f33d3dda5f GnuPG-bug-id: 7186 Signed-off-by: Jakub Jelen <jjelen@redhat.com>
This commit is contained in:
parent
736579331b
commit
cf3cec982d
@ -923,14 +923,14 @@ tpm2_import_key (ctrl_t ctrl, TSS_CONTEXT *tssc,
|
||||
u16len = 0;
|
||||
TSS_TPM2B_PUBLIC_Marshal (&objectPublic,
|
||||
&u16len, &buffer, &size);
|
||||
pub_len = len;
|
||||
pub_len = u16len;
|
||||
|
||||
size = sizeof (priv);
|
||||
buffer = priv;
|
||||
u16len = 0;
|
||||
TSS_TPM2B_PRIVATE_Marshal ((TPM2B_PRIVATE *)&outPrivate,
|
||||
&u16len, &buffer, &size);
|
||||
priv_len = len;
|
||||
priv_len = u16len;
|
||||
|
||||
*shadow_info = make_tpm2_shadow_info (parent, pub, pub_len,
|
||||
priv, priv_len, shadow_len);
|
||||
|
Loading…
x
Reference in New Issue
Block a user