Lines Matching refs:sDevice

344         ASSERT_EQ(0, keymaster_open(mod, &sDevice))  in SetUpTestCase()
350 ASSERT_TRUE(sDevice->generate_keypair != NULL) in SetUpTestCase()
353 ASSERT_TRUE(sDevice->import_keypair != NULL) in SetUpTestCase()
356 ASSERT_TRUE(sDevice->get_keypair_public != NULL) in SetUpTestCase()
359 ASSERT_TRUE(sDevice->sign_data != NULL) in SetUpTestCase()
362 ASSERT_TRUE(sDevice->verify_data != NULL) in SetUpTestCase()
367 ASSERT_EQ(0, keymaster_close(sDevice)); in TearDownTestCase()
371 static keymaster_device_t* sDevice; member in android::KeymasterBaseTest
374 keymaster_device_t* KeymasterBaseTest::sDevice = NULL; member in android::KeymasterBaseTest
406 sDevice->generate_keypair(sDevice, key_type, &params, &key_blob, &key_blob_length)) in TEST_P()
408 UniqueKey key(&sDevice, key_blob, key_blob_length); in TEST_P()
413 sDevice->get_keypair_public(sDevice, key_blob, key_blob_length, in TEST_P()
453 sDevice->generate_keypair(sDevice, key_type, &params, &key_blob, &key_blob_length)) in TEST_P()
455 UniqueKey key(&sDevice, key_blob, key_blob_length); in TEST_P()
460 sDevice->get_keypair_public(sDevice, key_blob, key_blob_length, in TEST_P()
497 sDevice->generate_keypair(sDevice, key_type, NULL, &key_blob, &key_blob_length)) in TEST_P()
512 sDevice->generate_keypair(sDevice, key_type, NULL, &key_blob, &key_blob_length)) in TEST_F()
521 sDevice->import_keypair(sDevice, TEST_RSA_KEY_1, sizeof(TEST_RSA_KEY_1), in TEST_F()
524 UniqueKey key(&sDevice, key_blob, key_blob_length); in TEST_F()
529 sDevice->get_keypair_public(sDevice, key_blob, key_blob_length, in TEST_F()
557 sDevice->import_keypair(sDevice, TEST_EC_KEY_1, sizeof(TEST_EC_KEY_1), in TEST_F()
560 UniqueKey key(&sDevice, key_blob, key_blob_length); in TEST_F()
565 sDevice->get_keypair_public(sDevice, key_blob, key_blob_length, in TEST_F()
593 sDevice->import_keypair(sDevice, BOGUS_KEY_1, sizeof(BOGUS_KEY_1), in TEST_F()
603 sDevice->import_keypair(sDevice, NULL, 0, in TEST_F()
616 sDevice->import_keypair(sDevice, testKey.get(), testKey.length(), in TEST_F()
619 UniqueKey key(&sDevice, key_blob, key_blob_length); in TEST_F()
624 sDevice->get_keypair_public(sDevice, key_blob, key_blob_length, in TEST_F()
638 sDevice->import_keypair(sDevice, testKey.get(), testKey.length(), in TEST_F()
641 UniqueKey key(&sDevice, key_blob, key_blob_length); in TEST_F()
646 sDevice->get_keypair_public(sDevice, key_blob, key_blob_length, in TEST_F()
659 sDevice->get_keypair_public(sDevice, NULL, 0, in TEST_F()
673 sDevice->import_keypair(sDevice, testKey.get(), testKey.length(), in TEST_F()
676 UniqueKey key(&sDevice, key_blob, key_blob_length); in TEST_F()
679 sDevice->get_keypair_public(sDevice, key.get(), key.length(), in TEST_F()
692 sDevice->import_keypair(sDevice, testKey.get(), testKey.length(), in TEST_F()
695 UniqueKey key(&sDevice, key_blob, key_blob_length); in TEST_F()
698 sDevice->get_keypair_public(sDevice, key.get(), key.length(), in TEST_F()
711 sDevice->import_keypair(sDevice, testKey.get(), testKey.length(), in TEST_F()
714 UniqueKey key(&sDevice, key_blob, key_blob_length); in TEST_F()
728 if (sDevice->delete_keypair != NULL) { in TEST_F()
730 sDevice->import_keypair(sDevice, testKey.get(), testKey.length(), in TEST_F()
735 ASSERT_EQ(0, sDevice->delete_keypair(sDevice, key_blob, key_blob_length)) in TEST_F()
738 ASSERT_EQ(-1, sDevice->delete_keypair(sDevice, key_blob, key_blob_length)) in TEST_F()
748 if (sDevice->delete_keypair != NULL) { in TEST_F()
749 ASSERT_EQ(-1, sDevice->delete_keypair(sDevice, NULL, 0)) in TEST_F()
861 sDevice->import_keypair(sDevice, testKey.get(), testKey.length(), in TEST_F()
864 UniqueKey key(&sDevice, key_blob, key_blob_length); in TEST_F()
878 sDevice->sign_data(sDevice, &params, key_blob, key_blob_length, in TEST_F()
901 sDevice->import_keypair(sDevice, testKey.get(), testKey.length(), in TEST_F()
904 UniqueKey key(&sDevice, key_blob, key_blob_length); in TEST_F()
917 sDevice->sign_data(sDevice, &params, key_blob, key_blob_length, in TEST_F()
926 sDevice->get_keypair_public(sDevice, key_blob, key_blob_length, in TEST_F()
949 sDevice->import_keypair(sDevice, testKey.get(), testKey.length(), in TEST_F()
952 UniqueKey key(&sDevice, key_blob, key_blob_length); in TEST_F()
966 sDevice->sign_data(sDevice, &params, key_blob, key_blob_length, in TEST_F()
985 sDevice->sign_data(sDevice, &params, NULL, 0, in TEST_F()
999 sDevice->import_keypair(sDevice, testKey.get(), testKey.length(), in TEST_F()
1002 UniqueKey key(&sDevice, key_blob, key_blob_length); in TEST_F()
1013 sDevice->sign_data(sDevice, &params, key_blob, key_blob_length, in TEST_F()
1027 sDevice->import_keypair(sDevice, testKey.get(), testKey.length(), in TEST_F()
1030 UniqueKey key(&sDevice, key_blob, key_blob_length); in TEST_F()
1044 sDevice->sign_data(sDevice, &params, key_blob, key_blob_length, in TEST_F()
1058 sDevice->import_keypair(sDevice, testKey.get(), testKey.length(), in TEST_F()
1061 UniqueKey key(&sDevice, key_blob, key_blob_length); in TEST_F()
1075 sDevice->verify_data(sDevice, &params, key_blob, key_blob_length, in TEST_F()
1089 sDevice->import_keypair(sDevice, testKey.get(), testKey.length(), in TEST_F()
1092 UniqueKey key(&sDevice, key_blob, key_blob_length); in TEST_F()
1105 sDevice->sign_data(sDevice, &params, key_blob, key_blob_length, in TEST_F()
1112 sDevice->verify_data(sDevice, &params, key_blob, key_blob_length, in TEST_F()
1126 sDevice->import_keypair(sDevice, testKey.get(), testKey.length(), in TEST_F()
1129 UniqueKey key(&sDevice, key_blob, key_blob_length); in TEST_F()
1137 sDevice->verify_data(sDevice, &params, key_blob, key_blob_length, in TEST_F()
1151 sDevice->import_keypair(sDevice, testKey.get(), testKey.length(), in TEST_F()
1154 UniqueKey key(&sDevice, key_blob, key_blob_length); in TEST_F()
1161 sDevice->verify_data(sDevice, &params, key_blob, key_blob_length, in TEST_F()
1180 sDevice->verify_data(sDevice, &params, NULL, 0, in TEST_F()
1191 sDevice->import_keypair(sDevice, TEST_SIGN_RSA_KEY_1, sizeof(TEST_SIGN_RSA_KEY_1), in TEST_F()
1194 UniqueKey key(&sDevice, key_blob, key_blob_length); in TEST_F()
1205 sDevice->verify_data(sDevice, &params, key_blob, key_blob_length, in TEST_F()
1219 sDevice->import_keypair(sDevice, testKey.get(), testKey.length(), in TEST_F()
1222 UniqueKey key(&sDevice, key_blob, key_blob_length); in TEST_F()
1233 sDevice->verify_data(sDevice, &params, key.get(), key.length(), in TEST_F()
1244 if (sDevice->delete_all == NULL) { in TEST_F()
1252 sDevice->import_keypair(sDevice, testKey.get(), testKey.length(), in TEST_F()
1255 UniqueKey key1(&sDevice, key1_blob, key1_blob_length); in TEST_F()
1261 sDevice->import_keypair(sDevice, testKey2.get(), testKey2.length(), in TEST_F()
1264 UniqueKey key2(&sDevice, key2_blob, key2_blob_length); in TEST_F()
1266 ASSERT_EQ(0, sDevice->delete_all(sDevice)) in TEST_F()
1274 sDevice->get_keypair_public(sDevice, key1_blob, key1_blob_length, in TEST_F()
1279 sDevice->get_keypair_public(sDevice, key2_blob, key2_blob_length, in TEST_F()