Class ShibbolethAuthenticationServiceImpl
- java.lang.Object
-
- org.nuxeo.runtime.model.DefaultComponent
-
- org.nuxeo.ecm.platform.shibboleth.service.ShibbolethAuthenticationServiceImpl
-
- All Implemented Interfaces:
ShibbolethAuthenticationService
,Adaptable
,Component
,Extensible
,TimestampedService
public class ShibbolethAuthenticationServiceImpl extends DefaultComponent implements ShibbolethAuthenticationService
-
-
Field Summary
Fields Modifier and Type Field Description protected ShibbolethAuthenticationConfig
config
static String
CONFIG_EP
-
Fields inherited from class org.nuxeo.runtime.model.DefaultComponent
lastModified, name
-
-
Constructor Summary
Constructors Constructor Description ShibbolethAuthenticationServiceImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ShibbolethAuthenticationConfig
getConfig()
String
getLoginURL(String redirectURL)
Returns the computed login URL to Shibboleth , ornull
if no login URL is configured.String
getLoginURL(javax.servlet.http.HttpServletRequest request)
Returns the computed login URL to Shibboleth , ornull
if no login URL is configured.String
getLogoutURL(String redirectURL)
Returns the computed logout URL to Shibboleth, ornull
if no logout URL is configured.String
getLogoutURL(javax.servlet.http.HttpServletRequest request)
Returns the computed logout URL to Shibboleth, ornull
if no logout URL is configured.String
getUserID(javax.servlet.http.HttpServletRequest httpRequest)
Returns the user ID based on the source IdP.com.google.common.collect.BiMap<String,String>
getUserMetadata()
Returns a bi-map of the user metadata {response headers, values} based on the configuration.Map<String,Object>
getUserMetadata(String userIdField, javax.servlet.http.HttpServletRequest httpRequest)
Returns a map of the user metadata based on the configuration.protected String
readHeader(javax.servlet.http.HttpServletRequest request, String key)
void
registerContribution(Object contribution, String extensionPoint, ComponentInstance contributor)
-
Methods inherited from class org.nuxeo.runtime.model.DefaultComponent
activate, addRuntimeMessage, addRuntimeMessage, deactivate, getAdapter, getDescriptor, getDescriptors, getLastModified, getRegistry, register, registerExtension, setLastModified, setModifiedNow, setName, start, stop, unregister, unregisterContribution, unregisterExtension
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.nuxeo.runtime.model.Component
applicationStarted, getApplicationStartedOrder
-
-
-
-
Field Detail
-
CONFIG_EP
public static final String CONFIG_EP
- See Also:
- Constant Field Values
-
config
protected ShibbolethAuthenticationConfig config
-
-
Method Detail
-
registerContribution
public void registerContribution(Object contribution, String extensionPoint, ComponentInstance contributor)
- Overrides:
registerContribution
in classDefaultComponent
-
getConfig
public ShibbolethAuthenticationConfig getConfig()
-
getLoginURL
public String getLoginURL(String redirectURL)
Description copied from interface:ShibbolethAuthenticationService
Returns the computed login URL to Shibboleth , ornull
if no login URL is configured.- Specified by:
getLoginURL
in interfaceShibbolethAuthenticationService
-
getLogoutURL
public String getLogoutURL(String redirectURL)
Description copied from interface:ShibbolethAuthenticationService
Returns the computed logout URL to Shibboleth, ornull
if no logout URL is configured.- Specified by:
getLogoutURL
in interfaceShibbolethAuthenticationService
-
getLoginURL
public String getLoginURL(javax.servlet.http.HttpServletRequest request)
Description copied from interface:ShibbolethAuthenticationService
Returns the computed login URL to Shibboleth , ornull
if no login URL is configured.- Specified by:
getLoginURL
in interfaceShibbolethAuthenticationService
-
getLogoutURL
public String getLogoutURL(javax.servlet.http.HttpServletRequest request)
Description copied from interface:ShibbolethAuthenticationService
Returns the computed logout URL to Shibboleth, ornull
if no logout URL is configured.- Specified by:
getLogoutURL
in interfaceShibbolethAuthenticationService
-
getUserID
public String getUserID(javax.servlet.http.HttpServletRequest httpRequest)
Description copied from interface:ShibbolethAuthenticationService
Returns the user ID based on the source IdP. In the configuration is defined which HTTP header is used for each registered IdP.- Specified by:
getUserID
in interfaceShibbolethAuthenticationService
-
getUserMetadata
public Map<String,Object> getUserMetadata(String userIdField, javax.servlet.http.HttpServletRequest httpRequest)
Description copied from interface:ShibbolethAuthenticationService
Returns a map of the user metadata based on the configuration. Keys are the field names and values coming from the HTTP headers.- Specified by:
getUserMetadata
in interfaceShibbolethAuthenticationService
-
getUserMetadata
public com.google.common.collect.BiMap<String,String> getUserMetadata()
Description copied from interface:ShibbolethAuthenticationService
Returns a bi-map of the user metadata {response headers, values} based on the configuration.- Specified by:
getUserMetadata
in interfaceShibbolethAuthenticationService
-
-