public class PublicKeyAuthenticationClient extends SshAuthenticationClient
| Modifier and Type | Field and Description |
|---|---|
protected SshPrivateKey |
key |
| Constructor and Description |
|---|
PublicKeyAuthenticationClient()
Creates a new PublicKeyAuthenticationClient object.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
acceptsKey(AuthenticationProtocolClient authentication,
java.lang.String username,
java.lang.String serviceToStart,
SshPublicKey key) |
void |
authenticate(AuthenticationProtocolClient authentication,
java.lang.String serviceToStart) |
boolean |
canAuthenticate() |
java.lang.String |
getKeyfile() |
java.lang.String |
getMethodName() |
java.util.Properties |
getPersistableProperties() |
void |
reset() |
void |
setKey(SshPrivateKey key) |
void |
setKeyfile(java.lang.String privateKeyFile) |
void |
setPersistableProperties(java.util.Properties properties) |
canPrompt, getAuthenticationPrompt, getUsername, setAuthenticationPrompt, setUsernameprotected SshPrivateKey key
public PublicKeyAuthenticationClient()
public void setKey(SshPrivateKey key)
key - public void setKeyfile(java.lang.String privateKeyFile)
public java.lang.String getKeyfile()
public void reset()
reset in class SshAuthenticationClientpublic java.lang.String getMethodName()
getMethodName in class SshAuthenticationClientpublic boolean acceptsKey(AuthenticationProtocolClient authentication, java.lang.String username, java.lang.String serviceToStart, SshPublicKey key) throws java.io.IOException
authentication - username - serviceToStart - key - java.io.IOExceptionpublic void authenticate(AuthenticationProtocolClient authentication, java.lang.String serviceToStart) throws java.io.IOException, TerminatedStateException
authenticate in class SshAuthenticationClientauthentication - serviceToStart - java.io.IOExceptionTerminatedStateExceptionAuthenticationProtocolExceptionpublic java.util.Properties getPersistableProperties()
getPersistableProperties in class SshAuthenticationClientpublic void setPersistableProperties(java.util.Properties properties)
setPersistableProperties in class SshAuthenticationClientproperties - public boolean canAuthenticate()
canAuthenticate in class SshAuthenticationClientCopyright © 2002-2003 Lee David Painter & Contributors. All Rights Reserved.