|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.schmizz.sshj.userauth.method.AbstractAuthMethod
public abstract class AbstractAuthMethod
This abstract class for AuthMethod implements common or default functionality.
| Field Summary | |
|---|---|
protected org.slf4j.Logger |
log
Logger |
protected AuthParams |
params
AuthParams useful for building request. |
| Constructor Summary | |
|---|---|
protected |
AbstractAuthMethod(String name)
|
| Method Summary | |
|---|---|
protected SSHPacket |
buildReq()
Builds a SSHPacket containing the fields common to all authentication method. |
String |
getName()
|
void |
handle(Message msg,
SSHPacket buf)
Delegate handling of some SSH packet to this object. |
void |
init(AuthParams params)
This method must be called before requesting authentication with this method. |
protected AccountResource |
makeAccountResource()
|
void |
request()
|
boolean |
shouldRetry()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected final org.slf4j.Logger log
protected AuthParams params
AuthParams useful for building request.
| Constructor Detail |
|---|
protected AbstractAuthMethod(String name)
name - the name of this authentication method.| Method Detail |
|---|
public String getName()
getName in interface AuthMethod
public void handle(Message msg,
SSHPacket buf)
throws UserAuthException,
TransportException
SSHPacketHandler
handle in interface SSHPacketHandlermsg - the SSH message identifierbuf - SSHPacket containing rest of the request
UserAuthException
TransportExceptionpublic void init(AuthParams params)
AuthMethod
init in interface AuthMethodparams - parameters needed for authentication
public void request()
throws UserAuthException,
TransportException
request in interface AuthMethodUserAuthException - if there is an error with the request
TransportException - if there is a transport-related errorpublic boolean shouldRetry()
shouldRetry in interface AuthMethod
protected SSHPacket buildReq()
throws UserAuthException
SSHPacket containing the fields common to all authentication method. Method-specific fields can
further be put into this buffer.
UserAuthExceptionprotected AccountResource makeAccountResource()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||