|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.enterprisedt.net.ftp.ssh.SSHFTPValidator
com.enterprisedt.net.ftp.ssh.SSHFTPPublicKey
public class SSHFTPPublicKey
Represents an SSH public key. This class may be used to obtain information about a public key. It has methods for accessing the name of the algorithm, the bit length, the key data, the fingerprint, as well as a method for writing the key to a stream in either OpenSSH or IETF SECSH format.
| Field Summary | |
|---|---|
static int |
IETF_SECSH_FORMAT
Specifies the IETF SECSH format. |
static int |
OPENSSH_FORMAT
Specifies the OpenSSH format. |
| Method Summary | |
|---|---|
boolean |
equals(java.lang.Object obj)
Indicates whether some other object is "equal to" this one. |
java.lang.String |
getAlgorithmName()
Returns the name of the algorithm (either DSA or RSA). |
int |
getBitLength()
Returns the bit-length of the key. |
java.lang.String |
getFingerprint()
Returns the finger-print of the key. |
byte[] |
getKeyData()
Returns the raw data of the key. |
int |
hashCode()
Returns a hash code value for the object. |
int |
write(java.io.OutputStream outStr,
int formatCode)
Writes a printable representation of the key to the given stream. |
| Methods inherited from class com.enterprisedt.net.ftp.ssh.SSHFTPValidator |
|---|
addKnownHost, addKnownHost, getHostPublicKey, getKnownHosts, isHostValidationEnabled, loadKnownHosts, loadKnownHosts, removeAllKnownHosts, removeKnownHost, setHostValidationEnabled, validate, validate |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int OPENSSH_FORMAT
public static final int IETF_SECSH_FORMAT
| Method Detail |
|---|
public java.lang.String getAlgorithmName()
public int getBitLength()
public byte[] getKeyData()
public java.lang.String getFingerprint()
public boolean equals(java.lang.Object obj)
equals in class java.lang.Objecttruefalse
public int hashCode()
hashCode in class java.lang.Object
public int write(java.io.OutputStream outStr,
int formatCode)
throws SSHFTPException,
java.io.IOException
OPENSSH_FORMAT or IETF_SECSH_FORMAT.
The stream is not closed.
outStr - OutputStream to which to write the key.formatCode - Format to use (either OPENSSH_FORMAT or IETF_SECSH_FORMAT).
SSHFTPException - Thrown if the format-code is not OPENSSH_FORMAT or IETF_SECSH_FORMAT.
java.io.IOException - Thrown if there was an error while writing to the stream.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||