/cts/tests/tests/keystore/src/android/keystore/cts/ |
KeyProtectionTest.java | 20 import android.security.keystore.KeyProperties; 33 KeyProtection spec = new KeyProtection.Builder(KeyProperties.PURPOSE_ENCRYPT) 36 assertEquals(KeyProperties.PURPOSE_ENCRYPT, spec.getPurposes()); 63 KeyProperties.PURPOSE_DECRYPT | KeyProperties.PURPOSE_VERIFY) 64 .setBlockModes(KeyProperties.BLOCK_MODE_GCM, KeyProperties.BLOCK_MODE_CTR) 65 .setDigests(KeyProperties.DIGEST_SHA256, KeyProperties.DIGEST_SHA512) 66 .setEncryptionPaddings(KeyProperties.ENCRYPTION_PADDING_RSA_PKCS1 [all...] |
KeyPairGeneratorTest.java | 22 import android.security.keystore.KeyProperties; 175 KeyProperties.PURPOSE_SIGN | KeyProperties.PURPOSE_VERIFY) 290 KeyProperties.PURPOSE_ENCRYPT) 291 .setEncryptionPaddings(KeyProperties.ENCRYPTION_PADDING_NONE) 310 new String[] {KeyProperties.BLOCK_MODE_GCM, KeyProperties.BLOCK_MODE_CBC}; 312 new String[] {KeyProperties.ENCRYPTION_PADDING_RSA_OAEP, 313 KeyProperties.ENCRYPTION_PADDING_RSA_PKCS1}; 315 new String[] {KeyProperties.DIGEST_SHA256, KeyProperties.DIGEST_SHA1} [all...] |
KeyGenParameterSpecTest.java | 20 import android.security.keystore.KeyProperties; 44 "arbitrary", KeyProperties.PURPOSE_ENCRYPT) 48 assertEquals(KeyProperties.PURPOSE_ENCRYPT, spec.getPurposes()); 83 "arbitrary", KeyProperties.PURPOSE_SIGN | KeyProperties.PURPOSE_ENCRYPT) 85 .setBlockModes(KeyProperties.BLOCK_MODE_GCM, KeyProperties.BLOCK_MODE_CBC) 90 .setDigests(KeyProperties.DIGEST_SHA256, KeyProperties.DIGEST_SHA384) 91 .setEncryptionPaddings(KeyProperties.ENCRYPTION_PADDING_RSA_OAEP [all...] |
KeyInfoTest.java | 21 import android.security.keystore.KeyProperties; 45 KeyProperties.PURPOSE_SIGN | KeyProperties.PURPOSE_ENCRYPT) 50 .setEncryptionPaddings(KeyProperties.ENCRYPTION_PADDING_RSA_PKCS1, 51 KeyProperties.ENCRYPTION_PADDING_RSA_OAEP) 52 .setSignaturePaddings(KeyProperties.SIGNATURE_PADDING_RSA_PKCS1, 53 KeyProperties.SIGNATURE_PADDING_RSA_PSS) 54 .setDigests(KeyProperties.DIGEST_SHA256, KeyProperties.DIGEST_SHA512) 55 .setBlockModes(KeyProperties.BLOCK_MODE_ECB [all...] |
CipherTest.java | 24 import android.security.keystore.KeyProperties; 328 KeyProperties.PURPOSE_ENCRYPT | KeyProperties.PURPOSE_DECRYPT, 368 KeyProperties.PURPOSE_ENCRYPT, 390 KeyProperties.PURPOSE_ENCRYPT | KeyProperties.PURPOSE_DECRYPT, 474 KeyProperties.PURPOSE_ENCRYPT | KeyProperties.PURPOSE_DECRYPT, 531 KeyProperties.PURPOSE_ENCRYPT | KeyProperties.PURPOSE_DECRYPT [all...] |
SecretKeyFactoryTest.java | 21 import android.security.keystore.KeyProperties; 97 new String[] {KeyProperties.BLOCK_MODE_CTR, KeyProperties.BLOCK_MODE_ECB}; 99 new String[] {KeyProperties.ENCRYPTION_PADDING_PKCS7, 100 KeyProperties.ENCRYPTION_PADDING_NONE}; 106 purposes = KeyProperties.PURPOSE_SIGN; 108 digests = new String[] {KeyProperties.DIGEST_SHA384}; 109 purposes = KeyProperties.PURPOSE_DECRYPT; 181 KeyProperties.PURPOSE_ENCRYPT) 182 .setBlockModes(KeyProperties.BLOCK_MODE_CBC [all...] |
TestUtils.java | 24 import android.security.keystore.KeyProperties; 644 return KeyProperties.KEY_ALGORITHM_AES; 646 return KeyProperties.KEY_ALGORITHM_3DES; 648 return KeyProperties.KEY_ALGORITHM_RSA; 670 return KeyProperties.DIGEST_SHA1; 673 return KeyProperties.DIGEST_SHA1; 676 return KeyProperties.DIGEST_SHA224; 679 return KeyProperties.DIGEST_SHA256; 682 return KeyProperties.DIGEST_SHA384; 685 return KeyProperties.DIGEST_SHA512 [all...] |
/frameworks/base/keystore/java/android/security/keystore/ |
KeyInfo.java | 70 private final @KeyProperties.OriginEnum int mOrigin; 74 private final @KeyProperties.PurposeEnum int mPurposes; 75 private final @KeyProperties.EncryptionPaddingEnum String[] mEncryptionPaddings; 76 private final @KeyProperties.SignaturePaddingEnum String[] mSignaturePaddings; 77 private final @KeyProperties.DigestEnum String[] mDigests; 78 private final @KeyProperties.BlockModeEnum String[] mBlockModes; 92 @KeyProperties.OriginEnum int origin, 97 @KeyProperties.PurposeEnum int purposes, 98 @KeyProperties.EncryptionPaddingEnum String[] encryptionPaddings, 99 @KeyProperties.SignaturePaddingEnum String[] signaturePaddings [all...] |
KeyProtection.java | 88 * new KeyProtection.Builder(KeyProperties.PURPOSE_ENCRYPT | KeyProperties.PURPOSE_DECRYPT) 89 * .setBlockMode(KeyProperties.BLOCK_MODE_GCM) 90 * .setEncryptionPaddings(KeyProperties.ENCRYPTION_PADDING_NONE) 113 * new KeyProtection.Builder(KeyProperties.PURPOSE_SIGN).build()); 139 * new KeyProtection.Builder(KeyProperties.PURPOSE_SIGN) 140 * .setDigests(KeyProperties.DIGEST_SHA256, KeyProperties.DIGEST_SHA512) 169 * new KeyProtection.Builder(KeyProperties.PURPOSE_SIGN) 170 * .setDigests(KeyProperties.DIGEST_SHA256 [all...] |
AndroidKeyStoreSpi.java | 27 import android.security.keystore.KeyProperties; 290 if (KeyProperties.KEY_ALGORITHM_EC.equalsIgnoreCase(keyAlgorithm)) { 293 KeyProperties.PURPOSE_SIGN | KeyProperties.PURPOSE_VERIFY); 297 KeyProperties.DIGEST_NONE, 298 KeyProperties.DIGEST_SHA1, 299 KeyProperties.DIGEST_SHA224, 300 KeyProperties.DIGEST_SHA256, 301 KeyProperties.DIGEST_SHA384, 302 KeyProperties.DIGEST_SHA512) [all...] |
KeyGenParameterSpec.java | 53 * {@link KeyProperties}.{@code KEY_ALGORITHM} constants) from the {@code AndroidKeyStore} provider 82 * <li>{@link KeyProperties#PURPOSE_SIGN},</li> 88 * <li>(RSA keys only) padding scheme {@link KeyProperties#SIGNATURE_PADDING_RSA_PKCS1}.</li> 114 * KeyProperties.KEY_ALGORITHM_EC, "AndroidKeyStore"); 118 * KeyProperties.PURPOSE_SIGN) 120 * .setDigests(KeyProperties.DIGEST_SHA256, 121 * KeyProperties.DIGEST_SHA384, 122 * KeyProperties.DIGEST_SHA512) 146 * KeyProperties.KEY_ALGORITHM_RSA, "AndroidKeyStore"); 150 * KeyProperties.PURPOSE_SIGN [all...] |
AndroidKeyStoreSecretKeyFactorySpi.java | 90 @KeyProperties.OriginEnum int origin; 92 @KeyProperties.PurposeEnum int purposes; 95 @KeyProperties.DigestEnum String[] digests; 96 @KeyProperties.BlockModeEnum String[] blockModes; 103 origin = KeyProperties.Origin.fromKeymaster( 107 origin = KeyProperties.Origin.fromKeymaster( 120 purposes = KeyProperties.Purpose.allFromKeymaster( 128 @KeyProperties.EncryptionPaddingEnum String jcaPadding = 129 KeyProperties.EncryptionPadding.fromKeymaster(keymasterPadding); 133 @KeyProperties.SignaturePaddingEnum String padding [all...] |
AndroidKeyStoreECPrivateKey.java | 32 super(alias, uid, KeyProperties.KEY_ALGORITHM_EC);
|
AndroidKeyStoreRSAPrivateKey.java | 33 super(alias, uid, KeyProperties.KEY_ALGORITHM_RSA);
|
AndroidKeyStoreKeyGeneratorSpi.java | 26 import android.security.keystore.KeyProperties; 185 mKeymasterPurposes = KeyProperties.Purpose.allToKeymaster(spec.getPurposes()); 186 mKeymasterPaddings = KeyProperties.EncryptionPadding.allToKeymaster( 192 mKeymasterBlockModes = KeyProperties.BlockMode.allToKeymaster(spec.getBlockModes()); 193 if (((spec.getPurposes() & KeyProperties.PURPOSE_ENCRYPT) != 0) 201 + KeyProperties.BlockMode.fromKeymaster(keymasterBlockMode) 224 KeyProperties.Digest.allToKeymaster(spec.getDigests()); 230 + KeyProperties.Digest.fromKeymaster(mKeymasterDigest) 237 mKeymasterDigests = KeyProperties.Digest.allToKeymaster(spec.getDigests()); 294 if (((spec.getPurposes() & KeyProperties.PURPOSE_ENCRYPT) != 0 [all...] |
AndroidKeyStoreKeyPairGeneratorSpi.java | 160 private @KeyProperties.KeyAlgorithmEnum String mJcaKeyAlgorithm; 214 KeyProperties.KeyAlgorithm.toKeymasterAsymmetricKeyAlgorithm( 225 KeyProperties.PURPOSE_SIGN 226 | KeyProperties.PURPOSE_VERIFY); 230 KeyProperties.DIGEST_NONE, 231 KeyProperties.DIGEST_SHA1, 232 KeyProperties.DIGEST_SHA224, 233 KeyProperties.DIGEST_SHA256, 234 KeyProperties.DIGEST_SHA384, 235 KeyProperties.DIGEST_SHA512) [all...] |
/cts/apps/CtsVerifier/src/com/android/cts/verifier/security/ |
ScreenLockBoundKeysTest.java | 29 import android.security.keystore.KeyProperties; 118 KeyProperties.KEY_ALGORITHM_AES, "AndroidKeyStore"); 123 KeyProperties.PURPOSE_ENCRYPT | KeyProperties.PURPOSE_DECRYPT) 124 .setBlockModes(KeyProperties.BLOCK_MODE_CBC) 128 .setEncryptionPaddings(KeyProperties.ENCRYPTION_PADDING_PKCS7) 148 KeyProperties.KEY_ALGORITHM_AES + "/" + KeyProperties.BLOCK_MODE_CBC + "/" 149 + KeyProperties.ENCRYPTION_PADDING_PKCS7);
|
/developers/build/prebuilts/gradle/ConfirmCredential/Application/src/main/java/com/example/android/confirmcredential/ |
MainActivity.java | 26 import android.security.keystore.KeyProperties; 104 KeyProperties.KEY_ALGORITHM_AES + "/" + KeyProperties.BLOCK_MODE_CBC + "/" 105 + KeyProperties.ENCRYPTION_PADDING_PKCS7); 144 KeyProperties.KEY_ALGORITHM_AES, "AndroidKeyStore"); 149 KeyProperties.PURPOSE_ENCRYPT | KeyProperties.PURPOSE_DECRYPT) 150 .setBlockModes(KeyProperties.BLOCK_MODE_CBC) 154 .setEncryptionPaddings(KeyProperties.ENCRYPTION_PADDING_PKCS7)
|
/developers/samples/android/security/ConfirmCredential/Application/src/main/java/com/example/android/confirmcredential/ |
MainActivity.java | 26 import android.security.keystore.KeyProperties; 104 KeyProperties.KEY_ALGORITHM_AES + "/" + KeyProperties.BLOCK_MODE_CBC + "/" 105 + KeyProperties.ENCRYPTION_PADDING_PKCS7); 144 KeyProperties.KEY_ALGORITHM_AES, "AndroidKeyStore"); 149 KeyProperties.PURPOSE_ENCRYPT | KeyProperties.PURPOSE_DECRYPT) 150 .setBlockModes(KeyProperties.BLOCK_MODE_CBC) 154 .setEncryptionPaddings(KeyProperties.ENCRYPTION_PADDING_PKCS7)
|
/development/samples/browseable/ConfirmCredential/src/com.example.android.confirmcredential/ |
MainActivity.java | 26 import android.security.keystore.KeyProperties; 104 KeyProperties.KEY_ALGORITHM_AES + "/" + KeyProperties.BLOCK_MODE_CBC + "/" 105 + KeyProperties.ENCRYPTION_PADDING_PKCS7); 144 KeyProperties.KEY_ALGORITHM_AES, "AndroidKeyStore"); 149 KeyProperties.PURPOSE_ENCRYPT | KeyProperties.PURPOSE_DECRYPT) 150 .setBlockModes(KeyProperties.BLOCK_MODE_CBC) 154 .setEncryptionPaddings(KeyProperties.ENCRYPTION_PADDING_PKCS7)
|
/frameworks/base/services/core/java/com/android/server/locksettings/recoverablekeystore/storage/ |
ApplicationKeyStorage.java | 24 import android.security.keystore.KeyProperties; 86 new SecretKeySpec(secretKey, KeyProperties.KEY_ALGORITHM_AES)), 88 KeyProperties.PURPOSE_ENCRYPT | KeyProperties.PURPOSE_DECRYPT) 89 .setBlockModes(KeyProperties.BLOCK_MODE_GCM) 90 .setEncryptionPaddings(KeyProperties.ENCRYPTION_PADDING_NONE)
|
/frameworks/base/services/core/java/com/android/server/locksettings/ |
SyntheticPasswordCrypto.java | 19 import android.security.keystore.KeyProperties; 61 Cipher cipher = Cipher.getInstance(KeyProperties.KEY_ALGORITHM_AES + "/" 62 + KeyProperties.BLOCK_MODE_GCM + "/" + KeyProperties.ENCRYPTION_PADDING_NONE); 74 KeyProperties.KEY_ALGORITHM_AES + "/" + KeyProperties.BLOCK_MODE_GCM + "/" 75 + KeyProperties.ENCRYPTION_PADDING_NONE); 91 KeyProperties.KEY_ALGORITHM_AES); 104 KeyProperties.KEY_ALGORITHM_AES); 149 KeyGenerator keyGenerator = KeyGenerator.getInstance(KeyProperties.KEY_ALGORITHM_AES) [all...] |
/frameworks/base/keystore/tests/src/android/security/keystore/ |
KeyGenParameterSpecTest.java | 24 import android.security.keystore.KeyProperties; 34 static final int KEY_PURPOSES = KeyProperties.PURPOSE_SIGN | KeyProperties.PURPOSE_VERIFY;
|
/developers/build/prebuilts/gradle/FingerprintDialog/Application/src/main/java/com/example/android/fingerprintdialog/ |
MainActivity.java | 28 import android.security.keystore.KeyProperties; 88 .getInstance(KeyProperties.KEY_ALGORITHM_AES, "AndroidKeyStore"); 95 defaultCipher = Cipher.getInstance(KeyProperties.KEY_ALGORITHM_AES + "/" 96 + KeyProperties.BLOCK_MODE_CBC + "/" 97 + KeyProperties.ENCRYPTION_PADDING_PKCS7); 98 cipherNotInvalidated = Cipher.getInstance(KeyProperties.KEY_ALGORITHM_AES + "/" 99 + KeyProperties.BLOCK_MODE_CBC + "/" 100 + KeyProperties.ENCRYPTION_PADDING_PKCS7); 245 KeyProperties.PURPOSE_ENCRYPT | 246 KeyProperties.PURPOSE_DECRYPT [all...] |
/developers/samples/android/security/FingerprintDialog/Application/src/main/java/com/example/android/fingerprintdialog/ |
MainActivity.java | 28 import android.security.keystore.KeyProperties; 88 .getInstance(KeyProperties.KEY_ALGORITHM_AES, "AndroidKeyStore"); 95 defaultCipher = Cipher.getInstance(KeyProperties.KEY_ALGORITHM_AES + "/" 96 + KeyProperties.BLOCK_MODE_CBC + "/" 97 + KeyProperties.ENCRYPTION_PADDING_PKCS7); 98 cipherNotInvalidated = Cipher.getInstance(KeyProperties.KEY_ALGORITHM_AES + "/" 99 + KeyProperties.BLOCK_MODE_CBC + "/" 100 + KeyProperties.ENCRYPTION_PADDING_PKCS7); 245 KeyProperties.PURPOSE_ENCRYPT | 246 KeyProperties.PURPOSE_DECRYPT [all...] |