[openssl-users] openssl_tpm_engine - create_tpm_key failed when tried to wrap key

zakkir hussain Kharim zakkir.kharim at gmail.com
Fri Feb 27 05:16:53 UTC 2015


*Problem*

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
understand what is wrong*.  * We are trying to wrap using Storage root key.
Input private key is a 2048 bit length RSA key without any passphrase. The
failure seems to related to getting public key of SRK from the SRK handle
loaded.







*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





Thanks and Regards

Zakkir
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mta.openssl.org/pipermail/openssl-users/attachments/20150227/e32e5152/attachment-0001.html>


More information about the openssl-users mailing list