Class DefaultSingleSignOnSessionFactory
- java.lang.Object
-
- org.wildfly.security.http.util.sso.DefaultSingleSignOnSessionFactory
-
- All Implemented Interfaces:
SingleSignOnSessionContext
,SingleSignOnSessionFactory
public class DefaultSingleSignOnSessionFactory extends Object implements SingleSignOnSessionFactory, SingleSignOnSessionContext
SingleSignOnSessionFactory
that delegates the management of single sign-on entries to aSingleSignOnManager
.- Author:
- Pedro Igor, Paul Ferraro
-
-
Field Summary
Fields Modifier and Type Field Description private static String
DEFAULT_SIGNATURE_ALGORITHM
private KeyPair
keyPair
private Consumer<HttpsURLConnection>
logoutConnectionConfigurator
private SingleSignOnManager
manager
-
Constructor Summary
Constructors Constructor Description DefaultSingleSignOnSessionFactory(SingleSignOnManager manager, KeyPair keyPair)
DefaultSingleSignOnSessionFactory(SingleSignOnManager manager, KeyPair keyPair, Consumer<HttpsURLConnection> logoutConnectionConfigurator)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
configureLogoutConnection(HttpURLConnection connection)
SingleSignOnSession
create(HttpServerRequest request, String mechanismName, boolean programmatic)
Creates a newSingleSignOnSession
for the specified request and authentication mechanism.String
createLogoutParameter(String sessionId)
SingleSignOnSession
find(String id, HttpServerRequest request)
Returns aSingleSignOnSession
instance associated with the specified identifier and request.SingleSignOnManager
getSingleSignOnManager()
String
verifyLogoutParameter(String parameter)
-
-
-
Field Detail
-
DEFAULT_SIGNATURE_ALGORITHM
private static final String DEFAULT_SIGNATURE_ALGORITHM
- See Also:
- Constant Field Values
-
manager
private final SingleSignOnManager manager
-
keyPair
private final KeyPair keyPair
-
logoutConnectionConfigurator
private final Consumer<HttpsURLConnection> logoutConnectionConfigurator
-
-
Constructor Detail
-
DefaultSingleSignOnSessionFactory
public DefaultSingleSignOnSessionFactory(SingleSignOnManager manager, KeyPair keyPair)
-
DefaultSingleSignOnSessionFactory
public DefaultSingleSignOnSessionFactory(SingleSignOnManager manager, KeyPair keyPair, Consumer<HttpsURLConnection> logoutConnectionConfigurator)
-
-
Method Detail
-
find
public SingleSignOnSession find(String id, HttpServerRequest request)
Description copied from interface:SingleSignOnSessionFactory
Returns aSingleSignOnSession
instance associated with the specified identifier and request.- Specified by:
find
in interfaceSingleSignOnSessionFactory
- Parameters:
id
- the identifier to lookup the sessionrequest
- the current request- Returns:
- a
SingleSignOnSession
instance associated with the specified identifier and request, ornull
if there is no session with the given identifier
-
create
public SingleSignOnSession create(HttpServerRequest request, String mechanismName, boolean programmatic)
Description copied from interface:SingleSignOnSessionFactory
Creates a newSingleSignOnSession
for the specified request and authentication mechanism.- Specified by:
create
in interfaceSingleSignOnSessionFactory
- Parameters:
request
- the current requestmechanismName
- the name of the authentication mechanismprogrammatic
-true
if the session if being created for programmatic authentication- Returns:
- a
SingleSignOnSession
instance associated with the specified identifier and request
-
getSingleSignOnManager
public SingleSignOnManager getSingleSignOnManager()
- Specified by:
getSingleSignOnManager
in interfaceSingleSignOnSessionContext
-
createLogoutParameter
public String createLogoutParameter(String sessionId)
- Specified by:
createLogoutParameter
in interfaceSingleSignOnSessionContext
-
verifyLogoutParameter
public String verifyLogoutParameter(String parameter)
- Specified by:
verifyLogoutParameter
in interfaceSingleSignOnSessionContext
-
configureLogoutConnection
public void configureLogoutConnection(HttpURLConnection connection)
- Specified by:
configureLogoutConnection
in interfaceSingleSignOnSessionContext
-
-