Class ControlCenterSecurityConfigurer

java.lang.Object
org.springframework.security.config.annotation.SecurityConfigurerAdapter<org.springframework.security.web.DefaultSecurityFilterChain,org.springframework.security.config.annotation.web.builders.HttpSecurity>
org.springframework.security.config.annotation.web.configurers.AbstractHttpConfigurer<ControlCenterSecurityConfigurer,org.springframework.security.config.annotation.web.builders.HttpSecurity>
com.vaadin.controlcenter.starter.ControlCenterSecurityConfigurer
All Implemented Interfaces:
org.springframework.security.config.annotation.SecurityConfigurer<org.springframework.security.web.DefaultSecurityFilterChain,org.springframework.security.config.annotation.web.builders.HttpSecurity>

public final class ControlCenterSecurityConfigurer extends org.springframework.security.config.annotation.web.configurers.AbstractHttpConfigurer<ControlCenterSecurityConfigurer,org.springframework.security.config.annotation.web.builders.HttpSecurity>

A configurer for HttpSecurity builders designed to set up the security filter chain for Control Center.

Usage example:

@Configuration
@EnableWebSecurity
public class MyConfiguration {

    @Bean
    SecurityFilterChain mySecurityFilterChain(HttpSecurity http) throws Exception {
        return http.with(new ControlCenterSecurityConfigurer(), Customizer.withDefaults()).build();
    }
}
  • Method Summary

    Modifier and Type
    Method
    Description
    Provides a new instance of ControlCenterSecurityConfigurer that can be used to configure security for applications using Control Center.
    void
    init(org.springframework.security.config.annotation.web.builders.HttpSecurity http)
     

    Methods inherited from class org.springframework.security.config.annotation.web.configurers.AbstractHttpConfigurer

    disable, getSecurityContextHolderStrategy, withObjectPostProcessor, withObjectPostProcessor

    Methods inherited from class org.springframework.security.config.annotation.SecurityConfigurerAdapter

    addObjectPostProcessor, addObjectPostProcessor, and, configure, getBuilder, postProcess, setBuilder

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • controlCenter

      public static ControlCenterSecurityConfigurer controlCenter()
      Provides a new instance of ControlCenterSecurityConfigurer that can be used to configure security for applications using Control Center.
      Returns:
      a new instance of this configurer
    • init

      public void init(org.springframework.security.config.annotation.web.builders.HttpSecurity http) throws Exception
      Specified by:
      init in interface org.springframework.security.config.annotation.SecurityConfigurer<org.springframework.security.web.DefaultSecurityFilterChain,org.springframework.security.config.annotation.web.builders.HttpSecurity>
      Overrides:
      init in class org.springframework.security.config.annotation.SecurityConfigurerAdapter<org.springframework.security.web.DefaultSecurityFilterChain,org.springframework.security.config.annotation.web.builders.HttpSecurity>
      Throws:
      Exception