Home
last modified time | relevance | path

Searched refs:KeyStore (Results 1 – 25 of 86) sorted by relevance

1234

/frameworks/base/core/java/android/security/
DConfirmationPrompt.java94 private final KeyStore mKeyStore = KeyStore.getInstance();
99 case KeyStore.CONFIRMATIONUI_OK: in doCallback()
103 case KeyStore.CONFIRMATIONUI_CANCELED: in doCallback()
107 case KeyStore.CONFIRMATIONUI_ABORTED: in doCallback()
111 case KeyStore.CONFIRMATIONUI_SYSTEM_ERROR: in doCallback()
278 case KeyStore.CONFIRMATIONUI_OK: in presentPrompt()
281 case KeyStore.CONFIRMATIONUI_OPERATION_PENDING: in presentPrompt()
284 case KeyStore.CONFIRMATIONUI_UNIMPLEMENTED: in presentPrompt()
287 case KeyStore.CONFIRMATIONUI_UIERROR: in presentPrompt()
310 if (responseCode == KeyStore.CONFIRMATIONUI_OK) { in cancelPrompt()
[all …]
/frameworks/base/services/core/java/com/android/server/locksettings/recoverablekeystore/
DKeyStoreProxyImpl.java22 import java.security.KeyStore;
34 private final KeyStore mKeyStore;
39 public KeyStoreProxyImpl(KeyStore keyStore) { in KeyStoreProxyImpl()
55 public void setEntry(String alias, KeyStore.Entry entry, KeyStore.ProtectionParameter protParam) in setEntry()
71 public static KeyStore getAndLoadAndroidKeyStore() throws KeyStoreException { in getAndLoadAndroidKeyStore()
72 KeyStore keyStore = KeyStore.getInstance(ANDROID_KEY_STORE_PROVIDER); in getAndLoadAndroidKeyStore()
DKeyStoreProxy.java20 import java.security.KeyStore;
41 void setEntry(String alias, KeyStore.Entry entry, KeyStore.ProtectionParameter protParam) in setEntry()
/frameworks/base/keystore/java/android/security/
DCredentials.java180 public static boolean deleteAllTypesForAlias(KeyStore keystore, String alias) { in deleteAllTypesForAlias()
181 return deleteAllTypesForAlias(keystore, alias, KeyStore.UID_SELF); in deleteAllTypesForAlias()
189 public static boolean deleteAllTypesForAlias(KeyStore keystore, String alias, int uid) { in deleteAllTypesForAlias()
203 public static boolean deleteCertificateTypesForAlias(KeyStore keystore, String alias) { in deleteCertificateTypesForAlias()
204 return deleteCertificateTypesForAlias(keystore, alias, KeyStore.UID_SELF); in deleteCertificateTypesForAlias()
212 public static boolean deleteCertificateTypesForAlias(KeyStore keystore, String alias, int uid) { in deleteCertificateTypesForAlias()
225 public static boolean deleteUserKeyTypeForAlias(KeyStore keystore, String alias) { in deleteUserKeyTypeForAlias()
226 return deleteUserKeyTypeForAlias(keystore, alias, KeyStore.UID_SELF); in deleteUserKeyTypeForAlias()
233 public static boolean deleteUserKeyTypeForAlias(KeyStore keystore, String alias, int uid) { in deleteUserKeyTypeForAlias()
235 if (ret == KeyStore.KEY_NOT_FOUND) { in deleteUserKeyTypeForAlias()
[all …]
DKeyStoreParameter.java25 import java.security.KeyStore.ProtectionParameter;
79 return (mFlags & KeyStore.FLAG_ENCRYPTED) != 0; in isEncryptionRequired()
133 mFlags |= KeyStore.FLAG_ENCRYPTED; in setEncryptionRequired()
135 mFlags &= ~KeyStore.FLAG_ENCRYPTED; in setEncryptionRequired()
/frameworks/base/keystore/java/android/security/keystore/
DAndroidKeyStoreProvider.java21 import android.security.KeyStore;
229 private static KeyCharacteristics getKeyCharacteristics(@NonNull KeyStore keyStore, in getKeyCharacteristics()
235 if (errorCode == KeyStore.KEY_PERMANENTLY_INVALIDATED) { in getKeyCharacteristics()
239 KeyStore.getKeyStoreException(errorCode)); in getKeyCharacteristics()
241 if (errorCode != KeyStore.NO_ERROR) { in getKeyCharacteristics()
244 .initCause(KeyStore.getKeyStoreException(errorCode)); in getKeyCharacteristics()
251 @NonNull KeyStore keyStore, @NonNull String privateKeyAlias, int uid, in loadAndroidKeyStorePublicKeyFromKeystore()
256 if (exportResult.resultCode != KeyStore.NO_ERROR) { in loadAndroidKeyStorePublicKeyFromKeystore()
259 .initCause(KeyStore.getKeyStoreException(exportResult.resultCode)); in loadAndroidKeyStorePublicKeyFromKeystore()
284 @NonNull KeyStore keyStore, @NonNull String privateKeyAlias, int uid) in loadAndroidKeyStorePublicKeyFromKeystore()
[all …]
DKeyStoreCryptoOperationUtils.java19 import android.security.KeyStore;
46 KeyStore keyStore, AndroidKeyStoreKey key, int beginOpResultCode) { in getInvalidKeyExceptionForInit()
47 if (beginOpResultCode == KeyStore.NO_ERROR) { in getInvalidKeyExceptionForInit()
56 case KeyStore.OP_AUTH_NEEDED: in getInvalidKeyExceptionForInit()
75 KeyStore keyStore, AndroidKeyStoreKey key, int beginOpResultCode) { in getExceptionForCipherInit()
76 if (beginOpResultCode == KeyStore.NO_ERROR) { in getExceptionForCipherInit()
DAndroidKeyStoreSpi.java21 import android.security.KeyStore;
40 import java.security.KeyStore.Entry;
41 import java.security.KeyStore.LoadStoreParameter;
42 import java.security.KeyStore.PrivateKeyEntry;
43 import java.security.KeyStore.ProtectionParameter;
44 import java.security.KeyStore.SecretKeyEntry;
91 private KeyStore mKeyStore;
92 private int mUid = KeyStore.UID_SELF;
356 java.security.KeyStore.ProtectionParameter param) throws KeyStoreException { in setPrivateKeyEntry()
365 flags = KeyStore.FLAG_ENCRYPTED; in setPrivateKeyEntry()
[all …]
DKeyStoreCryptoOperationChunkedStreamer.java20 import android.security.KeyStore;
139 } else if (opResult.resultCode != KeyStore.NO_ERROR) { in update()
140 throw KeyStore.getKeyStoreException(opResult.resultCode); in update()
175 } else if (opResult.resultCode != KeyStore.NO_ERROR) { in doFinal()
176 throw KeyStore.getKeyStoreException(opResult.resultCode); in doFinal()
207 private final KeyStore mKeyStore;
210 public MainDataStream(KeyStore keyStore, IBinder operationToken) { in MainDataStream()
DAndroidKeyStoreLoadStoreParameter.java19 import java.security.KeyStore;
20 import java.security.KeyStore.ProtectionParameter;
22 class AndroidKeyStoreLoadStoreParameter implements KeyStore.LoadStoreParameter {
DAndroidKeyStoreKeyGeneratorSpi.java20 import android.security.KeyStore;
106 private final KeyStore mKeyStore = KeyStore.getInstance();
309 flags |= KeyStore.FLAG_STRONGBOX; in engineGenerateKey()
323 if (errorCode != KeyStore.NO_ERROR) { in engineGenerateKey()
324 if (errorCode == KeyStore.HARDWARE_TYPE_UNAVAILABLE) { in engineGenerateKey()
328 "Keystore operation failed", KeyStore.getKeyStoreException(errorCode)); in engineGenerateKey()
DAndroidKeyStoreAuthenticatedAESCipherSpi.java22 import android.security.KeyStore;
176 KeyStore keyStore, IBinder operationToken) { in createMainDataStreamer()
192 KeyStore keyStore, IBinder operationToken) { in createAdditionalAuthenticationDataStreamer()
405 private final KeyStore mKeyStore;
408 private AdditionalAuthenticationDataStream(KeyStore keyStore, IBinder operationToken) { in AdditionalAuthenticationDataStream()
422 if (result.resultCode == KeyStore.NO_ERROR) { in update()
440 KeyStore.NO_ERROR, in finish()
DAndroidKeyStoreKeyPairGeneratorSpi.java23 import android.security.KeyStore;
152 private KeyStore mKeyStore;
353 mKeyStore = KeyStore.getInstance(); in initialize()
364 mEntryUid = KeyStore.UID_SELF; in resetAll()
449 int flags = (mEncryptionAtRestRequired) ? KeyStore.FLAG_ENCRYPTED : 0; in generateKeyPair()
450 if (((flags & KeyStore.FLAG_ENCRYPTED) != 0) in generateKeyPair()
451 && (mKeyStore.state() != KeyStore.State.UNLOCKED)) { in generateKeyPair()
458 flags |= KeyStore.FLAG_STRONGBOX; in generateKeyPair()
522 if (errorCode != KeyStore.NO_ERROR) { in generateKeystoreKeyPair()
523 if (errorCode == KeyStore.HARDWARE_TYPE_UNAVAILABLE) { in generateKeystoreKeyPair()
[all …]
DSecureKeyImportUnavailableException.java19 import android.security.KeyStore;
34 super(message, new KeyStoreException(KeyStore.HARDWARE_TYPE_UNAVAILABLE, in SecureKeyImportUnavailableException()
DStrongBoxUnavailableException.java19 import android.security.KeyStore;
36 new KeyStoreException(KeyStore.HARDWARE_TYPE_UNAVAILABLE, "No StrongBox available") in StrongBoxUnavailableException()
/frameworks/opt/net/wifi/service/java/com/android/server/wifi/hotspot2/
DWfaKeyStore.java23 import java.security.KeyStore;
41 private KeyStore mKeyStore = null;
52 mKeyStore = KeyStore.getInstance(KeyStore.getDefaultType()); in load()
72 public KeyStore get() { in get()
DCertificateVerifier.java21 import java.security.KeyStore;
51 KeyStore ks = KeyStore.getInstance("AndroidCAStore"); in verifyCaCert()
/frameworks/base/core/tests/coretests/src/android/net/http/
DX509TrustManagerExtensionsTest.java19 import java.security.KeyStore;
53 String defaultType = KeyStore.getDefaultType(); in testGoodCast()
54 TrustManagerImpl tmi = new TrustManagerImpl(KeyStore.getInstance(defaultType)); in testGoodCast()
61 String defaultKeystoreType = KeyStore.getDefaultType(); in testNormalUseCase()
62 tmf.init(KeyStore.getInstance(defaultKeystoreType)); in testNormalUseCase()
/frameworks/base/services/core/java/com/android/server/locksettings/
DSyntheticPasswordCrypto.java26 import java.security.KeyStore;
126 KeyStore keyStore = KeyStore.getInstance("AndroidKeyStore"); in decryptBlobV1()
140 KeyStore keyStore = KeyStore.getInstance("AndroidKeyStore"); in decryptBlob()
161 KeyStore keyStore = KeyStore.getInstance("AndroidKeyStore"); in createBlob()
174 new KeyStore.SecretKeyEntry(secretKey), in createBlob()
189 KeyStore keyStore; in destroyBlobKey()
191 keyStore = KeyStore.getInstance("AndroidKeyStore"); in destroyBlobKey()
/frameworks/base/core/java/org/apache/http/conn/ssl/
DSSLSocketFactory.java48 import java.security.KeyStore;
192 final KeyStore keystore, in SSLSocketFactory()
194 final KeyStore truststore, in SSLSocketFactory()
218 final KeyStore keystore, in SSLSocketFactory()
220 final KeyStore truststore) in SSLSocketFactory()
226 public SSLSocketFactory(final KeyStore keystore, final String keystorePassword) in SSLSocketFactory()
232 public SSLSocketFactory(final KeyStore truststore) in SSLSocketFactory()
266 private static KeyManager[] createKeyManagers(final KeyStore keystore, final String password) in createKeyManagers()
278 private static TrustManager[] createTrustManagers(final KeyStore keystore) in createTrustManagers()
/frameworks/base/services/tests/servicestests/src/com/android/server/locksettings/
DLockSettingsServiceTestable.java29 import android.security.KeyStore;
42 private KeyStore mKeyStore;
51 public MockInjector(Context context, LockSettingsStorage storage, KeyStore keyStore, in MockInjector()
98 public KeyStore getKeyStore() { in getKeyStore()
128 public RecoverableKeyStoreManager getRecoverableKeyStoreManager(KeyStore keyStore) { in getRecoverableKeyStoreManager()
134 LockSettingsStorage storage, FakeGateKeeperService gatekeeper, KeyStore keystore, in LockSettingsServiceTestable()
/frameworks/base/services/core/java/com/android/server/locksettings/recoverablekeystore/storage/
DApplicationKeyStorage.java26 import android.security.KeyStore;
33 import java.security.KeyStore.SecretKeyEntry;
52 private final KeyStore mKeystoreService;
54 public static ApplicationKeyStorage getInstance(KeyStore keystoreService) in getInstance()
62 ApplicationKeyStorage(KeyStoreProxy keyStore, KeyStore keystoreService) { in ApplicationKeyStorage()
/frameworks/opt/net/wifi/tests/wifitests/src/com/android/server/wifi/hotspot2/
DPasspointProvisioningTestUtil.java28 import java.security.KeyStore;
107 public static KeyStore createFakeKeyStore() { in createFakeKeyStore()
108 KeyStore keyStore = null; in createFakeKeyStore()
111 keyStore = KeyStore.getInstance(KeyStore.getDefaultType()); in createFakeKeyStore()
/frameworks/opt/net/wifi/tests/wifitests/src/com/android/server/wifi/
DMockKeyStore.java8 import android.security.KeyStore;
35 public KeyStore createMock() { in createMock()
36 KeyStore mock = mock(KeyStore.class); in createMock()
37 when(mock.state()).thenReturn(KeyStore.State.UNLOCKED); in createMock()
/frameworks/opt/net/wifi/service/java/com/android/server/wifi/
DWifiKeyStore.java24 import android.security.KeyStore;
52 private final KeyStore mKeyStore;
54 WifiKeyStore(KeyStore keyStore) { in WifiKeyStore()
102 KeyStore.FLAG_NONE); in installKeys()
190 return mKeyStore.put(name, certData, Process.WIFI_UID, KeyStore.FLAG_NONE); in putCertsInKeyStore()
207 return mKeyStore.importKey(name, privKeyData, Process.WIFI_UID, KeyStore.FLAG_NONE); in putKeyInKeyStore()

1234