Class WebSecurityConfig

java.lang.Object
com.is.findyourplace.configuration.WebSecurityConfig

@Configuration @EnableWebSecurity public class WebSecurityConfig extends Object
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    configureGlobal(org.springframework.security.config.annotation.authentication.builders.AuthenticationManagerBuilder auth)
    Autowiring to encode with specified passwordEncoder.
    static org.springframework.security.crypto.password.PasswordEncoder
    Define the type of PasswordEncoder used for Authentication.
    org.springframework.security.web.SecurityFilterChain
    securityFilterChain(org.springframework.security.config.annotation.web.builders.HttpSecurity http)
    Define the security filter for every http.

    Methods inherited from class java.lang.Object

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

    • WebSecurityConfig

      public WebSecurityConfig()
  • Method Details

    • passwordEncoder

      @Bean public static org.springframework.security.crypto.password.PasswordEncoder passwordEncoder()
      Define the type of PasswordEncoder used for Authentication.
      Returns:
      BCryptPasswordEncoder
    • securityFilterChain

      @Bean public org.springframework.security.web.SecurityFilterChain securityFilterChain(org.springframework.security.config.annotation.web.builders.HttpSecurity http) throws Exception
      Define the security filter for every http.
      Parameters:
      http - link http passed
      Returns:
      Builded security http
      Throws:
      Exception - in case there is an error
    • configureGlobal

      @Autowired public void configureGlobal(org.springframework.security.config.annotation.authentication.builders.AuthenticationManagerBuilder auth) throws Exception
      Autowiring to encode with specified passwordEncoder.
      Parameters:
      auth - AuthenticationManagerBuilder
      Throws:
      Exception - in case of errors