Merge "KeyMint: fix auth test HAT" into main am: 41bbc573f7

Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2727633

Change-Id: I20656fb1ade0c7580f53944809bc3393cb582e69
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
David Drysdale
2023-08-25 10:06:17 +00:00
committed by Automerger Merge Worker

View File

@@ -545,7 +545,7 @@ TEST_P(AuthTest, AuthPerOperation) {
ASSERT_GT(dodgy_hat->mac.size(), 0); ASSERT_GT(dodgy_hat->mac.size(), 0);
dodgy_hat->mac[0] ^= 0x01; dodgy_hat->mac[0] ^= 0x01;
EXPECT_EQ(ErrorCode::KEY_USER_NOT_AUTHENTICATED, EXPECT_EQ(ErrorCode::KEY_USER_NOT_AUTHENTICATED,
Finish(message, {} /* signature */, &ciphertext, hat.value())); Finish(message, {} /* signature */, &ciphertext, dodgy_hat.value()));
} }
// Test use of a key that requires an auth token for each action on the operation, with // Test use of a key that requires an auth token for each action on the operation, with