コード例 #1
0
 /**
  * Returns the key associated with given alias using the supplied password.
  *
  * @param alias an alias for the key to get
  * @param password password to access key with
  * @return the requested key, or null otherwise
  * @throws NoSuchAlgorithmException if there is no algorithm for recovering the key
  * @throws UnrecoverableKeyException key cannot be reocovered (wrong password).
  */
 public final Key getKey(String alias, char[] password)
     throws KeyStoreException, NoSuchAlgorithmException, UnrecoverableKeyException {
   return keyStoreSpi.engineGetKey(alias, password);
 }