/aosp12/hardware/broadcom/wlan/bcmdhd/dhdutil/include/proto/ |
H A D | wpa.h | 116 #define IS_WPA_CIPHER(cipher) ((cipher) == WPA_CIPHER_NONE || \ argument 117 (cipher) == WPA_CIPHER_WEP_40 || \ 118 (cipher) == WPA_CIPHER_WEP_104 || \ 119 (cipher) == WPA_CIPHER_TKIP || \ 120 (cipher) == WPA_CIPHER_AES_OCB || \ 121 (cipher) == WPA_CIPHER_AES_CCM || \ 122 (cipher) == WPA_CIPHER_TPK)
|
/aosp12/frameworks/base/services/core/java/com/android/server/accounts/ |
H A D | CryptoHelper.java | 64 Cipher cipher = Cipher.getInstance(CIPHER_ALGORITHM); in encryptBundle() local 65 cipher.init(Cipher.ENCRYPT_MODE, mEncryptionKey); in encryptBundle() 66 byte[] encryptedBytes = cipher.doFinal(clearBytes); in encryptBundle() 67 byte[] iv = cipher.getIV(); in encryptBundle() 90 Cipher cipher = Cipher.getInstance(CIPHER_ALGORITHM); in decryptBundle() local 91 cipher.init(Cipher.DECRYPT_MODE, mEncryptionKey, ivSpec); in decryptBundle() 92 byte[] decryptedBytes = cipher.doFinal(encryptedBytes); in decryptBundle() 116 …private byte[] createMac(@NonNull byte[] cipher, @NonNull byte[] iv) throws GeneralSecurityExcepti… in createMac() argument 119 mac.update(cipher); in createMac()
|
/aosp12/frameworks/base/services/core/java/com/android/server/locksettings/recoverablekeystore/ |
H A D | WrappedKey.java | 72 Cipher cipher; in fromSecretKey() local 74 cipher = Cipher.getInstance(KEY_WRAP_CIPHER_ALGORITHM); in fromSecretKey() 80 cipher.init(Cipher.WRAP_MODE, wrappingKey.getKey()); in fromSecretKey() 83 encryptedKeyMaterial = cipher.wrap(key); in fromSecretKey() 101 /*nonce=*/ cipher.getIV(), in fromSecretKey() 206 Cipher cipher = Cipher.getInstance(KEY_WRAP_CIPHER_ALGORITHM); in unwrapKeys() local 221 cipher.init( in unwrapKeys() 227 key = (SecretKey) cipher.unwrap( in unwrapKeys()
|
H A D | SecureBox.java | 343 Cipher cipher; in aesGcmInternal() local 345 cipher = Cipher.getInstance(ENC_ALG); in aesGcmInternal() 353 cipher.init(Cipher.DECRYPT_MODE, key, spec); in aesGcmInternal() 355 cipher.init(Cipher.ENCRYPT_MODE, key, spec); in aesGcmInternal() 362 cipher.updateAAD(aad); in aesGcmInternal() 363 return cipher.doFinal(text); in aesGcmInternal()
|
/aosp12/frameworks/base/packages/BackupEncryption/src/com/android/server/backup/encryption/keys/ |
H A D | KeyWrapUtils.java | 72 Cipher cipher = getCipher(); in unwrap() local 74 cipher.init( in unwrap() 79 return (SecretKey) cipher.unwrap(wrappedKey.key, KEY_ALGORITHM, Cipher.SECRET_KEY); in unwrap() 94 Cipher cipher = getCipher(); in wrap() local 95 cipher.init(Cipher.WRAP_MODE, secondaryKey); in wrap() 98 wrappedKey.key = cipher.wrap(tertiaryKey); in wrap() 99 wrappedKey.nonce = cipher.getIV(); in wrap()
|
/aosp12/frameworks/base/services/core/java/com/android/server/locksettings/ |
H A D | ManagedProfilePasswordCache.java | 114 Cipher cipher; in storePassword() local 116 cipher = Cipher.getInstance("AES/GCM/NoPadding"); in storePassword() 117 cipher.init(Cipher.ENCRYPT_MODE, key); in storePassword() 118 byte[] ciphertext = cipher.doFinal(password.getCredential()); in storePassword() 119 byte[] iv = cipher.getIV(); in storePassword() 152 Cipher cipher = Cipher.getInstance("AES/GCM/NoPadding"); in retrievePassword() local 153 cipher.init(Cipher.DECRYPT_MODE, key, new GCMParameterSpec(128, iv)); in retrievePassword() 154 credential = cipher.doFinal(ciphertext); in retrievePassword()
|
H A D | SyntheticPasswordCrypto.java | 69 Cipher cipher = Cipher.getInstance(KeyProperties.KEY_ALGORITHM_AES + "/" in decrypt() local 71 cipher.init(Cipher.DECRYPT_MODE, key, new GCMParameterSpec(DEFAULT_TAG_LENGTH_BITS, iv)); in decrypt() 72 return cipher.doFinal(ciphertext); in decrypt() 82 Cipher cipher = Cipher.getInstance( in encrypt() local 85 cipher.init(Cipher.ENCRYPT_MODE, key); in encrypt() 86 byte[] ciphertext = cipher.doFinal(blob); in encrypt() 87 byte[] iv = cipher.getIV(); in encrypt() 91 final GCMParameterSpec spec = cipher.getParameters().getParameterSpec( in encrypt()
|
H A D | AesEncryptionUtil.java | 93 Cipher cipher = Cipher.getInstance(CIPHER_ALGO); in encrypt() local 94 cipher.init(Cipher.ENCRYPT_MODE, key); in encrypt() 95 cipherText = cipher.doFinal(plainText); in encrypt() 96 iv = cipher.getIV(); in encrypt()
|
/aosp12/packages/apps/Car/Dialer/src/com/android/car/dialer/storage/ |
H A D | CipherConverter.java | 78 Cipher cipher = getCipherInstance(); in decrypt() local 89 cipher.init(Cipher.DECRYPT_MODE, decryptionKey, new GCMParameterSpec(128, iv)); in decrypt() 90 byte[] decryptionResult = cipher.doFinal(encryptedPhoneNumber); in decrypt() 130 Cipher cipher = getCipherInstance(); in encrypt() local 131 cipher.init(Cipher.ENCRYPT_MODE, secretKey); in encrypt() 132 byte[] iv = cipher.getIV(); in encrypt() 136 byte[] encryptionResult = cipher.doFinal( in encrypt()
|
/aosp12/packages/modules/Connectivity/tests/cts/net/src/android/net/cts/ |
H A D | PacketUtils.java | 360 public final EspCipher cipher; field in PacketUtils.EspHeader 389 EspCipher cipher, in EspHeader() argument 395 this.cipher = cipher; in EspHeader() 398 if (cipher instanceof EspCipherNull && auth instanceof EspAuthNull) { in EspHeader() 422 cipher instanceof EspAeadCipher ? ((EspAeadCipher) cipher).icvLen : auth.icvLen; in length() 424 payload.length, cipher.ivLen, cipher.blockSize, icvLen * 8); in length() 607 final Cipher cipher = Cipher.getInstance(algoName); in getCipherText() local 608 cipher.init(Cipher.ENCRYPT_MODE, secretKeySpec, ivParameterSpec); in getCipherText() 650 final Cipher cipher = Cipher.getInstance(algoName); in getCipherText() local 651 cipher.init(Cipher.ENCRYPT_MODE, secretKeySpec, ivParameterSpec); in getCipherText() [all …]
|
/aosp12/packages/modules/Wifi/service/java/com/android/server/wifi/util/ |
H A D | WifiConfigStoreEncryptionUtil.java | 87 Cipher cipher = Cipher.getInstance(CIPHER_ALGORITHM); in encrypt() local 90 cipher.init(Cipher.ENCRYPT_MODE, secretKeyReference); in encrypt() 91 encryptedData = new EncryptedData(cipher.doFinal(data), cipher.getIV()); in encrypt() 121 Cipher cipher = Cipher.getInstance(CIPHER_ALGORITHM); in decrypt() local 125 cipher.init(Cipher.DECRYPT_MODE, secretKeyReference, spec); in decrypt() 126 decryptedData = cipher.doFinal(encryptedData.getEncryptedData()); in decrypt()
|
/aosp12/packages/modules/adb/pairing_auth/tests/ |
H A D | aes_128_gcm_test.cpp | 28 std::unique_ptr<Aes128Gcm> cipher; in TEST() local 29 ASSERT_DEATH({ cipher.reset(new Aes128Gcm(nullptr, 42)); }, ""); in TEST() 34 std::unique_ptr<Aes128Gcm> cipher; in TEST() local 35 ASSERT_DEATH({ cipher.reset(new Aes128Gcm(material, 0)); }, ""); in TEST()
|
/aosp12/frameworks/base/packages/BackupEncryption/src/com/android/server/backup/encryption/chunking/ |
H A D | ChunkEncryptor.java | 63 Cipher cipher; in encrypt() local 65 cipher = Cipher.getInstance(CIPHER_ALGORITHM); in encrypt() 66 cipher.init( in encrypt() 78 encryptedBytes = cipher.doFinal(plaintext); in encrypt()
|
/aosp12/frameworks/base/services/tests/servicestests/src/com/android/server/locksettings/recoverablekeystore/ |
H A D | RecoverableKeyGeneratorTest.java | 130 Cipher cipher = Cipher.getInstance(KEY_WRAP_ALGORITHM); in generateAndStoreKey_storesTheWrappedVersionOfTheRawMaterial() local 131 cipher.init(Cipher.DECRYPT_MODE, mDecryptKey.getKey(), in generateAndStoreKey_storesTheWrappedVersionOfTheRawMaterial() 133 byte[] unwrappedMaterial = cipher.doFinal(wrappedKey.getKeyMaterial()); in generateAndStoreKey_storesTheWrappedVersionOfTheRawMaterial() 164 Cipher cipher = Cipher.getInstance(KEY_WRAP_ALGORITHM); in importKey_storesTheWrappedVersionOfTheRawMaterial() local 165 cipher.init(Cipher.DECRYPT_MODE, mDecryptKey.getKey(), in importKey_storesTheWrappedVersionOfTheRawMaterial() 167 byte[] unwrappedMaterial = cipher.doFinal(wrappedKey.getKeyMaterial()); in importKey_storesTheWrappedVersionOfTheRawMaterial()
|
H A D | WrappedKeyTest.java | 76 Cipher cipher = Cipher.getInstance(CIPHER_ALGORITHM); in fromSecretKey_createsWrappedKeyThatCanBeUnwrapped_nullMetadata() local 77 cipher.init( in fromSecretKey_createsWrappedKeyThatCanBeUnwrapped_nullMetadata() 81 SecretKey unwrappedKey = (SecretKey) cipher.unwrap( in fromSecretKey_createsWrappedKeyThatCanBeUnwrapped_nullMetadata() 95 Cipher cipher = Cipher.getInstance(CIPHER_ALGORITHM); in fromSecretKey_createsWrappedKeyThatCanBeUnwrapped_nonNullMetadata() local 96 cipher.init( in fromSecretKey_createsWrappedKeyThatCanBeUnwrapped_nonNullMetadata() 100 SecretKey unwrappedKey = (SecretKey) cipher.unwrap( in fromSecretKey_createsWrappedKeyThatCanBeUnwrapped_nonNullMetadata()
|
/aosp12/system/security/keystore2/src/crypto/ |
H A D | crypto.cpp | 62 const EVP_CIPHER* cipher = EVP_aes_256_gcm(); in getAesCipherForKey() local 64 cipher = EVP_aes_128_gcm(); in getAesCipherForKey() 66 return cipher; in getAesCipherForKey() 82 const EVP_CIPHER* cipher = getAesCipherForKey(key_size); in AES_gcm_encrypt() local 86 EVP_EncryptInit_ex(ctx.get(), cipher, nullptr /* engine */, key, iv); in AES_gcm_encrypt() 118 const EVP_CIPHER* cipher = getAesCipherForKey(key_size); in AES_gcm_decrypt() local 122 EVP_DecryptInit_ex(ctx.get(), cipher, nullptr /* engine */, key, iv); in AES_gcm_decrypt()
|
/aosp12/frameworks/proto_logging/stats/enums/stats/tls/ |
H A D | enums.proto | 33 // If you add new cipher suite, make sure id is the same as in IANA's database (see link above) 48 // TLSv1.2 cipher suites 58 // Pre-Shared Key (PSK) cipher suites 65 // TLS 1.3 cipher suites
|
/aosp12/system/vold/ |
H A D | MetadataCrypt.cpp | 57 struct CryptoType cipher = invalid_crypto_type; member 80 return KeyGeneration{options.cipher.get_keysize(), true, options.use_hw_wrapped_key}; in makeGen() 163 auto target = std::make_unique<DmTargetDefaultKey>(0, *nr_sec, options.cipher.get_kernel_name(), in create_crypto_blk_dev() 197 options->cipher = lookup_cipher(cipher_name); in parse_options() 198 if (options->cipher.get_kernel_name() == nullptr) { in parse_options() 242 options.cipher = legacy_aes_256_xts; in fscrypt_mount_metadata_encrypted()
|
/aosp12/hardware/interfaces/wifi/supplicant/1.2/ |
H A D | ISupplicantStaNetwork.hal | 101 * Set pairwise cipher mask for the network. 116 * Get the pairwise cipher mask set for the network. 129 * Set group cipher mask for the network. 144 * Get the group cipher mask set for the network. 157 * Set group management cipher mask for the network. 172 * Get the group management cipher mask set for the network.
|
/aosp12/frameworks/base/core/java/android/hardware/biometrics/ |
H A D | CryptoObject.java | 41 public CryptoObject(@NonNull Cipher cipher) { in CryptoObject() argument 42 mCrypto = cipher; in CryptoObject()
|
/aosp12/frameworks/base/packages/BackupEncryption/test/robolectric/src/com/android/server/backup/encryption/chunking/ |
H A D | ChunkEncryptorTest.java | 149 Cipher cipher = Cipher.getInstance(CIPHER_ALGORITHM); in encrypt_decryptedResultCorrespondsToPlaintext() local 150 cipher.init( in encrypt_decryptedResultCorrespondsToPlaintext() 154 byte[] decrypted = cipher.doFinal(chunk.encryptedBytes()); in encrypt_decryptedResultCorrespondsToPlaintext()
|
/aosp12/frameworks/base/identity/java/android/security/identity/ |
H A D | CredstoreIdentityCredential.java | 172 Cipher cipher = Cipher.getInstance("AES/GCM/NoPadding"); in encryptMessageToReader() local 174 cipher.init(Cipher.ENCRYPT_MODE, mSecretKey, encryptionParameterSpec); in encryptMessageToReader() 175 messageCiphertextAndAuthTag = cipher.doFinal(messagePlaintext); in encryptMessageToReader() 197 final Cipher cipher = Cipher.getInstance("AES/GCM/NoPadding"); in decryptMessageFromReader() local 198 cipher.init(Cipher.DECRYPT_MODE, mReaderSecretKey, in decryptMessageFromReader() 200 plainText = cipher.doFinal(messageCiphertext); in decryptMessageFromReader()
|
/aosp12/hardware/interfaces/wifi/supplicant/1.4/ |
H A D | ISupplicantStaNetwork.hal | 76 * Set group cipher mask for the network. 91 * Get the group cipher mask set for the network. 104 * Set pairwise cipher mask for the network. 119 * Get the pairwise cipher mask set for the network.
|
/aosp12/packages/services/Car/service/src/com/android/car/ |
H A D | FastPairGattServer.java | 305 Cipher cipher = Cipher.getInstance("AES/ECB/NoPadding"); in encrypt() local 306 cipher.init(Cipher.ENCRYPT_MODE, mSharedSecretKey); in encrypt() 309 return cipher.doFinal(decoded); in encrypt() 328 Cipher cipher = Cipher.getInstance("AES/ECB/NoPadding"); in decrypt() local 329 cipher.init(Cipher.DECRYPT_MODE, mSharedSecretKey); in decrypt() 332 return cipher.doFinal(encoded); in decrypt()
|
/aosp12/packages/apps/Bluetooth/src/com/android/bluetooth/btservice/bluetoothKeystore/ |
H A D | BluetoothKeystoreService.java | 718 Cipher cipher = Cipher.getInstance(CIPHER_ALGORITHM); in encrypt() local 722 cipher.init(Cipher.ENCRYPT_MODE, secretKeyReference); in encrypt() 724 .setEncryptedData(ByteString.copyFrom(cipher.doFinal(data.getBytes()))) in encrypt() 725 .setInitVector(ByteString.copyFrom(cipher.getIV())).build(); in encrypt() 769 Cipher cipher = Cipher.getInstance(CIPHER_ALGORITHM); in decrypt() local 775 cipher.init(Cipher.DECRYPT_MODE, secretKeyReference, spec); in decrypt() 776 decryptedDataBytes = cipher.doFinal(protobuf.getEncryptedData().toByteArray()); in decrypt()
|