TPM_RC Tss2_Sys_NV_Read( TSS2_SYS_CONTEXT *sysContext, TPMI_RH_NV_AUTH authHandle, TPMI_RH_NV_INDEX nvIndex, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, UINT16 size, UINT16 offset, TPM2B_MAX_NV_BUFFER *data, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; if( sysContext == NULL ) { return( TSS2_SYS_RC_BAD_REFERENCE ); } rval = Tss2_Sys_NV_Read_Prepare( sysContext, authHandle, nvIndex, size, offset ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_NV_Read_Complete( sysContext, data ); } } return rval; }
TPM_RC Tss2_Sys_PCR_Event( TSS2_SYS_CONTEXT *sysContext, TPMI_DH_PCR pcrHandle, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM2B_EVENT *eventData, TPML_DIGEST_VALUES *digests, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; if( sysContext == NULL ) { return( TSS2_SYS_RC_BAD_REFERENCE ); } rval = Tss2_Sys_PCR_Event_Prepare( sysContext, pcrHandle, eventData ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_PCR_Event_Complete( sysContext, digests ); } } return rval; }
TPM_RC Tss2_Sys_FieldUpgradeData( TSS2_SYS_CONTEXT *sysContext, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM2B_MAX_BUFFER *fuData, TPMT_HA *nextDigest, TPMT_HA *firstDigest, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; if( sysContext == NULL ) { return( TSS2_SYS_RC_BAD_REFERENCE ); } rval = Tss2_Sys_FieldUpgradeData_Prepare( sysContext, fuData ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_FieldUpgradeData_Complete( sysContext, nextDigest, firstDigest ); } } return rval; }
TPM_RC Tss2_Sys_VerifySignature( TSS2_SYS_CONTEXT *sysContext, TPMI_DH_OBJECT keyHandle, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM2B_DIGEST *digest, TPMT_SIGNATURE *signature, TPMT_TK_VERIFIED *validation, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; if( sysContext == NULL ) { return( TSS2_SYS_RC_BAD_REFERENCE ); } rval = Tss2_Sys_VerifySignature_Prepare( sysContext, keyHandle, digest, signature ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_VerifySignature_Complete( sysContext, validation ); } } return rval; }
TPM_RC Tss2_Sys_EC_Ephemeral( TSS2_SYS_CONTEXT *sysContext, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPMI_ECC_CURVE curveID, TPM2B_ECC_POINT *Q, UINT16 *counter, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; rval = Tss2_Sys_EC_Ephemeral_Prepare( sysContext, curveID ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_EC_Ephemeral_Complete( sysContext, Q, counter ); } } return rval; }
TPM_RC Tss2_Sys_MakeCredential( TSS2_SYS_CONTEXT *sysContext, TPMI_DH_OBJECT handle, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM2B_DIGEST *credential, TPM2B_NAME *objectName, TPM2B_ID_OBJECT *credentialBlob, TPM2B_ENCRYPTED_SECRET *secret, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; rval = Tss2_Sys_MakeCredential_Prepare( sysContext, handle, credential, objectName ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_MakeCredential_Complete( sysContext, credentialBlob, secret ); } } return rval; }
TPM_RC Tss2_Sys_Load( TSS2_SYS_CONTEXT *sysContext, TPMI_DH_OBJECT parentHandle, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM2B_PRIVATE *inPrivate, TPM2B_PUBLIC *inPublic, TPM_HANDLE *objectHandle, TPM2B_NAME *name, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; rval = Tss2_Sys_Load_Prepare( sysContext, parentHandle, inPrivate, inPublic ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_Load_Complete( sysContext, objectHandle, name ); } } return rval; }
TPM_RC Tss2_Sys_GetCapability( TSS2_SYS_CONTEXT *sysContext, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM_CAP capability, UINT32 property, UINT32 propertyCount, TPMI_YES_NO *moreData, TPMS_CAPABILITY_DATA *capabilityData, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; rval = Tss2_Sys_GetCapability_Prepare( sysContext, capability, property, propertyCount ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_GetCapability_Complete( sysContext, moreData, capabilityData ); } } return rval; }
TPM_RC Tss2_Sys_SequenceComplete( TSS2_SYS_CONTEXT *sysContext, TPMI_DH_OBJECT sequenceHandle, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM2B_MAX_BUFFER *buffer, TPMI_RH_HIERARCHY hierarchy, TPM2B_DIGEST *result, TPMT_TK_HASHCHECK *validation, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; if( sysContext == NULL ) { return( TSS2_SYS_RC_BAD_REFERENCE ); } rval = Tss2_Sys_SequenceComplete_Prepare( sysContext, sequenceHandle, buffer, hierarchy ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_SequenceComplete_Complete( sysContext, result, validation ); } } return rval; }
TPM_RC Tss2_Sys_Rewrap( TSS2_SYS_CONTEXT *sysContext, TPMI_DH_OBJECT oldParent, TPMI_DH_OBJECT newParent, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM2B_PRIVATE *inDuplicate, TPM2B_NAME *name, TPM2B_ENCRYPTED_SECRET *inSymSeed, TPM2B_PRIVATE *outDuplicate, TPM2B_ENCRYPTED_SECRET *outSymSeed, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; rval = Tss2_Sys_Rewrap_Prepare( sysContext, oldParent, newParent, inDuplicate, name, inSymSeed ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_Rewrap_Complete( sysContext, outDuplicate, outSymSeed ); } } return rval; }
TPM_RC Tss2_Sys_HMAC( TSS2_SYS_CONTEXT *sysContext, TPMI_DH_OBJECT handle, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM2B_MAX_BUFFER *buffer, TPMI_ALG_HASH hashAlg, TPM2B_DIGEST *outHMAC, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; rval = Tss2_Sys_HMAC_Prepare( sysContext, handle, buffer, hashAlg ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_HMAC_Complete( sysContext, outHMAC ); } } return rval; }
TPM_RC Tss2_Sys_RSA_Encrypt( TSS2_SYS_CONTEXT *sysContext, TPMI_DH_OBJECT keyHandle, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM2B_PUBLIC_KEY_RSA *message, TPMT_RSA_DECRYPT *inScheme, TPM2B_DATA *label, TPM2B_PUBLIC_KEY_RSA *outData, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; if( sysContext == NULL ) { return( TSS2_SYS_RC_BAD_REFERENCE ); } rval = Tss2_Sys_RSA_Encrypt_Prepare( sysContext, keyHandle, message, inScheme, label ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_RSA_Encrypt_Complete( sysContext, outData ); } } return rval; }
TPM_RC Tss2_Sys_GetRandom( TSS2_SYS_CONTEXT *sysContext, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, UINT16 bytesRequested, TPM2B_DIGEST *randomBytes, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; rval = Tss2_Sys_GetRandom_Prepare( sysContext, bytesRequested ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_GetRandom_Complete( sysContext, randomBytes ); } } return rval; }
TPM_RC Tss2_Sys_CertifyCreation( TSS2_SYS_CONTEXT *sysContext, TPMI_DH_OBJECT signHandle, TPMI_DH_OBJECT objectHandle, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM2B_DATA *qualifyingData, TPM2B_DIGEST *creationHash, TPMT_SIG_SCHEME *inScheme, TPMT_TK_CREATION *creationTicket, TPM2B_ATTEST *certifyInfo, TPMT_SIGNATURE *signature, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; if( inScheme == NULL || creationTicket == NULL ) { return TSS2_SYS_RC_BAD_REFERENCE; } rval = Tss2_Sys_CertifyCreation_Prepare( sysContext, signHandle, objectHandle, qualifyingData, creationHash, inScheme, creationTicket ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_CertifyCreation_Complete( sysContext, certifyInfo, signature ); } } return rval; }
TPM_RC Tss2_Sys_GetTestResult( TSS2_SYS_CONTEXT *sysContext, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM2B_MAX_BUFFER *outData, TPM_RC *testResult, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; rval = Tss2_Sys_GetTestResult_Prepare( sysContext ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_GetTestResult_Complete( sysContext, outData, testResult ); } } return rval; }
TPM_RC Tss2_Sys_ZGen_2Phase( TSS2_SYS_CONTEXT *sysContext, TPMI_DH_OBJECT keyA, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM2B_ECC_POINT *inQsB, TPM2B_ECC_POINT *inQeB, TPMI_ECC_KEY_EXCHANGE inScheme, UINT16 counter, TPM2B_ECC_POINT *outZ1, TPM2B_ECC_POINT *outZ2, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; if( sysContext == NULL ) { return( TSS2_SYS_RC_BAD_REFERENCE ); } rval = Tss2_Sys_ZGen_2Phase_Prepare( sysContext, keyA, inQsB, inQeB, inScheme, counter ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_ZGen_2Phase_Complete( sysContext, outZ1, outZ2 ); } } return rval; }
TPM_RC Tss2_Sys_GetCommandAuditDigest( TSS2_SYS_CONTEXT *sysContext, TPMI_RH_ENDORSEMENT privacyHandle, TPMI_DH_OBJECT signHandle, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM2B_DATA *qualifyingData, TPMT_SIG_SCHEME *inScheme, TPM2B_ATTEST *auditInfo, TPMT_SIGNATURE *signature, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; if( sysContext == NULL ) { return( TSS2_SYS_RC_BAD_REFERENCE ); } rval = Tss2_Sys_GetCommandAuditDigest_Prepare( sysContext, privacyHandle, signHandle, qualifyingData, inScheme ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_GetCommandAuditDigest_Complete( sysContext, auditInfo, signature ); } } return rval; }
TPM_RC Tss2_Sys_ECDH_KeyGen( TSS2_SYS_CONTEXT *sysContext, TPMI_DH_OBJECT keyHandle, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM2B_ECC_POINT *zPoint, TPM2B_ECC_POINT *pubPoint, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; rval = Tss2_Sys_ECDH_KeyGen_Prepare( sysContext, keyHandle ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_ECDH_KeyGen_Complete( sysContext, zPoint, pubPoint ); } } return rval; }
TPM_RC Tss2_Sys_NV_ReadPublic( TSS2_SYS_CONTEXT *sysContext, TPMI_RH_NV_INDEX nvIndex, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM2B_NV_PUBLIC *nvPublic, TPM2B_NAME *nvName, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; if( sysContext == NULL ) { return( TSS2_SYS_RC_BAD_REFERENCE ); } rval = Tss2_Sys_NV_ReadPublic_Prepare( sysContext, nvIndex ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_NV_ReadPublic_Complete( sysContext, nvPublic, nvName ); } } return rval; }
TPM_RC Tss2_Sys_ContextLoad( TSS2_SYS_CONTEXT *sysContext, TPMS_CONTEXT *context, TPMI_DH_CONTEXT *loadedHandle ) { TSS2_RC rval = TPM_RC_SUCCESS; if( context == NULL ) { return TSS2_SYS_RC_BAD_REFERENCE; } rval = Tss2_Sys_ContextLoad_Prepare( sysContext, context ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, 0, 0 ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_ContextLoad_Complete( sysContext, loadedHandle ); } } return rval; }
TPM_RC Tss2_Sys_ContextSave( TSS2_SYS_CONTEXT *sysContext, TPMI_DH_CONTEXT saveHandle, TPMS_CONTEXT *context ) { TSS2_RC rval = TPM_RC_SUCCESS; if( sysContext == NULL ) { return( TSS2_SYS_RC_BAD_REFERENCE ); } rval = Tss2_Sys_ContextSave_Prepare( sysContext, saveHandle ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, 0, 0 ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_ContextSave_Complete( sysContext, context ); } } return rval; }
TPM_RC Tss2_Sys_Import( TSS2_SYS_CONTEXT *sysContext, TPMI_DH_OBJECT parentHandle, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM2B_DATA *encryptionKey, TPM2B_PUBLIC *objectPublic, TPM2B_PRIVATE *duplicate, TPM2B_ENCRYPTED_SECRET *inSymSeed, TPMT_SYM_DEF_OBJECT *symmetricAlg, TPM2B_PRIVATE *outPrivate, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; if( sysContext == NULL ) { return( TSS2_SYS_RC_BAD_REFERENCE ); } rval = Tss2_Sys_Import_Prepare( sysContext, parentHandle, encryptionKey, objectPublic, duplicate, inSymSeed, symmetricAlg ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_Import_Complete( sysContext, outPrivate ); } } return rval; }
TPM_RC Tss2_Sys_PCR_Allocate( TSS2_SYS_CONTEXT *sysContext, TPMI_RH_PLATFORM authHandle, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPML_PCR_SELECTION *pcrAllocation, TPMI_YES_NO *allocationSuccess, UINT32 *maxPCR, UINT32 *sizeNeeded, UINT32 *sizeAvailable, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; if( sysContext == NULL ) { return( TSS2_SYS_RC_BAD_REFERENCE ); } rval = Tss2_Sys_PCR_Allocate_Prepare( sysContext, authHandle, pcrAllocation ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_PCR_Allocate_Complete( sysContext, allocationSuccess, maxPCR, sizeNeeded, sizeAvailable ); } } return rval; }
TPM_RC Tss2_Sys_EncryptDecrypt( TSS2_SYS_CONTEXT *sysContext, TPMI_DH_OBJECT keyHandle, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPMI_YES_NO decrypt, TPMI_ALG_SYM_MODE mode, TPM2B_IV *ivIn, TPM2B_MAX_BUFFER *inData, TPM2B_MAX_BUFFER *outData, TPM2B_IV *ivOut, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; rval = Tss2_Sys_EncryptDecrypt_Prepare( sysContext, keyHandle, decrypt, mode, ivIn, inData ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_EncryptDecrypt_Complete( sysContext, outData, ivOut ); } } return rval; }
TPM_RC Tss2_Sys_Hash( TSS2_SYS_CONTEXT *sysContext, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM2B_MAX_BUFFER *data, TPMI_ALG_HASH hashAlg, TPMI_RH_HIERARCHY hierarchy, TPM2B_DIGEST *outHash, TPMT_TK_HASHCHECK *validation, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; rval = Tss2_Sys_Hash_Prepare( sysContext, data, hashAlg, hierarchy ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_Hash_Complete( sysContext, outHash, validation ); } } return rval; }
TPM_RC Tss2_Sys_ECC_Parameters( TSS2_SYS_CONTEXT *sysContext, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPMI_ECC_CURVE curveID, TPMS_ALGORITHM_DETAIL_ECC *parameters, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; if( sysContext == NULL ) { return( TSS2_SYS_RC_BAD_REFERENCE ); } rval = Tss2_Sys_ECC_Parameters_Prepare( sysContext, curveID ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_ECC_Parameters_Complete( sysContext, parameters ); } } return rval; }
TPM_RC Tss2_Sys_IncrementalSelfTest( TSS2_SYS_CONTEXT *sysContext, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPML_ALG *toTest, TPML_ALG *toDoList, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; if( toTest == NULL ) { return TSS2_SYS_RC_BAD_REFERENCE; } rval = Tss2_Sys_IncrementalSelfTest_Prepare( sysContext, toTest ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_IncrementalSelfTest_Complete( sysContext, toDoList ); } } return rval; }
TPM_RC Tss2_Sys_HashSequenceStart( TSS2_SYS_CONTEXT *sysContext, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM2B_AUTH *auth, TPMI_ALG_HASH hashAlg, TPMI_DH_OBJECT *sequenceHandle, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; if( sysContext == NULL ) { return( TSS2_SYS_RC_BAD_REFERENCE ); } rval = Tss2_Sys_HashSequenceStart_Prepare( sysContext, auth, hashAlg ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_HashSequenceStart_Complete( sysContext, sequenceHandle ); } } return rval; }
TPM_RC Tss2_Sys_EventSequenceComplete( TSS2_SYS_CONTEXT *sysContext, TPMI_DH_PCR pcrHandle, TPMI_DH_OBJECT sequenceHandle, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM2B_MAX_BUFFER *buffer, TPML_DIGEST_VALUES *results, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; rval = Tss2_Sys_EventSequenceComplete_Prepare( sysContext, pcrHandle, sequenceHandle, buffer ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_EventSequenceComplete_Complete( sysContext, results ); } } return rval; }
TPM_RC Tss2_Sys_Duplicate( TSS2_SYS_CONTEXT *sysContext, TPMI_DH_OBJECT objectHandle, TPMI_DH_OBJECT newParentHandle, TSS2_SYS_CMD_AUTHS const *cmdAuthsArray, TPM2B_DATA *encryptionKeyIn, TPMT_SYM_DEF_OBJECT *symmetricAlg, TPM2B_DATA *encryptionKeyOut, TPM2B_PRIVATE *duplicate, TPM2B_ENCRYPTED_SECRET *outSymSeed, TSS2_SYS_RSP_AUTHS *rspAuthsArray ) { TSS2_RC rval = TPM_RC_SUCCESS; if( sysContext == NULL ) { return( TSS2_SYS_RC_BAD_REFERENCE ); } rval = Tss2_Sys_Duplicate_Prepare( sysContext, objectHandle, newParentHandle, encryptionKeyIn, symmetricAlg ); if( rval == TSS2_RC_SUCCESS ) { rval = CommonOneCall( sysContext, cmdAuthsArray, rspAuthsArray ); if( rval == TSS2_RC_SUCCESS ) { rval = Tss2_Sys_Duplicate_Complete( sysContext, encryptionKeyOut, duplicate, outSymSeed ); } } return rval; }