Class LdaptiveUserDetailsAutoConfiguration


  • @Configuration
    @ConditionalOnWebApplication(type=ANY)
    @AutoConfigureBefore(InMemoryUserDetailsAutoConfiguration.class)
    @AutoConfigureAfter(LdaptiveAutoConfiguration.class)
    @ConditionalOnClass({org.ldaptive.ConnectionFactory.class,org.bremersee.data.ldaptive.LdaptiveOperations.class})
    @ConditionalOnProperty(prefix="bremersee.ldaptive",
                           name={"enabled","authentication-enabled"},
                           havingValue="true")
    @EnableConfigurationProperties(LdaptiveProperties.class)
    public class LdaptiveUserDetailsAutoConfiguration
    extends Object
    The ldaptive user details auto configuration.
    Author:
    Christian Bremer
    • Constructor Detail

      • LdaptiveUserDetailsAutoConfiguration

        public LdaptiveUserDetailsAutoConfiguration​(LdaptiveProperties properties,
                                                    org.springframework.beans.factory.ObjectProvider<org.bremersee.data.ldaptive.LdaptiveOperations> ldaptiveOperationsProvider)
        Instantiates a new ldaptive user details auto configuration.
        Parameters:
        properties - the properties
        ldaptiveOperationsProvider - the ldaptive operations provider
    • Method Detail

      • init

        @EventListener(org.springframework.boot.context.event.ApplicationReadyEvent.class)
        public void init()
        Init.
      • ldaptiveUserDetailsService

        @ConditionalOnWebApplication(type=SERVLET)
        @ConditionalOnMissingBean(org.springframework.security.core.userdetails.UserDetailsService.class)
        @Bean
        public org.bremersee.security.core.userdetails.LdaptiveUserDetailsService ldaptiveUserDetailsService()
        Ldaptive user details service.
        Returns:
        the ldaptive user details service
      • reactiveLdaptiveUserDetailsService

        @ConditionalOnWebApplication(type=REACTIVE)
        @ConditionalOnMissingBean(org.springframework.security.core.userdetails.ReactiveUserDetailsService.class)
        @Bean
        public org.bremersee.security.core.userdetails.ReactiveLdaptiveUserDetailsService reactiveLdaptiveUserDetailsService​(org.springframework.beans.factory.ObjectProvider<org.bremersee.data.ldaptive.reactive.ReactiveLdaptiveOperations> reactiveLdaptiveOperationsProvider)
        Reactive ldaptive user details service.
        Parameters:
        reactiveLdaptiveOperationsProvider - the reactive ldaptive operations provider
        Returns:
        the reactive ldaptive user details service
      • passwordEncoder

        @ConditionalOnMissingBean(org.springframework.security.crypto.password.PasswordEncoder.class)
        @Bean
        public org.bremersee.security.core.userdetails.LdaptivePasswordMatcher passwordEncoder()
        Ldaptive password matcher.
        Returns:
        the ldaptive password matcher