Example usage for Java android.security KeyChain fields, constructors, methods, implement or subclass
The text is from its open source code.
String | EXTRA_NAME Optional extra to specify a String credential name on the Intent returned by #createInstallIntent . |
String | EXTRA_CERTIFICATE Optional extra to specify an X.509 certificate to install on the Intent returned by #createInstallIntent . |
String | EXTRA_PKCS12 Optional extra for use with the Intent returned by #createInstallIntent to specify a PKCS#12 key store to install. |
void | choosePrivateKeyAlias(@NonNull Activity activity, @NonNull KeyChainAliasCallback response, @Nullable @KeyProperties.KeyAlgorithmEnum String[] keyTypes, @Nullable Principal[] issuers, @Nullable Uri uri, @Nullable String alias) Launches an Activity for the user to select the alias for a private key and certificate pair for authentication. |
Intent | createInstallIntent() Returns an Intent that can be used for credential installation. |
X509Certificate[] | getCertificateChain(@NonNull Context context, @NonNull String alias) Returns the X509Certificate chain for the requested alias, or null if there is no result. |
PrivateKey | getPrivateKey(@NonNull Context context, @NonNull String alias) Returns the PrivateKey for the requested alias, or null if there is no result. |
boolean | isBoundKeyAlgorithm(@NonNull @KeyProperties.KeyAlgorithmEnum String algorithm) Returns true if the current device's KeyChain binds any PrivateKey of the given algorithm to the device once imported or generated. |