Java Key Create getKeyPairGenerator(final String algorithm)

Here you can find the source of getKeyPairGenerator(final String algorithm)

Description

get Key Pair Generator

License

Apache License

Declaration

private static KeyPairGenerator getKeyPairGenerator(final String algorithm) throws NoSuchAlgorithmException 

Method Source Code

//package com.java2s;
//License from project: Apache License 

import java.security.KeyPairGenerator;

import java.security.NoSuchAlgorithmException;

public class Main {
    private static KeyPairGenerator getKeyPairGenerator(final String algorithm) throws NoSuchAlgorithmException {
        return KeyPairGenerator.getInstance(algorithm);
    }//  w w w .  j  a  v  a  2  s.co  m

    private static KeyPairGenerator getKeyPairGenerator(final String algorithm, final int keysize)
            throws NoSuchAlgorithmException {
        final KeyPairGenerator keyPairGenerator = KeyPairGenerator.getInstance(algorithm);
        keyPairGenerator.initialize(keysize);
        return keyPairGenerator;
    }
}

Related

  1. getKeyManagers(KeyStore ks, String password)
  2. getKeyPair()
  3. getKeyPair()
  4. getKeyPair()
  5. getKeyPair(KeyStore keyStore, String alias, String password)
  6. getKeys()
  7. getKeySize(final Key key)
  8. getKeySize(PrivateKey key)
  9. getKeyStore()