public static KeyStore loadKeyStore(String type,String file,String password){
  try {
    KeyStore keyStore=KeyStore.getInstance(type);
    InputStream fis=getFile(file);
    keyStore.load(fis,password.toCharArray());
    fis.close();
    return keyStore;
  }
 catch (  Exception e) {
    throw new RuntimeException(e);
  }
}

public static KeyStore loadKeyStore ( String type , String file , String password ) { try { KeyStore keyStore = KeyStore . getInstance ( type ) ; InputStream fis = getFile ( file ) ; keyStore . load ( fis , password . toCharArray ( ) ) ; fis . close ( ) ; return keyStore ; } catch ( Exception e ) { throw new RuntimeException ( e ) ; } }
loads a keystore with the given type from the specified filename .
