/system/tpm/trunks/ |
H A D | policy_session_test.cc | 125 std::vector<std::string> digests; local 126 digests.push_back("digest1"); 127 digests.push_back("digest2"); 128 digests.push_back("digest3"); 133 EXPECT_EQ(TPM_RC_SUCCESS, session.PolicyOR(digests)); 134 EXPECT_EQ(tpm_digests.count, digests.size()); 135 EXPECT_EQ(StringFrom_TPM2B_DIGEST(tpm_digests.digests[0]), digests[0]); local 136 EXPECT_EQ(StringFrom_TPM2B_DIGEST(tpm_digests.digests[1]), digests[ local 137 EXPECT_EQ(StringFrom_TPM2B_DIGEST(tpm_digests.digests[2]), digests[2]); local 142 std::vector<std::string> digests; local 151 std::vector<std::string> digests; local [all...] |
H A D | policy_session_impl.cc | 93 TPM_RC PolicySessionImpl::PolicyOR(const std::vector<std::string>& digests) { argument 94 if (digests.size() >= arraysize(TPML_DIGEST::digests)) { 95 LOG(ERROR) << "TPM2.0 Spec only allows for up to 8 digests."; 99 tpm_digests.count = digests.size(); 100 for (size_t i = 0; i < digests.size(); i++) { 101 tpm_digests.digests[i] = Make_TPM2B_DIGEST(digests[i]);
|
H A D | trunks_client_test.cc | 714 std::vector<std::string> digests; local 715 digests.push_back(sign_digest); 716 digests.push_back(decrypt_digest); 717 result = trial_session->PolicyOR(digests); 778 result = policy_session->PolicyOR(digests); 802 result = policy_session->PolicyOR(digests);
|
H A D | tpm_utility_test.cc | 426 TPML_DIGEST_VALUES digests; local 429 .WillOnce(DoAll(SaveArg<2>(&digests), 433 EXPECT_EQ(1u, digests.count); 434 EXPECT_EQ(TPM_ALG_SHA256, digests.digests[0].hash_alg); 437 digests.digests[0].digest.sha256, 466 pcr_values.digests[0].size = 5; 1654 pcr_values.digests[0] = Make_TPM2B_DIGEST(pcr_value);
|
H A D | tpm_utility_impl.cc | 360 TPML_DIGEST_VALUES digests; local 361 digests.count = 1; 362 digests.digests[0].hash_alg = TPM_ALG_SHA256; 364 digests.digests[0].digest.sha256, 368 digests, 405 pcr_value->assign(StringFrom_TPM2B_DIGEST(pcr_values.digests[0]));
|
H A D | tpm_generated.h | 1082 TPM2B_DIGEST digests[8]; member in struct:trunks::TPML_DIGEST 1087 TPMT_HA digests[HASH_COUNT]; member in struct:trunks::TPML_DIGEST_VALUES 5082 const TPML_DIGEST_VALUES& digests, 5091 const TPML_DIGEST_VALUES& digests, 5097 const TPML_DIGEST_VALUES& digests, 5101 const TPML_DIGEST_VALUES& digests)> PCR_EventResponse; 5110 TPML_DIGEST_VALUES* digests, 5122 TPML_DIGEST_VALUES* digests,
|
H A D | tpm_generated.cc | 3676 if (arraysize(value.digests) < value.count) { 3680 result = Serialize_TPM2B_DIGEST(value.digests[i], buffer); 3703 if (arraysize(value->digests) < value->count) { 3709 &value->digests[i], 3729 if (arraysize(value.digests) < value.count) { 3733 result = Serialize_TPMT_HA(value.digests[i], buffer); 3756 if (arraysize(value->digests) < value->count) { 3762 &value->digests[i], 23488 const TPML_DIGEST_VALUES& digests, 23516 digests, 23485 SerializeCommand_PCR_Extend( const TPMI_DH_PCR& pcr_handle, const std::string& pcr_handle_name, const TPML_DIGEST_VALUES& digests, std::string* serialized_command, AuthorizationDelegate* authorization_delegate) argument 23692 PCR_Extend( const TPMI_DH_PCR& pcr_handle, const std::string& pcr_handle_name, const TPML_DIGEST_VALUES& digests, AuthorizationDelegate* authorization_delegate, const PCR_ExtendResponse& callback) argument 23719 PCR_ExtendSync( const TPMI_DH_PCR& pcr_handle, const std::string& pcr_handle_name, const TPML_DIGEST_VALUES& digests, AuthorizationDelegate* authorization_delegate) argument 23849 ParseResponse_PCR_Event( const std::string& response, TPML_DIGEST_VALUES* digests, AuthorizationDelegate* authorization_delegate) argument 23956 TPML_DIGEST_VALUES digests; local 23997 PCR_EventSync( const TPMI_DH_PCR& pcr_handle, const std::string& pcr_handle_name, const TPM2B_EVENT& event_data, TPML_DIGEST_VALUES* digests, AuthorizationDelegate* authorization_delegate) argument [all...] |
/system/keymaster/ |
H A D | android_keymaster_messages_test.cpp | 109 keymaster_digest_t digests[] = {KM_DIGEST_NONE, KM_DIGEST_MD5, KM_DIGEST_SHA1}; local 111 rsp.SetResults(digests); 114 EXPECT_EQ(array_length(digests), deserialized->results_length); 115 EXPECT_EQ(0, memcmp(deserialized->results, digests, array_size(digests)));
|
H A D | android_keymaster_test.cpp | 725 vector<keymaster_digest_t> digests = { local 731 for (keymaster_digest_t digest : digests) { 745 EXPECT_EQ(digests.size() * key_sizes.size() * 3, 761 // Can't emulate other digests for HMAC. 778 // Can't emulate other digests for HMAC. 795 // Can't emulate other digests for HMAC. 812 // Can't emulate other digests for HMAC. 830 // Can't emulate other digests for HMAC. 1372 vector<keymaster_digest_t> digests = { local 1383 for (keymaster_digest_t digest : digests) { 1554 keymaster_digest_t digests[] = { local 2281 keymaster_digest_t digests[] = { local [all...] |
H A D | android_keymaster_test_utils.cpp | 769 keymaster_digest_t** digests, 772 unwrap(dev), algorithm, purpose, digests, digests_length); 777 std::copy_if(*digests, *digests + *digests_length, std::back_inserter(filtered_digests), 780 free(*digests); 782 *digests = reinterpret_cast<keymaster_digest_t*>( 784 std::copy(filtered_digests.begin(), filtered_digests.end(), *digests); 766 get_supported_digests(const keymaster1_device_t* dev, keymaster_algorithm_t algorithm, keymaster_purpose_t purpose, keymaster_digest_t** digests, size_t* digests_length) argument
|
H A D | soft_keymaster_device.cpp | 88 keymaster_digest_t* digests; local 91 dev->get_supported_digests(dev, algorithm, purpose, &digests, &digests_length); 93 LOG_E("Error %d getting supported digests from keymaster1 device", error); 96 std::unique_ptr<keymaster_digest_t, Malloc_Delete> digests_deleter(digests); 98 (*map)[key] = make_vector(digests, digests_length); 507 keymaster_digest_t** digests, 512 if (!digests || !digests_length) 517 return km1_dev->get_supported_digests(km1_dev, algorithm, purpose, digests, digests_length); 531 *digests = reinterpret_cast<keymaster_digest_t*>(malloc(*digests_length * sizeof(**digests))); 504 get_supported_digests(const keymaster1_device_t* dev, keymaster_algorithm_t algorithm, keymaster_purpose_t purpose, keymaster_digest_t** digests, size_t* digests_length) argument [all...] |