Create ECC keypair in NVM within Hyper-V with TSS.NET #124
Unanswered
RussellGantman
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hello.
I am wanting to create a ECC signing key and save it in the NVRAM area: Primary key index at 0x800001
I am attempting to do this in a Gen-2 Hyper-V system with a TPM.
I looked at the device manager and it indicates a TPM 2.0 is present and working
When I attempt to create the key with "CreatePrimary" I get the following error
Return Code: 134217730 TpmUtility.MfgException: Tpm2Lib.TpmException: Error {Hierarchy} was returned for command CreatePrimary. Details: [Code=TpmRc.Hierarchy],[RawCode=0x85,133] [ErrorEntity=Handle], [ParmNum=0] [[ParmName=Unknown]] at Tpm2Lib.Tpm2.ProcessError(TpmSt responseTag, UInt32 responseParamSize, TpmRc resultCode, TpmStructureBase inParms) at Tpm2Lib.Tpm2.DispatchMethod(TpmCc ordinal, TpmStructureBase inParms, Type expectedResponseType, TpmStructureBase& outParms, Int32 numInHandlesNotUsed, Int32 numOutHandlesNotUsed) at Tpm2Lib.Tpm2.CreatePrimary(TpmHandle primaryHandle, SensitiveCreate inSensitive, TpmPublic inPublic, Byte[] outsideInfo, PcrSelection[] creationPCR, TpmPublic& outPublic, CreationData& creationData, Byte[]& creationHash, TkCreation& creationTicket)Here is the code I use to create the key:
`private TpmHandle CreatePlatformPrimaryKey(Tpm2 tpm, byte[] parentKeyAuth)
{
EccParms eccParams = new EccParms(new SymDefObject(TpmAlgId.Aes, 128, TpmAlgId.Cfb), new NullAsymScheme(), EccCurve.TpmEccNistP256, null);
When I run this on the TPM on my host system it works perfectly.
I figure I need to make a change to run within Hyper-V
Thanks for any assistance
Russell
--
It is our choices, that show what we truly are, far more than our abilities.
Beta Was this translation helpful? Give feedback.
All reactions