code: public void setPassword(String alias, String password, String passwordPassword) throws NoSuchAlgorithmException, InvalidKeySpecException, KeyStoreException {
  		SecretKeyFactory skf = SecretKeyFactory.getInstance("PBE");
          SecretKey pSecret = skf.generateSecret(new PBEKeySpec(password.toCharArray()));
          KeyStore.PasswordProtection kspp = new KeyStore.PasswordProtection(passwordPassword.toCharArray());
          this.keystore.setEntry(alias, new KeyStore.SecretKeyEntry(pSecret), kspp);
  	}
docs: Sets the password in the currently openend keystore. Do not forget to store it afterwards
  
  @param alias
  @param password to store
  @param passwordPassword password for encrypting password. You can use the same as the keystore password
  @throws NoSuchAlgorithmException
  @throws InvalidKeySpecException
  @throws KeyStoreException