Interface QAuthenticationModuleInterface
- All Known Implementing Classes:
Auth0AuthenticationModule,FullyAnonymousAuthenticationModule,MockAuthenticationModule,OAuth2AuthenticationModule,TableBasedAuthenticationModule
public interface QAuthenticationModuleInterface
Interface that a QAuthenticationModule must implement.
-
Method Summary
Modifier and TypeMethodDescriptiondefault QSessioncreateAutomatedSessionForUser(QInstance qInstance, Serializable userId) default QSessioncreateSession(QInstance qInstance, QAuthenticationMetaData authenticationMetaData, Map<String, String> context) Create a session for the given (possibly scoped) authentication provider.createSession(QInstance qInstance, Map<String, String> context) default StringgetLoginRedirectUrl(String originalUrl) booleanisSessionValid(QInstance instance, QSession session) default voidLogout a session, invalidating it server-side.default boolean
-
Method Details
-
createSession
QSession createSession(QInstance qInstance, Map<String, String> context) throws QAuthenticationException- Throws:
QAuthenticationException
-
createSession
default QSession createSession(QInstance qInstance, QAuthenticationMetaData authenticationMetaData, Map<String, String> context) throws QAuthenticationExceptionCreate a session for the given (possibly scoped) authentication provider. Callers that resolved a provider (e.g., per API) use this, so a module can read its own provider's settings rather than the instance default. The default ignores the metadata, for modules that only know the instance one.- Throws:
QAuthenticationException
-
isSessionValid
-
createAutomatedSessionForUser
default QSession createAutomatedSessionForUser(QInstance qInstance, Serializable userId) throws QAuthenticationException - Throws:
QAuthenticationException
-
usesSessionIdCookie
default boolean usesSessionIdCookie() -
getLoginRedirectUrl
- Throws:
QAuthenticationException
-
logout
-