Closed fadel09 closed 5 months ago
I am using spring security 5.7.11 and the following code
@Autowired public void configureGlobal(AuthenticationManagerBuilder auth) throws Exception { auth. ldapAuthentication() .userSearchFilter(ldapUserSearchFilter) .userSearchBase(ldapUserSearchBase) .groupSearchBase(ldapGroupSearchBase) .groupSearchFilter(ldapGroupSearchFilter) .contextSource() .url(ldapUrl) .port(ldapPort) .managerDn(ldapManagerDn) .managerPassword(ldapManagerPassword); }
If i entered the user and the password it works however when I check remeber me checkbox it gives bad credentials.
<input type="checkbox" name ="remember-me">
and
@Bean public SecurityFilterChain securityFilterChain(HttpSecurity http) throws Exception { return http.csrf().disable() .authorizeHttpRequests() .antMatchers("/login").permitAll() .antMatchers(staticResources).permitAll() .antMatchers("/**").authenticated() .and() .rememberMe().tokenValiditySeconds(86400) .and() .formLogin().loginPage("/login") .and().build() ; }
I am using spring security 5.7.11 and the following code
If i entered the user and the password it works however when I check remeber me checkbox it gives bad credentials.
and
@Bean public SecurityFilterChain securityFilterChain(HttpSecurity http) throws Exception { return http.csrf().disable() .authorizeHttpRequests() .antMatchers("/login").permitAll() .antMatchers(staticResources).permitAll() .antMatchers("/**").authenticated() .and() .rememberMe().tokenValiditySeconds(86400) .and() .formLogin().loginPage("/login") .and().build() ; }