public abstract class AbstractUserAuth extends AbstractLoggingBean implements UserAuth
logBY_NAME_COMPARATOR, NAME_EXTRACTOR| Modifier | Constructor and Description |
|---|---|
protected |
AbstractUserAuth(String name) |
| Modifier and Type | Method and Description |
|---|---|
Boolean |
auth(ServerSession session,
String username,
String service,
Buffer buffer)
Try to authenticate the user.
|
void |
destroy()
Free any system resources used by the module.
|
protected abstract Boolean |
doAuth(Buffer buffer,
boolean init) |
String |
getName() |
ServerSession |
getServerSession() |
String |
getService() |
ServerSession |
getSession() |
String |
getUsername() |
Boolean |
next(Buffer buffer)
Handle another step in the authentication process.
|
String |
toString() |
debug, debug, debug, debug, debug, error, error, error, error, error, getSimplifiedLogger, info, info, warn, warn, warn, warn, warn, warn, warn, warnclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitfindByName, findFirstMatchByName, getNameList, getNames, ofName, removeByName, safeCompareByNameprotected AbstractUserAuth(String name)
public final String getName()
getName in interface NamedResourcepublic String getUsername()
getUsername in interface UsernameHolderpublic String getService()
public ServerSession getServerSession()
getServerSession in interface ServerSessionHolderServerSession usedpublic ServerSession getSession()
getSession in interface UserAuthInstance<ServerSession>public Boolean auth(ServerSession session, String username, String service, Buffer buffer) throws Exception
UserAuthnull value indicating if the
authentication succeeded. If the authentication is still ongoing, a null value should be returned.auth in interface UserAuthsession - the current ServerSession sessionusername - the user trying to log inservice - the requested service namebuffer - the request buffer containing parameters specific to this requesttrue if the authentication succeeded, false if the
authentication failed and null if not finished yetAsyncAuthException - if the service is willing to perform an asynchronous authenticationException - if the authentication failspublic Boolean next(Buffer buffer) throws Exception
UserAuthnext in interface UserAuthbuffer - the request buffer containing parameters specific to this requesttrue if the authentication succeeded, false if the
authentication failed and null if not finished yetAsyncAuthException - if the service is willing to perform an asynchronous authenticationException - if the authentication failspublic void destroy()
UserAuthprotected abstract Boolean doAuth(Buffer buffer, boolean init) throws Exception
ExceptionCopyright © 2008–2021 The Apache Software Foundation. All rights reserved.