|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.ow2.petals.bc.sftp.authentication.SshAuthentication
org.ow2.petals.bc.sftp.authentication.SshPublicKeyAuthentication
public final class SshPublicKeyAuthentication
Utility class used to authenticate a client onto a SSH server using a public key. NOTE : This method of authentication uses public-key cryptography to verify the user's identity. The user can access an account on an SSH server by proving that they possess a private key. The key is authorized if it is contained within the user's authorization file. NOTE : when using this authentication method, key MUST be stored on the same server as PEtALS. We can attach private key with XML message, but this is not a good solution, since private key might not be private anymore.
| Constructor Summary | |
|---|---|
SshPublicKeyAuthentication(java.lang.String user,
java.lang.String pathToPrivateKey,
java.lang.String passphrase)
Default constructor. |
|
| Method Summary | |
|---|---|
com.sshtools.j2ssh.authentication.SshAuthenticationClient |
getAuthenticationClient()
Builds the object used by the SFTPClientPool to perform the authentication on the SSH server. |
java.lang.String |
getKey()
Builds & returns a portion of the key used by the SFTPClientPool to identify a SSH session. |
java.lang.String |
toString()
Return the object content as String (Overrides the toString method). |
| Methods inherited from class org.ow2.petals.bc.sftp.authentication.SshAuthentication |
|---|
getUser |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public SshPublicKeyAuthentication(java.lang.String user,
java.lang.String pathToPrivateKey,
java.lang.String passphrase)
throws ConfigurationException
user - the username used for SSH user / private key authenticationpathToPrivateKey - the PrivateKey used for SSH user / private key authenticationpassphrase - the optional passphrase used for SSH user / private key
authentication
ConfigurationException| Method Detail |
|---|
public final com.sshtools.j2ssh.authentication.SshAuthenticationClient getAuthenticationClient()
throws java.io.IOException
getAuthenticationClient in class SshAuthenticationSshAuthenticationException
java.io.IOExceptionpublic final java.lang.String getKey()
getKey in class SshAuthenticationpublic final java.lang.String toString()
toString in class SshAuthentication
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||