Package io.hawt.system
Class AbstractAuthenticator
- java.lang.Object
-
- io.hawt.system.AbstractAuthenticator
-
- All Implemented Interfaces:
Authenticator
- Direct Known Subclasses:
JaasAuthenticator
public abstract class AbstractAuthenticator extends Object implements Authenticator
-
-
Field Summary
Fields Modifier and Type Field Description protected AuthenticationConfigurationauthConfigurationprotected X509Certificate[]certificatesprotected Stringpasswordprotected javax.servlet.http.HttpServletRequestrequestprotected Stringusername
-
Constructor Summary
Constructors Constructor Description AbstractAuthenticator(org.slf4j.Logger log, javax.servlet.http.HttpServletRequest request, AuthenticationConfiguration authConfiguration)Request-based authenticator such as when authenticating direct Jolokia accesses.AbstractAuthenticator(org.slf4j.Logger log, javax.servlet.http.HttpServletRequest request, AuthenticationConfiguration authConfiguration, String username, String password)Explicit username/password authenticator when authenticating users from login page.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description AuthenticateResultauthenticate(Consumer<Subject> callback)protected abstract SubjectdoAuthenticate()booleanhasNoCredentials()SubjectinitSubject()booleanisUsernamePasswordSet()-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface io.hawt.system.Authenticator
logout
-
-
-
-
Field Detail
-
request
protected javax.servlet.http.HttpServletRequest request
-
authConfiguration
protected AuthenticationConfiguration authConfiguration
-
username
protected String username
-
password
protected String password
-
certificates
protected X509Certificate[] certificates
-
-
Constructor Detail
-
AbstractAuthenticator
public AbstractAuthenticator(org.slf4j.Logger log, javax.servlet.http.HttpServletRequest request, AuthenticationConfiguration authConfiguration, String username, String password)Explicit username/password authenticator when authenticating users from login page.
-
AbstractAuthenticator
public AbstractAuthenticator(org.slf4j.Logger log, javax.servlet.http.HttpServletRequest request, AuthenticationConfiguration authConfiguration)Request-based authenticator such as when authenticating direct Jolokia accesses.
-
-
Method Detail
-
isUsernamePasswordSet
public boolean isUsernamePasswordSet()
-
hasNoCredentials
public boolean hasNoCredentials()
-
authenticate
public final AuthenticateResult authenticate(Consumer<Subject> callback)
- Specified by:
authenticatein interfaceAuthenticator
-
initSubject
public final Subject initSubject()
-
doAuthenticate
protected abstract Subject doAuthenticate()
-
-