Class FlowableLdapAuthenticationProviderConfigurer<B extends ProviderManagerBuilder<B>>
- java.lang.Object
-
- org.springframework.security.config.annotation.SecurityConfigurerAdapter<AuthenticationManager,B>
-
- com.flowable.core.spring.security.ldap.FlowableLdapAuthenticationProviderConfigurer<B>
-
- All Implemented Interfaces:
SecurityConfigurer<AuthenticationManager,B>
public class FlowableLdapAuthenticationProviderConfigurer<B extends ProviderManagerBuilder<B>> extends SecurityConfigurerAdapter<AuthenticationManager,B>
Configures an LDAPAuthenticationProvider
in theProviderManagerBuilder
using the FlowableLdapConfigurationApi
.- Author:
- Filip Hrisafov
-
-
Field Summary
Fields Modifier and Type Field Description protected ApplicationContext
applicationContext
protected BaseLdapPathContextSource
contextSource
protected String
defaultRole
protected LdapAuthoritiesPopulator
ldapAuthoritiesPopulator
protected LdapConfigurationApi
ldapConfiguration
protected LdapUserSearch
ldapUserSearch
protected UserDefinitionAuthoritiesProvider
userDefinitionAuthoritiesProvider
-
Constructor Summary
Constructors Constructor Description FlowableLdapAuthenticationProviderConfigurer(ApplicationContext applicationContext)
-
Method Summary
-
Methods inherited from class org.springframework.security.config.annotation.SecurityConfigurerAdapter
addObjectPostProcessor, and, getBuilder, init, postProcess, setBuilder
-
-
-
-
Field Detail
-
applicationContext
protected ApplicationContext applicationContext
-
ldapConfiguration
protected LdapConfigurationApi ldapConfiguration
-
contextSource
protected BaseLdapPathContextSource contextSource
-
userDefinitionAuthoritiesProvider
protected UserDefinitionAuthoritiesProvider userDefinitionAuthoritiesProvider
-
ldapUserSearch
protected LdapUserSearch ldapUserSearch
-
ldapAuthoritiesPopulator
protected LdapAuthoritiesPopulator ldapAuthoritiesPopulator
-
defaultRole
protected String defaultRole
-
-
Constructor Detail
-
FlowableLdapAuthenticationProviderConfigurer
public FlowableLdapAuthenticationProviderConfigurer(ApplicationContext applicationContext)
-
-
Method Detail
-
configure
public void configure(B builder) throws Exception
- Specified by:
configure
in interfaceSecurityConfigurer<AuthenticationManager,B extends ProviderManagerBuilder<B>>
- Overrides:
configure
in classSecurityConfigurerAdapter<AuthenticationManager,B extends ProviderManagerBuilder<B>>
- Throws:
Exception
-
build
protected LdapAuthenticationProvider build()
-
getContextSource
protected BaseLdapPathContextSource getContextSource()
-
createLdapAuthenticator
protected LdapAuthenticator createLdapAuthenticator()
-
getLdapUserSearch
protected LdapUserSearch getLdapUserSearch()
-
createDefaultLdapUserSearch
protected LdapUserSearch createDefaultLdapUserSearch()
-
getLdapAuthoritiesPopulator
protected LdapAuthoritiesPopulator getLdapAuthoritiesPopulator()
-
createDefaultLdapAuthoritiesPopulator
protected LdapAuthoritiesPopulator createDefaultLdapAuthoritiesPopulator()
-
getLdapConfiguration
protected LdapConfigurationApi getLdapConfiguration()
-
getUserDefinitionAuthoritiesProvider
protected UserDefinitionAuthoritiesProvider getUserDefinitionAuthoritiesProvider()
-
createDefaultUserDefinitionAuthoritiesProvider
protected UserDefinitionAuthoritiesProvider createDefaultUserDefinitionAuthoritiesProvider()
-
ldapConfiguration
public FlowableLdapAuthenticationProviderConfigurer<B> ldapConfiguration(LdapConfigurationApi ldapConfiguration)
Specifies theLdapConfigurationApi
- Parameters:
ldapConfiguration
- theLdapConfigurationApi
- Returns:
- the
FlowableLdapAuthenticationProviderConfigurer
for further customization
-
contextSource
public FlowableLdapAuthenticationProviderConfigurer<B> contextSource(BaseLdapPathContextSource contextSource)
Specifies theBaseLdapPathContextSource
- Parameters:
contextSource
- theBaseLdapPathContextSource
- Returns:
- the
FlowableLdapAuthenticationProviderConfigurer
for further customization
-
userDefinitionAuthoritiesProvider
public FlowableLdapAuthenticationProviderConfigurer<B> userDefinitionAuthoritiesProvider(UserDefinitionAuthoritiesProvider userDefinitionAuthoritiesProvider)
Specifies theUserDefinitionAuthoritiesProvider
- Parameters:
userDefinitionAuthoritiesProvider
- theUserDefinitionAuthoritiesProvider
- Returns:
- the
FlowableLdapAuthenticationProviderConfigurer
for further customization
-
userSearch
public FlowableLdapAuthenticationProviderConfigurer<B> userSearch(LdapUserSearch ldapUserSearch)
Specifies theLdapUserSearch
.- Parameters:
ldapUserSearch
- theLdapUserSearch
the default isFlowableLdapUserSearch
- Returns:
- the
FlowableLdapAuthenticationProviderConfigurer
for further customization
-
authoritiesPopulator
public FlowableLdapAuthenticationProviderConfigurer<B> authoritiesPopulator(LdapAuthoritiesPopulator ldapAuthoritiesPopulator)
Specifies theLdapAuthoritiesPopulator
.- Parameters:
ldapAuthoritiesPopulator
- theLdapAuthoritiesPopulator
the default isFlowableLdapAuthoritiesPopulator
- Returns:
- the
FlowableLdapAuthenticationProviderConfigurer
for further customization
-
defaultRole
public FlowableLdapAuthenticationProviderConfigurer<B> defaultRole(String defaultRole)
The default role that should be added to every user.- Parameters:
defaultRole
- the default role- Returns:
- the
FlowableLdapAuthenticationProviderConfigurer
for further customization
-
-