Package de.xima.fc.interfaces.auth
Interface IFormAuthContext
-
- All Superinterfaces:
Serializable
- All Known Implementing Classes:
FormAuthContext
public interface IFormAuthContext extends Serializable
Interface of an form based authentication context- Author:
- XIMA MEDIA GmbH
-
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description void
authorize()
Starts the authorization flow of the current contextvoid
authorize(javax.servlet.FilterChain chain)
Starts the authorization flow of the current contextvoid
callback()
Starts the callback handling of the current contextboolean
checkAuthorisation(org.pac4j.core.profile.CommonProfile profile)
Checks the authorization of the given profiles against the current contextorg.pac4j.core.config.Config
getAuthConfig()
Returns the current configuration of the authentication context.List<IAuthenticatorConfigWrapper>
getAuthConfigOptions()
String
getAuthenticatorToken()
Get the token of the currentIAuthenticator
or the name of an internal authenticatorString
getBaseUrl()
Get the current base URLMandant
getClient()
Get the client to which the form belongs.FRQSession
getFRQSession()
Get the current form request session to authenticate withLocale
getLocale()
Returns the locale of the auth contextMap<String,ProjectAuthenticatorConfig>
getProjectAuthConfig()
Deprecated.USegetAuthConfigOptions()
insteadjavax.servlet.http.HttpServletRequest
getRequest()
Returns the HTTP servlet requestjavax.servlet.http.HttpServletResponse
getResponse()
Returns the HTTP servlet responseIAuthenticatorConfigWrapper
getTokenAuthConfig()
void
logout()
Starts the logout from the given authorizationsvoid
logout(javax.servlet.FilterChain chain)
Starts the logout from the given authorizationsvoid
setAuthenticatorToken(String token)
Set the token of the currentIAuthenticator
-
-
-
Method Detail
-
getAuthenticatorToken
String getAuthenticatorToken()
Get the token of the currentIAuthenticator
or the name of an internal authenticator- Returns:
String
token or name
-
setAuthenticatorToken
void setAuthenticatorToken(String token)
Set the token of the currentIAuthenticator
- Parameters:
token
- The token of the currentIAuthenticator
or the name of an internal authenticator.
-
getTokenAuthConfig
IAuthenticatorConfigWrapper getTokenAuthConfig()
- Returns:
- the
IAuthenticatorConfigWrapper
for a given authenticator token
-
getAuthConfigOptions
List<IAuthenticatorConfigWrapper> getAuthConfigOptions()
- Returns:
- A
List
of all available authenticator configs
-
getClient
Mandant getClient()
Get the client to which the form belongs.- Returns:
- The current
Mandant
to which the form belongs.
-
getFRQSession
FRQSession getFRQSession()
Get the current form request session to authenticate with- Returns:
FRQSession
to authenticate
-
getAuthConfig
org.pac4j.core.config.Config getAuthConfig()
Returns the current configuration of the authentication context. If no configuration is present, the configuration will be build and saved.- Returns:
- The existing or newly created
Config
.
-
getRequest
javax.servlet.http.HttpServletRequest getRequest()
Returns the HTTP servlet request- Returns:
HttpServletRequest
-
getResponse
javax.servlet.http.HttpServletResponse getResponse()
Returns the HTTP servlet response- Returns:
- HttpServletResponse
-
checkAuthorisation
boolean checkAuthorisation(org.pac4j.core.profile.CommonProfile profile)
Checks the authorization of the given profiles against the current context- Parameters:
profile
- ACommonProfile
to check- Returns:
true
if authorized, orfalse
otherwise.
-
authorize
void authorize()
Starts the authorization flow of the current context
-
authorize
void authorize(javax.servlet.FilterChain chain)
Starts the authorization flow of the current context- Parameters:
chain
-FilterChain
to process after the authorization
-
logout
void logout()
Starts the logout from the given authorizations
-
logout
void logout(javax.servlet.FilterChain chain) throws IOException, javax.servlet.ServletException
Starts the logout from the given authorizations- Parameters:
chain
-FilterChain
to process after the logout- Throws:
IOException
- IO-errors while processing the chainjavax.servlet.ServletException
- Servlet-errors while processing the chain
-
callback
void callback()
Starts the callback handling of the current context
-
getProjectAuthConfig
@Deprecated Map<String,ProjectAuthenticatorConfig> getProjectAuthConfig()
Deprecated.USegetAuthConfigOptions()
instead
-
-