Package com.sshtools.client
Class IdentityFileAuthenticator
java.lang.Object
com.sshtools.common.ssh.AbstractRequestFuture
com.sshtools.client.SimpleClientAuthenticator
com.sshtools.client.PublicKeyAuthenticator
com.sshtools.client.IdentityFileAuthenticator
- All Implemented Interfaces:
ClientAuthenticator,RequestFuture
Implements public key authentication, taking a java.io.File object as the source private key.
-
Field Summary
Fields inherited from class com.sshtools.client.PublicKeyAuthenticator
SSH_MSG_USERAUTH_PK_OK -
Constructor Summary
ConstructorsConstructorDescriptionIdentityFileAuthenticator(PassphrasePrompt passphrase) IdentityFileAuthenticator(Collection<Path> identities, PassphrasePrompt passphrase) -
Method Summary
Modifier and TypeMethodDescriptioncollectIdentities(boolean onlyWellKnown) voiddone(boolean success) protected SshKeyPairprotected SshPublicKeygetPassphrase(String keyinfo) protected booleanMethods inherited from class com.sshtools.client.PublicKeyAuthenticator
authenticate, getName, getSignatureGenerator, onStartAuthentication, processMessage, signMethods inherited from class com.sshtools.client.SimpleClientAuthenticator
cancel, failure, getAuthenticationMethods, isCancelled, isMoreAuthenticationRequired, success, successMethods inherited from class com.sshtools.common.ssh.AbstractRequestFuture
addFutureListener, isDone, isSuccess, waitFor, waitForeverMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.sshtools.client.ClientAuthenticator
cancel, failure, getAuthenticationMethods, isCancelled, isMoreAuthenticationRequired, success, successMethods inherited from interface com.sshtools.common.ssh.RequestFuture
addFutureListener, isDone, isDoneAndSuccess, isSuccess, waitFor, waitForever
-
Constructor Details
-
IdentityFileAuthenticator
-
IdentityFileAuthenticator
- Throws:
IOException
-
-
Method Details
-
getPassphrase
-
getCurrentPath
-
getCurrentKey
-
collectIdentities
- Throws:
IOException
-
done
public void done(boolean success) - Overrides:
donein classAbstractRequestFuture
-
getNextKey
- Specified by:
getNextKeyin classPublicKeyAuthenticator- Throws:
IOException
-
getAuthenticatingKey
- Specified by:
getAuthenticatingKeyin classPublicKeyAuthenticator- Throws:
IOExceptionInvalidPassphraseException
-
hasCredentialsRemaining
protected boolean hasCredentialsRemaining()- Specified by:
hasCredentialsRemainingin classPublicKeyAuthenticator
-