Class SshKeyGenerator
java.lang.Object
com.sshtools.j2ssh.transport.publickey.SshKeyGenerator
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic void
changePassphrase
(File f, String oldPassphrase, String newPassphrase) static String
convertPublicKeyFile
(File f, SshPublicKeyFormat convert) void
generateKeyPair
(String type, int bits, String filename, String username, String passphrase) static void
static void
processCommandLine
(String[] args)
-
Constructor Details
-
SshKeyGenerator
public SshKeyGenerator()Creates a new SshKeyGenerator object.
-
-
Method Details
-
generateKeyPair
public void generateKeyPair(String type, int bits, String filename, String username, String passphrase) throws IOException - Parameters:
type
-bits
-filename
-username
-passphrase
-- Throws:
IOException
-
main
- Parameters:
args
-
-
processCommandLine
- Parameters:
args
-
-
changePassphrase
public static void changePassphrase(File f, String oldPassphrase, String newPassphrase) throws IOException, InvalidSshKeyException - Parameters:
f
-oldPassphrase
-newPassphrase
-- Throws:
IOException
InvalidSshKeyException
-
convertPublicKeyFile
public static String convertPublicKeyFile(File f, SshPublicKeyFormat convert) throws InvalidSshKeyException, IOException - Parameters:
f
-convert
-- Returns:
- Throws:
InvalidSshKeyException
IOException
-