Home
last modified time | relevance | path

Searched refs:keyStore (Results 1 – 20 of 20) sorted by relevance

/cts/tests/tests/keystore/src/android/keystore/cts/
DKeyStoreTest.java522 for (KeyStore keyStore : keyStores()) { in test_KeyStore_getProvider()
523 assertNotNull(keyStore.getProvider()); in test_KeyStore_getProvider()
533 for (KeyStore keyStore : keyStores()) { in test_KeyStore_getType()
534 assertNotNull(keyStore.getType()); in test_KeyStore_getType()
539 for (KeyStore keyStore : keyStores()) { in test_KeyStore_getKey()
541 keyStore.getKey(null, null); in test_KeyStore_getKey()
542 fail(keyStore.getType()); in test_KeyStore_getKey()
547 for (KeyStore keyStore : keyStores()) { in test_KeyStore_getKey()
548 populate(keyStore); in test_KeyStore_getKey()
552 keyStore.getKey(null, null); in test_KeyStore_getKey()
[all …]
DImportWrappedKeyTest.java112 KeyStore keyStore = KeyStore.getInstance("AndroidKeyStore"); in testKeyStore_ImportWrappedKey() local
113 keyStore.load(null, null); in testKeyStore_ImportWrappedKey()
115 assertTrue("Failed to load key after wrapped import", keyStore.containsAlias(ALIAS)); in testKeyStore_ImportWrappedKey()
117 Key key = keyStore.getKey(ALIAS, null); in testKeyStore_ImportWrappedKey()
175 KeyStore keyStore = KeyStore.getInstance("AndroidKeyStore"); in testKeyStore_ImportWrappedKey_3DES() local
176 keyStore.load(null, null); in testKeyStore_ImportWrappedKey_3DES()
178 assertTrue("Failed to load key after wrapped import", keyStore.containsAlias(ALIAS)); in testKeyStore_ImportWrappedKey_3DES()
180 Key key = keyStore.getKey(ALIAS, null); in testKeyStore_ImportWrappedKey_3DES()
212 KeyStore keyStore = KeyStore.getInstance("AndroidKeyStore"); in testKeyStore_ImportWrappedKey_3DES_StrongBox() local
213 keyStore.load(null, null); in testKeyStore_ImportWrappedKey_3DES_StrongBox()
[all …]
DKeyAttestationTest.java227 KeyStore keyStore = KeyStore.getInstance("AndroidKeyStore"); in testEcAttestation_NoChallenge() local
228 keyStore.load(null); in testEcAttestation_NoChallenge()
231 Certificate certificates[] = keyStore.getCertificateChain(keystoreAlias); in testEcAttestation_NoChallenge()
237 keyStore.deleteEntry(keystoreAlias); in testEcAttestation_NoChallenge()
265 KeyStore keyStore = KeyStore.getInstance("AndroidKeyStore"); in testEcAttestation_DeviceLocked() local
266 keyStore.load(null); in testEcAttestation_DeviceLocked()
269 Certificate certificates[] = keyStore.getCertificateChain(keystoreAlias); in testEcAttestation_DeviceLocked()
275 keyStore.deleteEntry(keystoreAlias); in testEcAttestation_DeviceLocked()
296 KeyStore keyStore = KeyStore.getInstance("AndroidKeyStore"); in testEcAttestation_KeyStoreExceptionWhenRequestingUniqueId() local
297 keyStore.load(null); in testEcAttestation_KeyStoreExceptionWhenRequestingUniqueId()
[all …]
DAESCipherNistCavpKatTest.java271 KeyStore keyStore = KeyStore.getInstance("AndroidKeyStore"); in runKatTest() local
272 keyStore.load(null); in runKatTest()
273 keyStore.setEntry(keyAlias, in runKatTest()
282 SecretKey key = (SecretKey) keyStore.getKey(keyAlias, null); in runKatTest()
301 keyStore.deleteEntry(keyAlias); in runKatTest()
DTestUtils.java157 static void assertKeyStoreKeyPair(KeyStore keyStore, String alias, KeyPair keyPair) { in assertKeyStoreKeyPair() argument
166 entry = keyStore.getEntry(alias, null); in assertKeyStoreKeyPair()
167 cert = keyStore.getCertificate(alias); in assertKeyStoreKeyPair()
428 KeyStore keyStore = KeyStore.getInstance("AndroidKeyStore"); in importIntoAndroidKeyStore() local
429 keyStore.load(null); in importIntoAndroidKeyStore()
430 keyStore.setEntry(alias, in importIntoAndroidKeyStore()
434 keyStore.getCertificate(alias).getPublicKey(), in importIntoAndroidKeyStore()
435 (PrivateKey) keyStore.getKey(alias, null)); in importIntoAndroidKeyStore()
442 KeyStore keyStore = KeyStore.getInstance("AndroidKeyStore"); in importIntoAndroidKeyStore() local
443 keyStore.load(null); in importIntoAndroidKeyStore()
[all …]
DAndroidKeyStoreTest.java749 KeyStore keyStore = KeyStore.getInstance("AndroidKeyStore"); in tearDown() local
750 keyStore.load(null, null); in tearDown()
751 Enumeration<String> aliases = keyStore.aliases(); in tearDown()
754 keyStore.deleteEntry(alias); in tearDown()
DKeyPairGeneratorTest.java1718 serverKeyStore.keyStore.setCertificateEntry( in assertUsableForTLSPeerAuthentication()
1724 TestKeyStore.createTrustManagers(serverKeyStore.keyStore)); in assertUsableForTLSPeerAuthentication()
/cts/tests/tests/security/src/android/security/cts/
DCertificateTest.java122 KeyStore keyStore = KeyStore.getInstance(KeyStore.getDefaultType()); in createWfaKeyStore() local
123 keyStore.load(null, null); in createWfaKeyStore()
127 keyStore.setCertificateEntry(String.format("%d", index++), cert); in createWfaKeyStore()
129 return keyStore; in createWfaKeyStore()
173 KeyStore keyStore = KeyStore.getInstance("AndroidCAStore"); in getDeviceCertificates() local
174 keyStore.load(null, null); in getDeviceCertificates()
176 List<String> aliases = Collections.list(keyStore.aliases()); in getDeviceCertificates()
181 assertTrue(keyStore.isCertificateEntry(alias)); in getDeviceCertificates()
182 X509Certificate certificate = (X509Certificate) keyStore.getCertificate(alias); in getDeviceCertificates()
/cts/hostsidetests/appsecurity/test-apps/AuthBoundKeyApp/src/com/android/cts/authboundkey/
DAuthBoundKeyAppTest.java46 KeyStore keyStore = KeyStore.getInstance(KEYSTORE); in testGenerateAuthBoundKey() local
47 keyStore.load(null); in testGenerateAuthBoundKey()
61 KeyStore keyStore = KeyStore.getInstance("AndroidKeyStore"); in testUseKey() local
62 keyStore.load(null); in testUseKey()
64 SecretKey secretKey = (SecretKey) keyStore.getKey(KEY_NAME, null); in testUseKey()
/cts/hostsidetests/devicepolicy/app/ProfileOwner/src/com/android/cts/profileowner/
DAdminActionBookkeepingTest.java97 KeyStore keyStore = KeyStore.getInstance("AndroidCAStore"); in testGetPolicyInstalledCaCerts() local
98 keyStore.load(null, null); in testGetPolicyInstalledCaCerts()
99 assertNull(keyStore.getCertificateAlias(cert)); in testGetPolicyInstalledCaCerts()
101 final String alias = keyStore.getCertificateAlias(cert); in testGetPolicyInstalledCaCerts()
/cts/apps/CtsVerifier/src/com/android/cts/verifier/security/
DScreenLockBoundKeysTest.java115 KeyStore keyStore = KeyStore.getInstance("AndroidKeyStore"); in createKey() local
116 keyStore.load(null); in createKey()
144 KeyStore keyStore = KeyStore.getInstance("AndroidKeyStore"); in tryEncrypt() local
145 keyStore.load(null); in tryEncrypt()
146 SecretKey secretKey = (SecretKey) keyStore.getKey(KEY_NAME, null); in tryEncrypt()
DFingerprintBoundKeysTest.java159 KeyStore keyStore = KeyStore.getInstance("AndroidKeyStore"); in createKey() local
160 keyStore.load(null); in createKey()
221 KeyStore keyStore = KeyStore.getInstance("AndroidKeyStore"); in encryptInternal() local
222 keyStore.load(null); in encryptInternal()
223 SecretKey secretKey = (SecretKey) keyStore.getKey(KEY_NAME, null); in encryptInternal()
DProtectedConfirmationTest.java155 KeyStore keyStore = KeyStore.getInstance("AndroidKeyStore"); in trySign() local
156 keyStore.load(null); in trySign()
157 KeyStore.Entry key = keyStore.getEntry(KEY_NAME, null); in trySign()
/cts/hostsidetests/devicepolicy/app/CertInstaller/src/com/android/cts/certinstaller/
DDirectDelegatedCertInstallerTest.java139 KeyStore keyStore = KeyStore.getInstance("AndroidCAStore"); in testCaCertsOperations() local
140 keyStore.load(null, null); in testCaCertsOperations()
142 + " beginning of the test").that(keyStore.getCertificateAlias(caCert)).isNull(); in testCaCertsOperations()
158 keyStore.getCertificateAlias(caCert)).isNotNull(); in testCaCertsOperations()
/cts/hostsidetests/devicepolicy/app/DeviceOwner/src/com/android/cts/deviceowner/
DAdminActionBookkeepingTest.java226 KeyStore keyStore = KeyStore.getInstance("AndroidCAStore"); in testGetPolicyInstalledCaCerts() local
227 keyStore.load(null, null); in testGetPolicyInstalledCaCerts()
228 assertNull(keyStore.getCertificateAlias(cert)); in testGetPolicyInstalledCaCerts()
230 final String alias = keyStore.getCertificateAlias(cert); in testGetPolicyInstalledCaCerts()
/cts/apps/CtsVerifier/src/com/android/cts/verifier/managedprovisioning/
DAuthenticationBoundKeyTestActivity.java214 KeyStore keyStore = KeyStore.getInstance(KEYSTORE_NAME); in createKey() local
215 keyStore.load(null); in createKey()
242 KeyStore keyStore = KeyStore.getInstance(KEYSTORE_NAME); in loadSecretKey() local
243 keyStore.load(null); in loadSecretKey()
244 return (SecretKey) keyStore.getKey(getKeyName(testType), null); in loadSecretKey()
/cts/hostsidetests/devicepolicy/app/DeviceAndProfileOwner/src/com/android/cts/deviceandprofileowner/
DDelegatedCertInstallerTest.java200 KeyStore keyStore = KeyStore.getInstance("AndroidCAStore"); in testCaCertsOperations() local
201 keyStore.load(null, null); in testCaCertsOperations()
202 assertNull(keyStore.getCertificateAlias(caCert)); in testCaCertsOperations()
213 final String alias = keyStore.getCertificateAlias(caCert); in testCaCertsOperations()
/cts/tests/tests/webkit/src/android/webkit/cts/
DWebViewSslTest.java1029 KeyStore keyStore = KeyStore.getInstance("AndroidKeyStore"); in onReceivedClientCertRequest() local
1030 keyStore.load(null); in onReceivedClientCertRequest()
1032 keyStore.setEntry( in onReceivedClientCertRequest()
1037 key = (PrivateKey) keyStore.getKey("fake1", null); in onReceivedClientCertRequest()
/cts/libs/testserver/src/android/webkit/cts/
DTestWebServer.java536 KeyStore keyStore = KeyStore.getInstance(KeyStore.getDefaultType()); in getKeyManagers() local
537 keyStore.load(inputStream, PASSWORD.toCharArray()); in getKeyManagers()
542 keyManagerFactory.init(keyStore, PASSWORD.toCharArray()); in getKeyManagers()
DCtsTestServer.java907 KeyStore keyStore = KeyStore.getInstance(KeyStore.getDefaultType()); in getKeyManagers() local
908 keyStore.load(inputStream, PASSWORD.toCharArray()); in getKeyManagers()
913 keyManagerFactory.init(keyStore, PASSWORD.toCharArray()); in getKeyManagers()