Package com.hybris.samlssobackoffice
Class BackofficeSSOService
- java.lang.Object
-
- de.hybris.platform.servicelayer.internal.service.AbstractService
-
- de.hybris.platform.samlsinglesignon.DefaultSSOService
-
- com.hybris.samlssobackoffice.BackofficeSSOService
-
- All Implemented Interfaces:
SSOUserService
,java.io.Serializable
,org.springframework.beans.factory.Aware
,org.springframework.beans.factory.BeanNameAware
,org.springframework.beans.factory.InitializingBean
public class BackofficeSSOService extends DefaultSSOService
Extends theDefaultSSOService
to allow to control the SSO user access to Backoffice.- When the SSO user mapping is done in properties, additional property is allowed:
sso.mapping.<usergroup>.enableBackofficeLogin=true
That will allow users with <usergroup> access to backoffice. - When mapping is done in database, there's additional field provided:
SamlUserGroupModel.ENABLEBACKOFFICELOGIN
, that works analogically.
PrincipalModel.BACKOFFICELOGINDISABLED
of the SSO user to false.- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class de.hybris.platform.samlsinglesignon.DefaultSSOService
DefaultSSOService.SSOUserMapping
-
Nested classes/interfaces inherited from class de.hybris.platform.servicelayer.internal.service.AbstractService
AbstractService.SerializableDTO
-
-
Field Summary
Fields Modifier and Type Field Description protected static java.lang.String
ENABLE_BACKOFFICE_LOGIN_PARAM
-
Fields inherited from class de.hybris.platform.samlsinglesignon.DefaultSSOService
MD5_PASSWORD_ENCODING, SSO_DATABASE_USERGROUP_MAPPING, SSO_PASSWORD_ENCODING
-
Fields inherited from class de.hybris.platform.servicelayer.internal.service.AbstractService
tenant
-
-
Constructor Summary
Constructors Constructor Description BackofficeSSOService()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
adjustUserAttributes(UserModel user, DefaultSSOService.SSOUserMapping mapping)
Adjusting user groupsprotected DefaultSSOService.SSOUserMapping
findMappingInProperties(java.util.Collection<java.lang.String> roles)
protected boolean
getEnableBackofficeLogin(java.util.Collection<java.lang.String> roles)
protected DefaultSSOService.SSOUserMapping
performMapping(java.util.List<SamlUserGroupModel> userGroupModels)
-
Methods inherited from class de.hybris.platform.samlsinglesignon.DefaultSSOService
createNewUser, findMapping, findMappingInDatabase, getMappingForRole, getOrCreateSSOUser, lookupExisting, setModelService, setSamlUserGroupDAO, setUserService, validateMappings
-
Methods inherited from class de.hybris.platform.servicelayer.internal.service.AbstractService
afterPropertiesSet, getCurrentTenant, setBeanName, setCurrentTenant, writeReplace
-
-
-
-
Field Detail
-
ENABLE_BACKOFFICE_LOGIN_PARAM
protected static final java.lang.String ENABLE_BACKOFFICE_LOGIN_PARAM
- See Also:
- Constant Field Values
-
-
Method Detail
-
findMappingInProperties
protected DefaultSSOService.SSOUserMapping findMappingInProperties(java.util.Collection<java.lang.String> roles)
- Overrides:
findMappingInProperties
in classDefaultSSOService
-
getEnableBackofficeLogin
protected boolean getEnableBackofficeLogin(java.util.Collection<java.lang.String> roles)
-
performMapping
protected DefaultSSOService.SSOUserMapping performMapping(java.util.List<SamlUserGroupModel> userGroupModels)
- Overrides:
performMapping
in classDefaultSSOService
-
adjustUserAttributes
protected void adjustUserAttributes(UserModel user, DefaultSSOService.SSOUserMapping mapping)
Description copied from class:DefaultSSOService
Adjusting user groups- Overrides:
adjustUserAttributes
in classDefaultSSOService
- Parameters:
user
- the user to adjust the groups formapping
- the mapping which holds the groups
-
-