public class CachingPublicKeyAuthenticator extends AbstractLoggingBean implements PublickeyAuthenticator, SessionListener
SessionListener.Event| Modifier and Type | Field and Description |
|---|---|
protected PublickeyAuthenticator |
authenticator |
protected Map<Session,Map<PublicKey,Boolean>> |
cache |
log| Constructor and Description |
|---|
CachingPublicKeyAuthenticator(PublickeyAuthenticator authenticator) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
authenticate(String username,
PublicKey key,
ServerSession session)
Check the validity of a public key.
|
void |
sessionClosed(Session session)
A session has been closed
|
void |
sessionCreated(Session session)
A new session just been created
|
void |
sessionEvent(Session session,
SessionListener.Event event)
An event has been triggered
|
void |
sessionException(Session session,
Throwable t)
An exception was caught and the session will be closed
(if not already so).
|
getSimplifiedLoggerclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitsessionNegotiationEnd, sessionNegotiationStart, validateListenervalidateListenerprotected final PublickeyAuthenticator authenticator
public CachingPublicKeyAuthenticator(PublickeyAuthenticator authenticator)
public boolean authenticate(String username, PublicKey key, ServerSession session)
PublickeyAuthenticatorauthenticate in interface PublickeyAuthenticatorusername - the usernamekey - the keysession - the server sessionpublic void sessionCreated(Session session)
SessionListenersessionCreated in interface SessionListenersession - The created Sessionpublic void sessionEvent(Session session, SessionListener.Event event)
SessionListenersessionEvent in interface SessionListenersession - The referenced Sessionevent - The generated SessionListener.Eventpublic void sessionException(Session session, Throwable t)
SessionListenerSessionListener.sessionClosed(Session) will be called
or perhaps has already been calledsessionException in interface SessionListenersession - The referenced Sessiont - The caught exceptionpublic void sessionClosed(Session session)
SessionListenersessionClosed in interface SessionListenersession - The closed SessionCopyright © 2008–2017 The Apache Software Foundation. All rights reserved.