use correct session index for wrap test so parameter encryption works

pull/269/head
John Bland 2023-05-03 19:29:45 -04:00
parent 382ff91eb3
commit d1cd4eff52
1 changed files with 1 additions and 1 deletions

View File

@ -259,7 +259,7 @@ int TPM2_Wrapper_TestArgs(void* userCtx, int argc, char *argv[])
(word32)tpmSession.handle.hndl);
/* set session for authorization of the storage key */
rc = wolfTPM2_SetAuthSession(&dev, 1, &tpmSession,
rc = wolfTPM2_SetAuthSession(&dev, 0, &tpmSession,
(TPMA_SESSION_decrypt | TPMA_SESSION_encrypt | TPMA_SESSION_continueSession));
if (rc != 0) goto exit;
}