Fix expected attestation version.

The attestation version cannot be infered from the keymaster version
because we provide software attestation for legacy keymaster 1 keys.
This patch changes the attestation test to expect either attestation
version 1 or 2.

Bug: 37351644
Test: VtsHalKeymasterV3_0TargetTest
Change-Id: I4db83a543db20191d288b2ca8308aa6597cd8e22
This commit is contained in:
Janis Danisevskis
2017-06-07 11:31:23 -07:00
parent 89ed70727d
commit 538b7d85ef

View File

@@ -925,11 +925,7 @@ bool verify_attestation_record(const string& challenge, const string& app_id,
&att_tee_enforced, //
&att_unique_id));
if (att_keymaster_version == 3) {
EXPECT_EQ(2U, att_attestation_version);
} else {
EXPECT_EQ(1U, att_attestation_version);
}
EXPECT_TRUE(att_attestation_version == 1 || att_attestation_version == 2);
expected_sw_enforced.push_back(TAG_ATTESTATION_APPLICATION_ID,
HidlBuf(app_id));