Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @Override
- protected void configure(HttpSecurity http) throws Exception {
- http
- .authorizeRequests()
- .antMatchers("/login**").permitAll()
- .antMatchers("/profile/**").fullyAuthenticated()
- .antMatchers("/").permitAll()
- .and()
- .formLogin()
- .loginPage("/login")
- .failureUrl("/login?error")
- .permitAll()
- .and()
- .logout()
- .invalidateHttpSession(true)
- .deleteCookies("JSESSIONID")
- .permitAll();
- }
- @Override protected void configure(AuthenticationManagerBuilder auth) throws
- Exception {
- auth.ldapAuthentication().userDnPatterns("sAMAccountName={0}")
- .url(
- "ldap://url:389/DC=dmc,DC=local"
- ); }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement