com.sshtools.publickey
Class SshPrivateKeyFileFactory
java.lang.Object
com.sshtools.publickey.SshPrivateKeyFileFactory
- public class SshPrivateKeyFileFactory
- extends java.lang.Object
Private key format factory used to decode private key files. This factory currently
supports SSHTools, OpenSSH and SSH1 encrypted private keys.
- Author:
- Lee David Painter
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
OPENSSH_FORMAT
public static final int OPENSSH_FORMAT
- See Also:
- Constant Field Values
SSHTOOLS_FORMAT
public static final int SSHTOOLS_FORMAT
- See Also:
- Constant Field Values
SSH1_FORMAT
public static final int SSH1_FORMAT
- See Also:
- Constant Field Values
SshPrivateKeyFileFactory
public SshPrivateKeyFileFactory()
parse
public static SshPrivateKeyFile parse(byte[] formattedkey)
throws java.io.IOException
- Parse formatted data and return a suitable SshPrivateKeyFile
implemenation.
- Parameters:
formattedkey
-
- Returns:
-
- Throws:
java.io.IOException
parse
public static SshPrivateKeyFile parse(java.io.InputStream in)
throws java.io.IOException
- Parse an InputStrewam and return a suitable SshPrivateKeyFile
implementation.
- Parameters:
in
-
- Returns:
-
- Throws:
java.io.IOException
create
public static SshPrivateKeyFile create(SshKeyPair pair,
java.lang.String passphrase,
java.lang.String comment,
int format)
throws java.io.IOException
- Throws:
java.io.IOException
Copyright © 2003 3SP LTD. All Rights Reserved.