public abstract class AbstractKeycloakAuthenticatorValve
extends org.apache.catalina.authenticator.FormAuthenticator
implements org.apache.catalina.LifecycleListener
Modifier and Type | Field and Description |
---|---|
protected AdapterDeploymentContext |
deploymentContext |
protected NodesRegistrationManagement |
nodesRegistrationManagement |
static String |
TOKEN_STORE_NOTE |
protected CatalinaUserSessionManagement |
userSessionManagement |
characterEncoding, landingPage
alwaysUseSession, AUTH_HEADER_NAME, cache, changeSessionIdOnAuthentication, context, disableProxyCaching, REALM_NAME, securePagesWithPragma, secureRandomAlgorithm, secureRandomClass, secureRandomProvider, sessionIdGenerator, sm, sso
asyncSupported, container, containerLog, next
AFTER_DESTROY_EVENT, AFTER_INIT_EVENT, AFTER_START_EVENT, AFTER_STOP_EVENT, BEFORE_DESTROY_EVENT, BEFORE_INIT_EVENT, BEFORE_START_EVENT, BEFORE_STOP_EVENT, CONFIGURE_START_EVENT, CONFIGURE_STOP_EVENT, PERIODIC_EVENT, START_EVENT, STOP_EVENT
Constructor and Description |
---|
AbstractKeycloakAuthenticatorValve() |
Modifier and Type | Method and Description |
---|---|
protected boolean |
authenticateInternal(org.apache.catalina.connector.Request request,
javax.servlet.http.HttpServletResponse response,
Object loginConfig) |
protected void |
beforeStop() |
protected void |
checkKeycloakSession(org.apache.catalina.connector.Request request,
HttpFacade facade)
Checks that access token is still valid.
|
protected abstract GenericPrincipalFactory |
createPrincipalFactory() |
protected abstract boolean |
forwardToErrorPageInternal(org.apache.catalina.connector.Request request,
javax.servlet.http.HttpServletResponse response,
Object loginConfig) |
protected AdapterTokenStore |
getTokenStore(org.apache.catalina.connector.Request request,
HttpFacade facade,
KeycloakDeployment resolvedDeployment) |
void |
invoke(org.apache.catalina.connector.Request request,
org.apache.catalina.connector.Response response) |
void |
keycloakInit() |
boolean |
keycloakRestoreRequest(org.apache.catalina.connector.Request request) |
void |
keycloakSaveRequest(org.apache.catalina.connector.Request request) |
void |
lifecycleEvent(org.apache.catalina.LifecycleEvent event) |
protected void |
logoutInternal(org.apache.catalina.connector.Request request) |
authenticate, forwardToErrorPage, forwardToLoginPage, getAuthMethod, getCharacterEncoding, getLandingPage, matchRequest, restoreRequest, savedRequestURL, saveRequest, setCharacterEncoding, setLandingPage
associate, doLogin, getAlwaysUseSession, getCache, getChangeSessionIdOnAuthentication, getContainer, getDisableProxyCaching, getRealmName, getRequestCertificates, getSecurePagesWithPragma, getSecureRandomAlgorithm, getSecureRandomClass, getSecureRandomProvider, login, logout, reauthenticateFromSSO, register, setAlwaysUseSession, setCache, setChangeSessionIdOnAuthentication, setContainer, setDisableProxyCaching, setSecurePagesWithPragma, setSecureRandomAlgorithm, setSecureRandomClass, setSecureRandomProvider, startInternal, stopInternal
backgroundProcess, event, getDomainInternal, getNext, getObjectNameKeyProperties, initInternal, isAsyncSupported, setAsyncSupported, setNext, toString
destroyInternal, getDomain, getObjectName, postDeregister, postRegister, preDeregister, preRegister, register, setDomain, unregister
public static final String TOKEN_STORE_NOTE
protected CatalinaUserSessionManagement userSessionManagement
protected AdapterDeploymentContext deploymentContext
protected NodesRegistrationManagement nodesRegistrationManagement
public void lifecycleEvent(org.apache.catalina.LifecycleEvent event)
lifecycleEvent
in interface org.apache.catalina.LifecycleListener
protected void logoutInternal(org.apache.catalina.connector.Request request)
public void keycloakInit()
protected void beforeStop()
public void invoke(org.apache.catalina.connector.Request request, org.apache.catalina.connector.Response response) throws IOException, javax.servlet.ServletException
invoke
in interface org.apache.catalina.Valve
invoke
in class org.apache.catalina.authenticator.AuthenticatorBase
IOException
javax.servlet.ServletException
protected abstract GenericPrincipalFactory createPrincipalFactory()
protected abstract boolean forwardToErrorPageInternal(org.apache.catalina.connector.Request request, javax.servlet.http.HttpServletResponse response, Object loginConfig) throws IOException
IOException
protected boolean authenticateInternal(org.apache.catalina.connector.Request request, javax.servlet.http.HttpServletResponse response, Object loginConfig) throws IOException
IOException
protected void checkKeycloakSession(org.apache.catalina.connector.Request request, HttpFacade facade)
request
- public void keycloakSaveRequest(org.apache.catalina.connector.Request request) throws IOException
IOException
public boolean keycloakRestoreRequest(org.apache.catalina.connector.Request request)
protected AdapterTokenStore getTokenStore(org.apache.catalina.connector.Request request, HttpFacade facade, KeycloakDeployment resolvedDeployment)
Copyright © 2015. All rights reserved.