summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEran Messeri <eranm@google.com>2020-05-19 11:03:31 +0100
committerEran Messeri <eranm@google.com>2020-05-20 11:14:06 +0100
commitcdcbb66be6208da7f5efbfb924d18f90848730e3 (patch)
treee9139eece7c078ea49fda2ba5b67ba2c12cd35cb
parent3d6a1cfb1b4b52648224f836fea9fa85ed331822 (diff)
Update KeyChain.createInstallIntent documentation
Update the KeyChain.createInstallIntent method documentation to reflect the change where CA certificates can no longer be installed using this intent. Bug: 156941631 Test: m docs Change-Id: I3cf2c677c4c772698c8df5f25224dd67d12b5606
-rw-r--r--keystore/java/android/security/KeyChain.java7
1 files changed, 7 insertions, 0 deletions
diff --git a/keystore/java/android/security/KeyChain.java b/keystore/java/android/security/KeyChain.java
index acd90a7f10cf..6df62c0a0cba 100644
--- a/keystore/java/android/security/KeyChain.java
+++ b/keystore/java/android/security/KeyChain.java
@@ -369,6 +369,13 @@ public final class KeyChain {
* {@link Activity#RESULT_OK} will be returned if a credential was
* successfully installed, otherwise {@link
* Activity#RESULT_CANCELED} will be returned.
+ *
+ * <p>Starting from {@link android.os.Build.VERSION_CODES#R}, the intent returned by this
+ * method cannot be used for installing CA certificates. Since CA certificates can only be
+ * installed via Settings, the app should provide the user with a file containing the
+ * CA certificate. One way to do this would be to use the {@link android.provider.MediaStore}
+ * API to write the certificate to the {@link android.provider.MediaStore.Downloads}
+ * collection.
*/
@NonNull
public static Intent createInstallIntent() {