use of org.springframework.security.kerberos.web.authentication.SpnegoEntryPoint in project kylo by Teradata.
the class KerberosWebSecurityConfigurer method configure.
@Override
@SuppressWarnings("unchecked")
protected void configure(HttpSecurity http) throws Exception {
// @formatter:off
http.removeConfigurer(LogoutConfigurer.class);
http.csrf().disable().sessionManagement().sessionCreationPolicy(SessionCreationPolicy.STATELESS).and().exceptionHandling().authenticationEntryPoint(spnegoEntryPoint).and().authorizeRequests().antMatchers("/**").authenticated().and().rememberMe().rememberMeServices(rememberMeServices).and().httpBasic().and().addFilterBefore(new RememberMeAuthenticationFilter(auth -> auth, rememberMeServices), BasicAuthenticationFilter.class).addFilterAfter(spnegoFilter(), RememberMeAuthenticationFilter.class).addFilterAfter(logoutFilter(), BasicAuthenticationFilter.class);
// @formatter:on
}
use of org.springframework.security.kerberos.web.authentication.SpnegoEntryPoint in project kylo by Teradata.
the class KerberosWebSecurityConfigurer method configure.
@Override
@SuppressWarnings("unchecked")
protected void configure(HttpSecurity http) throws Exception {
// @formatter:off
http.removeConfigurer(LogoutConfigurer.class);
http.csrf().disable().sessionManagement().sessionCreationPolicy(SessionCreationPolicy.STATELESS).and().exceptionHandling().authenticationEntryPoint(spnegoEntryPoint).and().authorizeRequests().antMatchers("/login", "/login/**", "/login**").permitAll().antMatchers("/**").authenticated().and().formLogin().usernameParameter("username").passwordParameter("password").loginPage("/login.html").loginProcessingUrl("/login").failureUrl("/login.html?error=true").permitAll().and().logout().permitAll().and().rememberMe().rememberMeServices(rememberMeServices).and().addFilterBefore(new RememberMeAuthenticationFilter(auth -> auth, rememberMeServices), BasicAuthenticationFilter.class).addFilterAfter(spnegoFilter(), RememberMeAuthenticationFilter.class).httpBasic();
// @formatter:on
}
Aggregations