diff options
author | Chad Brubaker <cbrubaker@google.com> | 2015-03-23 23:24:51 +0000 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2015-03-23 23:24:51 +0000 |
commit | 781df0451156842421ac249cf7f6c1c76c34b764 (patch) | |
tree | 92b30e89aeb6a5b005da9f941a1db674e9c0d376 /keystore | |
parent | 55113971e28ee2f1b331185884d67e1921ae7715 (diff) | |
parent | 6050eb5459a00b95bf135d40e9e37cd043c863e4 (diff) | |
download | frameworks_base-781df0451156842421ac249cf7f6c1c76c34b764.zip frameworks_base-781df0451156842421ac249cf7f6c1c76c34b764.tar.gz frameworks_base-781df0451156842421ac249cf7f6c1c76c34b764.tar.bz2 |
am 6050eb54: am 5b11b3d6: am 31cee318: Merge "Specify public exponent for RSA"
* commit '6050eb5459a00b95bf135d40e9e37cd043c863e4':
Specify public exponent for RSA
Diffstat (limited to 'keystore')
-rw-r--r-- | keystore/tests/src/android/security/KeyStoreTest.java | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/keystore/tests/src/android/security/KeyStoreTest.java b/keystore/tests/src/android/security/KeyStoreTest.java index f935bb1..f0b07a6 100644 --- a/keystore/tests/src/android/security/KeyStoreTest.java +++ b/keystore/tests/src/android/security/KeyStoreTest.java @@ -36,6 +36,7 @@ import java.nio.charset.StandardCharsets; import java.util.Arrays; import java.util.Date; import java.util.HashSet; +import java.security.spec.RSAKeyGenParameterSpec; import android.util.Log; import android.util.Base64; @@ -713,6 +714,8 @@ public class KeyStoreTest extends ActivityUnitTestCase<Activity> { args.addInt(KeymasterDefs.KM_TAG_KEY_SIZE, 2048); args.addBlob(KeymasterDefs.KM_TAG_APPLICATION_ID, null); args.addBlob(KeymasterDefs.KM_TAG_APPLICATION_DATA, null); + args.addBlob(KeymasterDefs.KM_TAG_RSA_PUBLIC_EXPONENT, + RSAKeyGenParameterSpec.F4.toByteArray()); KeyCharacteristics outCharacteristics = new KeyCharacteristics(); int result = mKeyStore.generateKey(name, args, 0, outCharacteristics); @@ -750,6 +753,8 @@ public class KeyStoreTest extends ActivityUnitTestCase<Activity> { args.addInt(KeymasterDefs.KM_TAG_BLOCK_MODE, KeymasterDefs.KM_MODE_ECB); args.addBlob(KeymasterDefs.KM_TAG_APPLICATION_ID, new byte[] {0x01, 0x02, 0x03}); args.addBlob(KeymasterDefs.KM_TAG_APPLICATION_DATA, null); + args.addBlob(KeymasterDefs.KM_TAG_RSA_PUBLIC_EXPONENT, + RSAKeyGenParameterSpec.F4.toByteArray()); KeyCharacteristics outCharacteristics = new KeyCharacteristics(); int result = mKeyStore.generateKey(name, args, 0, outCharacteristics); |