Class SimpleServerAuthConfig
java.lang.Object
org.apache.catalina.authenticator.jaspic.SimpleServerAuthConfig
- All Implemented Interfaces:
AuthConfig, ServerAuthConfig
Basic implementation primarily intended for use when using third-party
ServerAuthModule implementations that
only provide the module. This implementation supports configuring the ServerAuthContext with multiple
modules.-
Constructor Summary
ConstructorsConstructorDescriptionSimpleServerAuthConfig(String layer, String appContext, CallbackHandler handler, Map<String, String> properties) Creates a new SimpleServerAuthConfig. -
Method Summary
Modifier and TypeMethodDescriptionprotected ServerAuthContextcreateServerAuthContext(List<ServerAuthModule> modules) Creates the ServerAuthContext.getAuthContext(String authContextID, Subject serviceSubject, Map properties) getAuthContextID(MessageInfo messageInfo) booleanvoidrefresh()
-
Constructor Details
-
SimpleServerAuthConfig
-
-
Method Details
-
getMessageLayer
- Specified by:
getMessageLayerin interfaceAuthConfig
-
getAppContext
- Specified by:
getAppContextin interfaceAuthConfig
-
getAuthContextID
Returns the MessageInfo's string representation as the auth context ID.
- Specified by:
getAuthContextIDin interfaceAuthConfig
-
refresh
public void refresh()Clears the cached ServerAuthConfig so it will be recreated on next use.
- Specified by:
refreshin interfaceAuthConfig
-
isProtected
public boolean isProtected()This implementation always returns
false.- Specified by:
isProtectedin interfaceAuthConfig
-
getAuthContext
public ServerAuthContext getAuthContext(String authContextID, Subject serviceSubject, Map properties) throws AuthException Loads ServerAuthModule instances from properties keyed with
org.apache.catalina.authenticator.jaspic.ServerAuthModule.Nwhere N is 1-based index. The returned context is cached and reused for subsequent calls.- Specified by:
getAuthContextin interfaceServerAuthConfig- Throws:
AuthException
-
createServerAuthContext
Creates the ServerAuthContext. Can be overridden by subclasses to provide a custom implementation.- Parameters:
modules- List of ServerAuthModule instances- Returns:
- The ServerAuthContext instance
-