zakkir hussain Kharim
2015-02-26 14:19:51 UTC
*We are trying to wrap a private key using storage root key using the
"create_tpm_key" tool which is part of openssl tpm engine. But it is
failing. We tried to debug this in multiple ways, but not able to get what
is wrong. *
*Command Executed: *
# create_tpm_key -w private.pem rsmpvtkey.blob
SRK Password:
################################### result=12
create_tpm_key.c:444 Tspi_Key_WrapKey result: 0xc (Invalid keyhandle)
*TPM trousers code:*
File: tspi/tspi_key.c
Function : Tspi_Key_GetPubKey
if ((result = TCS_API(tspContext)->GetPubKey(tspContext,
tcsKeyHandle, pAuth,
pulPubKeyLength,
prgbPubKey)))
{
printf("\n ###################################
result=%d\n",result);
return result; // returns value 12
}
*Version details: *
trousers-0.3.13
openssl_tpm_engine-0.4.2
tpm-tools-1.3.8
*tpm version*
TPM 1.2 Version Info:
Chip Version: 1.2.3.16
Spec Level: 2
Errata Revision: 2
TPM Vendor ID: IFX
Vendor Specific data: 0310000a 00
TPM Version: 01010000
Manufacturer Info: 49465800
"create_tpm_key" tool which is part of openssl tpm engine. But it is
failing. We tried to debug this in multiple ways, but not able to get what
is wrong. *
*Command Executed: *
# create_tpm_key -w private.pem rsmpvtkey.blob
SRK Password:
################################### result=12
create_tpm_key.c:444 Tspi_Key_WrapKey result: 0xc (Invalid keyhandle)
*TPM trousers code:*
File: tspi/tspi_key.c
Function : Tspi_Key_GetPubKey
if ((result = TCS_API(tspContext)->GetPubKey(tspContext,
tcsKeyHandle, pAuth,
pulPubKeyLength,
prgbPubKey)))
{
printf("\n ###################################
result=%d\n",result);
return result; // returns value 12
}
*Version details: *
trousers-0.3.13
openssl_tpm_engine-0.4.2
tpm-tools-1.3.8
*tpm version*
TPM 1.2 Version Info:
Chip Version: 1.2.3.16
Spec Level: 2
Errata Revision: 2
TPM Vendor ID: IFX
Vendor Specific data: 0310000a 00
TPM Version: 01010000
Manufacturer Info: 49465800