summaryrefslogtreecommitdiff
path: root/keystore/java/android/security/AndroidKeyPairGenerator.java
diff options
context:
space:
mode:
Diffstat (limited to 'keystore/java/android/security/AndroidKeyPairGenerator.java')
-rw-r--r--keystore/java/android/security/AndroidKeyPairGenerator.java14
1 files changed, 7 insertions, 7 deletions
diff --git a/keystore/java/android/security/AndroidKeyPairGenerator.java b/keystore/java/android/security/AndroidKeyPairGenerator.java
index 69755833e6f4..43d1eb607fe6 100644
--- a/keystore/java/android/security/AndroidKeyPairGenerator.java
+++ b/keystore/java/android/security/AndroidKeyPairGenerator.java
@@ -52,12 +52,12 @@ import java.security.spec.X509EncodedKeySpec;
public class AndroidKeyPairGenerator extends KeyPairGeneratorSpi {
private android.security.KeyStore mKeyStore;
- private AndroidKeyPairGeneratorSpec mSpec;
+ private KeyPairGeneratorSpec mSpec;
/**
* Generate a KeyPair which is backed by the Android keystore service. You
* must call {@link KeyPairGenerator#initialize(AlgorithmParameterSpec)}
- * with an {@link AndroidKeyPairGeneratorSpec} as the {@code params}
+ * with an {@link KeyPairGeneratorSpec} as the {@code params}
* argument before calling this otherwise an {@code IllegalStateException}
* will be thrown.
* <p>
@@ -73,7 +73,7 @@ public class AndroidKeyPairGenerator extends KeyPairGeneratorSpi {
public KeyPair generateKeyPair() {
if (mKeyStore == null || mSpec == null) {
throw new IllegalStateException(
- "Must call initialize with an AndroidKeyPairGeneratorSpec first");
+ "Must call initialize with an android.security.KeyPairGeneratorSpec first");
}
if (((mSpec.getFlags() & KeyStore.FLAG_ENCRYPTED) != 0)
@@ -156,13 +156,13 @@ public class AndroidKeyPairGenerator extends KeyPairGeneratorSpi {
throws InvalidAlgorithmParameterException {
if (params == null) {
throw new InvalidAlgorithmParameterException(
- "must supply params of type AndroidKeyPairGenericSpec");
- } else if (!(params instanceof AndroidKeyPairGeneratorSpec)) {
+ "must supply params of type android.security.KeyPairGeneratorSpec");
+ } else if (!(params instanceof KeyPairGeneratorSpec)) {
throw new InvalidAlgorithmParameterException(
- "params must be of type AndroidKeyPairGeneratorSpec");
+ "params must be of type android.security.KeyPairGeneratorSpec");
}
- AndroidKeyPairGeneratorSpec spec = (AndroidKeyPairGeneratorSpec) params;
+ KeyPairGeneratorSpec spec = (KeyPairGeneratorSpec) params;
mSpec = spec;
mKeyStore = android.security.KeyStore.getInstance();