Allow unlocked in VTS am: 43dd6e34bd am: 767b4b3c2a

Change-Id: Ia559b9083b1ac7960b93f710fc5cb2d5390dfac7
This commit is contained in:
Bowgo Tsai
2020-06-01 04:25:02 +00:00
committed by Automerger Merge Worker

View File

@@ -438,10 +438,10 @@ bool verify_attestation_record(const string& challenge, const string& app_id,
EXPECT_TRUE(device_locked);
}
// Check that the expected result from VBMeta matches the build type. Only a user build
// should have AVB reporting the device is locked.
EXPECT_NE(property_get("ro.build.type", property_value, ""), 0);
if (!strcmp(property_value, "user")) {
// Check that the device is locked if not debuggable, e.g., user build
// images in CTS. For VTS, debuggable images are used to allow adb root
// and the device is unlocked.
if (!property_get_bool("ro.debuggable", false)) {
EXPECT_TRUE(device_locked);
} else {
EXPECT_FALSE(device_locked);